Subject: Re: MD patches
To: None <tech-pkg@netbsd.org>
From: Kazuki Sakamoto <sakamoto@cec.co.jp>
List: tech-pkg
Date: 07/14/1999 11:21:07
mcmahill@mtl.mit.edu wrote:

 > yeah, this is an ugly one.  Basically depending on i386, sparc (and
 > hopefully alpha), the distfile is different.  Each distfile has different
 > contents.  In fact the i386 creates its own subdir under 'work', but the
 > sparc one doesn't.  Then its different shell scripts.  The install script

I modified acroread pkg for helping sparc,alpha.

files/patch-${MACHINE_ARCH}	(md5 patch-${MACHINE_ARCH} >> patch-sum)
files/acroread-${MACHINE_ARCH}
pkg/PLIST-${MACHINE_ARCH}

Kazuki Sakamoto

--
# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	acroread/files/patch-i386
#	acroread/files/md5
#	acroread/files/acroread-i386
#	acroread/files/patch-sum
#	acroread/pkg/PLIST.i386
#	acroread/pkg/COMMENT
#	acroread/pkg/DESCR
#	acroread/Makefile
#
echo x - acroread/files/patch-i386
sed 's/^X//' >acroread/files/patch-i386 << 'END-of-acroread/files/patch-i386'
X$NetBSD: patch-aa,v 1.3 1999/06/17 01:04:29 sakamoto Exp $
X
X+++ INSTALL	Wed Nov 20 17:37:14 1996
X@@ -117,6 +117,8 @@
X     if [ "$i" -a -f "$i" ] ; then
X         if [ `uname -s` = "Linux" ] ; then
X           size=`ls -lLn "$i" | ( read perm links owner group size date ; echo $size )`
X+        elif [ `uname -s|sed -e 's|.*\(...\)|\\1|'` = "BSD" ] ; then
X+          size=`ls -lL "$i" | ( read perm links owner group size date ; echo $size )`
X         else
X           size=`ls -lLon "$i" | ( read perm links owner size date ; echo $size )`
X         fi
X@@ -559,7 +561,7 @@
X   *) ScriptDirectory="$CurrentDirectory"/"$ScriptDirectory" ;;
X esac
X 
X-if [ "`type uname`" != "uname not found" ] ; then
X+if [ "`uname`" != "uname not found" ] ; then
X   OSname=`uname -s`
X   if [ "$OSname" = "AIX" ] ; then
X     OSrelease=`uname -a | ( read name host minor major foo ; echo $major.$minor )`
X@@ -1044,7 +1046,7 @@
X     DistDefaultNum="$DistIntelBSDINum"
X     DefaultName="Intel/BSDI"
X     ;;
X-  Linux)
X+  *BSD|Linux)
X     AcroDefaultNum="$AcroIntelLinuxNum"
X     ExchDefaultNum="$ExchIntelLinuxNum"
X     ReadDefaultNum="$ReadIntelLinuxNum"
END-of-acroread/files/patch-i386
echo x - acroread/files/md5
sed 's/^X//' >acroread/files/md5 << 'END-of-acroread/files/md5'
X$NetBSD: md5,v 1.2 1999/06/16 11:08:31 sakamoto Exp $
X
XMD5 (linux-ar-40.tar.gz) = 018f4aee79e049095a7b16ed1e7ec925
XMD5 (dec-arws-40.tar.gz) = be2ba79ca8c73d95e347d491292d4f0b
XMD5 (sunsparc-arws-40.tar.gz) = 73e8ac1478f7ab1a3961d524808b6182
END-of-acroread/files/md5
echo x - acroread/files/acroread-i386
sed 's/^X//' >acroread/files/acroread-i386 << 'END-of-acroread/files/acroread-i386'
X+++ acroread	Fri Nov 20 17:45:11 1998
X@@ -205,7 +205,7 @@
X     ACRO_CONFIG=intelbsdi
X     export ACRO_CONFIG
X     ;;
X-  Linux)
X+  *BSD|Linux)
X     ACRO_CONFIG=intellinux
X     export ACRO_CONFIG
X     ;;
X@@ -309,6 +309,8 @@
X   intellinux)
X     LD_LIBRARY_PATH="`prepend "$ACRO_INSTALL_DIR/$ACRO_CONFIG/lib:$ACRO_INSTALL_DIR/$ACRO_CONFIG/lib" "$LD_LIBRARY_PATH"`"
X     export LD_LIBRARY_PATH
X+    LC_CTYPE="C"
X+    export LC_CTYPE
X     ;;
X   intelbsdi)
X     ;;
END-of-acroread/files/acroread-i386
echo x - acroread/files/patch-sum
sed 's/^X//' >acroread/files/patch-sum << 'END-of-acroread/files/patch-sum'
X$NetBSD$
X
XMD5 (patch-i386) = 31faa8db5798b527781c4df5b6dffc6c
END-of-acroread/files/patch-sum
echo x - acroread/pkg/PLIST.i386
sed 's/^X//' >acroread/pkg/PLIST.i386 << 'END-of-acroread/pkg/PLIST.i386'
X@comment $NetBSD: PLIST,v 1.2 1999/06/16 11:08:32 sakamoto Exp $
XAcrobat4/Browsers/intellinux/nppdf.so
XAcrobat4/Browsers/netscape
XAcrobat4/Reader/AcroVersion
XAcrobat4/Reader/Acrobat.pdf
XAcrobat4/Reader/License.pdf
XAcrobat4/Reader/MapTypes.pdf
XAcrobat4/Reader/ReadMe
XAcrobat4/Reader/help/reader.pdf
XAcrobat4/Reader/intellinux/app-defaults/AcroRead
XAcrobat4/Reader/intellinux/bin/acroread
XAcrobat4/Reader/intellinux/lib/XKeysymDB
XAcrobat4/Reader/intellinux/lib/libAGM.so
XAcrobat4/Reader/intellinux/lib/libAGM.so.3.0
XAcrobat4/Reader/intellinux/lib/libCoolType.so
XAcrobat4/Reader/intellinux/lib/libCoolType.so.1.0
XAcrobat4/Reader/intellinux/lib/libICC.so
XAcrobat4/Reader/intellinux/lib/libICC.so.1.0
XAcrobat4/Reader/intellinux/lib/libreadcore.so
XAcrobat4/Reader/intellinux/lib/libreadcore.so.4.0
XAcrobat4/Reader/intellinux/plug_ins/AcroForm.api
XAcrobat4/Reader/intellinux/plug_ins/Highlight.api
XAcrobat4/Reader/intellinux/plug_ins/JavaScripts/AFStrENU.js
XAcrobat4/Reader/intellinux/plug_ins/JavaScripts/AForm.js
XAcrobat4/Reader/intellinux/plug_ins/ewh.api
XAcrobat4/Reader/intellinux/plug_ins/wwwlink.api
XAcrobat4/Reader/res/splashScreen11R.xbm
XAcrobat4/Reader/res/splashScreen18R.xpm
XAcrobat4/Reader/res/splashScreen21.xbm
XAcrobat4/Reader/res/splashScreen28.xpm
XAcrobat4/Resource/Font/AdobeSansMM
XAcrobat4/Resource/Font/AdobeSansMM.MMM
XAcrobat4/Resource/Font/AdobeSerifMM
XAcrobat4/Resource/Font/AdobeSerifMM.MMM
XAcrobat4/Resource/Font/Arial
XAcrobat4/Resource/Font/Arial-Bold
XAcrobat4/Resource/Font/Arial-BoldItalic
XAcrobat4/Resource/Font/Arial-Italic
XAcrobat4/Resource/Font/Courier
XAcrobat4/Resource/Font/Courier-Bold
XAcrobat4/Resource/Font/Courier-BoldOblique
XAcrobat4/Resource/Font/Courier-Oblique
XAcrobat4/Resource/Font/Fonts14.upr
XAcrobat4/Resource/Font/Symbol
XAcrobat4/Resource/Font/TimesNewRoman
XAcrobat4/Resource/Font/TimesNewRoman-Bold
XAcrobat4/Resource/Font/TimesNewRoman-BoldItalic
XAcrobat4/Resource/Font/TimesNewRoman-Italic
XAcrobat4/Resource/Font/ZapfDingbats
XAcrobat4/bin/acroread
Xbin/acroread4
X@exec ln -sf ../../Resource/Font/ %D/Acrobat4/Reader/intellinux/fonts
X@unexec rm -f %D/Acrobat4/Reader/intellinux/fonts
X@exec ln -sf ../../res %D/Acrobat4/Reader/intellinux/res
X@unexec rm -f %D/Acrobat4/Reader/intellinux/res
X@dirrm Acrobat4/bin
X@dirrm Acrobat4/Resource/Font
X@dirrm Acrobat4/Resource
X@dirrm Acrobat4/Reader/res
X@dirrm Acrobat4/Reader/intellinux/plug_ins/JavaScripts
X@dirrm Acrobat4/Reader/intellinux/plug_ins
X@dirrm Acrobat4/Reader/intellinux/lib
X@dirrm Acrobat4/Reader/intellinux/bin
X@dirrm Acrobat4/Reader/intellinux/app-defaults
X@dirrm Acrobat4/Reader/intellinux
X@dirrm Acrobat4/Reader/help
X@dirrm Acrobat4/Reader
X@dirrm Acrobat4/Browsers/intellinux
X@dirrm Acrobat4/Browsers
X@dirrm Acrobat4
END-of-acroread/pkg/PLIST.i386
echo x - acroread/pkg/COMMENT
sed 's/^X//' >acroread/pkg/COMMENT << 'END-of-acroread/pkg/COMMENT'
XView, distribute and print PDF documents.
END-of-acroread/pkg/COMMENT
echo x - acroread/pkg/DESCR
sed 's/^X//' >acroread/pkg/DESCR << 'END-of-acroread/pkg/DESCR'
XAcrobat Reader is part of the Adobe Acrobat family of software, which lets 
Xyou view, distribute, and print documents in Portable Document Format 
X(PDF)--regardless of the computer, operating system, fonts, or application 
Xused to create the original file.  PDF files retain all the formatting, 
Xfonts, and graphics of the original document, and virtually any 
XPostScript(TM) document can be converted into a PDF file.
END-of-acroread/pkg/DESCR
echo x - acroread/Makefile
sed 's/^X//' >acroread/Makefile << 'END-of-acroread/Makefile'
X# $NetBSD: Makefile,v 1.4 1999/07/01 23:28:31 tron Exp $
X# FreeBSD Id: Makefile,v 1.13 1999/04/08 07:49:18 dima Exp $
X
XPKGNAME=	acroread-4.0
XCATEGORIES=	print
XMASTER_SITES=	ftp://ftp-pac.adobe.com/pub/adobe/acrobatreader/unix/4.x/
X
XMAINTAINER=	packages@netbsd.org
XHOMEPAGE=	http://www.adobe.com/prodindex/acrobat/readstep.html
X
XIS_INTERACTIVE=	YES
XRESTRICTED=	"Original installer required to redistribute."
X
XNO_BUILD=	YES
X
X.if (${MACHINE_ARCH} == "i386")
X.if !exists(/emul/linux/lib/ld-linux.so.2)
XIGNORE=	requires Linux glibc2 libraries - see compat_linux(8)
X.endif
XDISTNAME=	linux-ar-40
XWRKSRC=		${WRKDIR}/ILINXR.install
X#.elif (${MACHINE_ARCH} == "alpha")
X#.if !exists(/emul/osf1/sbin/loader)
X#IGNORE=	requires Digital UNIX libraries - see compat_osf1(8)
X#.endif
X#DISTNAME=	dec-arws-40
X#WRKSRC=	${WRKDIR}/AOSFRS.install
X#.elif (${MACHINE_ARCH} == "sparc")
X#.if !exists(/emul/sunos/usr/lib/ld.so)
X#IGNORE=	requires SunOS libraries - see compat_sunos(8)
X#.endif
X#DISTNAME=	sunsparc-arws-40
X#WRKSRC=	${WRKDIR}/SSOLRS.install
X.else
XDISTNAME=	${PKGNAME}
X.endif
X
XPATCHFILES=	${FILESDIR}/patch-${MACHINE_ARCH}
XPLIST_SRC=	PLIST-${MACHINE_ARCH}
X
XONLY_FOR_PLATFORM=	*-*-i386 *-*-alpha *-*-sparc
X
Xdo-install:
X	@${MKDIR} ${PREFIX}/Acrobat4
X	@ReadInstallDir=${PREFIX}/Acrobat4 ${WRKSRC}/INSTALL
X
Xpost-install:
X	@cd ${PREFIX}/Acrobat4/bin && \
X	  ${PATCH} --quiet < ${FILESDIR}/acroread-${MACHINE_ARCH} && \
X	  ${INSTALL_SCRIPT} ${PREFIX}/Acrobat4/bin/acroread \
X	     ${PREFIX}/bin/acroread4 && ${RM} acroread.orig
X	@chmod +x ${PREFIX}/bin/acroread4
X	@${ECHO_MSG} "Be sure to read the license agreement in"
X	@${ECHO_MSG} "${PREFIX}/Acrobat4/Reader/License.pdf"
X
X.include "../../mk/bsd.pkg.mk"
END-of-acroread/Makefile
exit