/[gentoo-alt]/trunk/toolchain-prefix-wrapper/configure.ac
Gentoo

Contents of /trunk/toolchain-prefix-wrapper/configure.ac

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1643 - (show annotations) (download)
Sat Mar 21 14:09:47 2009 UTC (5 years, 5 months ago) by grobian
File size: 2602 byte(s)
auto guess macosx-version-min value, as it's not worth dying for
1 # Copyright 2007-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # Author: Michael Haubenwallner <haubi@gentoo.org>
4
5 AC_INIT(toolchain-prefix-wrapper,0.3.svnversion)
6 AC_CONFIG_AUX_DIR([build-aux])
7 AC_PROG_INSTALL
8 AC_CONFIG_SRCDIR(ld/ldwrapper.c)
9 AC_PREREQ(2.52)
10 AC_CANONICAL_HOST
11 AM_INIT_AUTOMAKE
12 AC_CONFIG_HEADERS(config.h)
13 AC_CONFIG_FILES(utils/Makefile ld/Makefile ld/create-ldwrapper Makefile)
14
15 AC_PROG_CC
16
17 AC_PROG_RANLIB
18
19 AC_DEFINE_UNQUOTED([CHOST], ["${ac_cv_host}"], [host the wrapper is running on])
20
21 AC_MSG_CHECKING([for gentoo portage eprefix])
22 AC_ARG_WITH([gentoo-portage-eprefix],
23 [AC_HELP_STRING(
24 [--with-gentoo-portage-eprefix],
25 [the gentoo portage eprefix, fex '/opt/gentoo' for '/opt/gentoo/usr']
26 )],
27 [GENTOO_PORTAGE_EPREFIX=$withval],
28 [GENTOO_PORTAGE_EPREFIX=yes]
29 )
30 case "x${GENTOO_PORTAGE_EPREFIX}" in
31 xyes)
32 GENTOO_PORTAGE_EPREFIX=$prefix
33 if test "x${GENTOO_PORTAGE_EPREFIX}" = xNONE; then
34 GENTOO_PORTAGE_EPREFIX=
35 else
36 GENTOO_PORTAGE_EPREFIX=`echo "${GENTOO_PORTAGE_EPREFIX}" | sed 's,/usr/*$,,'`
37 fi
38 ;;
39 xno) GENTOO_PORTAGE_EPREFIX= ;;
40 x/*) ;;
41 *) AC_ERROR([need yes, no, or absolute path for --with-gentoo-portage-eprefix])
42 ;;
43 esac
44 case "x${GENTOO_PORTAGE_EPREFIX}" in
45 x*/) GENTOO_PORTAGE_EPREFIX=`echo "${GENTOO_PORTAGE_EPREFIX}" | sed 's,/*$,,'` ;;
46 esac
47 AC_MSG_RESULT(['${GENTOO_PORTAGE_EPREFIX}'])
48 AC_DEFINE_UNQUOTED(
49 [GENTOO_PORTAGE_EPREFIX], ["${GENTOO_PORTAGE_EPREFIX}"],
50 [gentoo portage eprefix]
51 )
52 AC_SUBST(GENTOO_PORTAGE_EPREFIX)
53
54 AC_MSG_CHECKING([for Mac OS X minimum deployment target])
55 AC_ARG_WITH([macosx-version-min],
56 [AC_HELP_STRING(
57 [--with-macosx-version-min],
58 [the minimum deployment target on Mac OS X, such as 10.4]
59 )],
60 [MIN_OSX_TARGET=$withval],
61 [MIN_OSX_TARGET=auto]
62 )
63 # We only "support" Panther, Tiger and Leopard
64 case $ac_cv_host in
65 *-darwin*)
66 case "x${MIN_OSX_TARGET}" in
67 x10.[[345]]) ;;
68 xno)
69 AC_ERROR([--with-macosx-version-min must be given on Mac OS X hosts])
70 ;;
71 xauto)
72 # auto guessing
73 case $ac_cv_host in
74 *-darwin7*)
75 MIN_OSX_TARGET=10.3
76 ;;
77 *-darwin8*)
78 MIN_OSX_TARGET=10.4
79 ;;
80 *-darwin9*)
81 MIN_OSX_TARGET=10.5
82 ;;
83 esac
84 ;;
85 *)
86 AC_ERROR([need an explicit Mac OS X version number with --with-macosx-version-min])
87 ;;
88 esac
89 AC_MSG_RESULT(['${MIN_OSX_TARGET}'])
90 ;;
91 *)
92 MIN_OSX_TARGET="you shouldn't use this"
93 AC_MSG_RESULT([irrelevant for $ac_cv_host])
94 ;;
95 esac
96 AC_DEFINE_UNQUOTED(
97 [MIN_OSX_TARGET], ["${MIN_OSX_TARGET}"],
98 [macosx_version_min]
99 )
100 AC_SUBST(MIN_OSX_TARGET)
101
102 AC_OUTPUT

  ViewVC Help
Powered by ViewVC 1.1.20