File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ set -o errexit
44
55pacman -S --noconfirm \
66 mingw-w64-ucrt-x86_64-gcc\
7+ mingw-w64-ucrt-x86_64-llvm-tools\
78 mingw-w64-ucrt-x86_64-tools-git\
89 m4\
910 make\
@@ -19,28 +20,16 @@ bin/build_dependencies_unix.sh \
1920 --patch-C23\
2021 #
2122
22- # Assumes the standard GitHub Actions Windows 2022 runner layout.
23- PATH=" $PATH :$( find " /c/Program Files/Microsoft Visual Studio/2022/" -name " Hostx86" ) /x64/"
24-
2523mkdir -p .local/lib
2624cd .local/bin
2725for dll_file in libgmp-* .dll libmpfr-* .dll libflint* .dll
2826do
29- lib_name=$( basename -s .dll ${dll_file} )
30- exports_file=${lib_name} -exports.txt
27+ lib_name=$( basename -s .dll " ${dll_file} " )
3128 def_file=${lib_name} .def
32- lib_file=${lib_name} .lib
33- name=$( echo ${lib_name} | sed ' s/^lib//;s/[-.][0-9].*$//' )
34-
35- dumpbin //exports ${dll_file} > ${exports_file}
36-
37- echo LIBRARY ${lib_name} > ${def_file}
38- echo EXPORTS >> ${def_file}
39- awk ' NR>19 && $4 != "" {print $4 " @"$1}' ${exports_file} >> ${def_file}
40- sed -i ' s/$/\r/' ${def_file}
29+ name=$( echo " ${lib_name} " | sed ' s/^lib//;s/[-.][0-9].*$//' )
4130
42- lib //def: ${def_file} //out: ${lib_file} //machine:x64
43- rm ${exports_file} ${ def_file} ${lib_name} .exp
44- mv ${lib_file} ../lib/ ${name} .lib
31+ gendef " ${dll_file} "
32+ llvm-lib /def: " ${ def_file}" /out: " ../lib/ ${name} .lib " /machine:x64 /nologo
33+ rm " ${def_file} "
4534done
4635cd ../..
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ set -o errexit
44
55pacman -S --noconfirm \
66 mingw-w64-clang-aarch64-toolchain\
7+ mingw-w64-clang-aarch64-llvm-tools\
78 mingw-w64-clang-aarch64-tools-git\
89 m4\
910 make\
@@ -22,27 +23,16 @@ bin/build_dependencies_unix.sh \
2223 --patch-ldd\
2324 #
2425
25- PATH=" $PATH :$( find " /c/Program Files/Microsoft Visual Studio/2022/" -name " Hostx86" ) /x64/"
26-
2726mkdir -p .local/lib
2827cd .local/bin
2928for dll_file in libgmp-* .dll libmpfr-* .dll libflint* .dll
3029do
31- lib_name=$( basename -s .dll ${dll_file} )
32- exports_file=${lib_name} -exports.txt
30+ lib_name=$( basename -s .dll " ${dll_file} " )
3331 def_file=${lib_name} .def
34- lib_file=${lib_name} .lib
35- name=$( echo ${lib_name} | sed ' s/^lib//;s/[-.][0-9].*$//' )
36-
37- dumpbin //exports ${dll_file} > ${exports_file}
38-
39- echo LIBRARY ${lib_name} > ${def_file}
40- echo EXPORTS >> ${def_file}
41- awk ' NR>19 && $4 != "" {print $4 " @"$1}' ${exports_file} >> ${def_file}
42- sed -i ' s/$/\r/' ${def_file}
32+ name=$( echo " ${lib_name} " | sed ' s/^lib//;s/[-.][0-9].*$//' )
4333
44- lib //def: ${def_file} //out: ${lib_file} //machine:arm64
45- rm ${exports_file} ${ def_file} ${lib_name} .exp
46- mv ${lib_file} ../lib/ ${name} .lib
34+ gendef " ${dll_file} "
35+ llvm-lib /def: " ${ def_file}" /out: " ../lib/ ${name} .lib " /machine:arm64 /nologo
36+ rm " ${def_file} "
4737done
4838cd ../..
You can’t perform that action at this time.
0 commit comments