aboutsummaryrefslogtreecommitdiffstats
path: root/math
diff options
context:
space:
mode:
authorthierry <thierry@FreeBSD.org>2017-06-15 05:10:00 +0800
committerthierry <thierry@FreeBSD.org>2017-06-15 05:10:00 +0800
commitc4da92aa58f952cff488ce2dda23284655636b99 (patch)
tree327819fcd88a327fd8940ba82ae74292b458f105 /math
parentc6e95fecf85ae5dd0644fabdf9ecd89a69061ce3 (diff)
downloadfreebsd-ports-gnome-c4da92aa58f952cff488ce2dda23284655636b99.tar.gz
freebsd-ports-gnome-c4da92aa58f952cff488ce2dda23284655636b99.tar.zst
freebsd-ports-gnome-c4da92aa58f952cff488ce2dda23284655636b99.zip
Rename the shared libraries correctly.
Reported by: pfg
Diffstat (limited to 'math')
-rw-r--r--math/mumps/Makefile18
-rw-r--r--math/mumps/files/patch-Makefile2
-rw-r--r--math/mumps/files/patch-PORD_lib_Makefile9
-rw-r--r--math/mumps/files/patch-libseq_Makefile9
-rw-r--r--math/mumps/files/patch-src_Makefile16
-rw-r--r--math/mumps/pkg-plist14
6 files changed, 35 insertions, 33 deletions
diff --git a/math/mumps/Makefile b/math/mumps/Makefile
index 1c46ead5769e..e1be5c805497 100644
--- a/math/mumps/Makefile
+++ b/math/mumps/Makefile
@@ -3,7 +3,7 @@
PORTNAME= mumps
PORTVERSION= 4.10.0 # Please do not upgrade to 5+: if needed repocopy to math/mumps5
-PORTREVISION= 7
+PORTREVISION= 8
CATEGORIES= math
MASTER_SITES= http://mumps.enseeiht.fr/ \
http://graal.ens-lyon.fr/MUMPS/ \
@@ -39,6 +39,8 @@ MAKE_JOBS_UNSAFE=yes
FORTRANLIBS= -lgfortran
GCCLIBDIR= ${LDFLAGS}
USE_LDCONFIG= yes
+VEM= ${PORTVERSION:R:R}
+LIBS= cmumps dmumps mumps_common pord smumps zmumps
.if defined(WITH_OPTIMIZED_FLAGS)
FFLAGS+= -O3 -ffast-math
@@ -49,7 +51,7 @@ BUILD_DEPENDS+= ${LOCALBASE}/bin/oemetis:math/metis4
MAKE_ENV+= ORDERINGSF=-Dmetis
.endif
-PLIST_SUB+= MUMPSVERSION=${PORTVERSION}
+PLIST_SUB+= MUMPSVERSION=${PORTVERSION} MUMPSV=${VEM}
OPTIONS_DEFINE= DOCS EXAMPLES
@@ -85,6 +87,7 @@ CONFLICTS= mumps-mpich-4*
.ifndef WITH_MPI
PLIST_SUB+= WITH_LIBSEQ=""
+LIBS+= mpiseq
.else
PLIST_SUB+= WITH_LIBSEQ="@comment "
.endif
@@ -101,11 +104,11 @@ pre-configure:
pre-build:
${DIRNAME} `${FC} -print-libgcc-file-name` > ${WRKSRC}/LIBDIR
-.for MF in Makefile.inc PORD/lib/Makefile libseq/Makefile src/Makefile
+.for MF in Makefile Makefile.inc PORD/lib/Makefile libseq/Makefile src/Makefile
${REINPLACE_CMD} -e 's+@CC@+${CC}+g ; s+@FC@+${FC}+g ; \
s+@CFLAGS@+${CFLAGS} -fPIC+g; \
s+@FCFLAGS@+${FCFLAGS} -fPIC+g; \
- s+@SOVER@+${PORTVERSION}+g; \
+ s+@SOVER@+${VEM}+g; \
s+@GCCLIBDIR@+${GCCLIBDIR}+g; \
s+@FORTRANLIBS@+${FORTRANLIBS}+g; \
s+@BLAS_LIBS@+${BLAS_LIBS}+ ; \
@@ -122,11 +125,14 @@ pre-build:
do-install:
${INSTALL_DATA} ${WRKSRC}/include/*.h ${STAGEDIR}${PREFIX}/include
${INSTALL_DATA} ${WRKSRC}/lib/lib*.a ${STAGEDIR}${PREFIX}/lib
- ${INSTALL_LIB} ${WRKSRC}/lib/lib*.so ${STAGEDIR}${PREFIX}/lib
+ ${INSTALL_LIB} ${WRKSRC}/lib/lib*.so.${VEM} ${STAGEDIR}${PREFIX}/lib
.ifndef WITH_MPI
${INSTALL_DATA} ${WRKSRC}/libseq/libmpiseq.a ${STAGEDIR}${PREFIX}/lib
- ${INSTALL_LIB} ${WRKSRC}/libseq/libmpiseq*.so ${STAGEDIR}${PREFIX}/lib
+ ${INSTALL_LIB} ${WRKSRC}/libseq/libmpiseq*.so.${VEM} ${STAGEDIR}${PREFIX}/lib
.endif
+.for lib in ${LIBS}
+ (cd ${STAGEDIR}${PREFIX}/lib && ${LN} -sf lib${lib}.so.${VEM} ${STAGEDIR}${PREFIX}/lib/lib${lib}.so)
+. endfor
${MKDIR} ${STAGEDIR}${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/doc/userguide_${PORTVERSION}.pdf ${STAGEDIR}${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/doc/userguide_${PORTVERSION}.ps ${STAGEDIR}${DOCSDIR}
diff --git a/math/mumps/files/patch-Makefile b/math/mumps/files/patch-Makefile
index ade5e437da94..b8022b5fa8f8 100644
--- a/math/mumps/files/patch-Makefile
+++ b/math/mumps/files/patch-Makefile
@@ -5,7 +5,7 @@
-requiredobj: Makefile.inc $(LIBSEQNEEDED) $(libdir)/libpord$(PLAT)$(LIBEXT)
-+requiredobj: Makefile.inc $(LIBSEQNEEDED) $(libdir)/libpord$(PLAT)$(LIBEXT) $(libdir)/libpord$(PLAT).so
++requiredobj: Makefile.inc $(LIBSEQNEEDED) $(libdir)/libpord$(PLAT)$(LIBEXT) $(libdir)/libpord$(PLAT).so.@SOVER@
# dummy MPI library (sequential version)
diff --git a/math/mumps/files/patch-PORD_lib_Makefile b/math/mumps/files/patch-PORD_lib_Makefile
index b99561151625..6b3f9cca85e8 100644
--- a/math/mumps/files/patch-PORD_lib_Makefile
+++ b/math/mumps/files/patch-PORD_lib_Makefile
@@ -1,20 +1,19 @@
--- PORD/lib/Makefile.orig 2011-05-10 12:56:32 UTC
+++ PORD/lib/Makefile
-@@ -21,10 +21,16 @@ OBJS = graph.o gbipart.o gbisect.o ddcre
+@@ -21,10 +21,15 @@ OBJS = graph.o gbipart.o gbisect.o ddcre
.c.o:
$(CC) $(COPTIONS) -c $*.c $(OUTC)$*.o
-libpord$(LIBEXT):$(OBJS)
- $(AR)$@ $(OBJS)
-+all: libpord$(LIBEXT) libpord.so
++all: libpord$(LIBEXT) libpord.so.@SOVER@
+
+libpord$(LIBEXT): $(OBJS)
+ $(AR) $@ $(OBJS)
$(RANLIB) $@
-+libpord.so: $(OBJS)
-+ $(CC) -shared $(OBJS) -Wl,-soname,libpord$(PLAT)-@SOVER@.so -o libpord$(PLAT)-@SOVER@.so -Wl,-z,defs
-+ ln -s libpord$(PLAT)-@SOVER@.so $@
++libpord.so.@SOVER@: $(OBJS)
++ $(CC) -shared $(OBJS) -Wl,-soname,libpord$(PLAT).so.@SOVER@ -o libpord$(PLAT).so.@SOVER@ -Wl,-z,defs
+
clean:
rm -f *.o
diff --git a/math/mumps/files/patch-libseq_Makefile b/math/mumps/files/patch-libseq_Makefile
index 7397dd3f27c7..200f519fa80e 100644
--- a/math/mumps/files/patch-libseq_Makefile
+++ b/math/mumps/files/patch-libseq_Makefile
@@ -1,20 +1,19 @@
--- libseq/Makefile.orig 2011-05-10 12:56:39 UTC
+++ libseq/Makefile
-@@ -7,13 +7,19 @@ all: libmpiseq
+@@ -7,13 +7,18 @@ all: libmpiseq
include ../Makefile.inc
-libmpiseq: libmpiseq$(PLAT)$(LIBEXT)
-+libmpiseq: libmpiseq$(PLAT)$(LIBEXT) libmpiseq$(PLAT).so
++libmpiseq: libmpiseq$(PLAT)$(LIBEXT) libmpiseq$(PLAT).so.@SOVER@
libmpiseq$(PLAT)$(LIBEXT): mpi.o mpic.o elapse.o
- $(AR)$@ mpi.o mpic.o elapse.o
+ $(AR) $@ mpi.o mpic.o elapse.o
$(RANLIB) $@
+
-+libmpiseq$(PLAT).so: mpi.o mpic.o elapse.o
-+ $(FC) -shared ${.ALLSRC} -Wl,-soname,libmpiseq$(PLAT)-@SOVER@.so -o libmpiseq$(PLAT)-@SOVER@.so -Wl,-z,defs
-+ ln -s libmpiseq$(PLAT)-@SOVER@.so $@
++libmpiseq$(PLAT).so.@SOVER@: mpi.o mpic.o elapse.o
++ $(FC) -shared ${.ALLSRC} -Wl,-soname,libmpiseq$(PLAT).so.@SOVER@ -o libmpiseq$(PLAT).so.@SOVER@ -Wl,-z,defs
+
.f.o:
$(FC) $(OPTF) -c $*.f $(OUTF)$*.o
diff --git a/math/mumps/files/patch-src_Makefile b/math/mumps/files/patch-src_Makefile
index 84d868e2b788..035e47408c6a 100644
--- a/math/mumps/files/patch-src_Makefile
+++ b/math/mumps/files/patch-src_Makefile
@@ -5,13 +5,13 @@
mumps_lib: $(libdir)/libmumps_common$(PLAT)$(LIBEXT) \
- $(libdir)/lib$(ARITH)mumps$(PLAT)$(LIBEXT)
-+ $(libdir)/libmumps_common$(PLAT).so \
++ $(libdir)/libmumps_common$(PLAT).so.@SOVER@ \
+ $(libdir)/lib$(ARITH)mumps$(PLAT)$(LIBEXT) \
-+ $(libdir)/lib$(ARITH)mumps$(PLAT).so
++ $(libdir)/lib$(ARITH)mumps$(PLAT).so.@SOVER@
OBJS_COMMON = \
mumps_part9.o\
-@@ -53,13 +55,21 @@ OBJS = $(ARITH)mumps_part1.o\
+@@ -53,13 +55,19 @@ OBJS = $(ARITH)mumps_part1.o\
$(libdir)/libmumps_common$(PLAT)$(LIBEXT): $(OBJS_COMMON)
@@ -19,18 +19,16 @@
+ $(AR) $@ $?
$(RANLIB) $@
-+$(libdir)/libmumps_common$(PLAT).so: $(OBJS_COMMON)
-+ $(FC) -shared ${.ALLSRC} -Wl,-soname,libmumps_common$(PLAT)-@SOVER@.so -L$(libdir) $(LORDERINGS) $(LIBPAR) $(LIBOTHERS) -o $(libdir)/libmumps_common$(PLAT)-@SOVER@.so -Wl,-z,defs
-+ ln -s libmumps_common$(PLAT)-@SOVER@.so $@
++$(libdir)/libmumps_common$(PLAT).so.@SOVER@: $(OBJS_COMMON)
++ $(FC) -shared ${.ALLSRC} -Wl,-soname,libmumps_common$(PLAT).so.@SOVER@ -L$(libdir) $(LORDERINGS) $(LIBPAR) $(LIBOTHERS) -o $(libdir)/libmumps_common$(PLAT).so.@SOVER@ -Wl,-z,defs
+
$(libdir)/lib$(ARITH)mumps$(PLAT)$(LIBEXT): $(OBJS)
- $(AR)$@ $?
+ $(AR) $@ $?
$(RANLIB) $@
-+$(libdir)/lib$(ARITH)mumps$(PLAT).so: $(OBJS)
-+ $(FC) -shared ${.ALLSRC} -Wl,-soname,lib$(ARITH)mumps$(PLAT)-@SOVER@.so -L$(libdir) -lmumps_common$(PLAT) $(LORDERINGS) $(LIBPAR) -lblas $(SCALAP) $(LIBOTHERS) -o $(libdir)/lib$(ARITH)mumps$(PLAT)-@SOVER@.so -Wl,-z,defs
-+ ln -s lib$(ARITH)mumps$(PLAT)-@SOVER@.so $@
++$(libdir)/lib$(ARITH)mumps$(PLAT).so.@SOVER@: $(OBJS)
++ $(FC) -shared ${.ALLSRC} -Wl,-soname,lib$(ARITH)mumps$(PLAT).so.@SOVER@ -L$(libdir) -lmumps_common$(PLAT) $(LORDERINGS) $(LIBPAR) -lblas $(SCALAP) $(LIBOTHERS) -o $(libdir)/lib$(ARITH)mumps$(PLAT).so.@SOVER@ -Wl,-z,defs
+
$(ARITH)mumps_load.o: $(ARITH)mumps_comm_buffer.o \
$(ARITH)mumps_struc_def.o
diff --git a/math/mumps/pkg-plist b/math/mumps/pkg-plist
index cbda83091df7..00ec7ea4f6f4 100644
--- a/math/mumps/pkg-plist
+++ b/math/mumps/pkg-plist
@@ -12,27 +12,27 @@ include/smumps_struc.h
include/zmumps_c.h
include/zmumps_root.h
include/zmumps_struc.h
-lib/libcmumps-%%MUMPSVERSION%%.so
lib/libcmumps.a
lib/libcmumps.so
-lib/libdmumps-%%MUMPSVERSION%%.so
+lib/libcmumps.so.4
lib/libdmumps.a
lib/libdmumps.so
-%%WITH_LIBSEQ%%lib/libmpiseq-%%MUMPSVERSION%%.so
+lib/libdmumps.so.4
%%WITH_LIBSEQ%%lib/libmpiseq.a
%%WITH_LIBSEQ%%lib/libmpiseq.so
-lib/libmumps_common-%%MUMPSVERSION%%.so
+%%WITH_LIBSEQ%%lib/libmpiseq.so.4
lib/libmumps_common.a
lib/libmumps_common.so
-lib/libpord-%%MUMPSVERSION%%.so
+lib/libmumps_common.so.4
lib/libpord.a
lib/libpord.so
-lib/libsmumps-%%MUMPSVERSION%%.so
+lib/libpord.so.4
lib/libsmumps.a
lib/libsmumps.so
-lib/libzmumps-%%MUMPSVERSION%%.so
+lib/libsmumps.so.4
lib/libzmumps.a
lib/libzmumps.so
+lib/libzmumps.so.4
%%PORTDOCS%%%%DOCSDIR%%/userguide_%%MUMPSVERSION%%.pdf
%%PORTDOCS%%%%DOCSDIR%%/userguide_%%MUMPSVERSION%%.ps.gz
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/Makefile