astro/cfitsio: Simplify Makefile

- Use hard-coded shlib version
  It helps remind maintainer to bump PORTREVISION of dependent ports.
This commit is contained in:
Po-Chuan Hsieh 2022-03-08 01:50:09 +08:00
parent d94780fa1e
commit 62a530d316
No known key found for this signature in database
GPG Key ID: 9A4BD10F002DD04B
2 changed files with 6 additions and 11 deletions

View File

@ -22,14 +22,9 @@ CONFIGURE_ARGS= ac_cv_prog_FC=f2c
GNU_CONFIGURE= yes
USE_LDCONFIG= yes
PLIST_SUB= SHLIB_MAJOR=${SHLIB_MAJOR} \
SHLIB_MINOR=${SHLIB_MINOR}
PLIST_SUB= PORTVERSION=${PORTVERSION}
CPE_VENDOR= nasa
SHLIB_MAJOR= 9
SHLIB_MINOR= ${PORTVERSION}
OPTIONS_DEFINE= DOCS
post-patch:
@ -38,10 +33,10 @@ post-patch:
do-install:
cd ${WRKSRC}/ && ${INSTALL_DATA} drvrsmem.h fitsio.h fitsio2.h longnam.h ${STAGEDIR}${PREFIX}/include/
${INSTALL_DATA} ${WRKSRC}/libcfitsio.a ${STAGEDIR}${PREFIX}/lib/
${INSTALL_LIB} ${WRKSRC}/libcfitsio.so.${SHLIB_MAJOR}.${SHLIB_MINOR} ${STAGEDIR}${PREFIX}/lib/
${INSTALL_LIB} ${WRKSRC}/libcfitsio.so.9.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/
${INSTALL_DATA} ${WRKSRC}/cfitsio.pc ${STAGEDIR}${PREFIX}/libdata/pkgconfig/
${LN} -fs libcfitsio.so.${SHLIB_MAJOR}.${SHLIB_MINOR} ${STAGEDIR}${PREFIX}/lib/libcfitsio.so.${SHLIB_MAJOR}
${LN} -fs libcfitsio.so.${SHLIB_MAJOR}.${SHLIB_MINOR} ${STAGEDIR}${PREFIX}/lib/libcfitsio.so
${LN} -fs libcfitsio.so.9.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libcfitsio.so.9
${LN} -fs libcfitsio.so.9.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libcfitsio.so
do-install-DOCS-on:
${MKDIR} ${STAGEDIR}${DOCSDIR}/

View File

@ -4,8 +4,8 @@ include/fitsio2.h
include/longnam.h
lib/libcfitsio.a
lib/libcfitsio.so
lib/libcfitsio.so.%%SHLIB_MAJOR%%
lib/libcfitsio.so.%%SHLIB_MAJOR%%.%%SHLIB_MINOR%%
lib/libcfitsio.so.9
lib/libcfitsio.so.9.%%PORTVERSION%%
libdata/pkgconfig/cfitsio.pc
%%PORTDOCS%%%%DOCSDIR%%/cfortran.doc
%%PORTDOCS%%%%DOCSDIR%%/fitsio.doc