-
Notifications
You must be signed in to change notification settings - Fork 825
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mapnik fails to build with boost 1.77, either 3.1.0 or latest #4329
Comments
Have you tried it with the cmake build? |
I haven't; the latest 3.1.0 release lacks a CMakeLists.txt file. |
Using the latest commit, it seems to detect boost fine, but now I have a new problem:
The build system insists on fetching catch2 from the web, although I've provided it with a system-provided package. |
If you are working in a offline setup, you need to specify some cmake variables:
|
Thanks for pointing the doc, the build got farther with this patch, which uses a very recent feature making the above variables obsolete: 1 file changed, 3 insertions(+), 2 deletions(-)
test/CMakeLists.txt | 5 +++--
modified test/CMakeLists.txt
@@ -6,7 +6,8 @@ include(FetchContent)
FetchContent_Declare(
Catch2
GIT_REPOSITORY https://github.com/catchorg/Catch2.git
- GIT_TAG v2.13.7)
+ GIT_TAG v2.13.7
+ FIND_PACKAGE_ARGS NAMES Catch2)
FetchContent_MakeAvailable(Catch2)
if(${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.19.0")
@@ -174,7 +175,7 @@ target_link_libraries(map_xml_test PUBLIC
)
target_include_directories(map_xml_test PRIVATE "${Catch2_SOURCE_DIR}/single_include/catch2" "${CMAKE_CURRENT_BINARY_DIR}")
-include("${Catch2_SOURCE_DIR}/contrib/Catch.cmake")
+include(Catch)
file(COPY data DESTINATION "${MAPNIK_OUTPUT_DIR}/test")
file(COPY data-visual DESTINATION "${MAPNIK_OUTPUT_DIR}/test")
Catch)\n")))) Or in Guix's language, Scheme: (arguments
(list
#:cmake cmake ;for FIND_PACKAGE_ARGS
#:configure-flags
#~(list (string-append "-DCMAKE_CXX_FLAGS=-I"
#$(this-package-native-input "catch2")
"/include/catch2"))
#:phases
#~(modify-phases %standard-phases
(add-after 'unpack 'use-system-catch2
(lambda _
(substitute* "test/CMakeLists.txt"
(("GIT_TAG.*v2.13.7" all)
(string-append all "\n"
" FIND_PACKAGE_ARGS NAMES Catch2"))
(("^include.*Catch2_SOURCE_DIR.*contrib/Catch.cmake.*")
"include(Catch)\n"))))))) I needed the submodules in the checkout for the mapbox dependencies and test data (I'll try making separate packages for the mapbox things later), and the above extra include directive so the test After which I got a build to fail with a single test failure:
The dependencies used are:
And the build is made in a containerized environment. Any ideas? |
For now I've marked the
And pushed the fixed package to the Guix repo. |
** Changes: ** * Add 3 packages dependencies: * Use mapbox-variant rather than submodule * Use protozero rather than submodule * Use ttf-dejavu rather than bundled fonts ** Patches: ** * mapnik-cmake-harfbuzz.patch based on [this](https://github.com/NixOS/nixpkgs/blob/4cd04c8dbf79b608cfd2274621dd154052dc23ae/pkgs/development/libraries/mapnik/cmake-harfbuzz.patch) * mapnik-datasource-ogr-test.patch based on [this](mapnik/mapnik#4329)
Hello,
I'm trying to update mapnik in Guix, but I haven't been able to build it.
Here's an excerpt of the failed build when using the latest commit:
If I use the latest release instead (3.1.0), I get:
What is the secret ingredient I'm missing for a successful build? :-)
The direct dependencies used are:
The text was updated successfully, but these errors were encountered: