Skip to content

Commit c484689

Browse files
committed
Disable LTO
1 parent 70a3547 commit c484689

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

.github/workflows/release-binaries.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -158,10 +158,15 @@ jobs:
158158
159159
build_flang="true"
160160
161-
#if [ "$RUNNER_OS" = "Windows" ]; then
162-
# The build times out on Windows, so we need to disable LTO.
163-
#target_cmake_flags="$target_cmake_flags -DLLVM_RELEASE_ENABLE_LTO=OFF"
164-
#fi
161+
if [ "$RUNNER_OS" = "Windows" ]; then
162+
# LTO causes the WiX generator to crash so we need to disable it:
163+
# light.exe : error LGHT0001 : Catastrophic failure (Exception from HRESULT: 0x8000FFFF (E_UNEXPECTED))
164+
# Stack Trace:
165+
# at Microsoft.Tools.WindowsInstallerXml.Cab.Interop.NativeMethods.CreateCabFinish(IntPtr contextHandle, IntPtr newCabNamesCallBackAddress)
166+
# at Microsoft.Tools.WindowsInstallerXml.Cab.WixCreateCab.Complete(IntPtr newCabNamesCallBackAddress)
167+
# at Microsoft.Tools.WindowsInstallerXml.CabinetBuilder.CreateCabinet(CabinetWorkItem cabinetWorkItem)
168+
target_cmake_flags="$target_cmake_flags -DLLVM_RELEASE_ENABLE_LTO=OFF"
169+
fi
165170
166171
echo "target-cmake-flags=$target_cmake_flags" >> $GITHUB_OUTPUT
167172
echo "build-flang=$build_flang" >> $GITHUB_OUTPUT

0 commit comments

Comments
 (0)