Skip to content

Commit

Permalink
Merge pull request #3787 from xsco/fix/djinterop-multi-prefix-path
Browse files Browse the repository at this point in the history
CMake fix passing multiple paths to libdjinterop
  • Loading branch information
Holzhaus authored Apr 18, 2021
2 parents fb118cc + 5cbb101 commit ba704bf
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1722,19 +1722,25 @@ if(ENGINEPRIME)
set(DJINTEROP_INSTALL_DIR "${CMAKE_CURRENT_BINARY_DIR}/lib/libdjinterop-install")
set(DJINTEROP_LIBRARY "lib/${CMAKE_STATIC_LIBRARY_PREFIX}djinterop${CMAKE_STATIC_LIBRARY_SUFFIX}")
file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/download")

# CMake does not pass lists of paths properly to external projects.
# This is worked around by changing the list separator.
string(REPLACE ";" "|" PIPE_DELIMITED_CMAKE_PREFIX_PATH "${CMAKE_PREFIX_PATH}")

# External project sources must be downloaded as an archive into DOWNLOAD_DIR
# from an URL to keep offline builds like for Fedora/RPM Fusion working!
ExternalProject_Add(libdjinterop
URL "https://github.com/xsco/libdjinterop/archive/0.15.1.tar.gz"
URL_HASH SHA256=87b3e6c726c208333d55b7e7e3af0a7230c9ad9edb3ca0ca81feffe17b3fc008
DOWNLOAD_DIR "${CMAKE_CURRENT_BINARY_DIR}/download/libdjinterop"
INSTALL_DIR ${DJINTEROP_INSTALL_DIR}
LIST_SEPARATOR "|"
CMAKE_ARGS
-DBUILD_SHARED_LIBS=OFF
-DCMAKE_SKIP_INSTALL_ALL_DEPENDENCY=ON
-DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
-DCMAKE_INSTALL_PREFIX:PATH=<INSTALL_DIR>
-DCMAKE_PREFIX_PATH:PATH=${CMAKE_PREFIX_PATH}
-DCMAKE_PREFIX_PATH=${PIPE_DELIMITED_CMAKE_PREFIX_PATH}
-DCMAKE_INSTALL_LIBDIR:PATH=lib
-DCMAKE_MODULE_PATH:PATH=${CMAKE_MODULE_PATH}
-DSYSTEM_SQLITE=${DJINTEROP_SYSTEM_SQLITE}
Expand Down

0 comments on commit ba704bf

Please sign in to comment.