m4 1.4.1 prerelease from RH sources

This commit is contained in:
Tom G. Christensen 2003-10-14 08:05:27 +00:00 committed by tgc
parent dcfc2c2ea7
commit 923472b61c
2 changed files with 119 additions and 0 deletions

108
m4/build.sh Executable file
View File

@ -0,0 +1,108 @@
#!/bin/bash
#
# This is a generic build.sh script
# It can be used nearly unmodified with many packages
#
# The concept of "method" registering and the logic that implements it was shamelessly
# stolen from jhlj's Compile.sh script :)
#
# Check the following 4 variables before running the script
topdir=m4
version=1.4.1
pkgver=2
source[0]=$topdir-$version.tar.gz
# If there are no patches, simply comment this
patch[0]=m4-1.4.1-sec.patch
patch[1]=m4-1.4.1-configure.patch
# Source function library
. ${BUILDPKG_BASE}/scripts/buildpkg.functions
# Fill in pkginfo values if necessary
# using pkgname,name,pkgcat,pkgvendor & pkgdesc
name="GNU m4 - Macro processor"
pkgcat="application"
pkgvendor="http://www.gnu.org"
pkgdesc="An implementation of the traditional UNIX macro processor"
# Define script functions and register them
METHODS=""
reg() {
METHODS="$METHODS $1"
}
reg prep
prep()
{
generic_prep
}
reg build
build()
{
setdir source
autoreconf -f
generic_build
}
reg install
install()
{
setdir source
$MAKE_PROG prefix=$stagedir INSTALL_DATA="/usr/local/bin/install -c -m644" install
}
reg pack
pack()
{
generic_pack shortroot
}
reg distclean
distclean()
{
clean distclean
}
###################################################
# No need to look below here
###################################################
reg all
all()
{
for METHOD in $METHODS
do
case $METHOD in
all*|*clean) ;;
*) $METHOD
;;
esac
done
}
reg
usage() {
echo Usage $0 "{"$(echo $METHODS | tr " " "|")"}"
exit 1
}
OK=0
for METHOD in $*
do
METHOD=" $METHOD *"
if [ "${METHODS%$METHOD}" == "$METHODS" ] ; then
usage
fi
OK=1
done
if [ $OK = 0 ] ; then
usage;
fi
for METHOD in $*
do
( $METHOD )
done

11
m4/meta/pkginfo.in Normal file
View File

@ -0,0 +1,11 @@
PKG="%%pkgname%%"
NAME="%%name%%"
ARCH="sparc"
VERSION="%%version%%"
CATEGORY="%%pkgcat%%"
VENDOR="%%pkgvendor%%"
EMAIL="Tom G. Christenen - tgc@statsbiblioteket.dk"
PSTAMP="%%pkgver%%"
BASEDIR="%%topinstalldir%%"
CLASSES="none"
DESC="%%pkgdesc%%"