config.guess (was: Re: cvs commit: ports/audio/libmikmod/files patch-config.sub)

Christian Weisgerber naddy at mips.inka.de
Fri Jun 20 17:31:33 PDT 2003


Kris Kennaway <kris at obsecurity.org> wrote:

> OK, I misunderstood the purpose of config.guess.  This sounds like the
> right approach!

Fetch config.{guess,sub} from ftp://ftp.gnu.org/gnu/config/ and add
them to /usr/ports/Templates/.  These still need editing for ia64
and amd64.

Index: bsd.port.mk
===================================================================
RCS file: /cvs/ports/Mk/bsd.port.mk,v
retrieving revision 1.453
diff -u -r1.453 bsd.port.mk
--- bsd.port.mk	10 Jun 2003 14:45:02 -0000	1.453
+++ bsd.port.mk	20 Jun 2003 23:50:27 -0000
@@ -620,6 +620,9 @@
 #				  ${HAS_CONFIGURE} is set.
 # CONFIGURE_LOG - The name of configure log file (default: config.log).
 #				  It will be printed to the screen if configure fails.
+# CONFIG_GUESS_DIRS - If GNU_CONFIGURE is set and a port uses config.guess
+#				  outside CONFIGURE_WRKSRC, the directories containing
+#				  the other copies must be set here.
 #
 # For build and install:
 #
@@ -2128,6 +2131,7 @@
 CONFIGURE_LOG?=		config.log
 
 .if defined(GNU_CONFIGURE)
+CONFIG_GUESS_DIRS?=	${CONFIGURE_WRKSRC}
 CONFIGURE_ARGS+=	--prefix=${PREFIX} ${CONFIGURE_TARGET}
 HAS_CONFIGURE=		yes
 .endif
@@ -2737,6 +2741,12 @@
 		cd ${.CURDIR} && ${SETENV} ${SCRIPTS_ENV} ${SH} \
 		  ${SCRIPTDIR}/configure; \
 	fi
+.if defined(GNU_CONFIGURE)
+.	for _D in ${CONFIG_GUESS_DIRS}
+	@cp -f ${TEMPLATES}/config.guess ${_D}; chmod a+rx ${_D}/config.guess; \
+	    cp -f ${TEMPLATES}/config.sub ${_D}; chmod a+rx ${_D}/config.sub
+.	endfor
+.endif
 .if defined(HAS_CONFIGURE)
 	@(cd ${CONFIGURE_WRKSRC} && \
 		if ! ${SETENV} CC="${CC}" CXX="${CXX}" \
-- 
Christian "naddy" Weisgerber                          naddy at mips.inka.de



More information about the freebsd-ports mailing list