Kaydet (Commit) a6c22d4e authored tarafından Stephan Bergmann's avatar Stephan Bergmann

Allow CXX_X86_BINARY to be passed into autogen.sh

This is necessary for building with clang-cl, where $CXX_X86_BINARY needs to
match $CXX (i.e., both invoke clang-cl) so that the compiler switches (which
have been determined based on the nature of $CXX, i.e., are Clang-specific when
$CXX is clang-cl) passed to $CXX_X86_BINARY are actually understood by it.
(Building extensions/source/scanner/twain32shim.cxx failed with "cl : Command
line error D8021 : invalid numeric argument '/Wendif-labels'".)

For now, my local clang-cl build will just pass a suitable CXX_X86_BINARY
similar to the passed CXX (but with --target=i686-pc-windows-msvc -arch:SSE
instead of --target=x86_64-pc-windows-msvc) into autogen.sh.

Change-Id: Id958525f97e1d16f17af49e0b0288c1018885749
Reviewed-on: https://gerrit.libreoffice.org/67228
Tested-by: Jenkins
Reviewed-by: 's avatarStephan Bergmann <sbergman@redhat.com>
üst 4d3571a3
......@@ -3610,15 +3610,18 @@ if test "$_os" = "WINNT"; then
# needed to support TWAIN scan on both 32- and 64-bit systems
BUILD_X86=
CXX_X86_BINARY=
if test "$BITNESS_OVERRIDE" = "64"; then
AC_MSG_CHECKING([for a x86 compiler and libraries for 32-bit binaries required for TWAIN support])
if "$VC_PRODUCT_DIR/Tools/MSVC/$vcbuildnumber/bin/HostX86/x86/cl.exe" -? </dev/null >/dev/null 2>&1; then
if test -n "$CXX_X86_BINARY"; then
BUILD_X86=TRUE
AC_MSG_RESULT([preset])
elif "$VC_PRODUCT_DIR/Tools/MSVC/$vcbuildnumber/bin/HostX86/x86/cl.exe" -? </dev/null >/dev/null 2>&1; then
BUILD_X86=TRUE
CXX_X86_BINARY="$VC_PRODUCT_DIR/Tools/MSVC/$vcbuildnumber/bin/HostX86/x86/cl.exe -arch:SSE"
AC_MSG_RESULT([found])
else
CXX_X86_BINARY=
AC_MSG_RESULT([not found])
AC_MSG_WARN([Installation set will not contain 32-bit binaries required for TWAIN support])
fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment