From 495ac0773c4341589f1cd9108c9de3daf5b78c2c Mon Sep 17 00:00:00 2001 From: Sebastian Faubel Date: Sat, 2 Jul 2016 19:15:39 +0200 Subject: Merge with trunk. (bzr r15002.1.1) --- CMakeScripts/ConfigPaths.cmake | 150 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 150 insertions(+) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index 3b13a7734..09cd96df0 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -1,6 +1,156 @@ message(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}") if(WIN32) +# Directory containing the precompiled Inkscape libraries. Usually c:\devlibs or c:\devlibs64 + set(DEVLIBS_PATH C:/devlibs64) + + # Directory containing the MinGW instance used for compilation. Usually c:\mingw or c:\mingw64 + set(MINGW_PATH C:/mingw64) + + # Directory containing the Ghostscript installation. + set(GS_PATH C:/latex/gs/gs8.61) + + # Normalize directory separator slashes. + string(REGEX REPLACE "\\\\" "/" DEVLIBS_PATH ${DEVLIBS_PATH}) + string(REGEX REPLACE "\\\\" "/" MINGW_PATH ${MINGW_PATH}) + string(REGEX REPLACE "\\\\" "/" GS_PATH ${GS_PATH}) + + # =============== DEVLIBS CHECKS =============== + + # Directory containing the compile time .dll.a and .a files. + set(DEVLIBS_LIB "${DEVLIBS_PATH}/lib") + + if(NOT EXISTS "${DEVLIBS_LIB}") + message(FATAL_ERROR "Inkscape development libraries directory does not exist: ${DEVLIBS_LIB}") + endif() + + # Add devlibs libraries to linker path. + link_directories(${DEVLIBS_LIB}) + + set(DEVLIBS_INCLUDE ${DEVLIBS_PATH}/include) + + if(NOT EXISTS ${DEVLIBS_INCLUDE}) + message(FATAL_ERROR "Inkscape development libraries directory does not exist: ${DEVLIBS_INCLUDE}") + endif() + + # Add general MinGW headers to compiler include path. + #include_directories(${DEVLIBS_INCLUDE}) + + # Directory containing the precompiled .dll files. + set(DEVLIBS_BIN ${DEVLIBS_PATH}/bin) + + if(NOT EXISTS ${DEVLIBS_BIN}) + message(FATAL_ERROR "Inkscape development binaries directory does not exist: ${DEVLIBS_BIN}") + endif() + + # Directory containing the pkgconfig .pc files. + set(PKG_CONFIG_PATH "${DEVLIBS_PATH}/lib/pkgconfig") + + if(NOT EXISTS "${PKG_CONFIG_PATH}") + message(FATAL_ERROR "pkgconfig directory does not exist: ${PKG_CONFIG_PATH}") + endif() + + # Add the devlibs directories to the paths used to find libraries and programs. + list(APPEND CMAKE_PREFIX_PATH ${DEVLIBS_PATH}) + + # Eliminate error messages when not having mingw in the environment path variable. + list(APPEND CMAKE_PROGRAM_PATH ${DEVLIBS_BIN}) + + # =============== MINGW CHECKS =============== + + # We are in a MinGW environment. + set(HAVE_MINGW ON) + + # Try to determine the MinGW processor architecture. + if(EXISTS ${MINGW_PATH}/mingw32) + set(HAVE_MINGW64 OFF) + set(MINGW_ARCH mingw32) + elseif(EXISTS ${MINGW_PATH}/x86_64-w64-mingw32) + set(HAVE_MINGW64 ON) + set(MINGW_ARCH x86_64-w64-mingw32) + else() + message(FATAL_ERROR "Unable to determine MinGW processor architecture. Are you using an unsupported MinGW version?") + endif() + + # Path to processor architecture specific binaries and libs. + set(MINGW_ARCH_PATH ${MINGW_PATH}/${MINGW_ARCH}) + + set(MINGW_BIN ${MINGW_PATH}/bin) + + if(NOT EXISTS ${MINGW_BIN}) + message(FATAL_ERROR "MinGW binary directory does not exist: ${MINGW_BIN}") + endif() + + # Eliminate error messages when not having mingw in the environment path variable. + list(APPEND CMAKE_PROGRAM_PATH ${MINGW_BIN}) + + set(MINGW_LIB ${MINGW_PATH}/lib) + + if(NOT EXISTS ${MINGW_LIB}) + message(FATAL_ERROR "MinGW library directory does not exist: ${MINGW_LIB}") + endif() + + # Add MinGW libraries to linker path. + link_directories(${MINGW_LIB}) + + set(MINGW_INCLUDE ${MINGW_PATH}/include) + + if(NOT EXISTS ${MINGW_INCLUDE}) + message(FATAL_ERROR "MinGW include directory does not exist: ${MINGW_INCLUDE}") + endif() + + # Add general MinGW headers to compiler include path. + include_directories(${MINGW_INCLUDE}) + + if(HAVE_MINGW64) + set(MINGW64_LIB ${MINGW_ARCH_PATH}/lib) + + if(NOT EXISTS ${MINGW64_LIB}) + message(FATAL_ERROR "MinGW 64-Bit libraries directory does not exist: ${MINGW64_LIB}") + endif() + + # Add 64-Bit libraries to linker path. + link_directories(${MINGW64_LIB}) + + set(MINGW64_INCLUDE ${MINGW_ARCH_PATH}/include) + + if(NOT EXISTS ${MINGW64_INCLUDE}) + message(FATAL_ERROR "MinGW 64-Bit include directory does not exist: ${MINGW64_INCLUDE}") + endif() + + set(MINGW64_INCLUDE_SDL ${MINGW64_INCLUDE}/c++) + + if(NOT EXISTS ${MINGW64_INCLUDE_SDL}) + message(FATAL_ERROR "MinGW 64-Bit SDL include directory does not exist: ${MINGW64_INCLUDE_SDL}") + endif() + + # Add 64-Bit MinGW headers to compiler include path. + include_directories(${MINGW64_INCLUDE}) + #include_directories(${MINGW64_INCLUDE_SDL}) + endif() + + # =============== GHOSTSCRIPT CHECKS =============== + + # Check for Ghostscript. + set(GS_BIN "${GS_PATH}/bin") + + if(EXISTS "${GS_BIN}") + set(HAVE_GS_BIN ON) + else() + set(HAVE_GS_BIN OFF) + endif() + + # =============== LIBRARY AND LINKER =============== + + # Tweak CMake into using Unix-style library names. + set(CMAKE_FIND_LIBRARY_PREFIXES "lib") + set(CMAKE_FIND_LIBRARY_SUFFIXES ".dll.a" ".dll") + + if(NOT HAVE_MINGW64) + list(APPEND CMAKE_FIND_LIBRARY_SUFFIXES ".a") + endif() + + # Directory containing the current locale (translations). set(PACKAGE_LOCALE_DIR "locale") set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") else(WIN32) -- cgit v1.2.3 From c55b258d2131bd51a1a98831324173f544cf236b Mon Sep 17 00:00:00 2001 From: Sebastian Faubel Date: Mon, 4 Jul 2016 10:02:41 +0200 Subject: Fixed locales. (bzr r15002.1.2) --- CMakeScripts/ConfigPaths.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index 09cd96df0..6ce849206 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -151,7 +151,7 @@ if(WIN32) endif() # Directory containing the current locale (translations). - set(PACKAGE_LOCALE_DIR "locale") + set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") else(WIN32) # TODO: check and change this to correct value: -- cgit v1.2.3 From 8155c4690b6a74d704eaee3b19fef32c62fd38a4 Mon Sep 17 00:00:00 2001 From: Sebastian Faubel Date: Tue, 5 Jul 2016 12:39:38 +0200 Subject: Refactored the path settings and install scripts. Fixed build for 32-Bit devlibs. (bzr r15002.1.3) --- CMakeScripts/ConfigPaths.cmake | 173 +++-------------------------------------- 1 file changed, 12 insertions(+), 161 deletions(-) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index 6ce849206..cfe6c66b6 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -1,166 +1,17 @@ message(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}") if(WIN32) -# Directory containing the precompiled Inkscape libraries. Usually c:\devlibs or c:\devlibs64 - set(DEVLIBS_PATH C:/devlibs64) - - # Directory containing the MinGW instance used for compilation. Usually c:\mingw or c:\mingw64 - set(MINGW_PATH C:/mingw64) - - # Directory containing the Ghostscript installation. - set(GS_PATH C:/latex/gs/gs8.61) - - # Normalize directory separator slashes. - string(REGEX REPLACE "\\\\" "/" DEVLIBS_PATH ${DEVLIBS_PATH}) - string(REGEX REPLACE "\\\\" "/" MINGW_PATH ${MINGW_PATH}) - string(REGEX REPLACE "\\\\" "/" GS_PATH ${GS_PATH}) - - # =============== DEVLIBS CHECKS =============== - - # Directory containing the compile time .dll.a and .a files. - set(DEVLIBS_LIB "${DEVLIBS_PATH}/lib") - - if(NOT EXISTS "${DEVLIBS_LIB}") - message(FATAL_ERROR "Inkscape development libraries directory does not exist: ${DEVLIBS_LIB}") - endif() - - # Add devlibs libraries to linker path. - link_directories(${DEVLIBS_LIB}) - - set(DEVLIBS_INCLUDE ${DEVLIBS_PATH}/include) - - if(NOT EXISTS ${DEVLIBS_INCLUDE}) - message(FATAL_ERROR "Inkscape development libraries directory does not exist: ${DEVLIBS_INCLUDE}") - endif() - - # Add general MinGW headers to compiler include path. - #include_directories(${DEVLIBS_INCLUDE}) - - # Directory containing the precompiled .dll files. - set(DEVLIBS_BIN ${DEVLIBS_PATH}/bin) - - if(NOT EXISTS ${DEVLIBS_BIN}) - message(FATAL_ERROR "Inkscape development binaries directory does not exist: ${DEVLIBS_BIN}") - endif() - - # Directory containing the pkgconfig .pc files. - set(PKG_CONFIG_PATH "${DEVLIBS_PATH}/lib/pkgconfig") - - if(NOT EXISTS "${PKG_CONFIG_PATH}") - message(FATAL_ERROR "pkgconfig directory does not exist: ${PKG_CONFIG_PATH}") - endif() - - # Add the devlibs directories to the paths used to find libraries and programs. - list(APPEND CMAKE_PREFIX_PATH ${DEVLIBS_PATH}) - - # Eliminate error messages when not having mingw in the environment path variable. - list(APPEND CMAKE_PROGRAM_PATH ${DEVLIBS_BIN}) - - # =============== MINGW CHECKS =============== - - # We are in a MinGW environment. - set(HAVE_MINGW ON) - - # Try to determine the MinGW processor architecture. - if(EXISTS ${MINGW_PATH}/mingw32) - set(HAVE_MINGW64 OFF) - set(MINGW_ARCH mingw32) - elseif(EXISTS ${MINGW_PATH}/x86_64-w64-mingw32) - set(HAVE_MINGW64 ON) - set(MINGW_ARCH x86_64-w64-mingw32) - else() - message(FATAL_ERROR "Unable to determine MinGW processor architecture. Are you using an unsupported MinGW version?") - endif() - - # Path to processor architecture specific binaries and libs. - set(MINGW_ARCH_PATH ${MINGW_PATH}/${MINGW_ARCH}) - - set(MINGW_BIN ${MINGW_PATH}/bin) - - if(NOT EXISTS ${MINGW_BIN}) - message(FATAL_ERROR "MinGW binary directory does not exist: ${MINGW_BIN}") - endif() - - # Eliminate error messages when not having mingw in the environment path variable. - list(APPEND CMAKE_PROGRAM_PATH ${MINGW_BIN}) - - set(MINGW_LIB ${MINGW_PATH}/lib) - - if(NOT EXISTS ${MINGW_LIB}) - message(FATAL_ERROR "MinGW library directory does not exist: ${MINGW_LIB}") - endif() - - # Add MinGW libraries to linker path. - link_directories(${MINGW_LIB}) - - set(MINGW_INCLUDE ${MINGW_PATH}/include) - - if(NOT EXISTS ${MINGW_INCLUDE}) - message(FATAL_ERROR "MinGW include directory does not exist: ${MINGW_INCLUDE}") - endif() - - # Add general MinGW headers to compiler include path. - include_directories(${MINGW_INCLUDE}) - - if(HAVE_MINGW64) - set(MINGW64_LIB ${MINGW_ARCH_PATH}/lib) - - if(NOT EXISTS ${MINGW64_LIB}) - message(FATAL_ERROR "MinGW 64-Bit libraries directory does not exist: ${MINGW64_LIB}") - endif() - - # Add 64-Bit libraries to linker path. - link_directories(${MINGW64_LIB}) - - set(MINGW64_INCLUDE ${MINGW_ARCH_PATH}/include) - - if(NOT EXISTS ${MINGW64_INCLUDE}) - message(FATAL_ERROR "MinGW 64-Bit include directory does not exist: ${MINGW64_INCLUDE}") - endif() - - set(MINGW64_INCLUDE_SDL ${MINGW64_INCLUDE}/c++) - - if(NOT EXISTS ${MINGW64_INCLUDE_SDL}) - message(FATAL_ERROR "MinGW 64-Bit SDL include directory does not exist: ${MINGW64_INCLUDE_SDL}") - endif() - - # Add 64-Bit MinGW headers to compiler include path. - include_directories(${MINGW64_INCLUDE}) - #include_directories(${MINGW64_INCLUDE_SDL}) - endif() - - # =============== GHOSTSCRIPT CHECKS =============== - - # Check for Ghostscript. - set(GS_BIN "${GS_PATH}/bin") - - if(EXISTS "${GS_BIN}") - set(HAVE_GS_BIN ON) - else() - set(HAVE_GS_BIN OFF) - endif() - - # =============== LIBRARY AND LINKER =============== - - # Tweak CMake into using Unix-style library names. - set(CMAKE_FIND_LIBRARY_PREFIXES "lib") - set(CMAKE_FIND_LIBRARY_SUFFIXES ".dll.a" ".dll") - - if(NOT HAVE_MINGW64) - list(APPEND CMAKE_FIND_LIBRARY_SUFFIXES ".a") - endif() - - # Directory containing the current locale (translations). - set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") - set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") -else(WIN32) - # TODO: check and change this to correct value: - if(NOT PACKAGE_LOCALE_DIR) set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") # packagers might overwrite this - endif(NOT PACKAGE_LOCALE_DIR) - - if(NOT SHARE_INSTALL) set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") - endif(NOT SHARE_INSTALL) - mark_as_advanced(SHARE_INSTALL) -endif(WIN32) +else() + # TODO: check and change this to correct value: + if(NOT PACKAGE_LOCALE_DIR) + set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") # packagers might overwrite this + endif(NOT PACKAGE_LOCALE_DIR) + + if(NOT SHARE_INSTALL) + set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") + endif(NOT SHARE_INSTALL) + + mark_as_advanced(SHARE_INSTALL) +endif() \ No newline at end of file -- cgit v1.2.3 From f381a48f549f2a3c4d7ec48a1458e7555306766b Mon Sep 17 00:00:00 2001 From: Sebastian Faubel Date: Wed, 6 Jul 2016 16:04:54 +0200 Subject: Fixed config.h defines to point to the right locations for data (icons) and locales. (bzr r15002.1.5) --- CMakeScripts/ConfigPaths.cmake | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index cfe6c66b6..9774d4df2 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -1,9 +1,20 @@ message(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}") if(WIN32) - set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") # packagers might overwrite this + set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape") + + set(INKSCAPE_LIBDIR "\\\\lib") + set(INKSCAPE_DATADIR "") + + set(PACKAGE_LOCALE_DIR "\\\\share\\\\locale") + set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") + + mark_as_advanced(SHARE_INSTALL) else() + set(INKSCAPE_LIBDIR "${CMAKE_INSTALL_PREFIX}/lib") + set(INKSCAPE_DATADIR "${CMAKE_INSTALL_PREFIX}/share") + # TODO: check and change this to correct value: if(NOT PACKAGE_LOCALE_DIR) set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") # packagers might overwrite this -- cgit v1.2.3 From 7b0f2601a652adb7566bfac6ec0eab7a9d95c7a2 Mon Sep 17 00:00:00 2001 From: Sebastian Faubel Date: Wed, 6 Jul 2016 17:42:00 +0200 Subject: Fixing build for Linux. Replaced tabs with whitespaces. (bzr r15002.1.7) --- CMakeScripts/ConfigPaths.cmake | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index 9774d4df2..9489ba047 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -1,28 +1,28 @@ message(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}") if(WIN32) - set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape") - - set(INKSCAPE_LIBDIR "\\\\lib") - set(INKSCAPE_DATADIR "") - - set(PACKAGE_LOCALE_DIR "\\\\share\\\\locale") - - set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") - - mark_as_advanced(SHARE_INSTALL) + set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape") + + set(INKSCAPE_LIBDIR "\\\\lib") + set(INKSCAPE_DATADIR "") + + set(PACKAGE_LOCALE_DIR "\\\\share\\\\locale") + + set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") + + mark_as_advanced(SHARE_INSTALL) else() - set(INKSCAPE_LIBDIR "${CMAKE_INSTALL_PREFIX}/lib") - set(INKSCAPE_DATADIR "${CMAKE_INSTALL_PREFIX}/share") + set(INKSCAPE_LIBDIR "${CMAKE_INSTALL_PREFIX}/lib") + set(INKSCAPE_DATADIR "${CMAKE_INSTALL_PREFIX}/share") - # TODO: check and change this to correct value: - if(NOT PACKAGE_LOCALE_DIR) - set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") # packagers might overwrite this - endif(NOT PACKAGE_LOCALE_DIR) + # TODO: check and change this to correct value: + if(NOT PACKAGE_LOCALE_DIR) + set(PACKAGE_LOCALE_DIR "${CMAKE_INSTALL_PREFIX}/share/locale") # packagers might overwrite this + endif(NOT PACKAGE_LOCALE_DIR) - if(NOT SHARE_INSTALL) - set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") - endif(NOT SHARE_INSTALL) + if(NOT SHARE_INSTALL) + set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") + endif(NOT SHARE_INSTALL) - mark_as_advanced(SHARE_INSTALL) + mark_as_advanced(SHARE_INSTALL) endif() \ No newline at end of file -- cgit v1.2.3 From 61b1ddd0599ee54f76494888524b156859134e85 Mon Sep 17 00:00:00 2001 From: Eduard Braun Date: Sat, 26 Nov 2016 17:15:27 +0100 Subject: CMake: Add ${INKSCAPE_SHARE_INSTALL} This is set to "share/inkscape" by default, on Windows we need to be able to install directly into "share" however (bzr r15278) --- CMakeScripts/ConfigPaths.cmake | 2 ++ 1 file changed, 2 insertions(+) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index 9489ba047..fae8ceea6 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -9,6 +9,7 @@ if(WIN32) set(PACKAGE_LOCALE_DIR "\\\\share\\\\locale") set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") + set(INKSCAPE_SHARE_INSTALL "${SHARE_INSTALL}") # share/inkscape goes directly into /share on Windows mark_as_advanced(SHARE_INSTALL) else() @@ -23,6 +24,7 @@ else() if(NOT SHARE_INSTALL) set(SHARE_INSTALL "share" CACHE STRING "Data file install path. Must be a relative path (from CMAKE_INSTALL_PREFIX), with no trailing slash.") endif(NOT SHARE_INSTALL) + set(INKSCAPE_SHARE_INSTALL "${SHARE_INSTALL}/inkscape") mark_as_advanced(SHARE_INSTALL) endif() \ No newline at end of file -- cgit v1.2.3 From ae2703a5383eb29078c09610d713411b2da5ecf8 Mon Sep 17 00:00:00 2001 From: Eduard Braun Date: Tue, 9 May 2017 20:42:01 +0200 Subject: cmake/Windows: convert all 'DESTINATION's to relative paths and allow easy customization of install location via 'CMAKE_INSTALL_PREFIX' (bzr r15681) --- CMakeScripts/ConfigPaths.cmake | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index fae8ceea6..417b265bf 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -1,7 +1,9 @@ message(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}") if(WIN32) - set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape") + if(${CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT}) + set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape") + endif() set(INKSCAPE_LIBDIR "\\\\lib") set(INKSCAPE_DATADIR "") -- cgit v1.2.3 From aafd57bd9a86853df3d4b369df16d8a555908baf Mon Sep 17 00:00:00 2001 From: Eduard Braun Date: Sun, 14 May 2017 17:48:05 +0200 Subject: cmake: Store defauklt CMAKE_INSTALL_PREFIX to cache, otherwise it will be lost on subsequent runs (bzr r15692) --- CMakeScripts/ConfigPaths.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'CMakeScripts/ConfigPaths.cmake') diff --git a/CMakeScripts/ConfigPaths.cmake b/CMakeScripts/ConfigPaths.cmake index 417b265bf..de053c4d8 100644 --- a/CMakeScripts/ConfigPaths.cmake +++ b/CMakeScripts/ConfigPaths.cmake @@ -2,7 +2,8 @@ message(STATUS "Creating build files in: ${CMAKE_CURRENT_BINARY_DIR}") if(WIN32) if(${CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT}) - set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape") + set(CMAKE_INSTALL_PREFIX "${CMAKE_BINARY_DIR}/inkscape" + CACHE PATH "Install path prefix, prepended onto install directories." FORCE) endif() set(INKSCAPE_LIBDIR "\\\\lib") -- cgit v1.2.3