diff options
author | Justin Davis <jrcd83@gmail.com> | 2012-05-15 18:47:20 +0200 |
---|---|---|
committer | Justin Davis <jrcd83@gmail.com> | 2012-05-15 18:47:20 +0200 |
commit | 296d7c4ad39fe4b0da0a08f6c16af7387b581fb5 (patch) | |
tree | 308045f4aa0622f389232655d48735e94ec26572 /bin | |
parent | 7fd10a393b2b47244e202f2c697da659db5bd3f6 (diff) | |
download | genpkg-296d7c4ad39fe4b0da0a08f6c16af7387b581fb5.tar.gz genpkg-296d7c4ad39fe4b0da0a08f6c16af7387b581fb5.tar.xz |
Duplicate the version in the prepkg step of genpkg.
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/genpkg | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -102,8 +102,10 @@ do [ -d PKGTREE ] && rm -rf PKGTREE mkdir PKGTREE + # Duplicate the version in case modpkg modifies it. vervar will remove a + # redundant ver field that is the same as pkgver. trap 'rm -f PKGDATA' 1 2 15 - if PREPSPATH="$prepd" PKGVAR="$vard" prepkg "$pkg" > PKGDATA + if PREPSPATH="$prepd" PKGVAR="$vard" prepkg "$pkg" | dupver > PKGDATA then echo "$pkgd/$pkg" else @@ -115,8 +117,8 @@ do mod="$modsd/$pkg" if [ -f "$mod" -a -r "$mod" ] then - trap 'rm PKGDATA.new' 1 2 15 - if cat PKGDATA | dupver | modpkg "$mod" > PKGDATA.new + trap 'rm -f PKGDATA.new' 1 2 15 + if modpkg "$mod" < PKGDATA > PKGDATA.new then echo "Modified with $mod." 1>&2 mv PKGDATA.new PKGDATA |