From f37f8d9fd7fad8986aa412846c96cefe7fb993da Mon Sep 17 00:00:00 2001 From: Kevin Lalumiere Date: Mon, 26 Apr 2021 20:55:46 -0400 Subject: [PATCH 1/4] Add triplet option VCPKG_NO_COMPILER_TRACKING --- scripts/detect_compiler/portfile.cmake | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/scripts/detect_compiler/portfile.cmake b/scripts/detect_compiler/portfile.cmake index 4f68faea46936b..e6ff70a6c26bf4 100644 --- a/scripts/detect_compiler/portfile.cmake +++ b/scripts/detect_compiler/portfile.cmake @@ -1,3 +1,15 @@ +if(VCPKG_NO_COMPILER_TRACKING) + string(SHA1 hash "nocompilertracking") + message("#COMPILER_HASH#${hash}") + message("#COMPILER_C_HASH#${hash}") + message("#COMPILER_C_VERSION#nocompilertracking") + message("#COMPILER_C_ID#nocompilertracking") + message("#COMPILER_CXX_HASH#${hash}") + message("#COMPILER_CXX_VERSION#nocompilertracking") + message("#COMPILER_CXX_ID#nocompilertracking") + return() +endif() + set(LOGS ${CURRENT_BUILDTREES_DIR}/config-${TARGET_TRIPLET}-out.log ${CURRENT_BUILDTREES_DIR}/config-${TARGET_TRIPLET}-rel-out.log From b689ad55c74ae2c27d23a9bc4c44d340dd0e7133 Mon Sep 17 00:00:00 2001 From: Kevin Lalumiere Date: Tue, 27 Apr 2021 10:22:12 -0400 Subject: [PATCH 2/4] Adds documentation --- docs/users/triplets.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/users/triplets.md b/docs/users/triplets.md index 3ebc6bd8e16fec..afc26bc53bfece 100644 --- a/docs/users/triplets.md +++ b/docs/users/triplets.md @@ -99,6 +99,10 @@ See the [`"supports"`](../maintainers/manifest-files.md#supports) manifest file > Implementers' Note: this list is extracted via the `vcpkg_get_dep_info` mechanism. +### VCPKG_NO_COMPILER_TRACKING + +When this option is set to (true|1|on), the compiler is ignored in the abi tracking. + ## Windows Variables ### VCPKG_ENV_PASSTHROUGH From 8a9da4dbde30a9759995d2345f81f171bfbfaab5 Mon Sep 17 00:00:00 2001 From: Kevin Lalumiere Date: Thu, 8 Jul 2021 20:12:20 -0400 Subject: [PATCH 3/4] Use vcpkg-tool's mechanism --- scripts/detect_compiler/portfile.cmake | 12 ------------ scripts/vcpkg_get_tags.cmake | 1 + 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/scripts/detect_compiler/portfile.cmake b/scripts/detect_compiler/portfile.cmake index e6ff70a6c26bf4..4f68faea46936b 100644 --- a/scripts/detect_compiler/portfile.cmake +++ b/scripts/detect_compiler/portfile.cmake @@ -1,15 +1,3 @@ -if(VCPKG_NO_COMPILER_TRACKING) - string(SHA1 hash "nocompilertracking") - message("#COMPILER_HASH#${hash}") - message("#COMPILER_C_HASH#${hash}") - message("#COMPILER_C_VERSION#nocompilertracking") - message("#COMPILER_C_ID#nocompilertracking") - message("#COMPILER_CXX_HASH#${hash}") - message("#COMPILER_CXX_VERSION#nocompilertracking") - message("#COMPILER_CXX_ID#nocompilertracking") - return() -endif() - set(LOGS ${CURRENT_BUILDTREES_DIR}/config-${TARGET_TRIPLET}-out.log ${CURRENT_BUILDTREES_DIR}/config-${TARGET_TRIPLET}-rel-out.log diff --git a/scripts/vcpkg_get_tags.cmake b/scripts/vcpkg_get_tags.cmake index 749b06e5a9f12c..db88996cec6ea7 100644 --- a/scripts/vcpkg_get_tags.cmake +++ b/scripts/vcpkg_get_tags.cmake @@ -12,6 +12,7 @@ VCPKG_VISUAL_STUDIO_PATH=${VCPKG_VISUAL_STUDIO_PATH} VCPKG_CHAINLOAD_TOOLCHAIN_FILE=${VCPKG_CHAINLOAD_TOOLCHAIN_FILE} VCPKG_BUILD_TYPE=${VCPKG_BUILD_TYPE} VCPKG_LIBRARY_LINKAGE=${VCPKG_LIBRARY_LINKAGE} +VCPKG_NO_COMPILER_TRACKING=${VCPKG_NO_COMPILER_TRACKING} e1e74b5c-18cb-4474-a6bd-5c1c8bc81f3f") # Just to enforce the user didn't set it in the triplet file From d46a07bf9c703aa745f9aa32504621de8cf83a6f Mon Sep 17 00:00:00 2001 From: Kevin Lalumiere Date: Sun, 15 Aug 2021 14:06:03 -0400 Subject: [PATCH 4/4] Use 'disable_compiler_tracking' --- docs/users/triplets.md | 2 +- scripts/vcpkg_get_tags.cmake | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/users/triplets.md b/docs/users/triplets.md index 188a14c8bb0c31..5753fd718a5314 100644 --- a/docs/users/triplets.md +++ b/docs/users/triplets.md @@ -118,7 +118,7 @@ See the [`"supports"`](../maintainers/manifest-files.md#supports) manifest file > Implementers' Note: this list is extracted via the `vcpkg_get_dep_info` mechanism. -### VCPKG_NO_COMPILER_TRACKING +### VCPKG_DISABLE_COMPILER_TRACKING When this option is set to (true|1|on), the compiler is ignored in the abi tracking. diff --git a/scripts/vcpkg_get_tags.cmake b/scripts/vcpkg_get_tags.cmake index 55657e8ae5b502..6a948d129eb597 100644 --- a/scripts/vcpkg_get_tags.cmake +++ b/scripts/vcpkg_get_tags.cmake @@ -13,7 +13,7 @@ VCPKG_CHAINLOAD_TOOLCHAIN_FILE=${VCPKG_CHAINLOAD_TOOLCHAIN_FILE} VCPKG_BUILD_TYPE=${VCPKG_BUILD_TYPE} VCPKG_LIBRARY_LINKAGE=${VCPKG_LIBRARY_LINKAGE} VCPKG_CRT_LINKAGE=${VCPKG_CRT_LINKAGE} -VCPKG_NO_COMPILER_TRACKING=${VCPKG_NO_COMPILER_TRACKING} +VCPKG_DISABLE_COMPILER_TRACKING=${VCPKG_DISABLE_COMPILER_TRACKING} e1e74b5c-18cb-4474-a6bd-5c1c8bc81f3f") # Just to enforce the user didn't set it in the triplet file