xbps-src: added a new var for templates "dkms_modules".
It will be used by packages that will install DKMS modules.
This commit is contained in:
parent
90922f9936
commit
ae3c15cb59
|
@ -288,6 +288,13 @@ xbps_write_metadata_pkg_real()
|
||||||
<key>long_desc</key>
|
<key>long_desc</key>
|
||||||
<string>$long_desc</string>
|
<string>$long_desc</string>
|
||||||
_EOF
|
_EOF
|
||||||
|
#
|
||||||
|
# If package sets $dkms_modules, add dkms rundep.
|
||||||
|
#
|
||||||
|
if [ -n "$dkms_modules" ]; then
|
||||||
|
Add_dependency run dkms
|
||||||
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
# If package sets $openrc_services, add the OpenRC rundep.
|
# If package sets $openrc_services, add the OpenRC rundep.
|
||||||
#
|
#
|
||||||
|
|
|
@ -63,7 +63,7 @@ xbps_write_metadata_scripts_pkg()
|
||||||
# not possible to chroot(3).
|
# not possible to chroot(3).
|
||||||
#
|
#
|
||||||
|
|
||||||
export PATH="./bin:./sbin:./usr/bin:./usr/sbin"
|
export PATH="/bin:/sbin:/usr/bin:/usr/sbin"
|
||||||
|
|
||||||
TRIGGERSDIR="./var/db/xbps/triggers"
|
TRIGGERSDIR="./var/db/xbps/triggers"
|
||||||
ACTION="\$1"
|
ACTION="\$1"
|
||||||
|
@ -77,25 +77,12 @@ UPDATE="\$4"
|
||||||
_EOF
|
_EOF
|
||||||
|
|
||||||
#
|
#
|
||||||
# Handle GNU Info files.
|
# Handle DKMS modules.
|
||||||
#
|
#
|
||||||
if [ -d "${DESTDIR}/usr/share/info" ]; then
|
if [ -n "${dkms_modules}" ]; then
|
||||||
unset info_files
|
_add_trigger dkms
|
||||||
for f in $(find ${DESTDIR}/usr/share/info -type f); do
|
echo "export dkms_modules=\"${dkms_modules}\"" >> $tmpf
|
||||||
j=$(echo $f|sed -e "$fpattern")
|
fi
|
||||||
[ "$j" = "" ] && continue
|
|
||||||
[ "$j" = "/usr/share/info/dir" ] && continue
|
|
||||||
if [ -z "$info_files" ]; then
|
|
||||||
info_files="$j"
|
|
||||||
else
|
|
||||||
info_files="$info_files $j"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
if [ -n "${info_files}" ]; then
|
|
||||||
_add_trigger info-files
|
|
||||||
echo "export info_files=\"${info_files}\"" >> $tmpf
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Handle OpenRC services.
|
# Handle OpenRC services.
|
||||||
|
@ -132,6 +119,27 @@ _EOF
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#
|
||||||
|
# Handle GNU Info files.
|
||||||
|
#
|
||||||
|
if [ -d "${DESTDIR}/usr/share/info" ]; then
|
||||||
|
unset info_files
|
||||||
|
for f in $(find ${DESTDIR}/usr/share/info -type f); do
|
||||||
|
j=$(echo $f|sed -e "$fpattern")
|
||||||
|
[ "$j" = "" ] && continue
|
||||||
|
[ "$j" = "/usr/share/info/dir" ] && continue
|
||||||
|
if [ -z "$info_files" ]; then
|
||||||
|
info_files="$j"
|
||||||
|
else
|
||||||
|
info_files="$info_files $j"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
if [ -n "${info_files}" ]; then
|
||||||
|
_add_trigger info-files
|
||||||
|
echo "export info_files=\"${info_files}\"" >> $tmpf
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
# (Un)Register a shell in /etc/shells.
|
# (Un)Register a shell in /etc/shells.
|
||||||
#
|
#
|
||||||
|
@ -208,6 +216,9 @@ _EOF
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# End of trigger var exports.
|
||||||
|
echo >> $tmpf
|
||||||
|
|
||||||
#
|
#
|
||||||
# Write the INSTALL/REMOVE package scripts.
|
# Write the INSTALL/REMOVE package scripts.
|
||||||
#
|
#
|
||||||
|
|
|
@ -75,7 +75,7 @@ reset_tmpl_vars()
|
||||||
noarch subpackages sourcepkg gtk_iconcache_dirs \
|
noarch subpackages sourcepkg gtk_iconcache_dirs \
|
||||||
abi_depends api_depends triggers openrc_services \
|
abi_depends api_depends triggers openrc_services \
|
||||||
replaces system_accounts build_wrksrc create_wrksrc \
|
replaces system_accounts build_wrksrc create_wrksrc \
|
||||||
ignore_vdeps_dir noverifyrdeps conflicts \
|
ignore_vdeps_dir noverifyrdeps conflicts dkms_modules \
|
||||||
gconf_entries gconf_schemas stow_copy stow_copy_files \
|
gconf_entries gconf_schemas stow_copy stow_copy_files \
|
||||||
pre_remove post_remove post_stow do_build do_install \
|
pre_remove post_remove post_stow do_build do_install \
|
||||||
XBPS_EXTRACT_DONE XBPS_CONFIGURE_DONE \
|
XBPS_EXTRACT_DONE XBPS_CONFIGURE_DONE \
|
||||||
|
|
Loading…
Reference in New Issue