Bug 79844 - Update port: net/olsrd
Summary: Update port: net/olsrd
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Sam Lawrance
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-04-13 03:50 UTC by dave
Modified: 2005-05-07 14:56 UTC (History)
0 users

See Also:


Attachments
file.shar (7.53 KB, text/plain)
2005-04-13 03:50 UTC, dave
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description dave 2005-04-13 03:50:22 UTC
	Update port to add a startup script and add some messages
	indicating how to build multi-IF support and that you must
	add "olsrd_enable" to rc.conf to start it up at boot time
Comment 1 Volker Stolz freebsd_committer freebsd_triage 2005-04-13 13:30:23 UTC
State Changed
From-To: open->feedback

Please submit updates in 'unified diff' format! 


Comment 2 Volker Stolz freebsd_committer freebsd_triage 2005-04-13 13:30:23 UTC
Class Changed
From-To: update->maintainer-update

Please submit updates in 'unified diff' format!
Comment 3 Sam Lawrance freebsd_committer freebsd_triage 2005-04-20 16:18:56 UTC
Responsible Changed
From-To: freebsd-ports-bugs->lawrance

Grab.
Comment 4 Sam Lawrance 2005-04-20 17:07:39 UTC
The patch you have submitted is against your original port, not the one
that was committed to the tree.  Please update your ports tree and work
from that.

Also, please submit all patches in unified diff format, not shars or
otherwise.

Have a look at USE_RC_SUBR in bsd.port.mk - it will save some work in
the makefile ;)

Cheers
Sam
Comment 5 dave 2005-04-21 21:48:25 UTC
Yes, Volker called me on it, and last thing, I think I ticked him off
at my cluelessness about how to update the update PR.  I have a patch
made against the committed port rather than my original done as a
unified diff, I just need to know how to get it in a form/place you
can use.  I'll paste the patch in below, and I will write a program
that will spew 5 million lines of "From now on I will make a unified
diff against the committed code rather than the submitted"

thanks,
dave c

> The patch you have submitted is against your original port, not the one
> that was committed to the tree.  Please update your ports tree and work
> from that.
> 
> Also, please submit all patches in unified diff format, not shars or
> otherwise.
> 
> Have a look at USE_RC_SUBR in bsd.port.mk - it will save some work in
> the makefile ;)
> 
> Cheers
> Sam
> 
> 
> 

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	OLSRDPATCH
#
echo x - OLSRDPATCH
sed 's/^X//' >OLSRDPATCH << 'END-of-OLSRDPATCH'
Xdiff -x CVS -urN /usr/ports/net/olsrd/Makefile ./Makefile
X--- /usr/ports/net/olsrd/Makefile	Thu Apr 14 15:01:00 2005
X+++ ./Makefile	Wed Apr 13 03:19:20 2005
X@@ -2,11 +2,12 @@
X # Date created:		6 April 2005
X # Whom:			dave@dogwood.com
X #
X-# $FreeBSD: ports/net/olsrd/Makefile,v 1.1 2005/04/08 22:22:36 pav Exp $
X+# $FreeBSD$
X #
X 
X PORTNAME=	olsrd
X PORTVERSION=	0.4.9
X+PORTREVISION=	1
X CATEGORIES=	net
X MASTER_SITES=	http://www.olsr.org/releases/0.4/
X 
X@@ -37,5 +38,23 @@
X .if ${OSVERSION} < 502000
X IGNORE=		needs ieee80211.h headers
X .endif
X+
X+.if !defined(WITH_MULTI_IF)
X+pre-everything::
X+	@${ECHO_MSG}	""
X+	@${ECHO_MSG}	" To enable multiple interface support make with"
X+	@${ECHO_MSG}	" WITH_MULTI_IF defined"
X+	@${ECHO_MSG}	""
X+.endif
X+
X+post-patch:
X+	@${SED} -e "s|%%PREFIX%%|${PREFIX}|g" -e "s|%%RC_SUBR%%|${RC_SUBR}|g" \
X+		< ${FILESDIR}/olsrd.sh > ${WRKDIR}/olsrd.sh
X+
X+post-install:
X+	${INSTALL_SCRIPT} ${WRKDIR}/olsrd.sh ${PREFIX}/etc/rc.d/olsrd.sh
X+	@${ECHO_MSG}	""
X+	@${ECHO_MSG}	" Set olsrd_enable=\"YES\" in /etc/rc.conf to enable"
X+	@${ECHO_MSG}	""
X 
X .include <bsd.port.post.mk>
Xdiff -x CVS -urN /usr/ports/net/olsrd/files/olsrd.sh ./files/olsrd.sh
X--- /usr/ports/net/olsrd/files/olsrd.sh	Wed Dec 31 14:00:00 1969
X+++ ./files/olsrd.sh	Wed Apr  6 21:18:10 2005
X@@ -0,0 +1,20 @@
X+#!/bin/sh
X+#
X+# $FreeBSD$
X+#
X+# PROVIDE: olsrd
X+# REQUIRE: NETWORKING SERVERS
X+
X+. /etc/rc.subr
X+
X+name="olsrd"
X+rcvar=`set_rcvar`
X+
X+command=%%PREFIX%%/sbin/olsrd
X+command_args="-d 0"
X+
X+olsrd_enable=${olsrd_enable:-"NO"}
X+
X+load_rc_config $name
X+run_rc_command "$1"
X+
Xdiff -x CVS -urN /usr/ports/net/olsrd/files/patch-Makefile ./files/patch-Makefile
X--- /usr/ports/net/olsrd/files/patch-Makefile	Fri Apr  8 12:22:36 2005
X+++ ./files/patch-Makefile	Wed Apr 13 03:35:11 2005
X@@ -1,65 +1,109 @@
X---- Makefile.orig	Thu Mar 31 20:39:24 2005
X-+++ Makefile	Sat Apr  9 00:09:42 2005
X-@@ -47,7 +47,9 @@
X- CCWARNINGS = -Wall -Wmissing-prototypes -Wstrict-prototypes \
X-              -Wmissing-declarations -Wsign-compare
X- 
X--INSTALL_PREFIX ?=
X-+PREFIX?=	/usr/local
X-+INSTALL_PREFIX?= ${PREFIX}
X-+CFGFILE?=	${INSTALL_PREFIX}/etc/olsrd.conf
X- 
X- INCLUDES =	-Isrc
X- 
X-@@ -84,7 +86,7 @@
X- 
X- SRCS +=		$(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
X- HDRS +=		$(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
X--CFLAGS ?=	$(CCWARNINGS) -O2 -g
X-+CFLAGS +=	-DOLSRD_GLOBAL_CONF_FILE=\"${CFGFILE}\"
X- LIBS =		-lm
X- MAKEDEPEND = 	makedepend -f $(DEPFILE) -D__FreeBSD__ $(INCLUDES) $(SRCS)
X- 
X-@@ -96,8 +98,8 @@
X- 
X- SRCS +=		$(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
X- HDRS +=		$(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
X--CFLAGS ?=	-Wall -Wmissing-prototypes -O2 -g -DSPOOF -I/usr/local/include
X--LIBS =		-lm -L/usr/local/lib -lnet
X-+CFLAGS +=	-DSPOOF -I${LOCALBASE}/include -DOLSRD_GLOBAL_CONF_FILE=\"${CFGFILE}\"
X-+LIBS =		-lm -L${LOCALBASE}/lib -lnet
X- MAKEDEPEND = 	makedepend -f $(DEPFILE) -D__FreeBSD__ $(INCLUDES) $(SRCS)
X- 
X- all:     cfgparser olsrd
X-@@ -292,8 +294,8 @@
X- 
X- install_bin:
X- 		$(STRIP) olsrd
X--		mkdir -p $(INSTALL_PREFIX)/usr/sbin
X--		install -m 755 olsrd $(INSTALL_PREFIX)/usr/sbin
X-+		mkdir -p $(INSTALL_PREFIX)/sbin
X-+		install -m 755 olsrd $(INSTALL_PREFIX)/sbin
X- 
X- install_olsrd:	install_bin
X- 		@echo ========= C O N F I G U R A T I O N - F I L E ============
X-@@ -303,15 +305,15 @@
X- 		@echo can be found at files/olsrd.conf.default.lq
X- 		@echo ==========================================================
X- 		mkdir -p $(INSTALL_PREFIX)/etc
X--		cp -i files/olsrd.conf.default.rfc $(INSTALL_PREFIX)/etc/olsrd.conf
X-+		cp files/olsrd.conf.default.rfc $(INSTALL_PREFIX)/etc/olsrd.conf.default
X- 		@echo -------------------------------------------
X- 		@echo Edit $(INSTALL_PREFIX)/etc/olsrd.conf before running olsrd!!
X- 		@echo -------------------------------------------
X- 		@echo Installing manpages olsrd\(8\) and olsrd.conf\(5\)
X--		mkdir -p $(INSTALL_PREFIX)/usr/share/man/man8/
X--		cp files/olsrd.8.gz $(INSTALL_PREFIX)/usr/share/man/man8/olsrd.8.gz
X--		mkdir -p $(INSTALL_PREFIX)/usr/share/man/man5/
X--		cp files/olsrd.conf.5.gz $(INSTALL_PREFIX)/usr/share/man/man5/olsrd.conf.5.gz
X-+		mkdir -p $(INSTALL_PREFIX)/man/man8/
X-+		cp files/olsrd.8.gz $(INSTALL_PREFIX)/man/man8/olsrd.8.gz
X-+		mkdir -p $(INSTALL_PREFIX)/man/man5/
X-+		cp files/olsrd.conf.5.gz $(INSTALL_PREFIX)/man/man5/olsrd.conf.5.gz
X- 
X- #
X- # PLUGINS
X+*** Makefile.orig	Thu Mar 31 08:39:24 2005
X+--- Makefile	Wed Apr 13 03:32:09 2005
X+***************
X+*** 47,53 ****
X+  CCWARNINGS = -Wall -Wmissing-prototypes -Wstrict-prototypes \
X+               -Wmissing-declarations -Wsign-compare
X+  
X+! INSTALL_PREFIX ?=
X+  
X+  INCLUDES =	-Isrc
X+  
X+--- 47,55 ----
X+  CCWARNINGS = -Wall -Wmissing-prototypes -Wstrict-prototypes \
X+               -Wmissing-declarations -Wsign-compare
X+  
X+! PREFIX?=	/usr/local
X+! INSTALL_PREFIX?= ${PREFIX}
X+! CFGFILE?=	${INSTALL_PREFIX}/etc/olsrd.conf
X+  
X+  INCLUDES =	-Isrc
X+  
X+***************
X+*** 84,90 ****
X+  
X+  SRCS +=		$(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
X+  HDRS +=		$(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
X+! CFLAGS ?=	$(CCWARNINGS) -O2 -g
X+  LIBS =		-lm
X+  MAKEDEPEND = 	makedepend -f $(DEPFILE) -D__FreeBSD__ $(INCLUDES) $(SRCS)
X+  
X+--- 86,92 ----
X+  
X+  SRCS +=		$(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
X+  HDRS +=		$(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
X+! CFLAGS +=	-DOLSRD_GLOBAL_CONF_FILE=\"${CFGFILE}\"
X+  LIBS =		-lm
X+  MAKEDEPEND = 	makedepend -f $(DEPFILE) -D__FreeBSD__ $(INCLUDES) $(SRCS)
X+  
X+***************
X+*** 96,103 ****
X+  
X+  SRCS +=		$(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
X+  HDRS +=		$(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
X+! CFLAGS ?=	-Wall -Wmissing-prototypes -O2 -g -DSPOOF -I/usr/local/include
X+! LIBS =		-lm -L/usr/local/lib -lnet
X+  MAKEDEPEND = 	makedepend -f $(DEPFILE) -D__FreeBSD__ $(INCLUDES) $(SRCS)
X+  
X+  all:     cfgparser olsrd
X+--- 98,105 ----
X+  
X+  SRCS +=		$(wildcard src/bsd/*.c) $(wildcard src/unix/*.c)
X+  HDRS +=		$(wildcard src/bsd/*.h) $(wildcard src/unix/*.h)
X+! CFLAGS +=	-DSPOOF -I${LOCALBASE}/include -DOLSRD_GLOBAL_CONF_FILE=\"${CFGFILE}\"
X+! LIBS =		-lm -L${LOCALBASE}/lib -lnet
X+  MAKEDEPEND = 	makedepend -f $(DEPFILE) -D__FreeBSD__ $(INCLUDES) $(SRCS)
X+  
X+  all:     cfgparser olsrd
X+***************
X+*** 292,299 ****
X+  
X+  install_bin:
X+  		$(STRIP) olsrd
X+! 		mkdir -p $(INSTALL_PREFIX)/usr/sbin
X+! 		install -m 755 olsrd $(INSTALL_PREFIX)/usr/sbin
X+  
X+  install_olsrd:	install_bin
X+  		@echo ========= C O N F I G U R A T I O N - F I L E ============
X+--- 294,301 ----
X+  
X+  install_bin:
X+  		$(STRIP) olsrd
X+! 		mkdir -p $(INSTALL_PREFIX)/sbin
X+! 		install -m 755 olsrd $(INSTALL_PREFIX)/sbin
X+  
X+  install_olsrd:	install_bin
X+  		@echo ========= C O N F I G U R A T I O N - F I L E ============
X+***************
X+*** 303,317 ****
X+  		@echo can be found at files/olsrd.conf.default.lq
X+  		@echo ==========================================================
X+  		mkdir -p $(INSTALL_PREFIX)/etc
X+! 		cp -i files/olsrd.conf.default.rfc $(INSTALL_PREFIX)/etc/olsrd.conf
X+  		@echo -------------------------------------------
X+  		@echo Edit $(INSTALL_PREFIX)/etc/olsrd.conf before running olsrd!!
X+  		@echo -------------------------------------------
X+  		@echo Installing manpages olsrd\(8\) and olsrd.conf\(5\)
X+! 		mkdir -p $(INSTALL_PREFIX)/usr/share/man/man8/
X+! 		cp files/olsrd.8.gz $(INSTALL_PREFIX)/usr/share/man/man8/olsrd.8.gz
X+! 		mkdir -p $(INSTALL_PREFIX)/usr/share/man/man5/
X+! 		cp files/olsrd.conf.5.gz $(INSTALL_PREFIX)/usr/share/man/man5/olsrd.conf.5.gz
X+  
X+  #
X+  # PLUGINS
X+--- 305,319 ----
X+  		@echo can be found at files/olsrd.conf.default.lq
X+  		@echo ==========================================================
X+  		mkdir -p $(INSTALL_PREFIX)/etc
X+! 		cp files/olsrd.conf.default.rfc $(INSTALL_PREFIX)/etc/olsrd.conf.default
X+  		@echo -------------------------------------------
X+  		@echo Edit $(INSTALL_PREFIX)/etc/olsrd.conf before running olsrd!!
X+  		@echo -------------------------------------------
X+  		@echo Installing manpages olsrd\(8\) and olsrd.conf\(5\)
X+! 		mkdir -p $(INSTALL_PREFIX)/man/man8/
X+! 		cp files/olsrd.8.gz $(INSTALL_PREFIX)/man/man8/olsrd.8.gz
X+! 		mkdir -p $(INSTALL_PREFIX)/man/man5/
X+! 		cp files/olsrd.conf.5.gz $(INSTALL_PREFIX)/man/man5/olsrd.conf.5.gz
X+  
X+  #
X+  # PLUGINS
Xdiff -x CVS -urN /usr/ports/net/olsrd/files/patch-src-defs.h ./files/patch-src-defs.h
X--- /usr/ports/net/olsrd/files/patch-src-defs.h	Fri Apr  8 12:22:36 2005
X+++ ./files/patch-src-defs.h	Wed Apr  6 10:31:05 2005
X@@ -1,13 +1,15 @@
X---- src/defs.h.orig	Fri Apr  1 07:14:22 2005
X-+++ src/defs.h	Sat Apr  9 00:08:01 2005
X-@@ -64,8 +64,10 @@
X- #define SOFTWARE_VERSION "olsr.org - " VERSION
X- #define OLSRD_VERSION_DATE "       *** " SOFTWARE_VERSION " (" __DATE__ ") ***\n"
X- 
X-+#ifndef OLSRD_GLOBAL_CONF_FILE
X- #define OLSRD_CONF_FILE_NAME "olsrd.conf"
X- #define OLSRD_GLOBAL_CONF_FILE "/etc/" OLSRD_CONF_FILE_NAME
X-+#endif
X- 
X- #define	HOPCNT_MAX		32	/* maximum hops number */
X- #define	MAXMESSAGESIZE		1500	/* max broadcast size */
X+*** src/defs.h.orig	Thu Mar 31 19:14:22 2005
X+--- src/defs.h	Wed Apr  6 10:30:18 2005
X+***************
X+*** 64,71 ****
X+--- 64,73 ----
X+  #define SOFTWARE_VERSION "olsr.org - " VERSION
X+  #define OLSRD_VERSION_DATE "       *** " SOFTWARE_VERSION " (" __DATE__ ") ***\n"
X+  
X++ #ifndef OLSRD_GLOBAL_CONF_FILE
X+  #define OLSRD_CONF_FILE_NAME "olsrd.conf"
X+  #define OLSRD_GLOBAL_CONF_FILE "/etc/" OLSRD_CONF_FILE_NAME
X++ #endif
X+  
X+  #define	HOPCNT_MAX		32	/* maximum hops number */
X+  #define	MAXMESSAGESIZE		1500	/* max broadcast size */
Xdiff -x CVS -urN /usr/ports/net/olsrd/pkg-plist ./pkg-plist
X--- /usr/ports/net/olsrd/pkg-plist	Fri Apr  8 12:22:36 2005
X+++ ./pkg-plist	Wed Apr  6 22:00:23 2005
X@@ -1,2 +1,3 @@
X sbin/olsrd
X etc/olsrd.conf.default
X+etc/rc.d/olsrd.sh
END-of-OLSRDPATCH
exit
Comment 6 Sam Lawrance freebsd_committer freebsd_triage 2005-05-07 14:56:08 UTC
State Changed
From-To: feedback->closed

Committed with modifications, thanks!