buildpkg/newpkg
Tom G. Christensen 410760a6d3 Introduce a new format for the automatically generated version field.
By extending it to a mandatory 8 digits and padding it with zeroes on the
right side it should be possible to avoid problems with version numbers
changing format.
This means  1.19.5->1.20 should be handled correctly now.

Add support for the new subsys.conf keyword (defalt/nodefault).

Flesh out the auto_rel function to help with release notes maintenance.
Added a relnotes.template.irix and make newpkg install a copy
into new sandboxes.
Also clean up newpkg a bit.

Fix a problem with the fix_man function and how to locate the man pages.
The problem was discoved when building gcc-3.4.1 into
$prefix=/usr/local/gcc-3.4.1 and still needing $topinstalldir
to be /usr/local. We now attempt to find any extra subdirs
needed by comparing $prefix and $topinstalldir.
2009-12-19 14:38:40 +01:00

37 lines
822 B
Bash

#!/bin/bash
#
# A simple script to create a sandbox for a new package
#
# params: $1=topdir ie. bash
#
. ${BUILDPKG_BASE}/scripts/buildpkg.functions
REQ_DIRS="stage src meta"
arg1=${1-'x'}
if [ "$arg1" == "x" ]; then
error $E_MISSING_ARGS
else
setdir "$buildpkgbase"
fi
echo "Creating sandbox for $arg1"
$MKDIR "$arg1"
for i in $REQ_DIRS
do
mkdir $arg1/$i
done
$CP scripts/build.sh.generic $arg1/build.sh
chmod 755 $arg1/build.sh
if [ "$($UNAME -s)" == "IRIX" ]; then
$SED -e 's/bin\/bash/usr\/local\/bin\/bash/g' $arg1/build.sh > $arg1/build.sh.tmp
$MV $arg1/build.sh.tmp $arg1/build.sh
$CP scripts/pkgdef.template.irix $arg1/meta/pkgdef
$CP scripts/relnotes.template.irix $arg1/meta/relnotes
fi
if [ "$($UNAME -s)" == "SunOS" ]; then
$CP scripts/pkgdef.template $arg1/meta/pkgdef
fi