diff options
author | maho <maho@FreeBSD.org> | 2007-01-09 12:08:38 +0800 |
---|---|---|
committer | maho <maho@FreeBSD.org> | 2007-01-09 12:08:38 +0800 |
commit | 8ee0083494ddbc82344c61faf8480374cf12df0b (patch) | |
tree | a1ae9e7b278150ef6dfae554d859879797afec72 /math/spooles | |
parent | c85a3cffa225845adc7ec35eff56eee3e7786b95 (diff) | |
download | freebsd-ports-gnome-8ee0083494ddbc82344c61faf8480374cf12df0b.tar.gz freebsd-ports-gnome-8ee0083494ddbc82344c61faf8480374cf12df0b.tar.zst freebsd-ports-gnome-8ee0083494ddbc82344c61faf8480374cf12df0b.zip |
Install shared libs too.
Bump port revision.
Diffstat (limited to 'math/spooles')
-rw-r--r-- | math/spooles/Makefile | 41 | ||||
-rw-r--r-- | math/spooles/files/patch-Make.inc | 26 | ||||
-rw-r--r-- | math/spooles/pkg-plist | 2 |
3 files changed, 46 insertions, 23 deletions
diff --git a/math/spooles/Makefile b/math/spooles/Makefile index 3a0967f46a9b..7356c0ac08cc 100644 --- a/math/spooles/Makefile +++ b/math/spooles/Makefile @@ -7,7 +7,7 @@ PORTNAME= spooles PORTVERSION= 2.2 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= math MASTER_SITES= http://www.netlib.org/linalg/spooles/ .ifdef WITH_MPI @@ -31,16 +31,12 @@ BUILD_DEPENDS= ${LOCALBASE}/mpich2/lib/libmpich.a:${PORTSDIR}/net/mpich2 .endif USE_GMAKE= yes #BSD make gives problems here -NO_WRKSUBDIR= yes -MAKEFILE= makefile -ALL_TARGET= global .if defined(WITH_MPI) PLIST_SUB+= MPI="" PLIST_SUB+= MT="@comment " CONFLICTS= spooles-2* .else -CFLAGS+= ${PTHREAD_CFLAGS} PLIST_SUB+= MT="" PLIST_SUB+= MPI="@comment " CONFLICTS= spooles-mpich-2* @@ -48,8 +44,10 @@ CONFLICTS= spooles-mpich-2* .include <bsd.port.pre.mk> -.if ${ARCH} == "amd64" -CFLAGS+= -fPIC +.if ${ARCH} == "sparc64" +PICFLAG?= -fPIC +.else +PICFLAG?= -fpic .endif .SILENT: @@ -59,23 +57,36 @@ pre-everything:: ${ECHO_MSG} "make WITH_MPI=yes for mpich version" .endif +do-extract: + ${MKDIR} ${WRKSRC} ; cd ${WRKSRC} ; ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} ${_DISTDIR}/${DISTNAME}${EXTRACT_SUFX} ${EXTRACT_AFTER_ARGS} + post-patch: -.if defined(WITH_MPI) - @${REINPLACE_CMD} -e 's+%%LOCALBASE%%+${LOCALBASE}+g;' ${WRKSRC}/Make.inc -.else - @${REINPLACE_CMD} -e 's+%%PTHREAD_LIBS%%+${PTHREAD_LIBS}+g;' ${WRKSRC}/Make.inc -.endif + ${MKDIR} ${WRKSRC}_SHARED ; ${CP} -r ${WRKSRC}/* ${WRKSRC}_SHARED + @${REINPLACE_CMD} -e 's+%%LOCALBASE%%+${LOCALBASE}+g;' -e 's+%%CFLAGS%%+${PTHREAD_CFLAGS} ${CFLAGS}+g;' -e 's+%%PTHREAD_LIBS%%+${PTHREAD_LIBS}+g;' -e 's+%%CC%%+${CC}+g;' ${WRKSRC}/Make.inc + @${REINPLACE_CMD} -e 's+%%LOCALBASE%%+${LOCALBASE}+g;' -e 's+%%CFLAGS%%+${CFLAGS} ${PTHREAD_CFLAGS} ${PICFLAG}+g;' -e 's+%%PTHREAD_LIBS%%+${PTHREAD_LIBS}+g;' -e 's+%%CC%%+${CC}+g;' ${WRKSRC}_SHARED/Make.inc -post-build: +do-build: .if defined(WITH_MPI) - @(cd ${WRKSRC}/MPI/src; ${SETENV} ${MAKE_ENV} ${GMAKE} -f makeGlobalLib) + @(cd ${WRKSRC}/MPI; ${SETENV} ${MAKE_ENV} ${GMAKE} global -f makefile) + @(cd ${WRKSRC}/MPI/src; ${SETENV} ${MAKE_ENV} ${GMAKE} ) + @(cd ${WRKSRC}_SHARED/MPI/src; ${SETENV} ${MAKE_ENV} ${GMAKE} global -f makefile) + @(cd ${WRKSRC}_SHARED/MPI/src; ${SETENV} ${MAKE_ENV} ${GMAKE} -f makeGlobalLib) + @(cd ${WRKSRC}_SHARED ; ld -Bshareable -o libspooles.so.1 -x -soname libspooles.so.1 --whole-archive spooles.a ) + .else + @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ${GMAKE} global -f makefile) @(cd ${WRKSRC}/MT/src; ${SETENV} ${MAKE_ENV} ${GMAKE} -f makeGlobalLib) + @(cd ${WRKSRC}_SHARED; ${SETENV} ${MAKE_ENV} ${GMAKE} global -f makefile) + @(cd ${WRKSRC}_SHARED/MT/src; ${SETENV} ${MAKE_ENV} ${GMAKE} -f makeGlobalLib) + @(cd ${WRKSRC}_SHARED ; ld -Bshareable -o libspooles.so.1 -x -soname libspooles.so.1 --whole-archive spooles.a ) .endif do-install: ${MKDIR} ${PREFIX}/include/spooles - ${INSTALL} ${WRKSRC}/spooles.a ${PREFIX}/lib/libspooles.a + ${INSTALL_DATA} ${WRKSRC}/spooles.a ${PREFIX}/lib/libspooles.a + ${INSTALL_DATA} ${WRKSRC}_SHARED/libspooles.so.1 ${PREFIX}/lib + ${LN} -sf libspooles.so.1 ${PREFIX}/lib/libspooles.so + .if defined(WITH_MPI) ${MKDIR} ${PREFIX}/include/spooles/MPI ${INSTALL_DATA} ${WRKSRC}/MPI/*.h ${PREFIX}/include/spooles/MPI diff --git a/math/spooles/files/patch-Make.inc b/math/spooles/files/patch-Make.inc index a855a75cf7aa..cd0ad9f78e57 100644 --- a/math/spooles/files/patch-Make.inc +++ b/math/spooles/files/patch-Make.inc @@ -1,5 +1,5 @@ ---- Make.inc.orig Mon Jan 18 16:48:55 1999 -+++ Make.inc Sun May 11 14:32:36 2003 +--- Make.inc.orig Tue Jan 19 06:48:55 1999 ++++ Make.inc Tue Jan 9 12:57:18 2007 @@ -12,7 +12,7 @@ # for solaris # @@ -9,7 +9,16 @@ # # for sgi # -@@ -28,14 +28,14 @@ +@@ -22,20 +22,23 @@ + # + # CC = /opt/mpi/bin/mpicc + # ++# for FreeBSD ++CC = %%CC%% ++# + #---------------------------------------- + # + # set the compiler flags # # OPTLEVEL = # OPTLEVEL = -g -v @@ -18,7 +27,8 @@ # OPTLEVEL = -xO5 -v # OPTLEVEL = -O3 # OPTLEVEL = -O4 - # CFLAGS = -Wall -g +-# CFLAGS = -Wall -g ++CFLAGS = %%CFLAGS%% # CFLAGS = -Wall -pg # CFLAGS = $(OPTLEVEL) -D_POSIX_C_SOURCE=199506L - CFLAGS = $(OPTLEVEL) @@ -26,7 +36,7 @@ # CFLAGS = -Wall $(OPTLEVEL) # #---------------------------------------- -@@ -50,8 +50,8 @@ +@@ -50,8 +53,8 @@ # set any thread libraries # # THREAD_LIBS = @@ -37,7 +47,7 @@ # THREAD_LIBS = -lpthread # #--------------------------------------------------------------------- -@@ -79,15 +79,15 @@ +@@ -79,15 +82,15 @@ # set the ranlib environment # (if ranlib is not needed, we echo the library name) # @@ -57,7 +67,7 @@ # #--------------------------------------------------------------------- # -@@ -103,7 +103,7 @@ +@@ -103,7 +106,7 @@ # MPI install library # # MPI_INSTALL_DIR = @@ -66,7 +76,7 @@ # #--------------------------------------------------------------------- # -@@ -115,7 +115,7 @@ +@@ -115,7 +118,7 @@ # # for solaris # diff --git a/math/spooles/pkg-plist b/math/spooles/pkg-plist index 8881f69fc6d6..06b5bffec560 100644 --- a/math/spooles/pkg-plist +++ b/math/spooles/pkg-plist @@ -99,6 +99,8 @@ include/spooles/misc.h include/spooles/misc/misc.h include/spooles/timings.h lib/libspooles.a +lib/libspooles.so +lib/libspooles.so.1 %%MPI%%include/spooles/MPI/spoolesMPI.h %%MPI%%@dirrm include/spooles/MPI %%MT%%include/spooles/MT/spoolesMT.h |