From owner-freebsd-current@FreeBSD.ORG Tue Mar 21 06:46:20 2006 Return-Path: X-Original-To: freebsd-current@FreeBSD.org Delivered-To: freebsd-current@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 367BA16A41F; Tue, 21 Mar 2006 06:46:20 +0000 (UTC) (envelope-from ru@ip.net.ua) Received: from tigra.ip.net.ua (tigra.ip.net.ua [82.193.96.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 23C7B43D5A; Tue, 21 Mar 2006 06:46:16 +0000 (GMT) (envelope-from ru@ip.net.ua) Received: from localhost (rocky.ip.net.ua [82.193.96.2]) by tigra.ip.net.ua (8.12.11/8.12.11) with ESMTP id k2L6kFdK095524; Tue, 21 Mar 2006 08:46:15 +0200 (EET) (envelope-from ru@ip.net.ua) Received: from tigra.ip.net.ua ([82.193.96.10]) by localhost (rocky.ip.net.ua [82.193.96.2]) (amavisd-new, port 10024) with LMTP id 99120-12; Tue, 21 Mar 2006 08:46:06 +0200 (EET) Received: from heffalump.ip.net.ua (heffalump.ip.net.ua [82.193.96.213]) by tigra.ip.net.ua (8.12.11/8.12.11) with ESMTP id k2L6j75G095498 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 21 Mar 2006 08:45:07 +0200 (EET) (envelope-from ru@ip.net.ua) Received: (from ru@localhost) by heffalump.ip.net.ua (8.13.4/8.13.4) id k2L6jTJg078048; Tue, 21 Mar 2006 08:45:29 +0200 (EET) (envelope-from ru) Date: Tue, 21 Mar 2006 08:45:28 +0200 From: Ruslan Ermilov To: Doug Barton Message-ID: <20060321064528.GD77849@ip.net.ua> References: <20060320221741.GA13699@troutmask.apl.washington.edu> <20060320230009.GA55254@troutmask.apl.washington.edu> <20060320231604.GH83781@ip.net.ua> <20060320232746.GI83781@ip.net.ua> <20060320234006.GV35129@funkthat.com> <20060320234145.GB33003@troutmask.apl.washington.edu> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="LSp5EJdfMPwZcMS1" Content-Disposition: inline In-Reply-To: <20060320234145.GB33003@troutmask.apl.washington.edu> User-Agent: Mutt/1.5.11 X-Virus-Scanned: amavisd-new at ip.net.ua Cc: freebsd-current@FreeBSD.org, Steve Kargl Subject: Re: mergemaster broken? X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Mar 2006 06:46:20 -0000 --LSp5EJdfMPwZcMS1 Content-Type: multipart/mixed; boundary="8nsIa27JVQLqB7/C" Content-Disposition: inline --8nsIa27JVQLqB7/C Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Mar 20, 2006 at 03:41:45PM -0800, Steve Kargl wrote: > On Mon, Mar 20, 2006 at 03:40:06PM -0800, John-Mark Gurney wrote: > >=20 > > Should we also document that -m is suppose to be src's etc dir instead > > of src? I've accidentally pointed -m at src, and then it does a make > > which is quite ammuzing as it's completely the wrong thing... Or now > > that we call outside of /etc, should we make -m really point to src, > > and have the proper calls add etc to the directory? > >=20 >=20 > Although you may already realize this, in this case -m did not work. > I haven't tried -m with ru's patch. >=20 Doesn't really matter, mergemaster(8) was broken because it was written when we didn't have correct wrappers for "distrib-dirs" and "distribution", upgrade and cross-arch friendly, at the top level. Anyway, attached is the patch I'd like to commit after a nod =66rom Doug. It fixes mergemaster(8) to use src/Makefile wrappers for distrib-dirs and distribution targets, and makes it use TARGET_ARCH instead of faking up MACHINE_ARCH, now that it uses the correct wrappers. It also makes ${SOURCEDIR} and -m point at the src/ top, as documented in a manpage. Cheers, --=20 Ruslan Ermilov ru@FreeBSD.org FreeBSD committer --8nsIa27JVQLqB7/C Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=p Content-Transfer-Encoding: quoted-printable Index: mergemaster.sh =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /home/ncvs/src/usr.sbin/mergemaster/mergemaster.sh,v retrieving revision 1.53 diff -u -r1.53 mergemaster.sh --- mergemaster.sh 4 Feb 2006 18:24:06 -0000 1.53 +++ mergemaster.sh 21 Mar 2006 06:39:08 -0000 @@ -242,7 +242,7 @@ while getopts ":ascrvhipCPm:t:du:w:D:A:" COMMAND_LINE_ARGUMENT ; do case "${COMMAND_LINE_ARGUMENT}" in A) - ARCHSTRING=3D'MACHINE_ARCH=3D'${OPTARG} + ARCHSTRING=3D'TARGET_ARCH=3D'${OPTARG} ;; s) STRICT=3Dyes @@ -380,7 +380,7 @@ =20 # Assign the source directory # -SOURCEDIR=3D${SOURCEDIR:-/usr/src/etc} +SOURCEDIR=3D${SOURCEDIR:-/usr/src} =20 # Check the width of the user's terminal # @@ -511,8 +511,8 @@ ;; esac make DESTDIR=3D${TEMPROOT} ${ARCHSTRING} distrib-dirs && - MAKEOBJDIRPREFIX=3D${TEMPROOT}/usr/obj make ${ARCHSTRING} obj && - MAKEOBJDIRPREFIX=3D${TEMPROOT}/usr/obj make ${ARCHSTRING} all && + MAKEOBJDIRPREFIX=3D${TEMPROOT}/usr/obj make ${ARCHSTRING} obj SUBDIR= _OVERRIDE=3Detc && + MAKEOBJDIRPREFIX=3D${TEMPROOT}/usr/obj make ${ARCHSTRING} all SUBDIR= _OVERRIDE=3Detc && MAKEOBJDIRPREFIX=3D${TEMPROOT}/usr/obj make ${ARCHSTRING} \ DESTDIR=3D${TEMPROOT} distribution;} || { echo ''; @@ -524,8 +524,8 @@ *) # Only set up files that are crucial to {build|install}world { mkdir -p ${TEMPROOT}/etc && - cp -p ${SOURCEDIR}/master.passwd ${TEMPROOT}/etc && - cp -p ${SOURCEDIR}/group ${TEMPROOT}/etc;} || + cp -p ${SOURCEDIR}/etc/master.passwd ${TEMPROOT}/etc && + cp -p ${SOURCEDIR}/etc/group ${TEMPROOT}/etc;} || { echo ''; echo ' *** FATAL ERROR: Cannot copy files to the temproot environme= nt'; echo ''; @@ -590,7 +590,7 @@ echo '' echo " *** Your umask is currently set to ${USER_UMASK}. By default, = this script" echo " installs all files with the same user, group and modes that" - echo " they are created with by ${SOURCEDIR}/Makefile, compared to" + echo " they are created with by ${SOURCEDIR}/etc/Makefile, compare= d to" echo " a umask of 022. This umask allows world read permission wh= en" echo " the file's default permissions have it." echo '' @@ -840,7 +840,7 @@ fi =20 # Using -size +0 avoids uselessly checking the empty log files created -# by ${SOURCEDIR}/Makefile and the device entries in ./dev, but does +# by ${SOURCEDIR}/etc/Makefile and the device entries in ./dev, but does # check the scripts in ./dev, as we'd like (assuming no devfs of course). # for COMPFILE in `find . -type f -size +0`; do @@ -1095,7 +1095,7 @@ case "${PRE_WORLD}" in '') ;; *) - MAKE_CONF=3D"${SOURCEDIR%etc}share/examples/etc/make.conf" + MAKE_CONF=3D"${SOURCEDIR}/share/examples/etc/make.conf" =20 (echo '' echo '*** Comparing make variables' --8nsIa27JVQLqB7/C-- --LSp5EJdfMPwZcMS1 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFEH6EIqRfpzJluFF4RAsrUAJ9e8TDk7H4KvMTD6hn4BfIsk06JbgCfXbFT Kch5OWoNDbf5QHMfULgKA0I= =h+E4 -----END PGP SIGNATURE----- --LSp5EJdfMPwZcMS1--