pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/math/p5-Math-Pari Use better hack as suggested by jlam...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/aee2ed6df8ec
branches:  trunk
changeset: 506094:aee2ed6df8ec
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Wed Jan 11 21:24:09 2006 +0000

description:
Use better hack as suggested by jlam: query pari for its WRKSRC and use
that.

diffstat:

 math/p5-Math-Pari/Makefile |  14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)

diffs (32 lines):

diff -r 0797277ea1f1 -r aee2ed6df8ec math/p5-Math-Pari/Makefile
--- a/math/p5-Math-Pari/Makefile        Wed Jan 11 21:06:37 2006 +0000
+++ b/math/p5-Math-Pari/Makefile        Wed Jan 11 21:24:09 2006 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.21 2006/01/11 19:36:59 joerg Exp $
+# $NetBSD: Makefile,v 1.22 2006/01/11 21:24:09 joerg Exp $
 #
 
 DISTNAME=              Math-Pari-2.010501
@@ -21,15 +21,17 @@
 #TEST_TARGET=          # the tests need looking at
 
 # XXX: could be improved...
+PKGSRCDIR.pari=                ${.CURDIR}/../../math/pari
+WRKSRC.pari_cmd=               \
+       cd ${PKGSRCDIR.pari} && ${MAKE} show-var VARNAME=WRKSRC
+
 post-extract:
-       if [ ! -d ${PKGSRCDIR}/math/pari/${WRKDIR_BASENAME} ]; then \
-         cd ${PKGSRCDIR}/math/pari && ${MAKE} configure; \
-       fi
+       cd ${PKGSRCDIR.pari:Q} && ${MAKE} configure;            \
        ${RM} -f ${WRKSRC}/pari-*
-       ${LN} -sf ${WRKSRC}/../../../../math/pari/${WRKDIR_BASENAME}/pari-* ${WRKSRC}/
+       ${LN} -sf ${WRKSRC.pari_cmd:sh:Q} ${WRKSRC}
 
 pre-clean:
-       cd ${PKGSRCDIR}/math/pari && ${MAKE} clean
+       cd ${PKGSRCDIR.pari:Q} && ${MAKE} clean
 
 .include "../../lang/perl5/module.mk"
 .include "../../mk/bsd.pkg.mk"



Home | Main Index | Thread Index | Old Index