- Update to 5.0

- Cleanups

PR:		ports/80372
Submitted by:	maintainer
This commit is contained in:
Jean-Yves Lefort 2005-04-28 19:01:41 +00:00
parent de4348cce2
commit b37b345fdb
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=134328
15 changed files with 851 additions and 782 deletions

View File

@ -6,91 +6,72 @@
#
PORTNAME= nab
PORTVERSION= 4.6
PORTVERSION= 5.0
CATEGORIES= biology
MASTER_SITES= ftp://ftp.scripps.edu/pub/case/ \
http://www.scripps.edu/case/ \
MASTER_SITES= http://www.scripps.edu/case/ \
http://siegfried.utmb.edu/bdodson/
MAINTAINER= bdodson@scms.utmb.edu
COMMENT= \
"This is nab (nucleic acid builder), a language for macromolecules"
COMMENT= A language for macromolecules
BUILD_DEPENDS= ucpp:${PORTSDIR}/devel/ucpp
ONLY_FOR_ARCHS= i386
MAKE_ENV+= NABHOME=${WRKSRC} ARCH= PATH=${WRKSRC}/bin:${PATH}
MAKE_ENV+= NABHOME=${WRKSRC} ARCH= PATH=${WRKSRC}/bin:${PATH} \
CFLAGS="${CFLAGS}" FFLAGS="${FFLAGS}"
MAN1= nab.1
MANCOMPRESSED= yes
USE_REINPLACE= yes
SUB_FILES= pkg-message
BINARIES= matextract matmul teLeap tss_main \
matgen nab transform tss_next \
matmerge nab2c tss_init
BINARIES= matextract matmul teLeap tss_main \
matgen nab transform tss_next \
matmerge nab2c tss_init
LIBRARIES= cifparse.a libnab.a libsym.a
LIBRARIES= cifparse.a libnab.a libsym.a
INCS= defreal.h nab.h nabcode.h nabtypes.h
INCS= defreal.h nab.h nabcode.h nabtypes.h
post-extract:
@${CP} ${FILESDIR}/config.h ${WRKSRC}
pre-patch:
@${REINPLACE_CMD} -e 's,<malloc.h>,<stdlib.h>,' \
${WRKSRC}/cifparse/cifparse.c
post-patch:
@${RM} -f ${WRKSRC}/examples/program_7.nab.orig
@${RM} -f ${WRKSRC}/examples/program_1.c \
${WRKSRC}/examples/program_1.exe
@${RM} -f ${WRKSRC}/test/1ubq/a.exe
@${RM} -f ${WRKSRC}/test/1ubq/rattle_min.c
@${RM} -f ${WRKSRC}/test/1ubq/runleap.c
@${RM} -f ${WRKSRC}/test/*.exe
@${RM} -f ${WRKSRC}/tleap/utilMakeHelp.exe
@${RM} -f ${WRKSRC}/fd_data/abdna.dat.old
@${RM} -f ${WRKSRC}/examples/circle.c
@${RM} -f ${WRKSRC}/reslib/conf.lib.orig
@${RM} -f ${WRKSRC}/reslib/leap/parm94.dat~
@(cd ${WRKSRC}/reslib/leap && \
${FIND} . -type f -print | ${GREP} -v '\./[a-zA-Z0-9]' | \
${XARGS} ${RM} -f)
pre-install:
@cd ${WRKSRC}/src && \
${SETENV} PREFIX=${PREFIX} ${MAKE} beforerealinstall
${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} beforerealinstall
do-install:
@-${MKDIR} ${PREFIX}/share/nab
@-${MKDIR} ${PREFIX}/share/nab/bin
@-${MKDIR} ${PREFIX}/share/nab/include
@-${MKDIR} ${PREFIX}/share/nab/lib
${MKDIR} ${DATADIR}/bin ${DATADIR}/include ${DATADIR}/lib
cd ${WRKSRC}/test && ${RM} -f gbrna.pdb.lpdb rembed.out
.if !defined(NOPORTDOCS)
@cd ${WRKSRC} && (${TAR} cf - examples test peptide suppose | \
(cd ${PREFIX}/share/nab; ${TAR} xf -))
@-${MKDIR} ${PREFIX}/share/doc/nab
${INSTALL_MAN} ${WRKSRC}/doc/NAB.pdf ${PREFIX}/share/doc/nab
cd ${WRKSRC} && (${TAR} cf - benchmarks examples test peptide suppose | \
(cd ${DATADIR}; ${TAR} xf -))
${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/doc/NAB.pdf ${DOCSDIR}
.endif
@cd ${WRKSRC} && (${TAR} cf - dgdb reslib fd_data | \
(cd ${PREFIX}/share/nab; ${TAR} xf -))
@(cd ${PREFIX}/share; ${CHOWN} -R ${SHAREOWN}:${SHAREGRP} nab; \
${CHMOD} -R ugo+rX-w nab)
@-(cd ${PREFIX}/share/nab && ${LN} -sf ../NDB coords)
${INSTALL_PROGRAM} ${WRKSRC}/bin/* ${PREFIX}/bin
cd ${WRKSRC} && (${TAR} cf - dgdb reslib fd_data leap | \
(cd ${DATADIR}; ${TAR} xf -))
${CHOWN} -R ${SHAREOWN}:${SHAREGRP} ${DATADIR}/*
cd ${DATADIR} && ${LN} -sf ../NDB coords
${INSTALL_PROGRAM} ${WRKSRC}/bin/* ${PREFIX}/bin
.for f in ${INCS}
${INSTALL_DATA} ${WRKSRC}/include/${f} ${PREFIX}/include
@-(cd ${PREFIX}/share/nab/include && ${LN} -sf ${PREFIX}/include/${f} .)
${INSTALL_DATA} ${WRKSRC}/include/${f} ${PREFIX}/include
cd ${DATADIR}/include && ${LN} -sf ${PREFIX}/include/${f} .
.endfor
${INSTALL_DATA} ${WRKSRC}/config.h ${PREFIX}/share/nab/include
${INSTALL_DATA} ${WRKSRC}/lib/* ${PREFIX}/lib
@-cd ${WRKSRC}/doc && ${GZIP_CMD} ${MAN1}
${INSTALL_MAN} ${WRKSRC}/doc/nab.1.gz ${PREFIX}/man/man1
${INSTALL_DATA} ${WRKSRC}/config.h ${DATADIR}
${INSTALL_MAN} ${WRKSRC}/doc/nab.1 ${MAN1PREFIX}/man/man1
.for f in ${BINARIES}
@cd ${PREFIX}/share/nab/bin && ${LN} -sf ../../../bin/${f} .
cd ${DATADIR}/bin && ${LN} -sf ${PREFIX}/bin/${f} .
.endfor
.for f in ${LIBRARIES}
@cd ${PREFIX}/share/nab/lib && ${LN} -sf ../../../lib/${f} .
${INSTALL_DATA} ${WRKSRC}/lib/${f} ${PREFIX}/lib
cd ${DATADIR}/lib && ${LN} -sf ${PREFIX}/lib/${f} .
.endfor
.for f in blas.a lapack.a
${INSTALL_DATA} ${WRKSRC}/lib/${f} ${DATADIR}/lib
.endfor
post-install:

View File

@ -1,2 +1,2 @@
MD5 (nab-4.6.tar.gz) = ec1e51b8a9f6d5a46770b952f0e59d26
SIZE (nab-4.6.tar.gz) = 3794078
MD5 (nab-5.0.tar.gz) = dfcde2ddaa833f4dc24d53c87b842cf9
SIZE (nab-5.0.tar.gz) = 5853573

View File

@ -1,114 +1,70 @@
# NAB configuration file, created with: ./configure
###############################################################################
# Configuration section: look at sections (1) to (4) below, making
# changes that seem necessary. For many UNIX systems, no changes
# should be necessary, but check especially the compiler options in
# section (4).
#
###############################################################################
#
# (1) You need to define the symbols NABHOME and ARCH, either on the
# make command line (e.g. "make ARCH=sun4 NABHOME=/thr/eigen/nab5")
# or as environment variables.
#
# NABHOME should be an absolute path to this directory.
# ARCH is used to distinguish compilations for various architectures.
#
# Files created by "make install" end up in:
# $NABHOME/bin/$ARCH
# $NABHOME/lib/$ARCH
# $NABHOME/include
#
# You can choose ARCH as you wish, but it would generally
# be related to the output of the "uname" command.
#
# (1) You need to define the symbol NABHOME in your environment
# NABHOME should be an absolute path to the top-level NAB directory;
# files are installed to the following directories:
BINDIR=$(NABHOME)/bin
LIBDIR=$(NABHOME)/lib
INCDIR=$(NABHOME)/include
#
###############################################################################
#
#
# (2) If you want to search additional libraries by default, add them
# to the FLIBS variable here. (External libraries can also be linked into
# NAB programs simply by including them on the command line; libraries
# included in FLIBS are always searched.)
#
#FLIBS=$(LIBDIR)/cifparse.a $(LIBDIR)/libsym.a
#
# following for linking in fortran subroutines on Sun4, Solaris 2.x
#
#FLIBS=$(LIBDIR)/cifparse.a $(LIBDIR)/libsym.a -lF77 -lM77 -lsunmath
#
# following for HP-UX
#
#FLIBS=$(LIBDIR)/cifparse.a $(LIBDIR)/libsym.a lapack.a blas.a -lf -lvec
#
FLIBS= $(LIBDIR)/libsym.a $(LIBDIR)/lapack.a $(LIBDIR)/blas.a -lg2c
###############################################################################
#
# (3) Set AVS to 1 if you want AVS support; if so, set AVSDIR to point to
# your AVS distribution. The directories $AVSDIR/include and $AVSDIR/lib
# must exist, and CFLAGS (below) must also be modified for AVS support.
#
AVS= 0
#
#AVSDIR= /tsri/avs/$(ARCH)/avs
#AVSINCDIR= $(AVSDIR)/include
#
#
###############################################################################
#
# (4) Modify any of the following if you need to change, e.g. to use gcc
# (3) Modify any of the following if you need to change, e.g. to use gcc
# rather than cc, etc.
#
#
SHELL= /bin/sh
#
# Set the C compiler, etc.
#
# For GNU: cc-->gcc; lex-->flex; yacc-->bison -y -t;
# Note: If you lexer is "really" flex, you need to set
# For GNU: CC-->gcc; LEX-->flex; YACC-->bison -y -t;
# Note: If your lexer is "really" flex, you need to set
# LEX=flex below. For example, on many linux distributions,
# /usr/bin/lex is really just a pointer to /usr/bin/flex,
# so LEX=flex is necessary. In general, gcc seems to need
# flex.
#
# For 64-bit IRIX, add "-n32" unless 64-bit objects are
# needed; it is also useful to add "-Wl,-dont_warn_unused"
# to keep the loader from complaining about libraries that
# are not used.
#
# For RedHat Linux 5.1 (and other linuxes?) add -DHAVE_STRERROR
#
#CC=
LEX= flex
YACC= yacc
AR= ar
#
CC?= cc
CFLAGS?=
OCFLAGS=${CFLAGS}
NABFLAGS?=
LEX= flex
YACC= yacc
AR= ar
RANLIB= ranlib
# Set the C-preprocessor. Code for a small preprocessor is in
# uccp-0.7; it gets installed as $(NABHOME)/bin/$(ARCH)/ucpp;
# uccp-1.3; it gets installed as $(NABHOME)/bin/ucpp;
# this should generally *not* be changed.
# Changed 14 Feb 2003 to use the ucpp port (FreeBSD). MLD
#
# For FreeBSD 4.x, I had problems using the system C-preprocessor. MLD
#
CPP= ucpp -l
#
# Use these CFLAGS if AVS = 0
#
# Pick up initial CFLAGS from /etc/make.conf instead of here
# This is a Berkeley make- (pmake-)specific construct
CFLAGS+=
OCFLAGS= ${CFLAGS}
NABFLAGS=
#
# Use these CFLAGS if AVS = 1
#
#CFLAGS= -g -DAVS=$(AVS) -DAVSDIR='"$(AVSDIR)"' -I$(AVSINCDIR)
#OCFLAGS= -O -DAVS=$(AVS) -DAVSDIR='"$(AVSDIR)"' -I$(AVSINCDIR)
#
#
# For Win95/98, set SFX to ".exe"; for Unix,NT leave it empty:
#
#SFX=.exe
# If you are going to use the Fortran lapack and blas libraries, you need
# to set the compiler information here. (Also, add the appropriate entries
# to the FLIBS variable, above.)
FC?=f77
FFLAGS?=
FOPTFLAGS=${FFLAGS}
FREEFORMAT_FLAG=-ffree-form
LAPACK=install
BLAS=install
# For Windows/cygwin, set SFX to ".exe"; for Unix/Linux leave it empty:
SFX=
#

View File

@ -1,28 +1,30 @@
--- Makefile.orig Tue May 18 15:46:55 2004
+++ Makefile Thu Jul 1 09:03:32 2004
@@ -1,16 +1,15 @@
# top-level Makefile for the NAB suite of programs
--- Makefile.orig Thu Apr 7 20:18:20 2005
+++ Makefile Mon Apr 25 13:37:39 2005
@@ -2,42 +2,39 @@
+all: compiler test
compiler:
-mkdir bin lib include
include config.h
+all: install test
+
install:
-mkdir $(BINDIR) $(LIBDIR) $(INCDIR)
- (cd ucpp-1.3; make install )
- (cd byacc; make install )
(cd cifparse; make install )
(cd src; make install )
(cd nss; make install )
(cd tleap; make install )
- @echo
- @echo "completed installation of NAB version 4"
- @echo
+# @echo
+# @echo "completed installation of NAB version 4"
+# @echo
# note: "make test" needs to follow "make", since it is very hard to
# tell if the compiler is completely "made" or not.
@@ -19,18 +18,15 @@
(cd nss; make test )
- (cd lapack; make $(LAPACK) )
- (cd blas; make $(BLAS) )
- (cd cifparse; make install )
- (cd src; make install )
- (cd nss; make install )
- (cd tleap; make install )
+ (cd lapack; env NABHOME=.. make $(LAPACK) )
+ (cd blas; env NABHOME=.. make $(BLAS) )
+ (cd cifparse; env NABHOME=.. make install )
+ (cd src; env NABHOME=.. make install )
+ (cd nss; env NABHOME=.. make install )
+ (cd tleap; env NABHOME=.. make install )
@echo
@echo "completed installation of NAB version 5"
@echo
clean:
- (cd ucpp-1.3; make clean )
@ -31,14 +33,25 @@
(cd src; make clean )
(cd nss; make clean )
(cd tleap; make clean )
(cd lapack; make clean )
(cd blas; make clean )
-
+
uninstall:
uninstall: clean
- (cd ucpp-1.3; make uninstall )
(cd cifparse; make uninstall )
(cd src; make uninstall )
(cd nss; make uninstall )
(cd tleap; make uninstall )
-/bin/rm config.h
-rm -rf $(BINDIR) $(LIBDIR) $(INCDIR)
-
+
# note: "make test" needs to follow "make", since it is very hard to
# tell if the compiler is completely "made" or not.
test::
- (cd test; make test)
- (cd nss; make test)
+ (cd test; env NABHOME=.. make test)
+ (cd nss; env NABHOME=.. make test)

View File

@ -1,18 +0,0 @@
*** src/Makefile.orig Mon Nov 13 13:37:07 2000
--- src/Makefile Mon Jan 29 12:33:37 2001
***************
*** 175,180 ****
--- 175,187 ----
cp defreal.h $(INCDIR)
cp nab.h $(INCDIR)
+ beforerealinstall:
+ $(CC) -DBINDIR='"$(PREFIX)/bin"' \
+ -DINCDIR='"$(PREFIX)/include"' \
+ -DLIBDIR='"$(PREFIX)/lib"' \
+ $(CFLAGS) -DCC='"$(CC)"' -DCPP='"$(CPP)"' -DFLIBS='"$(FLIBS)"' \
+ -o ../bin/nab nab.c
+
uninstall: clean
-rm -f \
$(BINDIR)/nab2c$(SFX) $(BINDIR)/nab$(SFX) $(INCDIR)/nabcode.h \

View File

@ -1,25 +0,0 @@
--- src/database.c.orig Thu Nov 16 15:37:11 2000
+++ src/database.c Fri Feb 14 12:15:53 2003
@@ -64,6 +64,13 @@
* The TOTAL database name MUST NEVER be longer than
* can be contained in the String object.
*/
+#if (defined(__unix__) || defined(unix)) && !defined(USG)
+#include <sys/param.h>
+#endif
+
+#if defined(BSD)
+#include <math.h>
+#endif
@@ -71,7 +78,7 @@
#include <stdio.h>
#include <string.h>
-#include <malloc.h>
+#include <stdlib.h>
#include "database.h"

View File

@ -1,10 +0,0 @@
--- src/molio.c.orig Mon May 10 16:53:34 2004
+++ src/molio.c Fri Jun 18 23:26:01 2004
@@ -1,7 +1,6 @@
#include <stdio.h>
#include <ctype.h>
#include <string.h>
-#include <malloc.h>
#include <math.h>
#include <stdlib.h>
#include <assert.h>

View File

@ -0,0 +1,17 @@
--- src/Makefile.orig Thu Apr 7 20:17:27 2005
+++ src/Makefile Tue Apr 26 12:54:15 2005
@@ -181,6 +181,14 @@
cp defreal.h $(INCDIR)
cp nab.h $(INCDIR)
+beforerealinstall:
+ $(CC) -DBINDIR='"$(PREFIX)/bin"' \
+ -DINCDIR='"$(PREFIX)/include"' \
+ -DLIBDIR='"$(NABHOME)/lib"' \
+ $(CFLAGS) -DCC='"$(CC)"' -DCPP='"$(CPP)"' \
+ -DFLIBS='"$(PREFIX)/share/nab/lib/libsym.a $(PREFIX)/share/nab/lib/lapack.a $(PREFIX)/share/nab/lib/blas.a -lg2c"' \
+ -static -o ../bin/nab${SFX} nab.c
+
uninstall: clean
-rm -f \
$(BINDIR)/nab2c$(SFX) $(BINDIR)/nab$(SFX) $(INCDIR)/nabcode.h \

View File

@ -0,0 +1,21 @@
--- src/cgen.c.orig Thu Apr 7 20:17:27 2005
+++ src/cgen.c Sun Apr 17 20:21:22 2005
@@ -102,6 +102,7 @@
void CG_genpids( NODE_T * );
void CG_genpdecl( NODE_T * );
char *CG_gentemp( int );
+void CG_gennull( void );
static int getdims( NODE_T *, int, int, int *, NODE_T *[] );
static NODE_T *mk_arraysize( int, NODE_T *[], int );
@@ -115,6 +116,10 @@
static void CG_debug( char [], NODE_T *, int );
FILE *tmpfile();
+
+void CG_gennull( )
+{
+}
int CG_init( char cfname[], int aopt )
{

View File

@ -0,0 +1,20 @@
--- src/nabgrm.y.orig Thu Apr 7 20:17:27 2005
+++ src/nabgrm.y Sun Apr 17 20:21:36 2005
@@ -41,6 +41,8 @@
# define YYSTYPE_IS_DECLARED 1
+#define YYSTYPE_IS_DECLARED 1
+
%}
%token <ival> SYM_ADDRESS
@@ -299,7 +301,7 @@
f_stmtpart SYM_RBRACE
{ CG_genestmts( TRUE );
CG_genop( NULL, SYM_RBRACE ); }
- SYM_SEMICOLON ;
+ SYM_SEMICOLON { CG_gennull ( ); } ;
f_defpart : lv_decls
| { $$ = NULL; } ;
lv_decls : var_decl

View File

@ -1,16 +0,0 @@
--- tleap/database.c.orig Sat Nov 9 18:36:58 2002
+++ tleap/database.c Wed Jan 29 09:56:46 2003
@@ -185,6 +185,13 @@
}
+#if (defined(__unix__) || defined(unix)) && !defined(USG)
+#include <sys/param.h>
+#endif
+
+#if defined(BSD)
+#include <math.h>
+#endif

View File

@ -1,10 +0,0 @@
--- tleap/unitio.c.orig Sat Nov 9 18:37:02 2002
+++ tleap/unitio.c Fri Feb 14 12:20:38 2003
@@ -5958,6 +5958,7 @@
*TODO: Add CAP information
*/
#define AMBERINDEX(i) 3*(i-1)
+#undef INTFORMAT
#define INTFORMAT "%6d"
#define DBLFORMAT "%16.8lE"
#define LBLFORMAT "%-4s"

View File

@ -0,0 +1,8 @@
-------------------------------------------------------------------------------
You must set the environment variable NABHOME to
%%DATADIR%%
before nab is used. This is needed so that nab can find its residue and
structure databases.
-------------------------------------------------------------------------------

View File

@ -1,6 +0,0 @@
-------------------------------------------------------------------------------
You must set the environment variable NABHOME before nab is used. This is
needed so that nab can find its residue and structure databases. This should be
NABHOME=${PREFIX}/share/nab, where ${PREFIX} was the value of the PREFIX
makefile variable when nab was built.
-------------------------------------------------------------------------------

File diff suppressed because it is too large Load Diff