aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorAlexander Neumann <30894796+Neumann-A@users.noreply.github.com>2020-10-13 20:06:31 +0200
committerGitHub <noreply@github.com>2020-10-13 11:06:31 -0700
commite14917f04b2a79b22087cab67ab80c0e3d47c8ba (patch)
treeb64e9e5080f75d388afcda8a51ff87379b06bd2d /scripts
parentbf7985127550bc93da55c721eb629b25e04d5349 (diff)
downloadvcpkg-e14917f04b2a79b22087cab67ab80c0e3d47c8ba.tar.gz
vcpkg-e14917f04b2a79b22087cab67ab80c0e3d47c8ba.zip
[vcpkg/configure_make] add USE_WRAPPERS option (#14000)
* [vcpkg/configure_make] add USE_WRAPPERS option * Move env setting for wrapper to correct spot
Diffstat (limited to 'scripts')
-rw-r--r--scripts/cmake/vcpkg_configure_make.cmake11
1 files changed, 8 insertions, 3 deletions
diff --git a/scripts/cmake/vcpkg_configure_make.cmake b/scripts/cmake/vcpkg_configure_make.cmake
index 668316746..ac13253c1 100644
--- a/scripts/cmake/vcpkg_configure_make.cmake
+++ b/scripts/cmake/vcpkg_configure_make.cmake
@@ -7,6 +7,7 @@
## vcpkg_configure_make(
## SOURCE_PATH <${SOURCE_PATH}>
## [AUTOCONFIG]
+## [USE_WRAPPERS]
## [BUILD_TRIPLET "--host=x64 --build=i686-unknown-pc"]
## [NO_ADDITIONAL_PATHS]
## [CONFIG_DEPENDENT_ENVIRONMENT <SOME_VAR>...]
@@ -34,6 +35,9 @@
## ### SKIP_CONFIGURE
## Skip configure process
##
+## ### USE_WRAPPERS
+## Use autotools ar-lib and compile wrappers (only applies to windows cl and lib)
+##
## ### BUILD_TRIPLET
## Used to pass custom --build/--target/--host to configure. Can be globally overwritten by VCPKG_MAKE_BUILD_TRIPLET
##
@@ -220,7 +224,6 @@ function(vcpkg_configure_make)
list(APPEND MSYS_REQUIRE_PACKAGES binutils libtool autoconf automake-wrapper automake1.16 m4)
vcpkg_acquire_msys(MSYS_ROOT PACKAGES ${MSYS_REQUIRE_PACKAGES})
# This inserts msys before system32 (which masks sort.exe and find.exe) but after MSVC (which avoids masking link.exe)
- set(APPEND_ENV)
if (_csc_AUTOCONFIG)
# --build: the machine you are building on
# --host: the machine you are building for
@@ -240,9 +243,11 @@ function(vcpkg_configure_make)
endif()
endif()
debug_message("Using make triplet: ${_csc_BUILD_TRIPLET}")
+ endif()
+ set(APPEND_ENV)
+ if(_csc_AUTOCONFIG OR _csc_USE_WRAPPERS)
set(APPEND_ENV ";${MSYS_ROOT}/usr/share/automake-1.16")
endif()
-
string(REPLACE ";$ENV{SystemRoot}\\System32;" "${APPEND_ENV};${MSYS_ROOT}/usr/bin;$ENV{SystemRoot}\\System32;" NEWPATH "$ENV{PATH}")
string(REPLACE ";$ENV{SystemRoot}\\system32;" "${APPEND_ENV};${MSYS_ROOT}/usr/bin;$ENV{SystemRoot}\\system32;" NEWPATH "$ENV{PATH}")
set(ENV{PATH} "${NEWPATH}")
@@ -258,7 +263,7 @@ function(vcpkg_configure_make)
endmacro()
set(CONFIGURE_ENV "V=1")
- if (_csc_AUTOCONFIG) # without autotools we assume a custom configure script which correctly handles cl and lib. Otherwise the port needs to set CC|CXX|AR and probably CPP
+ if (_csc_AUTOCONFIG OR _csc_USE_WRAPPERS)
_vcpkg_append_to_configure_environment(CONFIGURE_ENV CPP "compile cl.exe -nologo -E")
_vcpkg_append_to_configure_environment(CONFIGURE_ENV CC "compile cl.exe -nologo")
_vcpkg_append_to_configure_environment(CONFIGURE_ENV CXX "compile cl.exe -nologo")