Hi, Sergey! On Dec 18, Sergey Vojtovich wrote:
revision-id: 370ab48e9fcf4bc15ffa5e313fc34aa97981a832 (mariadb-10.1.9-24-g370ab48) parent(s): 428e09a789a17211de9b4f0a2c4c1226d5dcf993 committer: Sergey Vojtovich timestamp: 2015-12-18 16:50:03 +0400 message:
MDEV-9209 - [PATCH] scripts: Do not prepend the prefix to absolute paths
Allow absolute paths for INSTALL_*DIR.
Okay, I agree now. Let's use your approach :) See below, one minor issue in mariadb.pc file.
diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt index eb78016..54289c0 100644 --- a/scripts/CMakeLists.txt +++ b/scripts/CMakeLists.txt
IF(UNIX) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/mysql_install_db.sh ${CMAKE_CURRENT_BINARY_DIR}/mysql_install_db ESCAPE_QUOTES @ONLY) - SET(DEST ${INSTALL_SCRIPTDIR}) SET(EXT)
you can remove EXT as well, it's apparently not used anymore.
EXECUTE_PROCESS( COMMAND chmod +x ${CMAKE_CURRENT_BINARY_DIR}/mysql_install_db diff --git a/support-files/mariadb.pc.in b/support-files/mariadb.pc.in index bc84a5c..0605d86 100644 --- a/support-files/mariadb.pc.in +++ b/support-files/mariadb.pc.in @@ -1,18 +1,18 @@ # these four variables are present in almost every .pc file prefix=@CMAKE_INSTALL_PREFIX@ exec_prefix=${prefix} -libdir=${prefix}/@INSTALL_LIBDIR@ -includedir=${prefix}/@INSTALL_INCLUDEDIR@ +libdir=@INSTALL_LIBDIRABS@ +includedir=@INSTALL_INCLUDEDIRABS@
This is, strictly speaking, incorrect. In the old version one can change prefix to any other value and all other paths will auto-adjust. See: $ pkg-config --libs openrc -L/lib64 -lrc $ pkg-config --libs openrc --define-variable=prefix=/opt -L/opt/lib64 -lrc Regards, Sergei Chief Architect MariaDB and security@mariadb.org -- Vote for my Percona Live 2016 talks: https://www.percona.com/live/data-performance-conference-2016/sessions/maria... https://www.percona.com/live/data-performance-conference-2016/sessions/maria...