source: trunk/base/configure.ac @ 2818

Last change on this file since 2818 was 2818, checked in by landonf, 16 years ago

Pull in TCL_DEFS from tclConfig.sh, and use for building TEA extensions.

  • Property svn:eol-style set to native
File size: 2.3 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2AC_PREREQ(2.52)
3AC_INIT([OpenDarwin DarwinPorts], [1.0], [darwinports@opendarwin.org], [darwinports])
4AC_CONFIG_SRCDIR([src/pextlib1.0/Pextlib.c])
5AC_CONFIG_HEADERS([src/pextlib1.0/config.h])
6AC_CANONICAL_SYSTEM
7
8# Checks for programs.
9AC_PROG_CC
10AC_PROG_INSTALL
11AC_PROG_MAKE_SET
12
13OD_PROG_MD5
14
15# Check for paths
16AC_PREFIX_DEFAULT(/opt/local)
17OD_PATH_DPORTSDIR([/usr/dports])
18OD_PATH_PORTCONFIGDIR([/etc/ports], [$prefix])
19
20# Check for install ownership
21OD_CHECK_INSTALLUSER
22OD_CHECK_INSTALLGROUP
23
24# Check for standard header files.
25AC_HEADER_STDC
26AC_HEADER_DIRENT
27AC_HEADER_SYS_WAIT
28AC_HEADER_STAT
29AC_CHECK_HEADERS([limits.h paths.h sys/file.h crt_externs.h])
30
31INCLUDES="-I. $INCLUDES"
32
33# Checks for library functions.
34AC_FUNC_CLOSEDIR_VOID
35AC_FUNC_FORK
36AC_FUNC_STRERROR_R
37AC_CHECK_FUNCS([bzero memset dup2 regcomp strdup strerror strtol])
38
39
40# Check for Tcl public headers
41dnl XXX hardwire CYGPATH (CYGPATH must be set for SC_PUBLIC_TCL_HEADERS)
42CYGPATH=echo
43SC_PUBLIC_TCL_HEADERS
44
45# Load tclConfig.sh
46SC_PATH_TCLCONFIG
47SC_LOAD_TCLCONFIG
48
49# Check for Tcl package path
50OD_TCL_PACKAGE_DIR
51
52# Allows building of shared libraries
53SC_ENABLE_SHARED
54
55# Pull compiler / linker values from tclConfig.sh
56CFLAGS_DEBUG=${TCL_CFLAGS_DEBUG}
57CFLAGS_OPTIMIZE=${TCL_CFLAGS_OPTIMIZE}
58LDFLAGS_DEBUG=${TCL_LDFLAGS_DEBUG}
59LDFLAGS_OPTIMIZE=${TCL_LDFLAGS_OPTIMIZE}
60SHLIB_LD=${TCL_SHLIB_LD}
61STLIB_LD=${TCL_STLIB_LD}
62SHLIB_CFLAGS=${TCL_SHLIB_CFLAGS}
63SHLIB_SUFFIX=${TCL_SHLIB_SUFFIX}
64
65AC_SUBST(INCLUDES)
66AC_SUBST(CFLAGS_DEBUG)
67AC_SUBST(CFLAGS_OPTIMIZE)
68AC_SUBST(TCL_DEFS)
69AC_SUBST(STLIB_LD)
70AC_SUBST(SHLIB_LD)
71AC_SUBST(SHLIB_CFLAGS)
72AC_SUBST(SHLIB_LDFLAGS)
73AC_SUBST(SHLIB_SUFFIX)
74AC_SUBST(TCL_STUB_LIB_SPEC)
75
76#misc variables that need to be expanded for substitution into tcl
77
78oldprefix=$prefix
79if test "x$prefix" = "xNONE" ; then
80   prefix=$ac_default_prefix
81fi
82
83eval "prefix_expanded=$prefix"
84AC_SUBST(prefix_expanded)
85eval "PORTCONFIGDIR_EXPANDED=$PORTCONFIGDIR"
86AC_SUBST(PORTCONFIGDIR_EXPANDED)
87eval "localstatedir_expanded=$localstatedir"
88AC_SUBST(localstatedir_expanded)
89
90prefix=$oldprefix
91
92dnl man page settings (compressed, links, etc)
93dnl
94dnl SC_CONFIG_MANPAGES
95
96# Output
97
98AC_CONFIG_FILES([Makefile Mk/dports.autoconf.mk doc/prefix.mtree doc/ports.conf])
99AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.