From owner-freebsd-bugs@FreeBSD.ORG Fri May 2 15:37:43 2003 Return-Path: Delivered-To: freebsd-bugs@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B618E37B401; Fri, 2 May 2003 15:37:43 -0700 (PDT) Received: from mailman.zeta.org.au (mailman.zeta.org.au [203.26.10.16]) by mx1.FreeBSD.org (Postfix) with ESMTP id D2AB443FAF; Fri, 2 May 2003 15:37:41 -0700 (PDT) (envelope-from bde@zeta.org.au) Received: from katana.zip.com.au (katana.zip.com.au [61.8.7.246]) by mailman.zeta.org.au (8.9.3p2/8.8.7) with ESMTP id IAA31293; Sat, 3 May 2003 08:37:37 +1000 Date: Sat, 3 May 2003 08:37:35 +1000 (EST) From: Bruce Evans X-X-Sender: bde@gamplex.bde.org To: Ruslan Ermilov In-Reply-To: <20030426203002.GA66677@sunbay.com> Message-ID: <20030503081416.J24793@gamplex.bde.org> References: <20030426052507.N40408@gamplex.bde.org> <20030426203002.GA66677@sunbay.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: simon@comsys.ntu-kpi.kiev.ua cc: freebsd-bugs@freebsd.org cc: Darren Reed Subject: Re: misc/44148: installworld in 4.7-STABLE does not installIPFilter related header files X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 02 May 2003 22:37:44 -0000 On Sat, 26 Apr 2003, Ruslan Ermilov wrote: > On Sat, Apr 26, 2003 at 03:56:54PM +1000, Darren Reed wrote: > > In some email I received from Bruce Evans, sie wrote: > > > > > > > So, I'd like to either do this on a directory level, or kill > > > > the SHARED=symlinks concept. > > > > > > I depend on SHARED=symlinks a lot. However, the number of things that > > > must be installed manually when not using makeworld is large so another > > > set of includes wouldn't make much difference. > > > > So are we agreed then that we can move to netinet being created as a > > directory and populated with symbolic links ? > > > Here's an implementation (without ipfilter). Please review. I tested it lightly. It seems OK except for having lots of style bugs. % Index: Makefile % =================================================================== % RCS file: /home/ncvs/src/include/Makefile,v % retrieving revision 1.196 % diff -u -r1.196 Makefile % --- Makefile 17 Apr 2003 14:14:21 -0000 1.196 % +++ Makefile 26 Apr 2003 20:22:19 -0000 % ... % @@ -80,48 +76,74 @@ % INCSLINKS+= posix4/$i ${INCLUDEDIR}/$i % .endfor % % -copies: % -.for i in ${LDIRS} ${LSYMSUBDIRS} machine crypto % - if [ -L ${DESTDIR}/usr/include/$i ]; then \ % - rm -f ${DESTDIR}/usr/include/$i; \ % +.include % + % +installincludes: ${SHARED} % +${SHARED}: compat % + % +compat: % +.for i in ${LDIRS} ${LSUBDIRS} machine crypto % + if [ -L ${DESTDIR}${INCLUDEDIR}/$i ]; then \ % + rm -f ${DESTDIR}${INCLUDEDIR}/$i; \ % fi New style bug: indent of only 4 in a shell script (it's only a continued line at the level of the Makefile). % .endfor % mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/../etc/mtree/BSD.include.dist \ % -p ${DESTDIR}/usr/include Inherited style bugs: indent of 8 for a continued line (it really is a continued line), and line longer than 80 characters (particularly stupid since the line is split to make it not so long). Maybe the compat stuff can be cleaned up a bit. mtree could be run more globally as in all other Makefiles excrpt for the problem of removing the symlinks to directories. % + % +# INCLUDEDIR is defined only here. I don't understand this comment. INCLUDEDIR is defined in bsd.own.mk, not here. INCLUDEDIR is used before here. It never actually worked, even at install time, since it was hard-coded in many places. You fixed a few of these places, but it is still hard-coded in 2 comments, 1 error message and the main mtree step. % +copies: % +.for i in ${LDIRS} ${LSUBDIRS} crypto machine machine/pc % +.if exists(${DESTDIR}${INCLUDEDIR}/$i) % + cd ${DESTDIR}${INCLUDEDIR}/$i; \ % + for h in *.h; do \ % + if [ -L $$h ]; then \ % + rm -f $$h; \ % + fi; \ % + done More too-small indentations. % ... % -installincludes: ${SHARED} % + cd ${.CURDIR}/../sys/$i; \ % + for h in *.h; do \ % + ln -fs ../../../sys/$i/$$h ${DESTDIR}${INCLUDEDIR}/$i; \ % + done % +.endfor % +.for i in ${LSUBDIRS} % + cd ${.CURDIR}/../sys/$i; \ % + for h in *.h; do \ % + ln -fs ../../../../sys/$i/$$h ${DESTDIR}${INCLUDEDIR}/$i; \ % + done % +.endfor % + cd ${.CURDIR}/../sys/opencrypto; \ % + for h in *.h; do \ % + ln -fs ../../../sys/opencrypto/$$h ${DESTDIR}${INCLUDEDIR}/crypto; \ % + done % + cd ${.CURDIR}/../sys/${MACHINE_ARCH}/include; \ % + for h in *.h; do \ % + ln -fs ../../../sys/${MACHINE_ARCH}/include/$$h ${DESTDIR}${INCLUDEDIR}/machine; \ % + done % +.if exists(${.CURDIR}/../sys/${MACHINE_ARCH}/include/pc) % + cd ${.CURDIR}/../sys/${MACHINE_ARCH}/include/pc; \ % + for h in *.h; do \ % + ln -fs ../../../../sys/${MACHINE_ARCH}/include/$$h ${DESTDIR}${INCLUDEDIR}/machine/pc; \ % + done % +.endif More too-small indentations and too-long lines. Bruce