index : pacman | |
Archlinux32 fork of pacman | gitolite user |
summaryrefslogtreecommitdiff |
author | Allan McRae <allan@archlinux.org> | 2008-09-27 14:47:29 +1000 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2009-01-03 00:11:48 -0600 |
commit | 774c252753c3c1717684bea234a497941aa864d7 (patch) | |
tree | 8d6620dea8b3d6ef09b3ddfb85207c7ce1598b7f | |
parent | 1b7ff7a636b6ca6bbcb3953c681bd22166f4a6ca (diff) |
-rw-r--r-- | scripts/makepkg.sh.in | 17 |
diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in index 5fdd4b27..ef72dc25 100644 --- a/scripts/makepkg.sh.in +++ b/scripts/makepkg.sh.in @@ -41,8 +41,9 @@ confdir='@sysconfdir@' startdir="$PWD" srcdir="$startdir/src" pkgdir="$startdir/pkg" -known_options=('strip' 'docs' 'libtool' 'emptydirs' 'zipman' 'ccache' 'distcc' 'makeflags' 'force') -readonly -a known_options +packaging_options=('strip' 'docs' 'libtool' 'emptydirs' 'zipman') +other_options=('ccache' 'distcc' 'makeflags' 'force') +readonly -a packaging_options other_options # Options ASROOT=0 @@ -851,6 +852,16 @@ create_package() { for it in "${backup[@]}"; do echo "backup = $it" >>.PKGINFO done + for it in "${packaging_options[@]}"; do + local ret="$(check_option $it)" + if [ "$ret" != "?" ]; then + if [ "$ret" = "y" ]; then + echo "makepkgopt = $it" >>.PKGINFO + else + echo "makepkgopt = !$it" >>.PKGINFO + fi + fi + done # TODO maybe remove this at some point # warn if license array is not present or empty @@ -1518,7 +1529,7 @@ valid_options=1 for opt in ${options[@]}; do known=0 # check if option matches a known option or its inverse - for kopt in ${known_options[@]}; do + for kopt in ${packaging_options[@]} ${other_options[@]}; do if [ "${opt}" = "${kopt}" -o "${opt}" = "!${kopt}" ]; then known=1 fi |