Make pkgdef filename a global variable

This commit is contained in:
Tom G. Christensen 2019-05-31 10:06:32 +02:00
parent 7eb78af9ae
commit 3cd10f85d4

View File

@ -108,6 +108,12 @@ configure_args=(--prefix=$prefix --mandir=${prefix}/${_mandir} --infodir=${prefi
# evaluated (using _upls) # evaluated (using _upls)
distfile='$secname-$version-$secver.tgc-$os-$build_arch-$pkgdirdesig' distfile='$secname-$version-$secver.tgc-$os-$build_arch-$pkgdirdesig'
# What pkgdef file to use
pkgdef_file=pkgdef
# Check and see if there is an arch specific pkgdef file
[ -r $metadir/pkgdef.$arch ] && pkgdef_file=pkgdef.$arch
[ -r $metadir/pkgdef.$build_arch ] && pkgdef_file=pkgdef.$build_arch
##################################################### #####################################################
# "external" functions # "external" functions
##################################################### #####################################################
@ -659,7 +665,7 @@ auto_deps()
done >> $metadir/depend.$secname.auto done >> $metadir/depend.$secname.auto
} }
# parse_pkgdef(): Read in $metadir/pkgdef # parse_pkgdef(): Read in $metadir/$pkgdef_file
# params: none # params: none
# This will parse the package descriptions in # This will parse the package descriptions in
# pkgdef that tells us how many packages there # pkgdef that tells us how many packages there
@ -673,11 +679,6 @@ parse_def()
local legalend=0 local legalend=0
local hasaddedpkginfo=0 local hasaddedpkginfo=0
local condexpr="" local condexpr=""
local pkgdef_file=pkgdef
# Check and see if there is an arch specific pkgdef file
[ -r $metadir/pkgdef.$arch ] && pkgdef_file=pkgdef.$arch
[ -r $metadir/pkgdef.$build_arch ] && pkgdef_file=pkgdef.$build_arch
while read line while read line
do do