This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
deb-goldedplus/dist-sx86.sh

85 lines
3.4 KiB
Bash
Raw Normal View History

#!/bin/sh
# Create an archive 'gpsunx86-115-*.zip' (gpsunx86-115-YMMDD.zip)
# with binary SunOS x86 build installable package
pkgdir=bin/pkg
2006-02-02 10:00:15 +00:00
vendor=`sed -n -e "/^#define __GVER_VENDOR_NAME__/s/#define __GVER_VENDOR_NAME__ \"\(.*\)\"/\1/p" golded3/mygolded.h`
email=`sed -n -e "/^#define __GVER_VENDOR_EMAIL__/s/#define __GVER_VENDOR_EMAIL__ \"\(.*\)\"/\1/p" golded3/mygolded.h`
date=`date +%Y%m%d`
name=bin/gpsunx86-115-${date}.zip
pkgname=golded-plus-x86-115-${date}.pkg
dizfile=bin/file_id.diz
2006-02-18 19:03:30 +00:00
echo Build a Golded+/sunX86 binary package: ${name} \(${pkgname}\)
2006-02-18 14:08:47 +00:00
if [ ! -f golded3/mygolded.h ]; then
cp golded3/mygolded.__h golded3/mygolded.h
2006-02-20 08:42:13 +00:00
echo "golded3/mygolded.h is created now. Please edit this file"
exit 1
fi
2011-02-13 21:54:37 +00:00
#gsed -i.orig -e "s/\#define __GVER_POSTVERSION__ .*/\#define __GVER_POSTVERSION__ \"-b${date}\"/" golded3/mygolded.h
if [ ! -d "bin" ] ; then mkdir bin; fi
printf "GoldED+1.1.5 [`uname` `uname -i` pkg]\r\n" >${dizfile}
printf 'Snapshot (development version)\r\n' >>${dizfile}
printf 'This is unstable release and\r\n' >>${dizfile}
printf 'it should be used for testing.\r\n' >>${dizfile}
printf -- '------------------------------\r\n' >>${dizfile}
printf 'GoldED+ is a successor of the\r\n' >>${dizfile}
printf 'wellknown GoldED mail editor.\r\n' >>${dizfile}
printf -- '------------------------------\r\n' >>${dizfile}
printf '*golded-plus.sourceforge.net* \r\n' >>${dizfile}
# make binaries
gmake PLATFORM=sun clean
gmake PLATFORM=sun
gmake PLATFORM=sun strip
2006-02-02 10:00:15 +00:00
cd docs
gmake tokentpl.txt tokencfg.txt
cd ..
2006-02-20 08:39:04 +00:00
for i in bin/gedsun bin/gnsun bin/rddtsun ; do
if [ ! -f ${i} ] ; then echo "File ${i} not exists, stop!"; exit 1 ; fi
2006-02-20 08:39:04 +00:00
done
# creating package
if [ -d "$pkgdir" ] ; then rm -rf $pkgdir ; fi
mkdir $pkgdir
(echo "i pkginfo=./pkginfo" ;\
echo "i depend=./depend" ;\
echo "d none bin 0755 root root" ;\
echo "d none share 0755 root root" ;\
echo "d none share/golded+ 0755 root root" ;\
echo "d none share/man 0755 root root" ;\
echo "d none share/man/man1 0755 root root" ;\
((pkgproto bin/gedsun=bin/golded bin/gnsun=bin/goldnode bin/rddtsun=bin/rddt ;\
for i in docs/*.1 ; do pkgproto $i=share/man/man1/`basename $i` ; done ;\
pkgproto cfgs=share/golded+/cfgs ;\
(pkgproto docs=share/golded+/docs | grep -v building.txt | grep -v linux | grep -v "\.1=" | grep -v "\.html=") ;\
(pkgproto manuals=share/golded+/manuals | grep -v "\.tei=") ) | grep -v CVS | grep -v `basename ${dizfile}` | grep -v Makefile |\
gsed "s/\.\(chs\|bbs\|cfg\|esc\) 0755 /.\1 0644 /" | awk '{print $1 " " $2 " " $3 " " $4 " root root"}' )) \
>$pkgdir/Prototype
echo 'P CSWncurses ncurses - ncurses library and utilities' > $pkgdir/depend
echo 'ARCH="i386"' > $pkgdir/pkginfo
echo 'CATEGORY="application"' >> $pkgdir/pkginfo
echo 'NAME="GoldED+1.1.5 - FTN mail editor"' >> $pkgdir/pkginfo
echo 'PKG="CSWgolded+"' >> $pkgdir/pkginfo
echo 'CLASSES="none"' >> $pkgdir/pkginfo
echo 'VERSION="1.1.5"' >> $pkgdir/pkginfo
echo 'BASEDIR="/opt/csw"' >> $pkgdir/pkginfo
echo "EMAIL=\"$email\"" >> $pkgdir/pkginfo
echo "VENDOR=\"http://golded-plus.sourceforge.net/ packaged by $vendor\"" >> $pkgdir/pkginfo
echo 'HOTLINE="http://golded-plus.sourceforge.net"' >> $pkgdir/pkginfo
2006-02-02 10:00:15 +00:00
echo 'MAXINST="1"' >> $pkgdir/pkginfo
cd $pkgdir
pkgmk -o -d . -f ./Prototype -r ../..
echo 1|pkgtrans -s . ../$pkgname
cd ../..
rm -rf $pkgdir
# zipping
zip -9DXj ${name} ${dizfile} bin/$pkgname