diff --git a/bootstrap-jack2.sh b/bootstrap-jack2.sh index a02b735..8a8a834 100755 --- a/bootstrap-jack2.sh +++ b/bootstrap-jack2.sh @@ -145,3 +145,23 @@ if [ "${WIN32}" -eq 1 ]; then fi # --------------------------------------------------------------------------------------------------------------------- +# tre (win64 32bit build) +# NOTE this must be the last item to build + +if [ "${WIN64}" -eq 1 ]; then + target="win32" + source setup/check_target.sh + source setup/env.sh + PAWPAW_BUILDDIR="${PAWPAW_DIR}/builds/win64" + PAWPAW_PREFIX="${PAWPAW_DIR}/targets/win64" + source setup/functions.sh + + copy_download tre tre-x32 "${TRE_VERSION}" + build_autoconf tre-x32 "${TRE_VERSION}" "--disable-nls --libdir="${PAWPAW_PREFIX}"/lib32" + + if [ ! -e "${PAWPAW_PREFIX}/lib/libtre32.a" ]; then + ln -s "${PAWPAW_PREFIX}/lib32/libtre.a" "${PAWPAW_PREFIX}/lib/libtre32.a" + fi +fi + +# --------------------------------------------------------------------------------------------------------------------- diff --git a/build-jack2.sh b/build-jack2.sh index 03b450a..d067a1c 100755 --- a/build-jack2.sh +++ b/build-jack2.sh @@ -39,9 +39,7 @@ fi # jack2 jack2_args="--prefix=${jack2_prefix}" -# if [ "${MACOS_OLD}" -eq 1 ] || [ "${WIN64}" -eq 1 ]; then -# jack2_args="${jack2_args} --mixed" -# fi + if [ "${CROSS_COMPILING}" -eq 1 ]; then if [ "${LINUX}" -eq 1 ]; then jack2_args+=" --platform=linux" @@ -51,6 +49,7 @@ if [ "${CROSS_COMPILING}" -eq 1 ]; then jack2_args+=" --platform=win32" fi fi + if [ "${MACOS}" -eq 1 ]; then jack2_args+=" --prefix=${jack2_extra_prefix}" jack2_args+=" --destdir="${jack2_prefix}"" @@ -58,6 +57,16 @@ elif [ "${WIN32}" -eq 1 ]; then jack2_args+=" --static" fi +if [ "${WIN64}" -eq 1 ]; then + jack2_args="${jack2_args} --mixed" + # win32 toolchain prefix + TOOLCHAIN_PREFIX32=$(echo ${TOOLCHAIN_PREFIX} | sed 's/x86_64/i686/') + # let jack2 find win32 binaries + TARGET_PATH="${TARGET_PATH}:/usr/${TOOLCHAIN_PREFIX32}/bin" + # setup linker for our custom folder + export EXTRA_LDFLAGS="-L${PAWPAW_PREFIX}/lib32" +fi + if [ "${JACK2_VERSION}" = "git" ]; then if [ ! -d jack2 ]; then git clone --recursive "${jack2_repo}"