lomiri.biometryd: Fix lack of output fixup in pkg-config file, update pkg-config call with new CMake option
This commit is contained in:
@@ -38,12 +38,17 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# Uses pkg_get_variable, cannot substitute prefix with that
|
||||
# Substitute systemd's prefix in pkg-config call
|
||||
substituteInPlace data/CMakeLists.txt \
|
||||
--replace 'pkg_get_variable(SYSTEMD_SYSTEM_UNIT_DIR systemd systemdsystemunitdir)' 'set(SYSTEMD_SYSTEM_UNIT_DIR "''${CMAKE_INSTALL_PREFIX}/lib/systemd/system")'
|
||||
--replace-fail 'pkg_get_variable(SYSTEMD_SYSTEM_UNIT_DIR systemd systemdsystemunitdir)' 'pkg_get_variable(SYSTEMD_SYSTEM_UNIT_DIR systemd systemdsystemunitdir DEFINE_VARIABLES prefix=''${CMAKE_INSTALL_PREFIX})'
|
||||
|
||||
substituteInPlace src/biometry/qml/Biometryd/CMakeLists.txt \
|
||||
--replace "\''${CMAKE_INSTALL_LIBDIR}/qt5/qml" "\''${CMAKE_INSTALL_PREFIX}/${qtbase.qtQmlPrefix}"
|
||||
--replace-fail "\''${CMAKE_INSTALL_LIBDIR}/qt5/qml" "\''${CMAKE_INSTALL_PREFIX}/${qtbase.qtQmlPrefix}"
|
||||
|
||||
# For our automatic pkg-config output patcher to work, prefix must be used here
|
||||
substituteInPlace data/biometryd.pc.in \
|
||||
--replace-fail 'libdir=''${exec_prefix}' 'libdir=''${prefix}' \
|
||||
--replace-fail 'includedir=''${exec_prefix}' 'includedir=''${prefix}' \
|
||||
'' + lib.optionalString (!finalAttrs.doCheck) ''
|
||||
sed -i -e '/add_subdirectory(tests)/d' CMakeLists.txt
|
||||
'';
|
||||
|
||||
Reference in New Issue
Block a user