diff options
author | glewis <glewis@FreeBSD.org> | 2008-02-07 01:11:43 +0800 |
---|---|---|
committer | glewis <glewis@FreeBSD.org> | 2008-02-07 01:11:43 +0800 |
commit | 0b281d1b4e17b77b099ea1e7ed2260c416c9b12d (patch) | |
tree | f93c4ee1cac080583c1db1fbec7c9dff7176cff7 /print | |
parent | 76485c0d220d383037cbc3ccf2af8e5779391582 (diff) | |
download | freebsd-ports-gnome-0b281d1b4e17b77b099ea1e7ed2260c416c9b12d.tar.gz freebsd-ports-gnome-0b281d1b4e17b77b099ea1e7ed2260c416c9b12d.tar.zst freebsd-ports-gnome-0b281d1b4e17b77b099ea1e7ed2260c416c9b12d.zip |
. Make this port run. Its always built correctly, but I've had problems
running it. The changes include:
. Pull in stubs for the MRJToolkit classes. These are not used, but
some are imported, so the app was failing with NoClassDef errors.
. Eliminate the build dependency on Perl.
. Use standard ways of depending on Java.
. Don't install unnecessary stuff.
. Install in appropriate directories and respect NOPORTDOCS.
. Replace the relatively complicated and non-working launcher script
supplied with a simple version that uses javavm(1).
Diffstat (limited to 'print')
-rw-r--r-- | print/acrobatviewer/Makefile | 70 | ||||
-rw-r--r-- | print/acrobatviewer/distinfo | 3 | ||||
-rw-r--r-- | print/acrobatviewer/files/patch-aa | 48 | ||||
-rw-r--r-- | print/acrobatviewer/files/patch-ab | 11 | ||||
-rw-r--r-- | print/acrobatviewer/pkg-plist | 13 |
5 files changed, 42 insertions, 103 deletions
diff --git a/print/acrobatviewer/Makefile b/print/acrobatviewer/Makefile index 99edbafcf050..83b2153cb761 100644 --- a/print/acrobatviewer/Makefile +++ b/print/acrobatviewer/Makefile @@ -7,35 +7,29 @@ PORTNAME= acrobatviewer PORTVERSION= 1.1 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= print java -MASTER_SITES= ftp://ftp.adobe.com/pub/adobe/magic/acrobatviewer/unix/1.x/ -DISTNAME= viewer.bin -EXTRACT_SUFX= +DISTFILES= viewer.bin:1 MRJToolkitStubs.zip:2 +MASTER_SITES= ftp://ftp.adobe.com/pub/adobe/magic/acrobatviewer/unix/1.x/:1 \ + http://developer.apple.com/samplecode/MRJToolkitStubs/:2 MAINTAINER= ports@FreeBSD.org COMMENT= Viewer for the PDF files written in Java(TM) -#RUN_DEPENDS= ${JAVAVM}:${PORTSDIR}/java/javavmwrapper \ -# ${LOCALBASE}/etc/javavms:${PORTSDIR}/java/jre -RUN_DEPENDS= ${JAVAVM}:${PORTSDIR}/java/javavmwrapper - USE_ZIP= yes -USE_XLIB= yes -USE_PERL5_BUILD=yes +USE_JAVA= yes +JAVA_VERSION= 1.3+ NO_BUILD= yes +SUB_FILES+= AcrobatViewer +SUB_LIST+= PORTNAME=${PORTNAME} -JAVAVM= ${LOCALBASE}/bin/javavm - -INSTSBDR= ${PREFIX}/share/java/AdobeAcrobatViewer - -# For the end-users this "InstallAnywhere" whizard probably is a great step -# toward Windowze-like software installations comparing with traditional -# "make install" enviropment, but for *nix administrator it is a pain to deal -# with. Fortunately, Zero G (author of the InstallAnywhere) does not use -# propiertary format for archiving files, so it was possible for me to make -# following dirty hack. If they will provide better way to centralise -# installations in the next versions of InstallAnywhere than I'll be glad to +# For the end-users this "InstallAnywhere" wizard probably is a great step +# toward Windows-like software installations compared with the traditional +# "make install" paradigm, but for Unix administrators it is a pain to deal +# with. Fortunately, Zero G (author of the InstallAnywhere) does not use a +# proprietary format for archiving files, so it was possible for me to do the +# following dirty hack. If they will provide a better way to centralise +# installations in the next versions of InstallAnywhere then I'll be glad to # remove all following crap. BLOCKSIZE= 32768 @@ -45,25 +39,27 @@ ARCHBLOCKS= 84 do-extract: @${MKDIR} ${WRKSRC} && \ - cd ${WRKSRC} && \ - dd if=${DISTDIR}/${DISTNAME} of=archive.zip bs=${BLOCKSIZE} skip=${ARCHSTART} count=${ARCHBLOCKS} 2>/dev/null && \ - ${LOCALBASE}/bin/unzip -o -a -j -qq archive.zip && \ - ${PERL} -pi -e "s.\x0D.." ${WRKSRC}/AcrobatViewer.lax + cd ${WRKSRC} && \ + dd if=${DISTDIR}/viewer.bin of=archive.zip bs=${BLOCKSIZE} skip=${ARCHSTART} count=${ARCHBLOCKS} 2>/dev/null && \ + ${LOCALBASE}/bin/unzip -o -a -j -qq archive.zip + @${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} \ + ${DISTDIR}/MRJToolkitStubs.zip ${EXTRACT_AFTER_ARGS} -do-configure: - @${PERL} -pi -e "s|%INSTDIR%|${INSTSBDR}|g" ${WRKSRC}/AcrobatViewer.lax && \ - ${PERL} -pi -e "s|%JAVAVM%|${JAVAVM}|g" ${WRKSRC}/AcrobatViewer.lax && \ - ${PERL} -pi -e "s|%JAVAJIT%|${JAVAJIT}|g" ${WRKSRC}/AcrobatViewer.lax +post-extract: + @cd ${WRKDIR}/MRJToolkitStubs/MRJToolkitStubs && \ + ${JAR} cmf META-INF/MANIFEST.MF MRJToolkitStubs.jar com && \ + ${MV} MRJToolkitStubs.jar ${WRKSRC} do-install: - ${MKDIR} ${INSTSBDR} - ${INSTALL_SCRIPT} ${WRKSRC}/launixgc.sh ${INSTSBDR}/AcrobatViewer - ${INSTALL_DATA} ${WRKSRC}/License.pdf ${INSTSBDR}/ - ${INSTALL_DATA} ${WRKSRC}/help.pdf ${INSTSBDR}/ - ${INSTALL_DATA} ${WRKSRC}/lax.jar ${INSTSBDR}/ - ${INSTALL_DATA} ${WRKSRC}/acrobat.jar ${INSTSBDR}/ - ${INSTALL_DATA} ${WRKSRC}/AcrobatViewer.lax ${INSTSBDR}/ - ${LN} -sf ${INSTSBDR}/AcrobatViewer ${PREFIX}/bin/AcrobatViewer + ${MKDIR} ${JAVAJARDIR}/${PORTNAME} + ${INSTALL_DATA} ${WRKSRC}/acrobat.jar ${JAVAJARDIR}/${PORTNAME} + ${INSTALL_DATA} ${WRKSRC}/MRJToolkitStubs.jar ${JAVAJARDIR}/${PORTNAME} +.if !defined(NOPORTDOCS) + ${MKDIR} ${DOCSDIR}/ + ${INSTALL_DATA} ${WRKSRC}/License.pdf ${DOCSDIR}/ + ${INSTALL_DATA} ${WRKSRC}/help.pdf ${DOCSDIR}/ +.endif + ${INSTALL_SCRIPT} ${WRKDIR}/AcrobatViewer ${PREFIX}/bin/AcrobatViewer post-install: @${CAT} ${PKGMESSAGE} diff --git a/print/acrobatviewer/distinfo b/print/acrobatviewer/distinfo index 36f94deddc39..7afd398ff560 100644 --- a/print/acrobatviewer/distinfo +++ b/print/acrobatviewer/distinfo @@ -1,3 +1,6 @@ MD5 (viewer.bin) = 7cc85a3d8856de3bb1dc20eed8bfd466 SHA256 (viewer.bin) = beb9d32fca6f7411ef53f726e68172aeb21c2073f3a989bd16f4f6a6f298fcee SIZE (viewer.bin) = 2782530 +MD5 (MRJToolkitStubs.zip) = e527efeb54794f5f535ae2c3ac1c20c9 +SHA256 (MRJToolkitStubs.zip) = da7fed3f58e740fdb588daf064439356181e498f07dfe1218ac21da801c6f59a +SIZE (MRJToolkitStubs.zip) = 19748 diff --git a/print/acrobatviewer/files/patch-aa b/print/acrobatviewer/files/patch-aa deleted file mode 100644 index df5003a9aa94..000000000000 --- a/print/acrobatviewer/files/patch-aa +++ /dev/null @@ -1,48 +0,0 @@ ---- AcrobatViewer.lax.orig Fri Feb 11 18:02:57 2000 -+++ AcrobatViewer.lax Fri Feb 11 18:04:07 2000 -@@ -4,7 +4,7 @@ - # -------------------- - # name given the launcher in console windows - --lax.application.name=AcrobatViewer.exe -+lax.application.name=AcrobatViewer - - - # LAX.CLASS.PATH -@@ -12,7 +12,7 @@ - # the Java classpath necessary to run this application - # Can be separated by colons or semicolons - --lax.class.path=acrobat.jar;lax.jar -+lax.class.path=acrobat.jar:lax.jar - - - # LAX.COMMAND.LINE.ARGS -@@ -26,7 +26,7 @@ - # ------- - # path to directory holding LaunchAnywhere's native launcher - --lax.dir=C:\\Program Files\\AdobeAcrobatViewer\\ -+lax.dir=%INSTDIR%/ - - - # LAX.MAIN.CLASS -@@ -47,7 +47,8 @@ - # ----------------- - # the VM to use for the next launch - --lax.nl.current.vm=C:\\Java\\jdk1.1.8\\bin\\jre.exe -+lax.nl.current.vm=%JAVAVM% -+lax.nl.java.compiler=%JAVAJIT% - - - # LAX.NL.JAVA.LAUNCHER.MAIN.CLASS -@@ -104,7 +105,7 @@ - # -------------------- - # path to the installdir magic folder - --lax.root.install.dir=C:\\Program Files\\AdobeAcrobatViewer -+lax.root.install.dir=%INSTDIR% - - - # LAX.STDERR.REDIRECT diff --git a/print/acrobatviewer/files/patch-ab b/print/acrobatviewer/files/patch-ab deleted file mode 100644 index fa7cd1070117..000000000000 --- a/print/acrobatviewer/files/patch-ab +++ /dev/null @@ -1,11 +0,0 @@ ---- launixgc.sh.orig Thu Dec 2 09:30:38 1999 -+++ launixgc.sh Fri Feb 11 18:00:40 2000 -@@ -421,6 +421,8 @@ - if [ ${jittype:-""} = "off" ] - then - jitinvoc="-Djava.compiler=" -+ else -+ jitinvoc="-Djava.compiler=$jittype" - fi - fi - diff --git a/print/acrobatviewer/pkg-plist b/print/acrobatviewer/pkg-plist index 836d8a8511ad..54687938645c 100644 --- a/print/acrobatviewer/pkg-plist +++ b/print/acrobatviewer/pkg-plist @@ -1,8 +1,7 @@ bin/AcrobatViewer -share/java/AdobeAcrobatViewer/AcrobatViewer -share/java/AdobeAcrobatViewer/AcrobatViewer.lax -share/java/AdobeAcrobatViewer/License.pdf -share/java/AdobeAcrobatViewer/acrobat.jar -share/java/AdobeAcrobatViewer/help.pdf -share/java/AdobeAcrobatViewer/lax.jar -@dirrm share/java/AdobeAcrobatViewer +%%JAVAJARDIR%%/acrobatviewer/acrobat.jar +%%JAVAJARDIR%%/acrobatviewer/MRJToolkitStubs.jar +%%PORTDOCS%%%%DOCSDIR%%/License.pdf +%%PORTDOCS%%%%DOCSDIR%%/help.pdf +@dirrm %%JAVAJARDIR%%/acrobatviewer +@dirrm %%DOCSDIR%% |