Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Sep 2002 22:29:25 +1000 (EST)
From:      Joshua Goodall <joshua@roughtrade.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/42632: Maintainer update: net/spread (supersedes ports/41436)
Message-ID:  <20020910122925.EF1794134@green.shallow.net>

next in thread | raw e-mail | index | archive | help

>Number:         42632
>Category:       ports
>Synopsis:       Maintainer update: net/spread (supersedes ports/41436)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Tue Sep 10 05:30:02 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Joshua Goodall
>Release:        FreeBSD 4.6-STABLE i386
>Organization:
>Environment:
System: FreeBSD green.shallow.net 4.6-STABLE FreeBSD 4.6-STABLE #5: Thu Aug 22 01:43:23 EST 2002 root@green.shallow.net:/usr/obj/usr/src/sys/GREEN i386
>Description:
	Update net/spread with the following:

	. build and install shared libraries as well as the static archive
	. use the shared libs for the supplied client tools and perl wrapper
	. bump portrevision
	. whilst we're here, migrate from ${PERL} to ${REINPLACE_CMD}

	This update incorporates the intent of ports/41436.

>How-To-Repeat:
>Fix:
Index: Makefile
===================================================================
RCS file: /cvs/ports/net/spread/Makefile,v
retrieving revision 1.8
diff -u -u -r1.8 Makefile
--- Makefile	26 Apr 2002 22:28:52 -0000	1.8
+++ Makefile	10 Sep 2002 10:10:14 -0000
@@ -7,6 +7,7 @@
 
 PORTNAME=	spread
 PORTVERSION=	3.16.2
+PORTREVISION=	1
 CATEGORIES=	net perl5 java
 MASTER_SITES=	http://www.roughtrade.net/distfiles/ \
 		http://www.metaverse.nl/~ernst/ \
@@ -16,6 +17,7 @@
 
 MAINTAINER=	joshua@roughtrade.net
 
+USE_REINPLACE=	yes
 MAKEFILE=	FreeBSD_makefile
 
 MAN1=	spflooder.1 spmonitor.1 spread.1 sptuser.1 spuser.1
@@ -52,7 +54,7 @@
 post-patch:
 .for f in configuration.c auth-ip.c auth-pword.c docs/spread.1 \
 	docs/spmonitor.1 Readme.txt
-	@${PERL} -pi -e 's,/etc/spread,${PREFIX}/etc/spread,g' ${WRKSRC}/${f}
+	@${REINPLACE_CMD} -e 's,/etc/spread,${PREFIX}/etc/spread,g' ${WRKSRC}/${f}
 .endfor
 
 post-build:
@@ -76,7 +78,11 @@
 	${INSTALL_PROGRAM} ${WRKSRC}/spuser ${PREFIX}/bin
 	${INSTALL_PROGRAM} ${WRKSRC}/sptuser ${PREFIX}/bin
 	${INSTALL_DATA} ${WRKSRC}/libsp.a ${PREFIX}/lib
+	ln -sf libspread.so.1 ${PREFIX}/lib/libspread.so
+	${INSTALL_DATA} ${WRKSRC}/libspread.so ${PREFIX}/lib/libspread.so.1
 	${INSTALL_DATA} ${WRKSRC}/libtsp.a ${PREFIX}/lib
+	ln -sf libspread.so.1 ${PREFIX}/lib/libtspread.so
+	${INSTALL_DATA} ${WRKSRC}/libtspread.so ${PREFIX}/lib/libtspread.so.1
 	${INSTALL_DATA} ${WRKSRC}/sp.h ${PREFIX}/include
 	${INSTALL_DATA} ${WRKSRC}/sp_func.h ${PREFIX}/include
 	${INSTALL_DATA} ${WRKSRC}/sp_events.h ${PREFIX}/include
Index: pkg-plist
===================================================================
RCS file: /cvs/ports/net/spread/pkg-plist,v
retrieving revision 1.3
diff -u -u -r1.3 pkg-plist
--- pkg-plist	13 Apr 2002 10:02:26 -0000	1.3
+++ pkg-plist	9 Sep 2002 11:08:00 -0000
@@ -9,7 +9,11 @@
 etc/spread.conf.sample
 etc/spread.access_ip.sample
 lib/libsp.a
+lib/libspread.so
+lib/libspread.so.1
 lib/libtsp.a
+lib/libtspread.so
+lib/libtspread.so.1
 lib/perl5/site_perl/%%PERL_VER%%/%%PERL_ARCH%%/auto/Spread/Spread.so
 lib/perl5/site_perl/%%PERL_VER%%/%%PERL_ARCH%%/auto/Spread/Spread.bs
 lib/perl5/site_perl/%%PERL_VER%%/%%PERL_ARCH%%/auto/Spread/autosplit.ix
Index: files/patch-FreeBSD_makefile
===================================================================
RCS file: /cvs/ports/net/spread/files/patch-FreeBSD_makefile,v
retrieving revision 1.2
diff -u -u -r1.2 patch-FreeBSD_makefile
--- files/patch-FreeBSD_makefile	2 Mar 2002 16:59:30 -0000	1.2
+++ files/patch-FreeBSD_makefile	10 Sep 2002 11:11:40 -0000
@@ -1,31 +1,96 @@
---- FreeBSD_makefile.orig	Wed Aug 22 00:28:21 2001
-+++ FreeBSD_makefile	Thu Feb 28 23:27:26 2002
+--- FreeBSD_makefile	8 Sep 2002 14:48:53 -0000	1.1.1.1
++++ FreeBSD_makefile	9 Sep 2002 11:05:59 -0000	1.6
 @@ -1,4 +1,3 @@
 -CC=gcc
  MAKEFILE=FreeBSD_makefile
  YACC = bison -y
  LEX = flex
-@@ -8,8 +7,8 @@
+@@ -8,17 +7,26 @@
  #SRCDIRS= dir1 dir2
  #INCL=$(SRCDIRS:%=-I%)
  #CFLAGS =  -O does not always work on BSDI pc
 -CFLAGS = -ansi -c -Wall -O3
 -TCFLAGS = $(CFLAGS) -pthread
++
 +CFLAGS += -ansi -c
++SHLIB_NAME = libspread.so.1
++SHLIB_LINK = libspread.so
++SHLIBFLAGS = -L. -lspread
++
 +TCFLAGS = $(CFLAGS) $(PTHREAD_LIBS)
++TSHLIB_NAME = libtspread.so.1
++TSHLIB_LINK = libtspread.so
++TSHLIBFLAGS = -L. -ltspread
  
  COBJS = lex.yy.o y.tab.o configuration.o skiplist.o acm.o 
  OBJS =  alarm.o events.o memory.o membership.o data_link.o network.o status.o log.o flow_control.o message.o acp-permit.o auth-null.o auth-ip.o
-@@ -30,7 +29,7 @@
- 	$(CC) -o spuser user.o libsp.a
  
- sptuser : user.to libtsp.a 
+ .SUFFIXES : .o .to .lo .tlo
+ 
+-all: spread spmonitor spuser sptuser simple_user spflooder
++all: spread spmonitor spuser sptuser simple_user spflooder shared static
+ 
+-shared : libsp.so libtsp.so
++shared : $(SHLIB_NAME) $(TSHLIB_NAME)
++static : libsp.a libtsp.a
+ 
+ spread : $(OBJS) $(COBJS) spread.o protocol.o session.o groups.o
+ 	$(CC) -o spread spread.o protocol.o session.o groups.o $(OBJS) $(COBJS)
+@@ -26,17 +34,17 @@
+ spmonitor : monitor.o alarm.o events.o memory.o data_link.o $(COBJS)
+ 	$(CC) -o spmonitor monitor.o  alarm.o events.o memory.o data_link.o $(COBJS)
+ 
+-spuser : user.o libsp.a 
+-	$(CC) -o spuser user.o libsp.a
++spuser : user.o $(SHLIB_NAME)
++	$(CC) $(SHLIBFLAGS) -o spuser user.o
+ 
+-sptuser : user.to libtsp.a 
 -	$(CC) -pthread -o sptuser user.to libtsp.a
-+	$(CC) $(PTHREAD_LIBS) -o sptuser user.to libtsp.a
++sptuser : user.to $(TSHLIB_NAME)
++	$(CC) $(PTHREAD_LIBS) $(TSHLIBFLAGS) -o sptuser user.to
+ 
+-simple_user : simple_user.o libsp.a
+-	$(CC) -o simple_user simple_user.o libsp.a 
++simple_user : simple_user.o $(SHLIB_NAME)
++	$(CC) $(SHLIBFLAGS) -o simple_user simple_user.o
+ 
+-spflooder : flooder.o libsp.a
+-	$(CC) -o spflooder flooder.o libsp.a
++spflooder : flooder.o $(SHLIB_NAME)
++	$(CC) $(SHLIBFLAGS) -o spflooder flooder.o
+ 
+ run_spread : run_spread.o
+ 	$(CC) -o run_spread run_spread.o
+@@ -47,11 +55,13 @@
+ r : r.o alarm.o data_link.o
+ 	$(CC) -o r r.o alarm.o data_link.o
+ 
+-libsp.so : alarm.lo events.lo memory.lo sp.lo
+-	gcc -shared -o libsp.so alarm.lo events.lo memory.lo sp.lo
+-
+-libtsp.so : alarm.tlo events.tlo memory.tlo sp.tlo
+-	gcc -shared -o libtsp.so alarm.tlo events.tlo memory.tlo sp.tlo
++$(SHLIB_NAME) : alarm.lo events.lo memory.lo sp.lo
++	gcc -shared -Wl,-soname -Wl,$(SHLIB_NAME) -o $(SHLIB_NAME) alarm.lo events.lo memory.lo sp.lo
++	ln -fs $(SHLIB_NAME) $(SHLIB_LINK)
++
++$(TSHLIB_NAME) : alarm.tlo events.tlo memory.tlo sp.tlo
++	gcc -shared -Wl,-soname -Wl,$(TSHLIB_NAME) -o $(TSHLIB_NAME) alarm.tlo events.tlo memory.tlo sp.tlo
++	ln -fs $(TSHLIB_NAME) $(TSHLIB_LINK)
+ 
+ libsp.a : alarm.o events.o memory.o sp.o
+ 	ar r libsp.a alarm.o events.o memory.o sp.o; ranlib libsp.a
+@@ -60,7 +70,7 @@
+ 	ar r libtsp.a alarm.to events.to memory.to sp.to; ranlib libtsp.a
+ 
+ clean:
+-	rm -f *.o *.to libsp.a libtsp.a
++	rm -f *.o *.to libsp.a libtsp.a $(SHLIB_NAME) $(SHLIB_LINK) $(TSHLIB_NAME) $(TSHLIB_LINK)
  
- simple_user : simple_user.o libsp.a
- 	$(CC) -o simple_user simple_user.o libsp.a 
-@@ -78,7 +77,7 @@
+ lex.yy.c:       config_gram.l conf_body.h y.tab.h arch.h
+ 	$(LEX) config_gram.l
+@@ -78,7 +88,7 @@
  	$(CC) $(TCFLAGS) -fPIC -D_REENTRANT $*.c -o $*.tlo
  
  .c.to:	
Index: files/patch-perl::Spread::Makefile.PL
===================================================================
RCS file: files/patch-perl::Spread::Makefile.PL
diff -N files/patch-perl::Spread::Makefile.PL
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/patch-perl::Spread::Makefile.PL	8 Sep 2002 15:13:10 -0000
@@ -0,0 +1,17 @@
+Index: perl/Spread/Makefile.PL
+===================================================================
+RCS file: /usr/ports/net/spread/cvstree/cvssrc/perl/Spread/Makefile.PL,v
+retrieving revision 1.1.1.1
+retrieving revision 1.2
+diff -u -r1.1.1.1 -r1.2
+--- perl/Spread/Makefile.PL	8 Sep 2002 14:48:53 -0000	1.1.1.1
++++ perl/Spread/Makefile.PL	8 Sep 2002 15:12:49 -0000	1.2
+@@ -8,7 +8,7 @@
+ WriteMakefile(
+ 	NAME		=> 'Spread',
+ 	VERSION_FROM	=> 'Spread.pm',
+-	LIBS		=> [ "$SPLIB_LIB -lsp" ],
++	LIBS		=> [ "$SPLIB_LIB -lspread" ],
+ 	INC		=> " $SPLIB_INCLUDE" ,
+ 	dist		=> { COMPRESS => 'gzip -9f',
+ 			     SUFFIX => 'gz', },
>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020910122925.EF1794134>