aboutsummaryrefslogtreecommitdiff
path: root/science/hdf
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2015-09-10 16:55:41 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2015-09-10 16:55:41 +0000
commit7bc6b5920b1520075af78930bd7f213b08e498e4 (patch)
tree19f5cb53818b3682abdddd85fa266b808220c418 /science/hdf
parent9b8239b6a9660aa6ff372f0ee7baf057bdf4f428 (diff)
downloadports-7bc6b5920b1520075af78930bd7f213b08e498e4.tar.gz
ports-7bc6b5920b1520075af78930bd7f213b08e498e4.zip
- Unbreak the build on PowerPC by pretending to be pre-Intel Apple CPU;
while this is probably not right design-wise, it allows for a smaller fix in line count (all regression tests do pass) - While here, perform usual Makefile maintenance and cleanups: sort the knobs, wrap overly long lines, and improve `regression-test' target
Notes
Notes: svn path=/head/; revision=396586
Diffstat (limited to 'science/hdf')
-rw-r--r--science/hdf/Makefile29
1 files changed, 18 insertions, 11 deletions
diff --git a/science/hdf/Makefile b/science/hdf/Makefile
index 8a00ca8f2475..3e35575a61f2 100644
--- a/science/hdf/Makefile
+++ b/science/hdf/Makefile
@@ -15,27 +15,34 @@ LIB_DEPENDS= libsz.so:${PORTSDIR}/science/szip
CONFLICTS_INSTALL= netcdf-4.[0-9]*
-OPTIONS_DEFINE= EXAMPLES
-
+USES= fortran jpeg libtool tar:bzip2
GNU_CONFIGURE= yes
-CONFIGURE_ARGS= --enable-shared --with-jpeg=${LOCALBASE} --with-szlib=${LOCALBASE}
-INSTALL_TARGET= install-strip
+CONFIGURE_ARGS= --enable-shared --with-jpeg=${LOCALBASE} \
+ --with-szlib=${LOCALBASE}
USE_LDCONFIG= yes
-USES= fortran jpeg libtool tar:bzip2
+INSTALL_TARGET= install-strip
PORTDATA= *
PORTEXAMPLES= *
-BROKEN_powerpc= Does not compile on powerpc
+OPTIONS_DEFINE= EXAMPLES
post-patch:
@${REINPLACE_CMD} -e '/PROD_/ s|=.*|=""|' ${WRKSRC}/config/freebsd
+# Allow to build on PowerPC
+ @${REINPLACE_CMD} -e '/if defined (__APPLE__)/ \
+ s,),) || defined(__powerpc__),' ${WRKSRC}/hdf/src/hdfi.h
+ @${REINPLACE_CMD} -e 's/ || (__APPLE__.*//' \
+ ${WRKSRC}/hdf/test/fortest.c
post-install:
- ${INSTALL_MAN} ${WRKSRC}/man/hdfunpac.1 ${STAGEDIR}${MAN1PREFIX}/man/man1/
- ${INSTALL_MAN} ${WRKSRC}/man/gr_chunk.3 ${STAGEDIR}${MAN3PREFIX}/man/man3/
-
-regression-test test: build
- cd ${WRKSRC}/hdf/test/ && ${SETENV} ${MAKE_ENV} ${MAKE_CMD} check
+ ${INSTALL_MAN} ${WRKSRC}/man/hdfunpac.1 \
+ ${STAGEDIR}${MAN1PREFIX}/man/man1
+ ${INSTALL_MAN} ${WRKSRC}/man/gr_chunk.3 \
+ ${STAGEDIR}${MAN3PREFIX}/man/man3
+
+regression-test: build
+ @${SETENV} ${MAKE_ENV} ${MAKE_CMD} ${MAKE_FLAGS} ${MAKEFILE} \
+ ${MAKE_ARGS} check -C ${WRKSRC}/hdf/test
.include <bsd.port.mk>