pkg-config: prefix is not really configurable, don't pretend it was

We generally don't support prefix being != /usr, and this is hardcoded
all over the place. In the systemd.pc file it wasn't so far. Let's
adjust this to match the rest of the codebase.
This commit is contained in:
Lennart Poettering 2020-09-10 18:27:18 +02:00
parent b612c26ceb
commit 6e65df89c3
2 changed files with 6 additions and 8 deletions

View File

@ -11,7 +11,7 @@
# considered deprecated (though there is no plan to remove them). New names # considered deprecated (though there is no plan to remove them). New names
# shall have underscores. # shall have underscores.
prefix=@prefix@ prefix=/usr
root_prefix=@rootprefix_noslash@ root_prefix=@rootprefix_noslash@
rootprefix=${root_prefix} rootprefix=${root_prefix}
sysconf_dir=@sysconfdir@ sysconf_dir=@sysconfdir@
@ -26,10 +26,10 @@ systemdsystemunitdir=${systemd_system_unit_dir}
systemd_system_preset_dir=${rootprefix}/lib/systemd/system-preset systemd_system_preset_dir=${rootprefix}/lib/systemd/system-preset
systemdsystempresetdir=${systemd_system_preset_dir} systemdsystempresetdir=${systemd_system_preset_dir}
systemd_user_unit_dir=${prefix}/lib/systemd/user systemd_user_unit_dir=/usr/lib/systemd/user
systemduserunitdir=${systemd_user_unit_dir} systemduserunitdir=${systemd_user_unit_dir}
systemd_user_preset_dir=${prefix}/lib/systemd/user-preset systemd_user_preset_dir=/usr/lib/systemd/user-preset
systemduserpresetdir=${systemd_user_preset_dir} systemduserpresetdir=${systemd_user_preset_dir}
systemd_system_conf_dir=${sysconfdir}/systemd/system systemd_system_conf_dir=${sysconfdir}/systemd/system
@ -47,7 +47,7 @@ systemduserunitpath=${systemd_user_unit_path}
systemd_system_generator_dir=${root_prefix}/lib/systemd/system-generators systemd_system_generator_dir=${root_prefix}/lib/systemd/system-generators
systemdsystemgeneratordir=${systemd_system_generator_dir} systemdsystemgeneratordir=${systemd_system_generator_dir}
systemd_user_generator_dir=${prefix}/lib/systemd/user-generators systemd_user_generator_dir=/usr/lib/systemd/user-generators
systemdusergeneratordir=${systemd_user_generator_dir} systemdusergeneratordir=${systemd_user_generator_dir}
systemd_system_generator_path=/run/systemd/system-generators:/etc/systemd/system-generators:/usr/local/lib/systemd/system-generators:${systemd_system_generator_dir} systemd_system_generator_path=/run/systemd/system-generators:/etc/systemd/system-generators:/usr/local/lib/systemd/system-generators:${systemd_system_generator_dir}
@ -62,7 +62,7 @@ systemdsleepdir=${systemd_sleep_dir}
systemd_shutdown_dir=${root_prefix}/lib/systemd/system-shutdown systemd_shutdown_dir=${root_prefix}/lib/systemd/system-shutdown
systemdshutdowndir=${systemd_shutdown_dir} systemdshutdowndir=${systemd_shutdown_dir}
tmpfiles_dir=${prefix}/lib/tmpfiles.d tmpfiles_dir=/usr/lib/tmpfiles.d
tmpfilesdir=${tmpfiles_dir} tmpfilesdir=${tmpfiles_dir}
sysusers_dir=${rootprefix}/lib/sysusers.d sysusers_dir=${rootprefix}/lib/sysusers.d
@ -77,7 +77,7 @@ binfmtdir=${binfmt_dir}
modules_load_dir=${rootprefix}/lib/modules-load.d modules_load_dir=${rootprefix}/lib/modules-load.d
modulesloaddir=${modules_load_dir} modulesloaddir=${modules_load_dir}
catalog_dir=${prefix}/lib/systemd/catalog catalog_dir=/usr/lib/systemd/catalog
catalogdir=${catalog_dir} catalogdir=${catalog_dir}
system_uid_max=@systemuidmax@ system_uid_max=@systemuidmax@

View File

@ -364,8 +364,6 @@ static int get_path(uint64_t type, char **buffer, const char **ret) {
*ret = ROOTPREFIX_NOSLASH "/lib/systemd/system-shutdown"; *ret = ROOTPREFIX_NOSLASH "/lib/systemd/system-shutdown";
return 0; return 0;
/* FIXME: systemd.pc uses ${prefix}, but CONF_PATHS_NULSTR doesn't.
* Should ${prefix} use in systemd.pc be removed? */
case SD_PATH_TMPFILES: case SD_PATH_TMPFILES:
*ret = "/usr/lib/tmpfiles.d"; *ret = "/usr/lib/tmpfiles.d";
return 0; return 0;