summaryrefslogtreecommitdiffstats
path: root/js/src/devtools/automation/winbuildenv.sh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 14:29:10 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 14:29:10 +0000
commit2aa4a82499d4becd2284cdb482213d541b8804dd (patch)
treeb80bf8bf13c3766139fbacc530efd0dd9d54394c /js/src/devtools/automation/winbuildenv.sh
parentInitial commit. (diff)
downloadfirefox-upstream.tar.xz
firefox-upstream.zip
Adding upstream version 86.0.1.upstream/86.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'js/src/devtools/automation/winbuildenv.sh')
-rw-r--r--js/src/devtools/automation/winbuildenv.sh32
1 files changed, 32 insertions, 0 deletions
diff --git a/js/src/devtools/automation/winbuildenv.sh b/js/src/devtools/automation/winbuildenv.sh
new file mode 100644
index 0000000000..7fa10807df
--- /dev/null
+++ b/js/src/devtools/automation/winbuildenv.sh
@@ -0,0 +1,32 @@
+mk_export_correct_style() {
+ echo "export $1=$(cmd.exe //c echo %$1%)"
+}
+
+topsrcdir="$SOURCE"
+
+# Tooltool installs in parent of topsrcdir for spidermonkey builds.
+# Resolve that path since the mozconfigs assume tooltool installs in
+# topsrcdir.
+export VSPATH="$(cd ${topsrcdir}/.. && pwd)/vs2017_15.8.4"
+
+if [ -n "$USE_64BIT" ]; then
+ . $topsrcdir/build/win64/mozconfig.vs-latest
+else
+ . $topsrcdir/build/win32/mozconfig.vs-latest
+fi
+
+mk_export_correct_style CC
+mk_export_correct_style CXX
+mk_export_correct_style LINKER
+mk_export_correct_style WINDOWSSDKDIR
+mk_export_correct_style DIA_SDK_PATH
+mk_export_correct_style VC_PATH
+
+# PATH also needs to point to mozmake.exe, which can come from either
+# newer mozilla-build or tooltool.
+if ! which mozmake 2>/dev/null; then
+ export PATH="$PATH:$SOURCE/.."
+ if ! which mozmake 2>/dev/null; then
+ ( cd $SOURCE/..; $SOURCE/mach artifact toolchain -v --tooltool-manifest $SOURCE/browser/config/tooltool-manifests/${platform:-win32}/releng.manifest --retry 4${TOOLTOOL_CACHE:+ --cache-dir ${TOOLTOOL_CACHE}})
+ fi
+fi