From 8a2c4b805bc87d05381d0897b41d71e30f50019b Mon Sep 17 00:00:00 2001 From: Magnus Jacobsson Date: Sun, 3 Oct 2021 15:18:26 +0200 Subject: [PATCH] ci/build.sh: autotools: excplicitly specify the tclsh for MinGW Fixes these errors when using autotools with MinGW: C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: .libs/gdtclft.o: in function `tclGdWriteCmd': C:\Users\magja\graphviz\tclpkg\gdtclft/gdtclft.c:560: undefined reference to `Tcl_GetOpenFile' C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: .libs/gdtclft.o: in function `tclGdCreateCmd': C:\Users\magja\graphviz\tclpkg\gdtclft/gdtclft.c:450: undefined reference to `Tcl_GetOpenFile' C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: .libs/gdtclft.o: in function `Gdtclft_Init': C:\Users\magja\graphviz\tclpkg\gdtclft/gdtclft.c:1278: undefined reference to `Tcl_InitStubs' C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: .libs/gdtclft.o:gdtclft.c:(.rdata$.refptr.tclStubsPtr[.refptr.tclStubsPtr]+0x0): undefined reference to `tclStubsPtr' C:/tools/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: ../../tclpkg/tclstubs/.libs/libtclstubs_C.a(tclStubLib.o): in function `tclstubs_dummy': C:\Users\magja\graphviz\tclpkg\tclstubs/tclStubLib.c:17: undefined reference to `Tcl_InitStubs' --- ci/build.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ci/build.sh b/ci/build.sh index b95950f24..b3cf1c64e 100755 --- a/ci/build.sh +++ b/ci/build.sh @@ -80,6 +80,10 @@ else tar cfz graphviz-${GV_VERSION}-${ARCH}.tar.gz --options gzip:compression-level=9 build mv graphviz-${GV_VERSION}-${ARCH}.tar.gz ${DIR}/ elif [ "${OSTYPE}" = "cygwin" -o "${OSTYPE}" = "msys" ]; then + if [ "${OSTYPE}" = "msys" ]; then + # ensure that MinGW tcl shell is used in order to find tcl functions + CONFIGURE_OPTIONS="${CONFIGURE_OPTIONS:-} --with-tclsh=${MSYSTEM_PREFIX}/bin/tclsh86" + fi if [ "${use_autogen:-no}" = "yes" ]; then ./autogen.sh ./configure ${CONFIGURE_OPTIONS:-} --prefix=$( pwd )/build | tee >(./ci/extract-configure-log.sh >${META_DATA_DIR}/configure.log) -- 2.40.0