Wire comparator CLI, marionette threading model, and final load order.
Initialize SmoThreadingModelDesc from marionette before body startup, load comparator libs before stimbuff via -c/--comparator-lib, and drop the hardcoded libcomparatorCore.so load path. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+14
-1
@@ -43,6 +43,9 @@ struct option OptionParser::longOptions[] = {
|
||||
{"api-lib-path", required_argument, 0, 'p'},
|
||||
{"apipath", required_argument, 0, 'p'},
|
||||
{"libpath", required_argument, 0, 'p'},
|
||||
{"comparator-lib", required_argument, 0, 'c'},
|
||||
{"comp-lib", required_argument, 0, 'c'},
|
||||
{"complib", required_argument, 0, 'c'},
|
||||
{"verbose", no_argument, 0, 'v'},
|
||||
{"trace-callables", no_argument, 0, 't'},
|
||||
{"call-trace", no_argument, 0, 't'},
|
||||
@@ -62,7 +65,7 @@ void OptionParser::parseArguments(int argc, char *argv[], char **envp)
|
||||
optind = 1; // Reset optind to 1 before parsing
|
||||
opterr = 0;
|
||||
while ((opt = getopt_long(
|
||||
argc, argv, "s:d:a:p:vht?", longOptions, &optionIndex)) != -1)
|
||||
argc, argv, "s:d:a:p:c:vht?", longOptions, &optionIndex)) != -1)
|
||||
{
|
||||
switch (opt)
|
||||
{
|
||||
@@ -92,6 +95,9 @@ void OptionParser::parseArguments(int argc, char *argv[], char **envp)
|
||||
senseApiLibPath.push_back(optarg);
|
||||
break;
|
||||
}
|
||||
case 'c':
|
||||
comparatorLibs.push_back(optarg);
|
||||
break;
|
||||
case 'v':
|
||||
verbose = true;
|
||||
break;
|
||||
@@ -115,6 +121,7 @@ std::string OptionParser::getUsage() const
|
||||
return "Usage: " + argv0 + " [-s|--dapspec|--spec <device_spec>] "
|
||||
"[-d|--dapfile <DAP_spec_file>] "
|
||||
"[-a|--api-lib|--apilib|--api|--lib <filename>] "
|
||||
"[-c|--comparator-lib|--comp-lib|--complib <filename>] "
|
||||
"[-p|--api-lib-path|--apipath|--libpath <directory>] "
|
||||
"[-v|--verbose] "
|
||||
"[-t|--trace-callables|--call-trace|--calltrace] "
|
||||
@@ -154,5 +161,11 @@ std::string OptionParser::stringifyOptions(void) const
|
||||
}
|
||||
oss << std::endl;
|
||||
|
||||
oss << "Comparator Libraries: ";
|
||||
for (const auto& lib : comparatorLibs) {
|
||||
oss << lib << " ";
|
||||
}
|
||||
oss << std::endl;
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user