wownero/contrib/depends/packages/cmake/conf/target-cmake.in
TheCharlatan 8db3d5731b Modify depends for monero's dependencies
Add readline, ldns, graphviz, unbound to depends packages

Add a cmake toolchain file to depends that is uniquely created for every build and placed in triple/share/toolchain.cmake
This file is then passed to cmake with -DCMAKE_TOOLCHAIN_FILE=/path/to/triple/share/toolchain.cmake

Add the boost locale package to depends

In the depends cmake toolchain file, a DEPENDS flag is added
to exclude, or change cmake checks done that are required for depends

Link miniupnpc and unwind from depends and not external

Add libiconv and icu4c to depends, required for mingw32 builds.

Headers (winsock) need to be lower case in order to compile on unix systems.
This should not affect building on windows.
2018-09-10 22:03:42 +02:00

29 lines
1.2 KiB
Bash

#!/usr/bin/env bash
echo "== Using MXE wrapper: @PREFIX@/bin/@TARGET@-cmake"
# https://cmake.org/cmake/help/latest/manual/cmake-policies.7.html
# https://cmake.org/cmake/help/latest/variable/CMAKE_POLICY_DEFAULT_CMPNNNN.html
POLICIES=(0017,0020)
unset NO_MXE_TOOLCHAIN
if echo -- "$@" | grep -Ewq "(--build|-E|--system-information)" ; then
NO_MXE_TOOLCHAIN=1
fi
if [[ "$NO_MXE_TOOLCHAIN" == "1" ]]; then
echo "== Skip using MXE toolchain: @CMAKE_TOOLCHAIN_FILE@"
# see https://github.com/mxe/mxe/issues/932
exec "@PREFIX@/@BUILD@/bin/cmake" "$@"
else
echo " - cmake version @CMAKE_VERSION@"
echo " - warnings for unused CMAKE_POLICY_DEFAULT variables can be ignored"
echo "== Using MXE toolchain: @CMAKE_TOOLCHAIN_FILE@"
echo "== Using MXE runresult: @CMAKE_RUNRESULT_FILE@"
if ! ( echo "$@" | grep --silent "DCMAKE_BUILD_TYPE" ) ; then
echo '== Adding "-DCMAKE_BUILD_TYPE=Release"'
set -- "-DCMAKE_BUILD_TYPE=Release" "$@"
fi
exec "@PREFIX@/@BUILD@/bin/cmake" \
-DCMAKE_TOOLCHAIN_FILE="@CMAKE_TOOLCHAIN_FILE@" \
`eval echo -DCMAKE_POLICY_DEFAULT_CMP{$POLICIES}=NEW` \
-C"@CMAKE_RUNRESULT_FILE@" "$@"
fi