ports/165786: [PATCH] net/libnet Honor NOPORTEXAMPLES env var
Michael Scheidell
scheidell at FreeBSD.org
Tue Mar 6 19:40:12 UTC 2012
>Number: 165786
>Category: ports
>Synopsis: [PATCH] net/libnet Honor NOPORTEXAMPLES env var
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Tue Mar 06 19:40:11 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator: Michael Scheidell
>Release: FreeBSD 7.4-RELEASE-p3 i386
>Organization:
SECNAP Network Security
>Environment:
>Description:
if an OP devines NOPORTEXAMPLES in env (cmdline, make.etc), port should not install examples.
>How-To-Repeat:
make -DNOPORTEXAMPLES install
cd /usr/local/share/examples/libnet11
du -ch
350K ./libnet11
port installs 350K of examples.
>Fix:
patch for Makefile and pkg-plist.
since this isn't really broken, there is no need to force clusters to rebuild.
next upgrade for the OP, pkg-plist will automatically deinstall old examples, and (not) install new ones, so, no
portrevision bump needed.
- Honor NOPORTEXAMPLES env var
- No PORTREVISION bump
--- libnet.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/pcvs/ports/net/libnet/Makefile,v
retrieving revision 1.25
diff -u -r1.25 Makefile
--- Makefile 22 Feb 2012 04:49:08 -0000 1.25
+++ Makefile 6 Mar 2012 19:31:19 -0000
@@ -34,8 +34,10 @@
post-install:
${INSTALL_SCRIPT} ${WRKSRC}/libnet-config \
${PREFIX}/bin/libnet${PKGNAMESUFFIX}-config
+.if !defined(NOPORTEXAMPLES)
@${MKDIR} ${EXAMPLESDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${EXAMPLES} ${EXAMPLESDIR}
+.endif
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
cd ${WRKSRC} && ${INSTALL_DATA} ${DOCS} ${DOCSDIR}
Index: pkg-plist
===================================================================
RCS file: /home/pcvs/ports/net/libnet/pkg-plist,v
retrieving revision 1.11
diff -u -r1.11 pkg-plist
--- pkg-plist 31 Jan 2007 14:09:48 -0000 1.11
+++ pkg-plist 6 Mar 2012 19:31:19 -0000
@@ -50,51 +50,51 @@
%%PORTDOCS%%%%DOCSDIR%%/libnet_8h.html
%%PORTDOCS%%%%DOCSDIR%%/structlibnet__802__1q__hdr.html
%%PORTDOCS%%%%DOCSDIR%%/structlibnet__802__1x__hdr.html
-%%EXAMPLESDIR%%/arp-new.c
-%%EXAMPLESDIR%%/arp.c
-%%EXAMPLESDIR%%/bgp4_hdr.c
-%%EXAMPLESDIR%%/bgp4_notification.c
-%%EXAMPLESDIR%%/bgp4_open.c
-%%EXAMPLESDIR%%/bgp4_update.c
-%%EXAMPLESDIR%%/cdp.c
-%%EXAMPLESDIR%%/dhcp_discover.c
-%%EXAMPLESDIR%%/dns.c
-%%EXAMPLESDIR%%/dot1x.c
-%%EXAMPLESDIR%%/fddi_tcp1.c
-%%EXAMPLESDIR%%/fddi_tcp2.c
-%%EXAMPLESDIR%%/get_addr.c
-%%EXAMPLESDIR%%/gre.c
-%%EXAMPLESDIR%%/icmp6_echoreq.c
-%%EXAMPLESDIR%%/icmp_echo_cq.c
-%%EXAMPLESDIR%%/icmp_redirect.c
-%%EXAMPLESDIR%%/icmp_timeexceed.c
-%%EXAMPLESDIR%%/icmp_timestamp.c
-%%EXAMPLESDIR%%/icmp_unreach.c
-%%EXAMPLESDIR%%/ieee.c
-%%EXAMPLESDIR%%/ip_link.c
-%%EXAMPLESDIR%%/ip_raw.c
-%%EXAMPLESDIR%%/isl.c
-%%EXAMPLESDIR%%/mpls.c
-%%EXAMPLESDIR%%/ntp.c
-%%EXAMPLESDIR%%/ospf_hello.c
-%%EXAMPLESDIR%%/ospf_lsa.c
-%%EXAMPLESDIR%%/ping_of_death.c
-%%EXAMPLESDIR%%/rpc_tcp.c
-%%EXAMPLESDIR%%/rpc_udp.c
-%%EXAMPLESDIR%%/sebek.c
-%%EXAMPLESDIR%%/smurf.c
-%%EXAMPLESDIR%%/stp.c
-%%EXAMPLESDIR%%/synflood.c
-%%EXAMPLESDIR%%/synflood6.c
-%%EXAMPLESDIR%%/synflood6_frag.c
-%%EXAMPLESDIR%%/tcp1.c
-%%EXAMPLESDIR%%/tcp2.c
-%%EXAMPLESDIR%%/tftp.c
-%%EXAMPLESDIR%%/tring_tcp1.c
-%%EXAMPLESDIR%%/tring_tcp2.c
-%%EXAMPLESDIR%%/udp1.c
-%%EXAMPLESDIR%%/udp2.c
- at dirrm %%EXAMPLESDIR%%
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/arp-new.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/arp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/bgp4_hdr.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/bgp4_notification.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/bgp4_open.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/bgp4_update.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/cdp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/dhcp_discover.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/dns.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/dot1x.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/fddi_tcp1.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/fddi_tcp2.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/get_addr.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/gre.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/icmp6_echoreq.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/icmp_echo_cq.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/icmp_redirect.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/icmp_timeexceed.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/icmp_timestamp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/icmp_unreach.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ieee.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ip_link.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ip_raw.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/isl.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/mpls.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ntp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ospf_hello.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ospf_lsa.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/ping_of_death.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/rpc_tcp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/rpc_udp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/sebek.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/smurf.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/stp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/synflood.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/synflood6.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/synflood6_frag.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tcp1.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tcp2.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tftp.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tring_tcp1.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tring_tcp2.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/udp1.c
+%%PORTEXAMPLES%%%%EXAMPLESDIR%%/udp2.c
+%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%
%%PORTDOCS%%@dirrm %%DOCSDIR%%
@dirrm lib/libnet11
@dirrm include/libnet11/libnet
--- libnet.patch ends here ---
______________________________________________________________________
This email has been scanned and certified safe by SpammerTrap(r).
For Information please see http://www.spammertrap.com/
______________________________________________________________________
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list