Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Jan 2002 17:52:17 -0800 (PST)
From:      "David H. Munro" <munro1@llnl.gov>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/34471: upgrade yorick port
Message-ID:  <200201310152.g0V1qHk13350@jordan.llnl.gov>

next in thread | raw e-mail | index | archive | help

>Number:         34471
>Category:       ports
>Synopsis:       upgrade yorick port
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jan 30 18:00:02 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     David H. Munro
>Release:        FreeBSD 4.4-RELEASE i386
>Organization:
LLNL
>Environment:
System: FreeBSD jordan.llnl.gov 4.4-RELEASE FreeBSD 4.4-RELEASE #0: Wed Jan 16 22:14:13 PST 2002 wea@jordan.llnl.gov:/usr/src/sys/compile/JORDAN.2 i386
>Description:
yorick-1.5.07 upgrades existing yorick-1.5.02 port to use new source
  and be more consistent with other 1.5.07 distributions
deletes   files/patch-ab files/
adds      pkg-install
>How-To-Repeat:
>Fix:
diff -ruN yorick.orig/Makefile yorick/Makefile
--- yorick.orig/Makefile	Mon Dec 24 02:37:45 2001
+++ yorick/Makefile	Wed Jan 30 16:27:43 2002
@@ -5,44 +5,83 @@
 # $FreeBSD: ports/lang/yorick/Makefile,v 1.9 2001/12/24 10:37:45 dirk Exp $
 #
 
+# History: 1.4.1 port by Pedro Giffuni <giffunip@asme.org>
+#          1.5.02 port by ports@FreeBSD.org,
+#                 from submission by Ed Alley <wea@llnl.gov>
+#          1.5.07 port by David H. Munro <munro1@llnl.gov>
+# 1.5.07 notes:
+# (1) info pages installed in PREFIX/info for consistency with other apps
+#     -- really should be in PREFIX/share/info
+# (2) several fixes to allow PREFIX for package install to be different
+#     from PREFIX at build time (which is compiled into yorick and gist):
+#     (a) PREFIX/bin/{yorick,gist} are softlinks, which allows
+#         yorick and gist to compute ${PREFIX}/lib/${PORTNAME} at runtime
+#     (b) softlink for g/ put in lib/${PORTNAME} for gist
+#     (c) softlink doc/ so yorick online help is correct
+#     (d) copy of paths.i put in lib/${PORTNAME}/bin for yorick
+#     (e) pkg-install script added to fiddle softlinks, paths.i, and
+#         Maketmpl if PREFIX has changed at install time
+#     -- assume DOCSDIR and DATADIR take default values as does pkg-plist
+
 PORTNAME=	yorick
-PORTVERSION=	1.5.02
+PORTVERSION=	1.5.07
 CATEGORIES=	lang math
 MASTER_SITES=	ftp://ftp-icf.llnl.gov/pub/Yorick/ \
 		ftp://wuarchive.wustl.edu/languages/yorick/
 EXTRACT_SUFX=	.tgz
 
-MAINTAINER=	ports@FreeBSD.org
+MAINTAINER=	munro1@llnl.gov
 
 WRKSRC=		${WRKDIR}/${PORTNAME}-${PORTVERSION:R}
 
 USE_XLIB=	yes
-MAKE_ARGS=	Y_HOME="${PREFIX}/lib/${PORTNAME}" Y_SITE="${DATADIR}"
+MAKE_ARGS=	Y_HOME="${PREFIX}/lib/${PORTNAME}" Y_SITE="${DATADIR}" \
+		Y_DOCDIR=/dev/null
 MAN1=		yorick.1 gist.1
 
 PORTDOCS=	FILE_FORMATS README drat.doc drat.tex graph.doc hex.doc \
-		library.doc math.doc refs.ps refs.tex std.doc yorick.pdf \
-		yorick.ps yorick.tex
-
-post-patch:
-	@${PERL} -pi -e \
-		's|/usr/X11R6|${X11BASE}|g' ${WRKSRC}/play/x11/xconfig.sh
+		library.doc math.doc refs.pdf refs.ps refs.tex std.doc \
+		yorick.pdf yorick.ps yorick.tex
 
 do-configure:
 	@(cd ${CONFIGURE_WRKSRC}; ${SETENV} ${MAKE_ENV} \
 		${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} ysite config)
 
+post-build:
+.if !defined(NOPORTDOCS)
+	cd ${WRKSRC}/doc; make yorick.info
+	${GZIP_CMD} ${WRKSRC}/doc/yorick.info*
+.endif
+
 post-install:
+.if !exists(${PREFIX}/bin)
+	@${MKDIR} ${PREFIX}/bin
+.endif
+.if !exists(${PREFIX}/man/man1)
+	@${MKDIR} ${PREFIX}/man/man1
+.endif
 .for file in gist yorick
 	${INSTALL_MAN} ${WRKSRC}/doc/${file}.1 ${PREFIX}/man/man1
-	@strip ${PREFIX}/lib/${PORTNAME}/bin/${file}
+	@${STRIP_CMD} ${PREFIX}/lib/${PORTNAME}/bin/${file}
 	@${LN} -sf ${PREFIX}/lib/${PORTNAME}/bin/${file} ${PREFIX}/bin/${file}
 .endfor
+	@${STRIP_CMD} ${PREFIX}/lib/${PORTNAME}/lib/codger
+	${INSTALL_DATA} ${WRKSRC}/emacs/yorick.el ${DATADIR}
+	@${LN} -sf ../../share/${PORTNAME}/g ${PREFIX}/lib/${PORTNAME}/g
+	@${CP} ${DATADIR}/i0/paths.i ${PREFIX}/lib/${PORTNAME}/bin/paths.i
 .if !defined(NOPORTDOCS)
 	@${MKDIR} ${DOCSDIR}
 .for file in ${PORTDOCS}
 	${INSTALL_DATA} ${WRKSRC}/doc/${file} ${DOCSDIR}
 .endfor
+	@${LN} -sf ../doc/${PORTNAME} ${DATADIR}/doc
+.if !exists(${PREFIX}/info)
+	@${MKDIR} ${PREFIX}/info
+.endif
+	for f in ${WRKSRC}/doc/yorick.info*; do \
+	  ${INSTALL_DATA} $$f ${PREFIX}/info; \
+	done
+	install-info --entry='* Yorick: (yorick).  Yorick interpreted language.' ${PREFIX}/info/yorick.info.gz ${PREFIX}/info/dir
 .endif
 
 .include <bsd.port.mk>
diff -ruN yorick.orig/distinfo yorick/distinfo
--- yorick.orig/distinfo	Fri Sep 21 23:12:03 2001
+++ yorick/distinfo	Fri Jan 25 13:51:25 2002
@@ -1 +1 @@
-MD5 (yorick-1.5.02.tgz) = 0b8db7534b52e9fbaf9ab80d9d826a80
+MD5 (yorick-1.5.07.tgz) = 52f2c0714cdb9bfc8cccb51957bb7aea
diff -ruN yorick.orig/files/patch-ab yorick/files/patch-ab
--- yorick.orig/files/patch-ab	Fri Sep 21 23:12:03 2001
+++ yorick/files/patch-ab	Wed Dec 31 16:00:00 1969
@@ -1,18 +0,0 @@
---- install.sh.orig	Sat May 12 03:56:33 2001
-+++ install.sh	Wed Sep 19 23:40:58 2001
-@@ -91,7 +91,6 @@
- if test ! -d $Y_SITE/i; then mkdir $Y_SITE/i; fi
- if test ! -d $Y_SITE/i0; then mkdir $Y_SITE/i0; fi
- if test ! -d $Y_SITE/g; then mkdir $Y_SITE/g; fi
--if test ! -d $Y_SITE/doc; then mkdir $Y_SITE/doc; fi
- rm -f $Y_SITE/junk.tst
- touch ./junk.tst
- if test -f $Y_SITE/junk.tst; then
-@@ -100,7 +99,6 @@
-   cp -f i/*.i i/README $Y_SITE/i
-   cp -f i0/*.i i0/README $Y_SITE/i0
-   cp -f g/*.gs g/*.gp g/ps.ps g/README $Y_SITE/g
--  cp -f doc/*.tex doc/*.ps doc/*.pdf doc/FILE_FORMATS doc/README doc/*.doc $Y_SITE/doc
- fi
- rm -f ./junk.tst
- 
diff -ruN yorick.orig/pkg-comment yorick/pkg-comment
--- yorick.orig/pkg-comment	Mon Nov 24 01:23:01 1997
+++ yorick/pkg-comment	Wed Jan 30 15:07:22 2002
@@ -1 +1 @@
-An Interpreted Language for Scientific Computing
+Interpreted language and scientific graphics
diff -ruN yorick.orig/pkg-descr yorick/pkg-descr
--- yorick.orig/pkg-descr	Wed Aug 29 20:57:54 2001
+++ yorick/pkg-descr	Wed Jan 30 14:19:33 2002
@@ -1,19 +1,19 @@
-Yorick is an interpreted language like Basic or Lisp.  For an interpreter,
-Yorick is very fast for many scientific applications.  It features:
+Yorick is an interpreted programming language for:
+ * scientific simulations or calculations
+ * postprocessing or steering large simulation codes
+ * interactive scientific graphics
+ * reading, writing, and translating large files of numbers
 
-     * A C-like language, but without declarative statements.
-     * An X window system interactive graphics package.
-     * Yorick's binary file package can read or write floating point
-       formats foreign to the machine where Yorick is running.
-     * A library of functions written in the Yorick language.
-     * Provisions for embedding compiled subroutines and functions within
-       a Yorick interpreter.
+The language features a compact syntax for many common array
+operations, so it processes large arrays of numbers very quickly and
+efficiently.  Superficially, yorick code resembles C code, but yorick
+variables are never explicitly declared and have a dynamic scoping
+similar to many Lisp dialects.  The yorick language is designed to be
+typed interactively at a keyboard, as well as stored in files for
+later use.
 
-Because Yorick can read either text or binary files, it can be used
-"out of the box" as a pre- and post-processor for most existing
-physics simulation programs.
-
-Read the article in the Nov/Dec 1995 issue of Computers in Physics
-(Vol. 9, p. 609) for more details.
+This package includes an emacs-based development environment, which
+you can launch by typing M-x yorick in emacs, if you load
+.../share/yorick/yorick.el in your ~/.emacs file.
 
 WWW: ftp://ftp-icf.llnl.gov/pub/Yorick/doc/index.html
diff -ruN yorick.orig/pkg-install yorick/pkg-install
--- yorick.orig/pkg-install	Wed Dec 31 16:00:00 1969
+++ yorick/pkg-install	Wed Jan 30 15:00:12 2002
@@ -0,0 +1,19 @@
+#!/bin/sh
+if test "$2" = "POST-INSTALL"; then
+  YS=$PKG_PREFIX/share/yorick
+  YH=$PKG_PREFIX/lib/yorick
+  x=`grep "^Y_HOME = $YH" $YH/Maketmpl`
+  if test -z "$x"; then
+    YB=$PKG_PREFIX/lib/yorick/bin
+    ln -sf $YB/gist $PKG_PREFIX/bin/gist
+    ln -sf $YB/yorick $PKG_PREFIX/bin/yorick
+    s="s%^...set_site,.*%set_site, \"$YS\", \"$YH\"\\;%g"
+    sed -e "$s" $YB/paths.i >$YB/paths.tmp
+    mv -f $YB/paths.tmp $YB/paths.i
+    sed -e "s%^Y_SITE = .*%Y_SITE = $YS%g" $YH/Maketmpl >$YH/Maketmpl.tmp
+    rm -f $YH/Maketmpl
+    sed -e "s%^Y_HOME = .*%Y_HOME = $YH%g" $YH/Maketmpl.tmp >$YH/Maketmpl
+    rm -f $YH/Maketmpl.tmp
+  fi
+fi
+true
diff -ruN yorick.orig/pkg-plist yorick/pkg-plist
--- yorick.orig/pkg-plist	Fri Sep 21 23:12:03 2001
+++ yorick/pkg-plist	Wed Jan 30 13:57:11 2002
@@ -3,6 +3,7 @@
 lib/yorick/Make.cfg
 lib/yorick/Maketmpl
 lib/yorick/bin/gist
+lib/yorick/bin/paths.i
 lib/yorick/bin/yorick
 lib/yorick/include/bcast.h
 lib/yorick/include/binio.h
@@ -31,9 +32,13 @@
 lib/yorick/include/yasync.h
 lib/yorick/include/ydata.h
 lib/yorick/include/yio.h
+lib/yorick/include/yversion.h
 lib/yorick/lib/codger
+lib/yorick/lib/libdrat.a
+lib/yorick/lib/libhex.a
 lib/yorick/lib/libyor.a
 lib/yorick/lib/main.o
+lib/yorick/g
 %%PORTDOCS%%share/doc/yorick/FILE_FORMATS
 %%PORTDOCS%%share/doc/yorick/README
 %%PORTDOCS%%share/doc/yorick/drat.doc
@@ -42,12 +47,14 @@
 %%PORTDOCS%%share/doc/yorick/hex.doc
 %%PORTDOCS%%share/doc/yorick/library.doc
 %%PORTDOCS%%share/doc/yorick/math.doc
+%%PORTDOCS%%share/doc/yorick/refs.pdf
 %%PORTDOCS%%share/doc/yorick/refs.ps
 %%PORTDOCS%%share/doc/yorick/refs.tex
 %%PORTDOCS%%share/doc/yorick/std.doc
 %%PORTDOCS%%share/doc/yorick/yorick.pdf
 %%PORTDOCS%%share/doc/yorick/yorick.ps
 %%PORTDOCS%%share/doc/yorick/yorick.tex
+%%PORTDOCS%%share/yorick/doc
 share/yorick/g/README
 share/yorick/g/axes.gs
 share/yorick/g/boxed.gs
@@ -146,6 +153,15 @@
 share/yorick/i0/paths.i
 share/yorick/i0/std.i
 share/yorick/i0/stdx.i
+share/yorick/yorick.el
+%%PORTDOCS%%@unexec install-info --delete %D/info/yorick.info.gz %D/info/dir
+%%PORTDOCS%%info/yorick.info.gz
+%%PORTDOCS%%info/yorick.info-1.gz
+%%PORTDOCS%%info/yorick.info-4.gz
+%%PORTDOCS%%info/yorick.info-2.gz
+%%PORTDOCS%%info/yorick.info-5.gz
+%%PORTDOCS%%info/yorick.info-3.gz
+%%PORTDOCS%%@exec install-info --entry='* Yorick: (yorick).  Yorick interpreted language.' %D/info/yorick.info.gz %D/info/dir
 @dirrm share/yorick/i0
 @dirrm share/yorick/i
 @dirrm share/yorick/g
>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200201310152.g0V1qHk13350>