You are not logged in.
How can the build() function of a PKGBUILD read the complete options array, as set by both /etc/make.conf AND the PKGBUILD itself?
I tried to read $options, but that only worked when I set options in the PKGBUILD; it did not show anything from /etc/makepkg.conf
I need this because the package I am writing a PKGBUILD for has configure options that enable/disable documentation and optimization and such, which should be controlled by the 'docs', 'debug', and 'strip' options.
Last edited by Ranguvar (2009-10-26 01:20:46)
Offline
makepkg uses this function:
##
# Checks to see if options are present in makepkg.conf or PKGBUILD;
# PKGBUILD options always take precedence.
#
# usage : check_option( $option )
# return : y - enabled
# n - disabled
# ? - not found
##
check_option() {
Offline
Excellent
Perhaps this should be in some documentation? It seems quite useful.
Offline