- } else if (strncmp("as=", opt, 3) == 0) {
- if (as_path) {
- (*message)(LDPL_WARNING, "Path to as specified twice. "
- "Discarding %s", opt);
+ } else if (opt.startswith("mcpu=")) {
+ mcpu = opt.substr(strlen("mcpu="));
+ } else if (opt.startswith("extra-library-path=")) {
+ extra_library_path = opt.substr(strlen("extra_library_path="));
+ } else if (opt.startswith("mtriple=")) {
+ triple = opt.substr(strlen("mtriple="));
+ } else if (opt.startswith("obj-path=")) {
+ obj_path = opt.substr(strlen("obj-path="));
+ } else if (opt == "emit-llvm") {
+ generate_bc_file = BC_ONLY;
+ } else if (opt == "also-emit-llvm") {
+ generate_bc_file = BC_ALSO;
+ } else if (opt.startswith("also-emit-llvm=")) {
+ llvm::StringRef path = opt.substr(strlen("also-emit-llvm="));
+ generate_bc_file = BC_ALSO;
+ if (!bc_path.empty()) {
+ (*message)(LDPL_WARNING, "Path to the output IL file specified twice. "
+ "Discarding %s", opt_);