summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTausif Rahman <tausif.rahman@mongodb.com>2022-06-06 21:10:06 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-06-13 22:25:04 +0000
commit6e3484f1eff8c5ab74d0ea8e63a33f5b89dc5f11 (patch)
tree2fdd0ca93ca76b35f0c3a7e7c1443875c6fc1200
parentef624aeecc379ae684b2106605b3675d7814a6d1 (diff)
downloadmongo-6e3484f1eff8c5ab74d0ea8e63a33f5b89dc5f11.tar.gz
SERVER-66441 Remove third_party shims for libraries with no --use-system support
-rw-r--r--src/mongo/shell/SConscript2
-rw-r--r--src/third_party/SConscript38
2 files changed, 14 insertions, 26 deletions
diff --git a/src/mongo/shell/SConscript b/src/mongo/shell/SConscript
index 6607afc5792..650f8f72f1f 100644
--- a/src/mongo/shell/SConscript
+++ b/src/mongo/shell/SConscript
@@ -212,7 +212,7 @@ if get_option('ssl') == 'on':
'$BUILD_DIR/mongo/db/matcher/expressions',
'$BUILD_DIR/mongo/scripting/scripting',
'$BUILD_DIR/mongo/shell/shell_options_register',
- '$BUILD_DIR/third_party/shim_mozjs',
+ '$BUILD_DIR/third_party/mozjs/mozjs',
'kms',
],
)
diff --git a/src/third_party/SConscript b/src/third_party/SConscript
index 72abf90022b..4eb7c79d9c8 100644
--- a/src/third_party/SConscript
+++ b/src/third_party/SConscript
@@ -32,6 +32,15 @@ thirdPartyEnvironmentModifications = {
'timelib': {'CPPPATH': ['#/src/third_party/timelib' + timelibSuffix], },
'unwind': {},
'variant': {'CPPPATH': ['#src/third_party/variant' + variantSuffix + '/include'], },
+ 'mozjs': {
+ 'CPPPATH': [
+ '#/src/third_party/mozjs/include',
+ '#/src/third_party/mozjs/mongo_sources',
+ '#/src/third_party/mozjs/platform/' + env["TARGET_ARCH"] + "/" + env["TARGET_OS"] +
+ "/include",
+ ],
+ 'FORCEINCLUDES': ['js-config.h', ],
+ }
}
@@ -124,21 +133,6 @@ if not use_system_version_of_library('google-benchmark'):
'CPPPATH': ['#/src/third_party/benchmark/dist/include'],
}
-# TODO: figure out if we want to offer system versions of mozjs. Mozilla
-# hasn't offered a source tarball since 24, but in theory they could.
-#
-#if not use_system_version_of_library('mozjs'):
-if True:
- thirdPartyEnvironmentModifications['mozjs'] = {
- 'CPPPATH': [
- '#/src/third_party/mozjs/include',
- '#/src/third_party/mozjs/mongo_sources',
- '#/src/third_party/mozjs/platform/' + env["TARGET_ARCH"] + "/" + env["TARGET_OS"] +
- "/include",
- ],
- 'FORCEINCLUDES': ['js-config.h', ],
- }
-
if "tom" in env["MONGO_CRYPTO"]:
thirdPartyEnvironmentModifications['tomcrypt'] = {
'CPPPATH': ['#/src/third_party/tomcrypt' + tomcryptSuffix + '/src/headers'],
@@ -269,6 +263,10 @@ s2Env.InjectThirdParty(libraries=[
s2Env.InjectMongoIncludePaths()
s2Env.SConscript('s2/SConscript', exports={'env': s2Env})
+if jsEngine:
+ mozjsEnv = env.Clone()
+ mozjsEnv.SConscript('mozjs/SConscript', exports={'env': mozjsEnv})
+
if use_libunwind:
unwindEnv = env.Clone(LIBDEPS_NO_INHERIT=[
'$BUILD_DIR/third_party/shim_allocator',
@@ -448,16 +446,6 @@ else:
benchmarkEnv.ShimLibrary(name="benchmark")
-if jsEngine:
- mozjsEnv = env.Clone()
- mozjsEnv.SConscript('mozjs/SConscript', exports={'env': mozjsEnv})
- mozjsEnv = mozjsEnv.Clone(LIBDEPS_INTERFACE=[
- 'mozjs/mozjs',
- 'shim_zlib',
- ])
-
- mozjsEnv.ShimLibrary(name="mozjs")
-
if "tom" in env["MONGO_CRYPTO"]:
tomcryptEnv = env.Clone()
tomcryptEnv.SConscript(