This is an automated email from the ASF dual-hosted git repository.

bchapuis pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-baremaps-site.git


The following commit(s) were added to refs/heads/main by this push:
     new 24fee33  Update gdal-macos.mdx
24fee33 is described below

commit 24fee33ccf9ed865d9d43509789b04318a978033
Author: Bertil Chapuis <[email protected]>
AuthorDate: Sun Aug 20 09:45:03 2023 +0200

    Update gdal-macos.mdx
    
    Fix the build instructions
---
 src/pages/documentation/examples/gdal-macos.mdx | 29 ++++++++++++++++++++++---
 1 file changed, 26 insertions(+), 3 deletions(-)

diff --git a/src/pages/documentation/examples/gdal-macos.mdx 
b/src/pages/documentation/examples/gdal-macos.mdx
index ab51cdb..51e0fb7 100644
--- a/src/pages/documentation/examples/gdal-macos.mdx
+++ b/src/pages/documentation/examples/gdal-macos.mdx
@@ -35,7 +35,7 @@ find ${CONDA_PREFIX}/lib -name '*.la' -delete
 mkdir build
 cd build
 
-CFLAGS="-Wextra -Werror -Wunused-variable" CXXFLAGS="-Wextra -Werror 
-Wunused-variable" cmake .. \
+cmake .. \
         -DCMAKE_INSTALL_PREFIX=$HOME/install-gdal \
         -DCMAKE_PREFIX_PATH=${CONDA_PREFIX} \
         -DGDAL_USE_GEOTIFF_INTERNAL=ON \
@@ -45,8 +45,8 @@ CFLAGS="-Wextra -Werror -Wunused-variable" CXXFLAGS="-Wextra 
-Werror -Wunused-va
         -DGDAL_USE_ARROW=OFF \
         -DGDAL_USE_PARQUET=OFF \
         -DBUILD_CSHARP_BINDINGS=OFF
-make -j3
-make install
+cmake --build .
+cmake --build . --target install
 ```
 
 After this, the library can be found in 
`~/install-gdal/share/java/libgdalalljni.dylib`.
@@ -57,6 +57,29 @@ When starting a java application, the library can be loaded 
with the following c
 java -Djava.library.path=~/install-gdal/share/java -jar myapp.jar
 ```
 
+## Fix cmake file
+
+```
+diff --git a/cmake/modules/packages/FindSPATIALITE.cmake 
b/cmake/modules/packages/FindSPATIALITE.cmake
+index 80052a4d48..6e5744187e 100644
+--- a/cmake/modules/packages/FindSPATIALITE.cmake
++++ b/cmake/modules/packages/FindSPATIALITE.cmake
+@@ -55,8 +55,8 @@ mark_as_advanced(SPATIALITE_LIBRARY SPATIALITE_INCLUDE_DIR)
+ if(SPATIALITE_LIBRARY AND SPATIALITE_INCLUDE_DIR
+    AND NOT SPATIALITE_VERSION_STRING)
+     file(STRINGS "${SPATIALITE_INCLUDE_DIR}/spatialite.h" _spatialite_h_ver
+-         REGEX "^[ \t]version[ \t]([0-9]+\\.[0-9]+),.*")
+-    string(REGEX REPLACE "[ \t]version[ \t]([0-9]+\\.[0-9]+),.*" "\\1" 
_spatialite_h_ver ${_spatialite_h_ver})
++         REGEX "^[ \t]version[ \t]([0-9]+\\.[0-9]+\\.[0-9]+),.*")
++    string(REGEX REPLACE "[ \t]version[ \t]([0-9]+\\.[0-9]+\\.[0-9]+),.*" 
"\\1" _spatialite_h_ver ${_spatialite_h_ver})
+     set(SPATIALITE_VERSION_STRING "${_spatialite_h_ver}")
+ endif()
+```
+
+## Sources
+
 https://github.com/adoptium/temurin-build/issues/1671
+
 
https://stackoverflow.com/questions/52911791/hardened-runtime-for-java-and-mojave
+
 
https://stackoverflow.com/questions/52905940/how-to-codesign-and-enable-the-hardened-runtime-for-a-3rd-party-cli-on-xcode

Reply via email to