Skip to content

Commit

Permalink
fix(build-linux): use older variable name in systemd query
Browse files Browse the repository at this point in the history
The Ubuntu 20.x uses an older systemd version.
Both variable names work for all distros.
  • Loading branch information
PVermeer committed Jan 21, 2024
1 parent 299c131 commit a379c64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmake/FindSystemd.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ IF (NOT WIN32)

if (SYSTEMD_FOUND)
execute_process(COMMAND ${PKG_CONFIG_EXECUTABLE}
--variable=systemd_user_unit_dir systemd
--variable=systemduserunitdir systemd
OUTPUT_VARIABLE SYSTEMD_USER_UNIT_INSTALL_DIR)

string(REGEX REPLACE "[ \t\n]+" "" SYSTEMD_USER_UNIT_INSTALL_DIR
"${SYSTEMD_USER_UNIT_INSTALL_DIR}")

execute_process(COMMAND ${PKG_CONFIG_EXECUTABLE}
--variable=systemd_system_unit_dir systemd
--variable=systemdsystemunitdir systemd
OUTPUT_VARIABLE SYSTEMD_SYSTEM_UNIT_INSTALL_DIR)

string(REGEX REPLACE "[ \t\n]+" "" SYSTEMD_SYSTEM_UNIT_INSTALL_DIR
Expand Down

0 comments on commit a379c64

Please sign in to comment.