Преглед на файлове

Default-enable apps, tests, and warnings for the root project

default_compile_flags
vector-of-bool преди 5 години
родител
ревизия
8bf05a557d
променени са 3 файла, в които са добавени 11 реда и са изтрити 14 реда
  1. +7
    -10
      src/dds/dds.main.cpp
  2. +3
    -3
      tests/dds.py
  3. +1
    -1
      tools/ci.py

+ 7
- 10
src/dds/dds.main.cpp Целия файл

@@ -488,15 +488,12 @@ struct cli_build {
"Download any missing dependencies from the catalog",
{"download-deps"}};

args::Flag build_tests{cmd, "build_tests", "Build and run the tests", {"tests", 'T'}};
args::Flag build_apps{cmd, "build_apps", "Build applications", {"apps", 'A'}};
args::Flag export_{cmd, "export", "Generate a library export", {"export", 'E'}};
args::Flag no_tests{cmd, "no-tests", "Do not build and run tests", {"no-tests"}};
args::Flag no_apps{cmd, "no-apps", "Do not compile and link applications", {"no-apps"}};
args::Flag no_warnings{cmd, "no-warings", "Disable build warnings", {"no-warnings"}};
toolchain_flag tc_filepath{cmd};

args::Flag enable_warnings{cmd,
"enable_warnings",
"Enable compiler warnings",
{"warnings", 'W'}};
args::Flag export_{cmd, "export", "Generate a library export", {"export", 'E'}};

path_flag
lm_index{cmd,
@@ -522,9 +519,9 @@ struct cli_build {
params.out_root = out.Get();
params.toolchain = tc_filepath.get_toolchain();
params.do_export = export_.Get();
params.build_tests = build_tests.Get();
params.build_apps = build_apps.Get();
params.enable_warnings = enable_warnings.Get();
params.build_tests = !no_tests.Get();
params.build_apps = !no_apps.Get();
params.enable_warnings = !no_warnings.Get();
params.parallel_jobs = num_jobs.Get();
dds::package_manifest man;
const auto man_filepath = params.root / "package.dds";

+ 3
- 3
tests/dds.py Целия файл

@@ -101,9 +101,9 @@ class DDS:
return self.run([
'build',
f'--out={self.build_dir}',
['--tests'] if tests else [],
['--apps'] if apps else [],
['--warnings'] if warnings else [],
['--no-tests'] if not tests else [],
['--no-apps'] if not apps else [],
['--no-warnings'] if not warnings else [],
['--export'] if export else [],
f'--toolchain={toolchain or self.default_builtin_toolchain}',
f'--lm-index={self.lmi_path}',

+ 1
- 1
tools/ci.py Целия файл

@@ -115,7 +115,7 @@ def main(argv: Sequence[str]) -> int:
self_build(
paths.CUR_BUILT_DDS,
toolchain=opts.toolchain,
dds_flags=['--warnings', '--tests', '--apps', f'--repo-dir={ci_repo_dir}'])
dds_flags=[f'--repo-dir={ci_repo_dir}'])
print('Bootstrap test PASSED!')

return pytest.main([

Loading…
Отказ
Запис