Bug 1500803 - Convert fxc2 to the mingw-clang toolchain r=froydnj
authorTom Ritter <tom@mozilla.com>
Sun, 21 Oct 2018 09:10:50 -0500
changeset 490918 918d2aeb31eb7d18603be0c5f6ae9b27c12b6fc2
parent 490917 12e986367fe985de767c4a32a9e5c7fadf824bdd
child 490919 969fc88ef9a4aa881650668a1ddc16318802ce5c
push id247
push userfmarier@mozilla.com
push dateSat, 27 Oct 2018 01:06:44 +0000
reviewersfroydnj
bugs1500803
milestone65.0a1
Bug 1500803 - Convert fxc2 to the mingw-clang toolchain r=froydnj This required bumping wine since the ucrt bits we needed are not in the old version of wine we were using.
taskcluster/ci/build/windows.yml
taskcluster/ci/toolchain/linux.yml
taskcluster/scripts/misc/build-mingw-fxc2-x86.sh
taskcluster/scripts/misc/build-mingw32-fxc2.sh
taskcluster/scripts/misc/build-wine.sh
--- a/taskcluster/ci/build/windows.yml
+++ b/taskcluster/ci/build/windows.yml
@@ -916,17 +916,17 @@ win32-mingwclang/opt:
         - mingw32-rust
         - linux64-upx
         - linux64-wine
         - linux64-sccache
         - linux64-cbindgen
         - linux64-node
         - linux64-clang-trunk-mingw-x86
         - linux64-mingw32-nsis
-        - linux64-mingw32-fxc2
+        - linux64-mingw-fxc2-x86
 
 win32-mingwclang/debug:
     description: "Win32 MinGW-Clang Debug"
     index:
         product: firefox
         job-name: win32-mingwclang-debug
     treeherder:
         platform: windows-mingw32/all
@@ -952,17 +952,17 @@ win32-mingwclang/debug:
         - mingw32-rust
         - linux64-upx
         - linux64-wine
         - linux64-sccache
         - linux64-cbindgen
         - linux64-node
         - linux64-clang-trunk-mingw-x86
         - linux64-mingw32-nsis
-        - linux64-mingw32-fxc2
+        - linux64-mingw-fxc2-x86
 
 win64-mingwclang/opt:
     description: "Win64 MinGW-Clang Opt"
     index:
         product: firefox
         job-name: win64-mingwclang-opt
     treeherder:
         platform: windows-mingw32/all
@@ -987,17 +987,17 @@ win64-mingwclang/opt:
         - mingw32-rust
         - linux64-upx
         - linux64-wine
         - linux64-sccache
         - linux64-cbindgen
         - linux64-node
         - linux64-clang-trunk-mingw-x64
         - linux64-mingw32-nsis
-        - linux64-mingw32-fxc2
+        - linux64-mingw-fxc2-x86
 
 win64-mingwclang/debug:
     description: "Win64 MinGW-Clang Debug"
     index:
         product: firefox
         job-name: win64-mingwclang-debug
     treeherder:
         platform: windows-mingw32/all
@@ -1023,9 +1023,9 @@ win64-mingwclang/debug:
         - mingw32-rust
         - linux64-upx
         - linux64-wine
         - linux64-sccache
         - linux64-cbindgen
         - linux64-node
         - linux64-clang-trunk-mingw-x64
         - linux64-mingw32-nsis
-        - linux64-mingw32-fxc2
+        - linux64-mingw-fxc2-x86
--- a/taskcluster/ci/toolchain/linux.yml
+++ b/taskcluster/ci/toolchain/linux.yml
@@ -805,28 +805,29 @@ linux64-mingw32-nsis:
         script: build-mingw32-nsis.sh
         resources:
             - 'build/unix/build-gcc/build-gcc.sh'
             - 'taskcluster/scripts/misc/build-gcc-mingw32.sh'
         toolchain-artifact: public/build/nsis.tar.xz
     toolchains:
         - linux64-mingw32-gcc
 
-linux64-mingw32-fxc2:
-    description: "fxc2.exe build for MinGW32 Cross Compile"
+linux64-mingw-fxc2-x86:
+    description: "fxc2.exe x86 build for MinGW Cross Compile"
     treeherder:
         kind: build
         platform: toolchains/opt
-        symbol: TMW(mingw32-fxc2)
+        symbol: TMW(mingw-fxc2-x86)
         tier: 2
     worker-type: aws-provisioner-v1/gecko-{level}-b-linux
     worker:
         docker-image: {in-tree: mingw32-build}
         max-run-time: 1800
     run:
         using: toolchain-script
-        script: build-mingw32-fxc2.sh
+        script: build-mingw-fxc2-x86.sh
         resources:
-            - 'build/unix/build-gcc/build-gcc.sh'
-            - 'taskcluster/scripts/misc/build-gcc-mingw32.sh'
+            - 'build/build-clang/build-clang.py'
+            - 'build/build-clang/clang-trunk-mingw.json'
+            - 'taskcluster/scripts/misc/build-clang-trunk-mingw.sh'
         toolchain-artifact: public/build/fxc2.tar.xz
     toolchains:
-        - linux64-mingw32-gcc
+        - linux64-clang-trunk-mingw-x86
rename from taskcluster/scripts/misc/build-mingw32-fxc2.sh
rename to taskcluster/scripts/misc/build-mingw-fxc2-x86.sh
--- a/taskcluster/scripts/misc/build-mingw32-fxc2.sh
+++ b/taskcluster/scripts/misc/build-mingw-fxc2-x86.sh
@@ -6,30 +6,29 @@ HOME_DIR=$WORKSPACE/build
 INSTALL_DIR=$WORKSPACE/fxc2
 TOOLTOOL_DIR=$WORKSPACE/build/src
 UPLOAD_DIR=$HOME/artifacts
 
 mkdir -p $INSTALL_DIR/bin
 
 cd $TOOLTOOL_DIR
 . taskcluster/scripts/misc/tooltool-download.sh
-export PATH="$TOOLTOOL_DIR/mingw32/bin:$PATH"
+export PATH="$TOOLTOOL_DIR/clang/bin:$PATH"
 
 cd $WORKSPACE
 
 # --------------
 
-git clone -n https://github.com/mozilla/fxc2.git fxc2-clone
+git clone -n https://github.com/tomrittervg/fxc2.git fxc2-clone
 cd fxc2-clone
-git checkout 82527b81104e5e21390d3ddcd328700c67ce73d4 # Asserts integrity of the clone (right?)
-make -j$(nproc)
+git checkout 502ef40807a472ba845f1cbdeac95ecab1aea2fd # Asserts integrity of the clone (right?)
+make -j$(nproc) x86
 
 cp fxc2.exe $INSTALL_DIR/bin/
-cp d3dcompiler_47.dll $INSTALL_DIR/bin/
-cp $TOOLTOOL_DIR/mingw32/i686-w64-mingw32/bin/libwinpthread-1.dll $INSTALL_DIR/bin/
+cp dll/d3dcompiler_47_32.dll $INSTALL_DIR/bin/d3dcompiler_47.dll
 
 # --------------
 
 cd $WORKSPACE
 tar caf fxc2.tar.xz fxc2
 
 mkdir -p $UPLOAD_DIR
 cp fxc2.tar.* $UPLOAD_DIR
--- a/taskcluster/scripts/misc/build-wine.sh
+++ b/taskcluster/scripts/misc/build-wine.sh
@@ -12,20 +12,19 @@ root_dir=$HOME_DIR
 data_dir=$HOME_DIR/src/build/unix/build-gcc
 
 . $data_dir/download-tools.sh
 
 cd $WORKSPACE
 
 # --------------
 $GPG --import $data_dir/DA23579A74D4AD9AF9D3F945CEFAC8EAAF17519D.key
-
-download_and_check http://dl.winehq.org/wine/source/2.0/ wine-2.0.1.tar.xz.sign
-tar xaf $TMPDIR/wine-2.0.1.tar.xz
-cd wine-2.0.1
+download_and_check http://dl.winehq.org/wine/source/3.0/ wine-3.0.3.tar.xz.sign
+tar xaf $TMPDIR/wine-3.0.3.tar.xz
+cd wine-3.0.3
 ./configure --prefix=$INSTALL_DIR/
 make -j$(nproc)
 make install
 
 # --------------
 
 cd $WORKSPACE/
 tar caf wine.tar.xz wine