Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 22 Feb 2001 11:25:58 -0500
From:      "Patrick Bihan-Faou" <patrick@netzuno.com>
To:        <kris@FreeBSD.org>
Cc:        <cvs-all@freebsd.org>
Subject:   Re: cvs commit: src/share/mk Makefile
Message-ID:  <HJEEKLMFLKEOKHOKNPBMIEDBCLAA.patrick@netzuno.com>

next in thread | raw e-mail | index | archive | help


>   * If NO_CPU_CFLAGS is not defined, add relevant gcc compiler
optimization
>     settings by default (e.g. -karch=k6 for CPUTYPE=k6, etc).  Release
>     builders and developers of third-party software need to make sure not
to
>     enable CPU-specific optimization when generating code intended to be
>     portable.  We probably need to move to an /etc/world.conf to allow the
>     optimization stuff to be applied separately to world/kernel and
external
>     compilations, but it's not any worse a problem than it was before.



With that respect, I have implemented a quick patch to "sys.mk" which lets
me specify the location of the "make.conf" file. This is really usefull to
maintain several sets of make flags depending on what I intend to do.

The feature is simply activated by setting the environment variable
"MAKE_CONF" to the path of the file I want to use. I am using this to do
buildworlds for different machines that require different set of options on
one single system.


Anyway, this is really usefull to me, so it might be useful for other people
as well (especially now with the CPU specific stuff). This patch is against
the RELENG_4 version of sys.mk.


Patrick.


root@nitro# more patches/share/mk/sys.mk.patch
--- sys.mk.orig
+++ sys.mk
@@ -236,6 +236,16 @@

 .endif

+.if defined(MAKE_CONF)
+
+.if exists(${MAKE_CONF})
+.include "${MAKE_CONF}"
+.else
+.error Error: alternate make.conf file specified (${MAKE_CONF}) but file is
not available
+.endif
+
+.else
+
 .if exists(/etc/defaults/make.conf)
 .include </etc/defaults/make.conf>
 .endif
@@ -249,5 +259,6 @@
 .include </etc/make.conf.local>
 .endif

+.endif

 .include <bsd.own.mk>


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?HJEEKLMFLKEOKHOKNPBMIEDBCLAA.patrick>