From owner-freebsd-ports@FreeBSD.ORG Thu Dec 18 18:32:34 2008 Return-Path: Delivered-To: ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C60D31065676 for ; Thu, 18 Dec 2008 18:32:34 +0000 (UTC) (envelope-from jhein@timing.com) Received: from Daffy.timing.com (w.timing.com [206.168.13.218]) by mx1.freebsd.org (Postfix) with ESMTP id 89FE28FC0C for ; Thu, 18 Dec 2008 18:32:34 +0000 (UTC) (envelope-from jhein@timing.com) Received: from gromit.timing.com (gromit.timing.com [206.168.13.209]) by Daffy.timing.com (8.13.1/8.13.1) with ESMTP id mBIIWXZ3057488; Thu, 18 Dec 2008 11:32:33 -0700 (MST) (envelope-from jhein@timing.com) Received: from gromit.timing.com (localhost [127.0.0.1]) by gromit.timing.com (8.14.3/8.14.3) with ESMTP id mBIIEhB9093726; Thu, 18 Dec 2008 11:14:43 -0700 (MST) (envelope-from jhein@gromit.timing.com) Received: (from jhein@localhost) by gromit.timing.com (8.14.3/8.14.3/Submit) id mBIIEhYK093725; Thu, 18 Dec 2008 11:14:43 -0700 (MST) (envelope-from jhein) Date: Thu, 18 Dec 2008 11:14:43 -0700 (MST) Message-Id: <200812181814.mBIIEhYK093725@gromit.timing.com> To: FreeBSD-gnats-submit@freebsd.org From: John Hein X-send-pr-version: 3.113 X-GNATS-Notify: X-Virus-Scanned: ClamAV version 0.91.2, clamav-milter version 0.91.2 on Daffy.timing.com X-Virus-Status: Clean Cc: ports@freebsd.org Subject: [patch] support systems that have been built WITHOUT_INFO=yes (no makeinfo & install-info) X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John Hein List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Dec 2008 18:32:34 -0000 >Submitter-Id: current-users >Originator: John Hein >Organization: >Confidential: no >Synopsis: [patch] support systems that have been built WITHOUT_INFO=yes (no makeinfo & install-info) >Severity: non-critical >Priority: medium >Category: ports >Class: change-request >Release: FreeBSD 7.1-PRERELEASE i386 >Environment: >Description: If world is built with WITHOUT_INFO=yes, then as of 7.x, it does not install install-info and makeinfo, etc. (see the exclusion of the texinfo subdir in gnu/usr.bin/Makefile). But lots of ports and bsd.port.mk expect these tools to be there unconditionally. Worlds without these tools (think building for embedded boxes with nanobsd, for example) break when building these ports. The port I hit first that has this problem is libtool15 which has this... CONFIGURE_ENV= MAKEINFO="makeinfo --no-split" See also at least these PRs for more: ports/121296, ports/121717 >How-To-Repeat: make buildworld WITHOUT_INFO=yes make installworld WITHOUT_INFO=yes (or just manually move away /usr/bin/makeinfo and /usr/bin/install-info) Then cd ports/devel/libtool15 make && make install >Fix: Support WITHOUT_INFO (or detect missing install-info) in ports/Mk. See patch below. Ports can be fixed by keying on HAS_INFO (the preferred method, I think) or changing hard-coded invocations of makeinfo and/or install-info to the MAKEINFO and INSTALLINFO commands as defined below in bsd.commands.mk. Once this fix (or similar) is in place, we can generate a patch for all the ports that have hard-coded references to the *info utilities. Index: bsd.commands.mk =================================================================== RCS file: /base/FreeBSD-CVS/ports/Mk/bsd.commands.mk,v retrieving revision 1.3 diff -u -p -r1.3 bsd.commands.mk --- bsd.commands.mk 14 Apr 2008 16:46:41 -0000 1.3 +++ bsd.commands.mk 18 Dec 2008 17:58:12 -0000 @@ -92,6 +92,18 @@ XARGS?= /usr/bin/xargs XMKMF?= ${LOCALBASE}/bin/xmkmf -a YACC?= /usr/bin/yacc +.if exists(/usr/bin/install-info) && !defined(WITHOUT_INFO) +HAS_INFO= yes +INSTALLINFO?= /usr/bin/install-info +MAKEINFO?= /usr/bin/makeinfo +.else +# Ideally, ports should key on HAS_INFO. In some cases, it +# may make more sense to just have a port use ${MAKEINFO} and +# ${INSTALLINFO} which are defined to a no-op here. +INSTALLINFO?= true +MAKEINFO?= true +.endif + .if exists(/sbin/md5) MD5?= /sbin/md5 .else Index: bsd.port.mk =================================================================== RCS file: /base/FreeBSD-CVS/ports/Mk/bsd.port.mk,v retrieving revision 1.604 diff -u -p -r1.604 bsd.port.mk --- bsd.port.mk 5 Sep 2008 19:41:43 -0000 1.604 +++ bsd.port.mk 18 Dec 2008 17:58:05 -0000 @@ -5672,13 +5672,16 @@ add-plist-data: .if !target(add-plist-info) add-plist-info: # Process GNU INFO files at package install/deinstall time -.if defined(INFO) +.if defined(INFO) && defined(HAS_INFO) .for i in ${INFO} - install-info --quiet ${PREFIX}/${INFO_PATH}/$i.info ${PREFIX}/${INFO_PATH}/dir - @${ECHO_CMD} "@unexec install-info --quiet --delete %D/${INFO_PATH}/$i.info %D/${INFO_PATH}/dir" \ + -ls -alF ${PREFIX}/${INFO_PATH}/$i.info ${PREFIX}/${INFO_PATH}/dir + -cat ${PREFIX}/${INFO_PATH}/dir + ${INSTALLINFO} --quiet ${PREFIX}/${INFO_PATH}/$i.info ${PREFIX}/${INFO_PATH}/dir || \ + { echo "*** ignoring failed ${INSTALLINFO} for possible duplicate entry ***" >&2; true; } + @${ECHO_CMD} "@unexec ${INSTALLINFO} --quiet --delete %D/${INFO_PATH}/$i.info %D/${INFO_PATH}/dir" \ >> ${TMPPLIST} @${LS} ${PREFIX}/${INFO_PATH}/$i.info* | ${SED} -e s:${PREFIX}/::g >> ${TMPPLIST} - @${ECHO_CMD} "@exec install-info --quiet %D/${INFO_PATH}/$i.info %D/${INFO_PATH}/dir" \ + @${ECHO_CMD} "@exec ${INSTALLINFO} --quiet %D/${INFO_PATH}/$i.info %D/${INFO_PATH}/dir" \ >> ${TMPPLIST} .endfor .if defined(INFO_SUBDIR)