source: branches/variant-descs-14482/base/configure.ac @ 40953

Last change on this file since 40953 was 40953, checked in by raimue@…, 12 years ago

Merged revisions 38101-38102,38107,38109,38114-38115,38163,38230,38232,38252,38255,38271,38304,38315-38317,38331-38332,38344,38495-38497,38506,38556-38557,38577,38683-38684,38753,38756,38765,38835,38883,38940-38942,38960-38961,38973,39012,39016-39017,39021,39023,39025,39036,39116,39177,39257,39564,39573,39990,40051-40061,40142,40159,40387,40414,40445,40450,40475-40476,40693,40712,40729,40803,40824,40834,40836,40894,40906,40952 via svnmerge from
https://svn.macports.org/repository/macports/trunk/base

........

r38101 | raimue@… | 2008-07-06 18:41:47 +0200 (Sun, 06 Jul 2008) | 3 lines


doc/Makefile:
gzip man pages on make all

........

r38102 | raimue@… | 2008-07-06 18:43:33 +0200 (Sun, 06 Jul 2008) | 3 lines


doc:
Ignore generated gzipped man pages

........

r38107 | raimue@… | 2008-07-06 20:49:40 +0200 (Sun, 06 Jul 2008) | 3 lines


Makefile.in:
Remove Doxyfile on distclean

........

r38109 | raimue@… | 2008-07-06 22:27:48 +0200 (Sun, 06 Jul 2008) | 5 lines


base:
Add a new setupenv.sh script which can be used to setup the environment for
MacPorts. It will be installed to ${prefix}/share/macports/setupenv.sh and can
be sourced from your profile.

........

r38114 | raimue@… | 2008-07-07 02:38:32 +0200 (Mon, 07 Jul 2008) | 3 lines


base:
Rename setupenv.sh to setupenv.bash to reflect that it is for bash only

........

r38115 | raimue@… | 2008-07-07 03:00:40 +0200 (Mon, 07 Jul 2008) | 3 lines


setupenv.bash.in:
Set svn:keywords=Id and svn:eol-style=native

........

r38163 | jmr@… | 2008-07-10 03:50:57 +0200 (Thu, 10 Jul 2008) | 2 lines


In fetch, gracefully handle failure to spawn ping processes. (#15906)

........

r38230 | raimue@… | 2008-07-13 12:06:54 +0200 (Sun, 13 Jul 2008) | 3 lines


port/port.tcl:
Exit gracefully if an invalid global option was given

........

r38232 | jmr@… | 2008-07-13 12:25:29 +0200 (Sun, 13 Jul 2008) | 2 lines


Mirror sites: add new transact SourceForge mirror

........

r38252 | raimue@… | 2008-07-13 23:40:06 +0200 (Sun, 13 Jul 2008) | 3 lines


doc/port.1:
Document 'port edit --editor'

........

r38255 | raimue@… | 2008-07-14 00:38:40 +0200 (Mon, 14 Jul 2008) | 4 lines


port/port.tcl:
Convert list to string to allow additional parameters,
for example port edit --editor 'vim -y'

........

r38271 | mww@… | 2008-07-14 16:29:47 +0200 (Mon, 14 Jul 2008) | 3 lines


add 'llvm-gcc-4.2' compiler suite (from XCode 3.1);
make a wild guess at default compiler choice for 10.6;

........

r38304 | raimue@… | 2008-07-15 07:33:22 +0200 (Tue, 15 Jul 2008) | 6 lines


port1.0/portconfigure.tcl:
Add a new command 'use_autoreconf'
This can replace instances of 'system' in our Portfiles, especially when a port
runs any combination of aclocal/autoconf/automake/, as autoreconf automatically
figures out what needs to be run.

........

r38315 | ryandesign@… | 2008-07-15 11:38:03 +0200 (Tue, 15 Jul 2008) | 2 lines


portbuild.tcl: simplify port output by no longer showing the build target; closes #15881

........

r38316 | ryandesign@… | 2008-07-15 11:44:14 +0200 (Tue, 15 Jul 2008) | 2 lines


ChangeLog: Note fix for #15881

........

r38317 | jmr@… | 2008-07-15 14:47:07 +0200 (Tue, 15 Jul 2008) | 2 lines


Don't use quotes when setting MACOSX_DEPLOYMENT_TARGET in the env_array, for consistency

........

r38331 | jmr@… | 2008-07-16 07:35:46 +0200 (Wed, 16 Jul 2008) | 2 lines


ChangeLog: distfiles mirror is added to patch_sites too

........

r38332 | jmr@… | 2008-07-16 07:47:24 +0200 (Wed, 16 Jul 2008) | 2 lines


ChangeLog: note the fix for the case-sensitive deactivate bug (#11759)

........

r38344 | raimue@… | 2008-07-16 17:00:40 +0200 (Wed, 16 Jul 2008) | 4 lines


Makefile.in:
Added the install line for setupenv.bash at the wrong place which prevented
install to complete due to a missing directory.

........

r38495 | wsiegrist@… | 2008-07-22 20:09:32 +0200 (Tue, 22 Jul 2008) | 2 lines


Add checks to cleanup exports leftover from failed mprsyncup runs

........

r38496 | wsiegrist@… | 2008-07-22 20:36:55 +0200 (Tue, 22 Jul 2008) | 2 lines


Updating jobs scripts from servers: Use a more appropriate tmp dir

........

r38497 | wsiegrist@… | 2008-07-22 20:40:15 +0200 (Tue, 22 Jul 2008) | 2 lines


Adding scripts used on the servers for mirroring during post-commit and daily

........

r38506 | rhwood@… | 2008-07-23 11:43:14 +0200 (Wed, 23 Jul 2008) | 7 lines


Armahg's patch to macports::ui_init for the GSOC08 frameworks project.


This patch allows users of the Tcl API for MacPorts to define custom ui_*
procedures message handling mechanisms.


Closes #15913, committing per email and IRC conversation.

........

r38556 | ryandesign@… | 2008-07-25 08:58:30 +0200 (Fri, 25 Jul 2008) | 2 lines


portbuild.tcl: allow parallel builds for scons too, not just for make

........

r38557 | ryandesign@… | 2008-07-25 09:06:16 +0200 (Fri, 25 Jul 2008) | 2 lines


ChangeLog: note parallel build support for scons-based ports in r38556

........

r38577 | afb@… | 2008-07-25 11:44:33 +0200 (Fri, 25 Jul 2008) | 2 lines


don't use build.nice for creative build.cmd lines (#16091)

........

r38683 | febeling@… | 2008-07-28 23:21:33 +0200 (Mon, 28 Jul 2008) | 9 lines


Support for ruby19 ports in the ruby port group.


The command ruby.setup accepts an new optional
parameter "implementation", which is ruby18 by
default, and can also be ruby19. (As more ruby
implementations appear these may be added as
well.) Unit tests are in the new sub-directory
tests/.

........

r38684 | febeling@… | 2008-07-28 23:32:47 +0200 (Mon, 28 Jul 2008) | 2 lines


ChangeLog for ruby group change, #15912.

........

r38753 | afb@… | 2008-07-30 09:30:39 +0200 (Wed, 30 Jul 2008) | 2 lines


update changelog for r38577

........

r38756 | afb@… | 2008-07-30 12:13:23 +0200 (Wed, 30 Jul 2008) | 2 lines


unbreak test case when ruby19 is not installed or not running leopard

........

r38765 | toby@… | 2008-07-30 21:59:14 +0200 (Wed, 30 Jul 2008) | 2 lines


fix distclean

........

r38835 | febeling@… | 2008-08-01 10:47:58 +0200 (Fri, 01 Aug 2008) | 2 lines


remove hard-coded mp prefix in test case setup

........

r38883 | wsiegrist@… | 2008-08-02 01:53:41 +0200 (Sat, 02 Aug 2008) | 2 lines


Make the guide chunkier at <http://guide.macports.org/chunked/>

........

r38940 | raimue@… | 2008-08-03 10:05:42 +0200 (Sun, 03 Aug 2008) | 4 lines


pextlib1.0:
Add a wrapper for isatty(3). Add term_get_size to find the size of a connected
terminal for a channel using ioctl(2).

........

r38941 | raimue@… | 2008-08-03 10:10:26 +0200 (Sun, 03 Aug 2008) | 4 lines


port/port.tcl:
Use isatty and term_get_size from pextlib to determine the size of the
connected terminal. This requires the Pextlib package.

........

r38942 | raimue@… | 2008-08-03 10:19:05 +0200 (Sun, 03 Aug 2008) | 3 lines


pextlib1.0/tty.c:
Tabs to spaces

........

r38960 | afb@… | 2008-08-04 11:23:00 +0200 (Mon, 04 Aug 2008) | 2 lines


add use_lzma for .tar.lzma support

........

r38961 | afb@… | 2008-08-04 11:29:00 +0200 (Mon, 04 Aug 2008) | 2 lines


fix typo

........

r38973 | jmr@… | 2008-08-04 18:11:28 +0200 (Mon, 04 Aug 2008) | 2 lines


mirror sites: order sourceforge mirrors more or less geographically

........

r39012 | jmr@… | 2008-08-06 08:56:11 +0200 (Wed, 06 Aug 2008) | 2 lines


Fix invalid DOCTYPE in generated launchd .plists. Thanks to blb for the patch. Closes #16200.

........

r39016 | afb@… | 2008-08-06 09:42:34 +0200 (Wed, 06 Aug 2008) | 2 lines


work around Leopard Tcl bugs (#16010)

........

r39017 | afb@… | 2008-08-06 09:46:08 +0200 (Wed, 06 Aug 2008) | 2 lines


work around Leopard Tcl bugs (#16233)

........

r39021 | afb@… | 2008-08-06 09:53:18 +0200 (Wed, 06 Aug 2008) | 2 lines


update changelog

........

r39023 | ryandesign@… | 2008-08-06 10:00:26 +0200 (Wed, 06 Aug 2008) | 2 lines


ChangeLog: consolidate entries for Leopard environment variable issue

........

r39025 | ryandesign@… | 2008-08-06 10:36:18 +0200 (Wed, 06 Aug 2008) | 2 lines


portlint.tcl, portutil.tcl: undo changes inadvertently committed in r39023

........

r39036 | raimue@… | 2008-08-06 15:56:52 +0200 (Wed, 06 Aug 2008) | 4 lines


port/port.tcl:
In 'port gohome', use homepage variable from PortIndex if available. Otherwise
read it from the Portfile. This way, this command works faster. Closes #16146.

........

r39116 | jmr@… | 2008-08-08 18:12:16 +0200 (Fri, 08 Aug 2008) | 2 lines


Add clean_dep_map proc to registry, for removing duplicate dependency entries. (See #8763)

........

r39177 | simon@… | 2008-08-11 14:22:33 +0200 (Mon, 11 Aug 2008) | 2 lines


base: Typo fix in portfetch.tcl.

........

r39257 | afb@… | 2008-08-14 15:05:43 +0200 (Thu, 14 Aug 2008) | 2 lines


add new primary category: office (#16311)

........

r39564 | ryandesign@… | 2008-08-25 07:06:35 +0200 (Mon, 25 Aug 2008) | 2 lines


gcc-dp-* was renamed to gcc-mp-* quite some time ago

........

r39573 | raimue@… | 2008-08-25 19:18:20 +0200 (Mon, 25 Aug 2008) | 3 lines


port1.0/portconfigure.tcl:
Return an error if an invalid value was given to configure.compiler

........

r39990 | ryandesign@… | 2008-09-16 00:54:08 +0200 (Tue, 16 Sep 2008) | 2 lines


PortIndexRegen.sh: fix typo in comment

........

r40051 | toby@… | 2008-09-19 04:08:13 +0200 (Fri, 19 Sep 2008) | 2 lines


fix warnings

........

r40052 | toby@… | 2008-09-19 04:08:41 +0200 (Fri, 19 Sep 2008) | 2 lines


eliminate some -Wformat-security issues

........

r40053 | toby@… | 2008-09-19 04:12:52 +0200 (Fri, 19 Sep 2008) | 2 lines


another -Wformat-security fix

........

r40054 | toby@… | 2008-09-19 04:22:41 +0200 (Fri, 19 Sep 2008) | 2 lines


fix typecasts

........

r40055 | toby@… | 2008-09-19 04:33:48 +0200 (Fri, 19 Sep 2008) | 3 lines


Prefer -UTF8String over long-deprecated -cString.
Eliminate a format string issue.

........

r40056 | toby@… | 2008-09-19 04:42:46 +0200 (Fri, 19 Sep 2008) | 2 lines


Stop setting MACOSX_DEPLOYMENT_TARGET

........

r40057 | toby@… | 2008-09-19 04:49:56 +0200 (Fri, 19 Sep 2008) | 2 lines


-framework Foundation is meaningless when compiling, don't include in CFLAGS

........

r40058 | toby@… | 2008-09-19 04:53:51 +0200 (Fri, 19 Sep 2008) | 2 lines


another typecast fix

........

r40059 | toby@… | 2008-09-19 05:14:25 +0200 (Fri, 19 Sep 2008) | 2 lines


Somewhat ugly hack to eliminate PACKAGE_* warning spam.

........

r40060 | toby@… | 2008-09-19 05:20:22 +0200 (Fri, 19 Sep 2008) | 2 lines


handle _ in arch name (x86_64)

........

r40061 | toby@… | 2008-09-19 05:26:27 +0200 (Fri, 19 Sep 2008) | 2 lines


more warning fixes

........

r40142 | jmr@… | 2008-09-22 12:43:46 +0200 (Mon, 22 Sep 2008) | 2 lines


Run a script in 'make install' and .dmg postflight which removes any duplicate entries from the dep_map (#8763)

........

r40159 | jmr@… | 2008-09-23 03:12:18 +0200 (Tue, 23 Sep 2008) | 2 lines


Run dep_map_clean.tcl *after* installing, so it works on new installs.

........

r40387 | jmpp@… | 2008-09-30 09:35:42 +0200 (Tue, 30 Sep 2008) | 8 lines



It doesn't really matter as we don't have any Portfiles with non-ascii characters, as far as I've been able to see...
But stil, since we operate fully on utf8 mode when reading the Portfiles, we might as well store them as such in the db.


PS: As far as I'm aware, changes to this script require manual reinstallation, as our Makefiles don't install it by default.
PSS: Once reinstalled and the new, fully utf8 tables have been created, a "mysql_set_charset('utf8',$portsdb_connection);"
instruction would be appropriate in the else block of the portsdb_connect() function in trunk/www/includes/common.inc.

........

r40414 | raimue@… | 2008-10-01 04:53:38 +0200 (Wed, 01 Oct 2008) | 4 lines


port/port.tcl:
Quote homepage URL to avoid problems with special shell characters like '&'.
Closes #16491

........

r40445 | febeling@… | 2008-10-02 10:02:08 +0200 (Thu, 02 Oct 2008) | 2 lines


portlint.tcl: add erlang primary category

........

r40450 | macsforever2000@… | 2008-10-02 15:13:44 +0200 (Thu, 02 Oct 2008) | 2 lines


Added finance and gis as primary categories.

........

r40475 | toby@… | 2008-10-02 23:11:13 +0200 (Thu, 02 Oct 2008) | 2 lines


s/Keven/Kevin/

........

r40476 | toby@… | 2008-10-02 23:12:32 +0200 (Thu, 02 Oct 2008) | 3 lines


Include stdint.h to correctly get intptr_t.
Fixes #16718

........

r40693 | raimue@… | 2008-10-11 01:35:39 +0200 (Sat, 11 Oct 2008) | 4 lines


port/port.tcl:
Fix 'port cat'; A newline was always appended on the end of the file and there
was a problem with files larger than 4096 bytes. Closes #16817

........

r40712 | raimue@… | 2008-10-12 04:53:54 +0200 (Sun, 12 Oct 2008) | 4 lines


base:
Inheritance of macports.conf, patch by Adam Byrtek
Closes #16329

........

r40729 | jmr@… | 2008-10-13 01:37:22 +0200 (Mon, 13 Oct 2008) | 2 lines


Make 'port deps' show the correct dependencies when variants are given. (#11891)

........

r40803 | jmr@… | 2008-10-15 12:17:48 +0200 (Wed, 15 Oct 2008) | 2 lines


Move default frameworks_dir under prefix, and use it in portgroups

........

r40824 | nox@… | 2008-10-15 18:35:54 +0200 (Wed, 15 Oct 2008) | 2 lines


Fixed a bug introduced in r40803, variables were not imported in the proc scope.

........

r40834 | jmr@… | 2008-10-16 01:25:40 +0200 (Thu, 16 Oct 2008) | 2 lines


Fix _libtest breakage introduced in r40803 (#16877)

........

r40836 | toby@… | 2008-10-16 03:32:21 +0200 (Thu, 16 Oct 2008) | 2 lines


support platform releases with multiple versions, because nine plus one is ten

........

r40894 | simon@… | 2008-10-17 15:33:45 +0200 (Fri, 17 Oct 2008) | 2 lines


base: Add support to fetch using Mercurial.

........

r40906 | ryandesign@… | 2008-10-18 01:18:28 +0200 (Sat, 18 Oct 2008) | 2 lines


mirror_sites.tcl: remove stale ftp.uu.net mirror; see http://lists.macosforge.org/pipermail/macports-dev/2008-October/006191.html

........

r40952 | blb@… | 2008-10-19 01:37:46 +0200 (Sun, 19 Oct 2008) | 2 lines


Fix unarchive using xar, #16806

........

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 12.1 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2dnl $Id: configure.ac 40953 2008-10-19 00:26:55Z raimue@macports.org $
3AC_PREREQ(2.52)
4AC_DEFUN([MACPORTS_VERSION_MACRO], [esyscmd(cat config/macports_version | tr -d '\n')])
5AC_INIT([MacPorts], [MACPORTS_VERSION_MACRO], [macports-dev@lists.macosforge.org], [macports])
6AC_CONFIG_SRCDIR([src/pextlib1.0/Pextlib.c])
7AC_CONFIG_HEADERS([src/config.h])
8AC_CANONICAL_SYSTEM
9
10# Read in the MacPorts version from the base/config/macports_vesion file
11AC_MSG_CHECKING(MacPorts version)
12MACPORTS_VERSION=MACPORTS_VERSION_MACRO
13AC_MSG_RESULT([$MACPORTS_VERSION])
14AC_SUBST(MACPORTS_VERSION)
15# Read the old, floating point format version, which we still use internally, and export it for the $macports::autoconf::macports_version variable
16MP_VERSION=$(cat config/mp_version | tr -d '\n')
17AC_SUBST(MP_VERSION)
18
19# Check user PATH for MP paths, and remove as necessary.
20MP_PATH_SCAN
21
22AC_CHECK_PROGS(SW_VERS, sw_vers)
23if test "x$SW_VERS" != "x"; then
24  AC_MSG_CHECKING(Mac OS X version)
25  MACOSX_VERSION=`$SW_VERS | sed -n "s/^ProductVersion:[[[:space:]]]//p" | cut -f 1-3 -d.`
26  AC_MSG_RESULT([$MACOSX_VERSION])
27fi
28
29case "$MACOSX_VERSION" in
30  10.0*|10.1*|10.2*)
31    AC_WARN(This version of Mac OS X is not supported)
32    AC_WARN(Please upgrade at http://store.apple.com/)
33    ;;
34  10.1.[[0-4]]|10.2.[[0-7]]|10.3.[[0-8]]|10.4.[[0-8]])
35    AC_WARN(This version of Mac OS X is out of date)
36    AC_WARN(Please run Software Update to update it)
37    ;;
38  10.3*|10.4*|10.5*)
39    dnl Supported version
40    ;;
41  *)
42    ;;
43esac
44
45XCODEPLIST=/Developer/Applications/Xcode.app/Contents/version.plist
46if test -r "$XCODEPLIST"; then
47  AC_MSG_CHECKING(Xcode version)
48  XCODE_VERSION=`tr -d '\r\n' < $XCODEPLIST | sed -e 's/.*<key>CFBundleShortVersionString<\/key>.<string>\([[0-9.]]*\)<\/string>.*/\1/'`
49  AC_MSG_RESULT([$XCODE_VERSION])
50fi
51
52case "$XCODE_VERSION" in
53  1.[[0-1]]*|2.[[0-1]]*)
54    AC_WARN(This version of Xcode Tools is not supported)
55    AC_WARN(Please upgrade at http://connect.apple.com/)
56    ;;
57  1.[[2-4]]*|2.[[2-3]]*)
58    AC_WARN(This version of Xcode Tools is out of date)
59    AC_WARN(Please consider upgrading as some ports fail compiling)
60    ;;
61  1.5*|2.4*|3.*)
62    dnl Supported version
63    ;;
64  *)
65    ;;
66esac
67
68# Checks for programs.
69AC_PROG_CC
70AC_PROG_OBJC
71AC_PROG_INSTALL
72AC_PROG_MAKE_SET
73AC_PROG_LN_S
74AC_PATH_PROG(MTREE, [mtree], [], [$PATH:/usr/sbin])
75AC_PATH_PROG(CVS, [cvs], [])
76AC_PATH_PROG(SVN, [svn], [])
77AC_PATH_PROG(GIT, [git], [])
78AC_PATH_PROG(RSYNC, [rsync], [])
79AC_PATH_PROG(SED, [sed])
80AC_PATH_PROG(TAR, [tar])
81AC_PATH_PROG(MAKE, [make])
82AC_CHECK_PROG(HAVE_LAUNCHD, [launchd], [yes], [])
83AC_PATH_PROG(LAUNCHCTL, [launchctl], [])
84AC_PATH_PROG(XCODEBUILD, [xcodebuild], [])
85AC_PATH_PROGS(GNUTAR, [gnutar gtar], [], [$PATH:/usr/local/bin])
86AC_PATH_PROGS(GNUMAKE, [gnumake gmake], [], [$PATH:/usr/local/bin])
87AC_PATH_PROG(BZIP2, [bzip2], [])
88AC_PATH_PROG(XAR, [xar], [])
89AC_PATH_PROG(OPEN, [open], [])
90
91# Define some precious variables allowing user to override PATH for some programs
92AC_ARG_VAR(MTREE, [path to mtree command])
93AC_ARG_VAR(CVS, [path to cvs command])
94AC_ARG_VAR(SVN, [path to svn command])
95AC_ARG_VAR(RSYNC, [path to rsync command])
96AC_ARG_VAR(SED, [path to sed command])
97AC_ARG_VAR(TAR, [path to tar command])
98AC_ARG_VAR(MAKE, [path to make command])
99AC_ARG_VAR(GNUTAR, [path to gnutar command])
100AC_ARG_VAR(GNUMAKE, [path to gnumake command])
101AC_ARG_VAR(BZIP2, [path to bzip2 command])
102AC_ARG_VAR(XAR, [path to xar command])
103AC_ARG_VAR(OPEN, [path to open command])
104
105MP_SED_EXTENDED_REGEXP
106MP_TAR_NO_SAME_OWNER
107
108# Quiche eaters options.
109if test x$GCC = xyes; then
110        CFLAGS_QUICHEEATERS='-W -Wall -pedantic'
111fi
112AC_SUBST(CFLAGS_QUICHEEATERS)
113MP_WERROR
114
115MP_COMPILER_ATTRIBUTE_UNUSED
116MP_COMPILER_ATTRIBUTE_LF_PRIVATE
117
118# Foundation checks
119ACX_PTHREAD
120MP_OBJC_RUNTIME
121MP_OBJC_FOUNDATION
122
123MP_PROG_DAEMONDO
124#MP_PROG_XAR
125
126AC_SUBST(REPLACEMENT_PROGS)
127AC_SUBST(EXTRA_PROGS)
128
129# set default ports-directory
130PORTS_DIR_DEFAULT=`pwd | sed -e "s/base/ports/"`
131
132# Check for paths
133AC_PREFIX_DEFAULT(/opt/local)
134MP_PATH_PORTSDIR([$PORTS_DIR_DEFAULT])
135MP_PATH_MPCONFIGDIR
136
137# Check for install ownership
138MP_CHECK_INSTALLUSER
139MP_CHECK_INSTALLGROUP
140MP_DIRECTORY_MODE
141
142# Check for default directories
143MP_PATH_APPLICATIONS
144MP_PATH_FRAMEWORKS
145
146# Check for universal options
147MP_UNIVERSAL_OPTIONS
148
149# Check for standard header files.
150AC_HEADER_STDC
151AC_HEADER_DIRENT
152AC_HEADER_SYS_WAIT
153AC_HEADER_STAT
154AC_CHECK_HEADERS([limits.h paths.h sys/file.h crt_externs.h fcntl.h sys/fcntl.h sys/cdefs.h err.h libgen.h sys/socket.h \
155        readline/readline.h readline/history.h pwd.h sys/paths.h utime.h])
156
157INCLUDES="-I.. -I. $INCLUDES"
158
159# Checks for library functions.
160AC_FUNC_CLOSEDIR_VOID
161AC_FUNC_FORK
162AC_FUNC_STRERROR_R
163AC_CHECK_FUNCS([bzero memset dup2 regcomp strdup strerror strtol fgetln lockf flock setmode strcasecmp strncasecmp strlcpy copyfile])
164MP_CHECK_READLINK_IS_P1003_1A
165
166AC_ARG_WITH(x11-prefix, [AC_HELP_STRING([--with-x11-prefix=PREFIX], [use PREFIX as the X11 base dir (default autodetect)])], [ x11prefix="$withval" ] )
167case "$x11prefix" in
168  "")
169    # default to traditional value
170    x11prefix=/usr/X11R6
171    ;;
172  *)
173    x_includes=$x11prefix/include
174    x_libraries=$x11prefix/lib
175    ;;
176esac
177
178# Check for md5 implementation
179MP_LIB_MD5
180# Check for X11 and paraphernalia
181MP_CHECK_X11
182
183AC_MSG_CHECKING(for X11 prefix)
184X_INCLUDES_PREFIX=`echo "$x_includes" | sed "s,/include,,"`
185X_LIBRARIES_PREFIX=`echo "$x_libraries" | sed "s,/lib,,"`
186if test "x$have_x" = "xyes" -a "x$X_INCLUDES_PREFIX" = "x$X_LIBRARIES_PREFIX" -a "x$X_LIBRARIES_PREFIX" != x; then
187    x11prefix=$X_LIBRARIES_PREFIX
188fi
189AC_MSG_RESULT([$x11prefix])
190AC_SUBST(x11prefix)
191
192# Check for readline
193AC_ARG_ENABLE(readline, AC_HELP_STRING([--enable-readline], [Enable addition of readline support, if readline present.]),
194[
195        AC_CHECK_LIB([readline], [readline], [
196                                  READLINE_LIBS=-lreadline
197                                  AC_DEFINE([HAVE_LIBREADLINE], [1], [Define to 1 if you have the `readline' library (-lreadline).])
198                                  ])
199        AC_CHECK_DECLS([rl_username_completion_function,rl_filename_completion_function,rl_completion_matches,username_completion_function,filename_completion_function,completion_matches], [], [],
200        [
201        #include <stdio.h>
202        #if HAVE_READLINE_READLINE_H
203        # include <readline/readline.h>
204        #endif
205        ])
206])
207AC_SUBST(READLINE_LIBS)
208
209# Lowest non-system-reserved uid and gid (Apple claims <500)
210AC_DEFINE([MIN_USABLE_UID], [500], [Lowest non-system-reserved UID.])
211AC_DEFINE([MIN_USABLE_GID], [500], [Lowest non-system-reserved GID.])
212
213# Load tclConfig.sh
214SC_PATH_TCLCONFIG
215SC_LOAD_TCLCONFIG
216
217# Check for Tcl public headers
218dnl XXX  hardwire CYGPATH (CYGPATH must be set for SC_PUBLIC_TCL_HEADERS)
219CYGPATH=echo
220SC_PUBLIC_TCL_HEADERS
221
222# Check for tclsh binary
223MP_PROG_TCLSH
224
225# Check for Tcl package path
226MP_TCL_PACKAGE_DIR
227
228# Check if thread is enabled.
229MP_TCL_THREAD_SUPPORT
230
231## libcurl
232MP_LIBCURL_FLAGS
233
234# Do we have curl_easy_strerror?
235AH_TEMPLATE([HAVE_CURL_EASY_STRERROR],
236               [Define to 1 if you have the curl_easy_strerror function.])
237AC_CHECK_LIB([curl], [curl_easy_strerror],
238        [AC_DEFINE([HAVE_CURL_EASY_STRERROR])],[],
239        [$LDFLAGS_LIBCURL])
240
241# Determine if we need to install some bundled packages
242OUR_INCLUDED_PACKAGES=
243
244## Thread package.
245AC_ARG_WITH(
246                included-tclthread,
247                AS_HELP_STRING([--with-included-tclthread],
248                        [install included Thread package.]),
249                [with_included_tclthread=$withval],
250                [with_included_tclthread="unspecified"])
251
252# Check if thread package is already installed.
253if test "x$with_included_tclthread" = "xunspecified" ; then
254        MP_TCL_PACKAGE(
255                [Thread],
256                [AC_MSG_RESULT([yes]); with_included_tclthread=no],
257                [AC_MSG_RESULT([no]); with_included_tclthread=yes])
258fi
259
260# If thread package isn't installed, configure and install thread package.
261if test "$with_included_tclthread" = "yes"; then
262        OUR_INCLUDED_PACKAGES="$OUR_INCLUDED_PACKAGES thread2.6"
263        AC_CONFIG_SUBDIRS([src/thread2.6])
264        # Extract thread package
265        (cd src/; gzip -d < thread2.6.tar.gz | tar xf -)
266        # Patch thread package (so thread2.6 is the vanilla distribution directory)
267        patch -p0 < src/thread2.6.diff
268fi
269
270## sqlite3 package.
271AC_ARG_WITH(
272                included-sqlite3,
273                AS_HELP_STRING([--with-included-sqlite3],
274                        [build using bundled sqlite3 package]),
275                [with_included_sqlite3=$withval],
276                [with_included_sqlite3="unspecified"])
277
278# Check if sqlite3 package is already installed.
279if test "x$with_included_sqlite3" = "xunspecified" ; then
280        AC_CHECK_LIB([sqlite3],[sqlite3_open],
281                [with_included_sqlite3=no],
282                [with_included_sqlite3=yes])
283fi
284
285AC_ARG_WITH(
286                tcl-sqlite3,
287                AS_HELP_STRING([--with-tcl-sqlite3=DIR],
288                        [directory for Tcl sqlite3 (default /usr/lib/sqlite3)]),
289                [mp_sqlite3_dir=$withval],
290                [mp_sqlite3_dir=/usr/lib/sqlite3])
291
292# If sqlite3 package isn't installed, configure and install sqlite3 package.
293if test "$with_included_sqlite3" = "yes"; then
294        OUR_INCLUDED_PACKAGES="$OUR_INCLUDED_PACKAGES sqlite-3.1.3"
295        INCLUDES="$INCLUDES -I../sqlite-3.1.3"
296        AC_CONFIG_SUBDIRS([src/sqlite-3.1.3])
297        # Extract sqlite3 package
298        (cd src/; gzip -d < sqlite-3.1.3.tar.gz | tar xf -)
299        # patch sqlite3 with desired configure options
300        patch -p0 < src/sqlite-3.1.3.diff
301        # the new tclinstaller.tcl needs to have substitution occur
302        mv src/sqlite-3.1.3/tclinstaller.tcl src/sqlite-3.1.3/tclinstaller.tcl.in
303        SQLITE3_LIBS=`pwd`"/src/sqlite-3.1.3/.libs/libsqlite3.a"
304        if test "x$prefix" = "xNONE" ; then
305                SQLITE3_DIR=$ac_default_prefix/share/macports/Tcl/sqlite3
306        else
307                SQLITE3_DIR=$prefix/share/macports/Tcl/sqlite3
308        fi
309else
310        SQLITE3_LIBS="-lsqlite3"
311
312        AC_CACHE_CHECK([for Tcl sqlite3 location], [mp_cv_sqlite3_dir],
313                [mp_cv_sqlite3_dir=
314                test -r "${mp_sqlite3_dir}/pkgIndex.tcl" && mp_cv_sqlite3_dir=$mp_sqlite3_dir
315                ])
316
317        SQLITE3_DIR=$mp_cv_sqlite3_dir
318fi
319
320AC_SUBST(SQLITE3_LIBS)
321AC_SUBST(SQLITE3_DIR)
322
323AH_TEMPLATE([TRACE_SDK], [SDK for SDK redirect in tracelib])
324AC_ARG_WITH(
325        trace-sdk,
326        AS_HELP_STRING([--with-trace-sdk=SDK],
327                [SDK for redirection in trace lib (for example MacOSX10.4u.sdk)]),
328        [test -d /Developer/SDKs/$withval && AC_DEFINE_UNQUOTED([TRACE_SDK], "${withval}")], [])
329       
330       
331# If /etc/paths.d and /etc/manpaths.d then we can install our path configuration
332# (this code is currently disabled since this mechanism implies that MacPorts paths are
333# added after the system's paths, and so MacPorts commands would not override system functions).
334AC_MSG_CHECKING(whether to install MacPorts paths into /etc/paths.d and /etc/manpaths.d)
335mpprefix=$prefix
336test "x$mpprefix" = "xNONE" && mpprefix=$ac_default_prefix
337if false && test -d /etc/paths.d -a -d /etc/manpaths.d -a "$mpprefix" = "$ac_default_prefix"; then
338        PATHCONF=pathconf
339        AC_CONFIG_FILES([src/pathconf/Makefile src/pathconf/paths src/pathconf/manpaths])
340        AC_MSG_RESULT([yes])
341else
342        AC_MSG_RESULT([no])
343fi
344
345
346# Allows building of shared libraries
347SC_ENABLE_SHARED
348
349# Pull compiler / linker values from tclConfig.sh
350CFLAGS_DEBUG=${TCL_CFLAGS_DEBUG}
351CFLAGS_OPTIMIZE=${TCL_CFLAGS_OPTIMIZE}
352LDFLAGS_DEBUG=${TCL_LDFLAGS_DEBUG}
353LDFLAGS_OPTIMIZE=${TCL_LDFLAGS_OPTIMIZE}
354SHLIB_LD=${TCL_SHLIB_LD}
355STLIB_LD=${TCL_STLIB_LD}
356SHLIB_CFLAGS=${TCL_SHLIB_CFLAGS}
357SHLIB_SUFFIX=${TCL_SHLIB_SUFFIX}
358
359AC_SUBST(INCLUDES)
360AC_SUBST(CFLAGS_DEBUG)
361AC_SUBST(CFLAGS_OPTIMIZE)
362AC_SUBST(PATHCONF)
363AC_SUBST(STLIB_LD)
364AC_SUBST(SHLIB_LD)
365AC_SUBST(SHLIB_CFLAGS)
366AC_SUBST(SHLIB_LDFLAGS)
367AC_SUBST(SHLIB_SUFFIX)
368AC_SUBST(TCL_DEFS)
369AC_SUBST(TCL_STUB_LIB_SPEC)
370AC_SUBST(TCL_CC)
371AC_SUBST(OUR_INCLUDED_PACKAGES)
372
373# misc variables that need to be expanded for substitution into tcl
374
375oldprefix=$prefix
376if test "x$prefix" = "xNONE" ; then
377   prefix=$ac_default_prefix
378fi
379
380eval "prefix_expanded=$prefix"
381AC_SUBST(prefix_expanded)
382# do this twice, since there is a nested variable of
383# ${prefix} inside of ${sysconfdir}
384eval "MPCONFIGDIR_EXPANDED=$MPCONFIGDIR"
385eval "MPCONFIGDIR_EXPANDED=$MPCONFIGDIR_EXPANDED"
386AC_SUBST(MPCONFIGDIR_EXPANDED)
387eval "localstatedir_expanded=$localstatedir"
388AC_SUBST(localstatedir_expanded)
389
390prefix=$oldprefix
391
392dnl man page settings (compressed, links, etc)
393dnl
394dnl SC_CONFIG_MANPAGES
395
396# Output
397AC_CONFIG_FILES([
398        Doxyfile
399        Makefile
400        Mk/macports.autoconf.mk
401        doc/prefix.mtree
402        doc/macosx.mtree
403        doc/macports.conf
404        portmgr/freebsd/Makefile
405        portmgr/fedora/macports.spec
406        src/Makefile
407        src/macports1.0/macports_autoconf.tcl
408        src/tclobjc1.0/Makefile
409        src/port1.0/port_autoconf.tcl
410        src/registry1.0/registry_autoconf.tcl
411        src/programs/Makefile
412        src/macports1.0/macports_fastload.tcl
413        setupenv.bash
414])
415
416AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.