pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/benchmarks user-destdir support



details:   https://anonhg.NetBSD.org/pkgsrc/rev/4beae462a3ba
branches:  trunk
changeset: 395523:4beae462a3ba
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Wed Jul 08 14:28:28 2009 +0000

description:
user-destdir support

diffstat:

 benchmarks/netperf/Makefile         |  17 +++++++++--------
 benchmarks/netperf/distinfo         |   4 ++--
 benchmarks/netperf/patches/patch-aa |  35 ++++++++++++++++++++++++++++++-----
 benchmarks/xengine/Makefile         |   8 +++++---
 4 files changed, 46 insertions(+), 18 deletions(-)

diffs (136 lines):

diff -r 5140b14d4f0a -r 4beae462a3ba benchmarks/netperf/Makefile
--- a/benchmarks/netperf/Makefile       Wed Jul 08 14:25:32 2009 +0000
+++ b/benchmarks/netperf/Makefile       Wed Jul 08 14:28:28 2009 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.6 2009/04/28 18:58:40 zafer Exp $
+# $NetBSD: Makefile,v 1.7 2009/07/08 14:28:28 joerg Exp $
 #
 
 DISTNAME=      netperf-2.3pl1
@@ -12,19 +12,20 @@
 HOMEPAGE=      http://www.netperf.org/
 COMMENT=       Rick Jones' network performance benchmarking package
 
+PKG_DESTDIR_SUPPORT=   user-destdir
+
 USE_TOOLS+=    gzip
 MAKE_FILE=     makefile
 
 CFLAGS.IRIX+=  -DIRIX
 
+INSTALLATION_DIRS=     ${PKGMANDIR}/man1 share/doc/netperf
+
 post-install:
-       strip ${PREFIX}/netperf/netperf
-       strip ${PREFIX}/netperf/netserver
-       ${INSTALL_MAN} ${WRKSRC}/netperf.man ${PREFIX}/${PKGMANDIR}/man1/netperf.1
-       ${INSTALL_MAN} ${WRKSRC}/netserver.man ${PREFIX}/${PKGMANDIR}/man1/netserver.1
-       ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/netperf
-       ${INSTALL_MAN} ${WRKSRC}/netperf.ps ${PREFIX}/share/doc/netperf
-       ${GZIP_CMD} ${PREFIX}/share/doc/netperf/netperf.ps
+       ${INSTALL_MAN} ${WRKSRC}/netperf.man ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/netperf.1
+       ${INSTALL_MAN} ${WRKSRC}/netserver.man ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/netserver.1
+       ${INSTALL_MAN} ${WRKSRC}/netperf.ps ${DESTDIR}${PREFIX}/share/doc/netperf
+       ${GZIP_CMD} ${DESTDIR}${PREFIX}/share/doc/netperf/netperf.ps
 
 # The sources assume <malloc.h> exists.  Create a fake one for platforms
 # that don't have it.
diff -r 5140b14d4f0a -r 4beae462a3ba benchmarks/netperf/distinfo
--- a/benchmarks/netperf/distinfo       Wed Jul 08 14:25:32 2009 +0000
+++ b/benchmarks/netperf/distinfo       Wed Jul 08 14:28:28 2009 +0000
@@ -1,9 +1,9 @@
-$NetBSD: distinfo,v 1.3 2008/05/12 15:49:30 tonnerre Exp $
+$NetBSD: distinfo,v 1.4 2009/07/08 14:28:28 joerg Exp $
 
 SHA1 (netperf-2.3pl1.tar.gz) = 288c34b6c4d937b06422a8cdab3dcae5ed58cc17
 RMD160 (netperf-2.3pl1.tar.gz) = 83f2afd612b7d4d4b486b82554f4e792c5e8509d
 Size (netperf-2.3pl1.tar.gz) = 836110 bytes
-SHA1 (patch-aa) = f9a835995de2130d4bd74d9c5c6a48bc4c0eb59b
+SHA1 (patch-aa) = 62d0e7822d3cf9ef3159954f3d642096aa211350
 SHA1 (patch-ab) = a45be8f4f8caf182c053779012e560fa31bcb98b
 SHA1 (patch-ac) = 15714316008fa1362bb8f392f72a6f0125601ce4
 SHA1 (patch-ad) = a829f207d8af01497887b4386d184a4b0d14774f
diff -r 5140b14d4f0a -r 4beae462a3ba benchmarks/netperf/patches/patch-aa
--- a/benchmarks/netperf/patches/patch-aa       Wed Jul 08 14:25:32 2009 +0000
+++ b/benchmarks/netperf/patches/patch-aa       Wed Jul 08 14:28:28 2009 +0000
@@ -1,8 +1,8 @@
-$NetBSD: patch-aa,v 1.1 2006/11/21 10:59:25 tron Exp $
+$NetBSD: patch-aa,v 1.2 2009/07/08 14:28:29 joerg Exp $
 
---- makefile.orig      2004-09-22 06:33:40.000000000 +0900
-+++ makefile   2004-12-02 15:39:16.000000000 +0900
-@@ -15,8 +15,8 @@
+--- makefile.orig      2004-09-21 23:33:40.000000000 +0200
++++ makefile
+@@ -15,8 +15,8 @@ VERSION = 2.3pl1
  # for the rest of the world, it is probably better to put the binaries
  # in /usr/local/netperf or /opt/netperf
  #
@@ -13,7 +13,7 @@
  
  # The compiler on your system might be somewhere else, and/or have
  # a different name.
-@@ -113,7 +113,8 @@
+@@ -113,7 +113,8 @@ CC = cc
  #                   netserver via the netperf command line with -T
  
  LOG_FILE=DEBUG_LOG_FILE="\"/tmp/netperf.debug\""
@@ -23,3 +23,28 @@
  
  # Some platforms, and some options, require additional libraries.
  # you can add to the "LIBS =" line to accomplish this. if you find
+@@ -216,19 +217,12 @@ nettest_dns.o:  nettest_dns.c nettest_dn
+ netserver.o:  netserver.c nettest_bsd.h netlib.h makefile
+ 
+ install:      netperf netserver
+-              mkdir -p $(NETPERF_HOME)
++              mkdir -p ${DESTDIR}$(NETPERF_HOME)
+               chmod -w *.[ch]
+-              chmod +x $(NETPERF_SCRIPTS)
+-              @if [ ! -d $(NETPERF_HOME) ]; then \
+-                      mkdir $(NETPERF_HOME) && chmod a+rx $(NETPERF_HOME); \
+-              fi
+-              cp netperf $(NETPERF_HOME)
+-              cp netserver $(NETPERF_HOME)
+-              cp $(NETPERF_SCRIPTS) $(NETPERF_HOME)
+-              chmod a+rx $(NETPERF_HOME)/netperf $(NETPERF_HOME)/netserver
+-              @for i in $(NETPERF_SCRIPTS); do \
+-                      chmod a+rx $(NETPERF_HOME)/$$i; \
+-              done
++              ${BSD_INSTALL_PROGRAM} netperf ${DESTDIR}$(NETPERF_HOME)
++              ${BSD_INSTALL_PROGRAM} netserver ${DESTDIR}$(NETPERF_HOME)
++              ${BSD_INSTALL_SCRIPT} $(NETPERF_SCRIPTS) ${DESTDIR}$(NETPERF_HOME)
++
+ clean:
+       rm -f *.o netperf netserver core
+ 
diff -r 5140b14d4f0a -r 4beae462a3ba benchmarks/xengine/Makefile
--- a/benchmarks/xengine/Makefile       Wed Jul 08 14:25:32 2009 +0000
+++ b/benchmarks/xengine/Makefile       Wed Jul 08 14:28:28 2009 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.23 2009/05/16 21:12:17 zafer Exp $
+# $NetBSD: Makefile,v 1.24 2009/07/08 14:38:28 joerg Exp $
 
 DISTNAME=      xengine-1.0.1
 PKGREVISION=   4
@@ -10,6 +10,7 @@
 COMMENT=       Reciprocating engine for X
 
 PKG_INSTALLATION_TYPES=        overwrite pkgviews
+PKG_DESTDIR_SUPPORT=   user-destdir
 
 WRKSRC=                ${WRKDIR}
 DIST_SUBDIR=   xengine
@@ -23,9 +24,10 @@
 pre-configure:
        cd ${WRKSRC}; ${PATCH} ${PATCH_DIST_ARGS} < xengine.patch1
 
+INSTALLATION_DIRS=     share/doc/xengine
+
 post-install:
-       ${INSTALL_DATA_DIR} ${PREFIX}/share/doc/xengine
-       ${INSTALL_DATA} ${WRKSRC}/README ${PREFIX}/share/doc/xengine
+       ${INSTALL_DATA} ${WRKSRC}/README ${DESTDIR}${PREFIX}/share/doc/xengine
        @${ECHO} ""
        @${ECHO} "Example value:"
        @${ECHO} "   1067 RPMs with P100, Winner 2000PRO/X, resolution: 1152x900"



Home | Main Index | Thread Index | Old Index