[proj] fix gcc version<8 compile (#39578)

Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>
This commit is contained in:
Tom Willow 2024-07-02 04:01:08 +08:00 committed by GitHub
parent edf0366ad3
commit 485225516a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 27 additions and 1 deletions

View File

@ -0,0 +1,19 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 36afe1156..14287744d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -63,9 +63,13 @@ if("${CMAKE_C_COMPILER_ID}" STREQUAL "GNU")
set(PROJ_C_WARN_FLAGS ${PROJ_common_WARN_FLAGS}
-Wmissing-prototypes
)
+ if (CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 8)
+ set(PROJ_CXX_WARN_FLAGS ${PROJ_common_WARN_FLAGS}
+ -Wextra-semi
+ )
+ endif()
set(PROJ_CXX_WARN_FLAGS ${PROJ_common_WARN_FLAGS}
-Weffc++
- -Wextra-semi
# -Wold-style-cast
-Woverloaded-virtual
-Wzero-as-null-pointer-constant

View File

@ -8,6 +8,7 @@ vcpkg_from_github(
fix-win-output-name.patch
fix-proj4-targets-cmake.patch
remove_toolset_restriction.patch
fix-gcc-version-less-8.patch
)
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS

View File

@ -1,6 +1,7 @@
{
"name": "proj",
"version": "9.4.1",
"port-version": 1,
"description": "PROJ library for cartographic projections",
"homepage": "https://proj.org/",
"license": "MIT",

View File

@ -7026,7 +7026,7 @@
},
"proj": {
"baseline": "9.4.1",
"port-version": 0
"port-version": 1
},
"projectm-eval": {
"baseline": "1.0.0",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "3ea3cfc72b4b1d43a359755953f4792daadef34a",
"version": "9.4.1",
"port-version": 1
},
{
"git-tree": "dafa38417689eb52c17a425ace8e1f3ecfb74045",
"version": "9.4.1",