summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Moody <daniel.moody@mongodb.com>2022-08-19 14:52:21 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-08-19 15:52:01 +0000
commit61b444d5fe82e6ebfd0bb847500b9aa2a5d4de96 (patch)
tree492eab15ca0cbca0ae5260a34c86691027c00e7b
parent36e1574c92a0d89844c55d678e0aea5f3e4cc891 (diff)
downloadmongo-61b444d5fe82e6ebfd0bb847500b9aa2a5d4de96.tar.gz
SERVER-68116 switch to no unittest alias for static builders.
-rwxr-xr-xSConstruct13
-rw-r--r--etc/evergreen_yml_components/definitions.yml21
-rw-r--r--etc/evergreen_yml_components/variants/sanitizer.yml6
3 files changed, 35 insertions, 5 deletions
diff --git a/SConstruct b/SConstruct
index 7637ab4cabb..6a05dc2750f 100755
--- a/SConstruct
+++ b/SConstruct
@@ -6142,6 +6142,19 @@ env.Alias('configure', None)
# auto_install_binaries to finalize the installation setup.
env.FinalizeInstallDependencies()
+# Create a install-all-meta alias that excludes unittests. This is most useful in
+# static builds where the resource requirements of linking 100s of static unittest
+# binaries is prohibitive.
+candidate_nodes = set([
+ str(gchild) for gchild in env.Flatten(
+ [child.all_children() for child in env.Alias('install-all-meta')[0].all_children()])
+])
+names = [f'install-{env["AIB_META_COMPONENT"]}', 'install-tests', env["UNITTEST_ALIAS"]]
+env.Alias('install-all-meta-but-not-unittests', [
+ node for node in candidate_nodes if str(node) not in names
+ and not str(node).startswith(tuple([prefix_name + '-' for prefix_name in names]))
+])
+
# We don't want installing files to cause them to flow into the cache,
# since presumably we can re-install them from the origin if needed.
env.NoCache(env.FindInstalledFiles())
diff --git a/etc/evergreen_yml_components/definitions.yml b/etc/evergreen_yml_components/definitions.yml
index 86dbeff99a6..404e5c6b9ca 100644
--- a/etc/evergreen_yml_components/definitions.yml
+++ b/etc/evergreen_yml_components/definitions.yml
@@ -2426,6 +2426,16 @@ tasks:
targets: install-all-meta
compiling_for_test: true
+- name: compile_all_but_not_unittests
+ tags: []
+ depends_on:
+ - name: compile_dist_test
+ commands:
+ - func: "scons compile"
+ vars:
+ targets: install-all-meta-but-not-unittests
+ compiling_for_test: true
+
## clang_tidy - run clang_tidy
- name: clang_tidy
tags: []
@@ -7516,8 +7526,9 @@ task_groups:
- compile_all
- package
-# The *no_unittests_TG taskgroups remove compile/run unittests to work around
-# limitations in the size of debug info. See SERVER-68024.
+# The *no_unittests_TG taskgroups are useful for static builds,
+# were the static binaries of the unittests can take up to
+# a terabyte of data.
- <<: *compile_task_group_template
name: compile_test_and_package_serial_no_unittests_TG
tasks:
@@ -7527,6 +7538,7 @@ task_groups:
- compile_dbtest
- run_dbtest
- archive_dbtest
+ - compile_all_but_not_unittests
- package
- <<: *compile_task_group_template
@@ -7541,8 +7553,12 @@ task_groups:
- run_dbtest
- archive_dbtest
- compile_upload_benchmarks
+ - compile_all
- package
+# The *no_unittests_TG taskgroups are useful for static builds,
+# were the static binaries of the unittests can take up to
+# a terabyte of data.
- <<: *compile_task_group_template
name: compile_test_benchmark_and_package_serial_no_unittests_TG
tasks:
@@ -7553,6 +7569,7 @@ task_groups:
- run_dbtest
- archive_dbtest
- compile_upload_benchmarks
+ - compile_all_but_not_unittests
- package
- <<: *compile_task_group_template
diff --git a/etc/evergreen_yml_components/variants/sanitizer.yml b/etc/evergreen_yml_components/variants/sanitizer.yml
index 8530fbc2dab..6034e09cccc 100644
--- a/etc/evergreen_yml_components/variants/sanitizer.yml
+++ b/etc/evergreen_yml_components/variants/sanitizer.yml
@@ -23,7 +23,7 @@ buildvariants:
test_flags: --excludeWithAnyTags=requires_fast_memory,requires_ocsp_stapling
separate_debug: off
tasks:
- - name: compile_test_and_package_serial_no_unittests_TG
+ - name: compile_test_and_package_serial_TG
- name: .aggfuzzer .common !.feature_flag_guarded
- name: free_monitoring
- name: .jstestfuzz !.initsync
@@ -55,7 +55,7 @@ buildvariants:
separate_debug: off
large_distro_name: rhel80-build
tasks:
- - name: compile_test_benchmark_and_package_serial_no_unittests_TG
+ - name: compile_test_benchmark_and_package_serial_TG
- name: .aggregation !.feature_flag_guarded
- name: .auth
- name: audit
@@ -126,7 +126,7 @@ buildvariants:
separate_debug: off
large_distro_name: rhel80-build
tasks:
- - name: compile_test_benchmark_and_package_serial_no_unittests_TG
+ - name: compile_test_benchmark_and_package_serial_TG
- name: .aggregation !.feature_flag_guarded
- name: .auth
- name: audit