RE: howto identify os

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: autoconf-bounces+guus-leeuw=gmx.de@xxxxxxx [mailto:autoconf-
> bounces+guus-leeuw=gmx.de@xxxxxxx] On Behalf Of Francesco Zappa Nardelli
> Sent: lundi 24 janvier 2005 20:54
> 
> I am looking for a way to tell configure that the makefile it
> eventually generates should include the file "linux.mak" if we are
> building the software on Linux, and "macosx.mak" if we are building on
> Darwin.

configure.in:
...
case $host_os in
	linux*)
		PACKAGE_extra_makefile_include="linux.mak"
		;;
	Darwin*)
		PACKAGE_extra_makefile_include="macosx.mak"
		;;
	*)
		PACKAGE_extra_makefile_include=""
		;;
esac
AC_SUBST(PACKAGE_extra_makefile_include)
...

Makefile.am:
...
include @PACKAGE_extra_makefile_include@
...

*But*:
Depending on what you want the extra .mak file to do, it is probably better
to have configure figure this OS dependent stuff out by itself and have the
Makefile.am written accordingly.

Guus


-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.7.2 - Release Date: 21/01/2005
 



-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.7.2 - Release Date: 21/01/2005



_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf

[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux