mirror of
https://github.com/AuxXxilium/kmod.git
synced 2024-11-23 23:10:53 +07:00
8463809f8a
There is an ongoing effort to limit use of files outside of /usr (or ${prefix} on general). Currently all modprobe.d paths are hardcoded to outside of $prefix. Teach kmod to load modprobe.d from ${prefix}/lib. On some distributions /usr/lib and /lib are the same directory because of a compatibility symlink, and it is possible to craft configuration files with sideeffects that would behave differently when loaded twice. However, the override semantic ensures that one 'overrides' the other, and only one configuration file of the same name is loaded from any of the search directories. Signed-off-by: Michal Suchanek <msuchanek@suse.de> Link: https://lore.kernel.org/r/a290343ce32e2a3c25b134e4f27c13b26e06c9e0.1689681454.git.msuchanek@suse.de Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
31 lines
851 B
Makefile
31 lines
851 B
Makefile
MAN5 = depmod.d.5 modprobe.d.5 modules.dep.5
|
|
MAN8 = kmod.8 depmod.8 insmod.8 lsmod.8 rmmod.8 modprobe.8 modinfo.8
|
|
MAN_STUB = modules.dep.bin.5
|
|
|
|
AM_V_XSLT = $(AM_V_XSLT_$(V))
|
|
AM_V_XSLT_ = $(AM_V_XSLT_$(AM_DEFAULT_VERBOSITY))
|
|
AM_V_XSLT_0 = @echo " XSLT " $@;
|
|
|
|
XSLT = $(if $(XSLTPROC), $(XSLTPROC), xsltproc)
|
|
|
|
if BUILD_TOOLS
|
|
dist_man_MANS = $(MAN5) $(MAN8) $(MAN_STUB)
|
|
modules.dep.bin.5: modules.dep.5
|
|
endif
|
|
|
|
EXTRA_DIST = $(MAN5:%.5=%.xml) $(MAN8:%.8=%.xml)
|
|
CLEANFILES = $(dist_man_MANS)
|
|
|
|
%.5 %.8: %.xml
|
|
$(AM_V_XSLT)if [ '$(distconfdir)' != '/lib' ] ; then \
|
|
sed -e 's|@DISTCONFDIR@|$(distconfdir)|g' $< ; \
|
|
else \
|
|
sed -e '/@DISTCONFDIR@/d' $< ; \
|
|
fi | \
|
|
$(XSLT) \
|
|
-o $@ \
|
|
--nonet \
|
|
--stringparam man.output.quietly 1 \
|
|
--param funcsynopsis.style "'ansi'" \
|
|
http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl -
|