getopt.add_option('j', "jobs", jobs, GetOpt::REQUIRED_ARG).set_help("Run NUM commands at once, whenever possible.", "NUM");
getopt.add_option('n', "dry-run", dry_run, GetOpt::NO_ARG).set_help("Don't actually do anything, only show what would be done.");
getopt.add_option('v', "verbose", verbose, GetOpt::NO_ARG).set_help("Print more information about what's going on.");
+ getopt.add_option('x', "no-externals", no_externals, GetOpt::NO_ARG).set_help("Do not load external source packages.");
getopt.add_option('A', "conf-all", conf_all, GetOpt::NO_ARG).set_help("Apply configuration to all packages.");
getopt.add_option('B', "build-all", build_all, GetOpt::NO_ARG).set_help("Build all targets unconditionally.");
getopt.add_option('C', "chdir", work_dir, GetOpt::REQUIRED_ARG).set_help("Change to DIR before doing anything else.", "DIR");
if(i!=packages.end())
return i->second;
- FS::Path path = get_package_location(name);
- if(!path.empty() && !load_build_file(path/"Build"))
+ if(!no_externals)
{
- i = packages.find(name);
- if(i!=packages.end())
- return i->second;
+ FS::Path path = get_package_location(name);
+ if(!path.empty() && !load_build_file(path/"Build"))
+ {
+ i = packages.find(name);
+ if(i!=packages.end())
+ return i->second;
+ }
}
Package *pkg = 0;