source: configure.in @ 7d4fbcd

barnowl_perlaimdebianowlrelease-1.10release-1.4release-1.5release-1.6release-1.7release-1.8release-1.9
Last change on this file since 7d4fbcd was 7d4fbcd, checked in by James M. Kretchmar <kretch@mit.edu>, 22 years ago
Initial check in
  • Property mode set to 100644
File size: 2.8 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2AC_INIT(owl.c)
3
4AC_CONFIG_HEADER(config.h)
5
6AC_PROG_CC
7
8dnl If we're using GCC, enable all warnings
9if test "$GCC" = yes; then
10     CFLAGS="$CFLAGS -Wall -g";
11fi
12
13dnl Check for Athena
14AC_MSG_CHECKING(for /usr/athena/include)
15if test -d /usr/athena/include; then
16        CFLAGS=${CFLAGS}\ -I/usr/athena/include
17        AC_MSG_RESULT(yes)
18else
19        AC_MSG_RESULT(no)
20fi
21AC_MSG_CHECKING(for /usr/athena/lib)
22if test -d /usr/athena/lib; then
23        LDFLAGS=-L/usr/athena/lib\ ${LDFLAGS}
24        AC_MSG_RESULT(yes)
25else
26        AC_MSG_RESULT(no)
27fi
28
29dnl A hack for myself to use gnu curses
30dnl AC_MSG_CHECKING(for mit gnu hack)
31dnl if test -d /mit/gnu/include; then
32dnl     CFLAGS=${CFLAGS}\ -I/mit/gnu/include
33dnl     AC_MSG_RESULT(yes)
34dnl else
35dnl     AC_MSG_RESULT(no)
36dnl fi
37
38
39dnl Solaris ships with a broken curses.h
40dnl AC_MSG_CHECKING(for solaris broken curses.h)
41dnl if grep "Sun Microsystems" /usr/include/curses.h > /dev/null 2> /dev/null; then
42dnl   if test  "`grep -c getwc\(stdin\) /usr/include/widec.h`" = "2" ; then
43dnl     rm -rf includefix
44dnl     mkdir includefix
45dnl     sed -e 's/<widec.h>/\"widec.h\"/' /usr/include/curses.h > ./includefix/curses.h
46dnl 
47dnl     sed -e 's/<wchar.h>/\"wchar.h\"/' \
48dnl         -e 's/^#define.putwchar.*//' \
49dnl         -e 's/^#define.getwchar().*//' \
50dnl         -e 's/^#define.getwc(p).*//' \
51dnl         -e 's/^#define.putwc(x, p).*//' \
52dnl         /usr/include/widec.h > includefix/widec.h
53dnl     CFLAGS=-I./includefix\ ${CFLAGS}
54dnl     AC_MSG_RESULT(yes)
55dnl   fi
56dnl else
57dnl   AC_MSG_RESULT(no)
58dnl fi
59
60
61
62AC_CHECK_LIB(ncurses, initscr,,
63   AC_CHECK_LIB(curses, initscr,, AC_MSG_ERROR(No curses library found.)))
64AC_CHECK_LIB(com_err, com_err)
65AC_CHECK_LIB(nsl, gethostbyname)
66AC_CHECK_LIB(socket, socket)
67AC_CHECK_LIB(k5crypto, krb5_derive_key)
68AC_CHECK_LIB(des425, des425_req_act_vno)
69AC_CHECK_LIB(krb5, krb5_get_credentials)
70AC_CHECK_LIB(krb4, krb_sendauth)
71AC_CHECK_LIB(zephyr, ZGetSender,, AC_MSG_ERROR(No zephyr library found.))
72AC_CHECK_LIB(zephyr, ZInitLocationInfo, AC_DEFINE(HAVE_LIBZEPHYR_ZINITLOCATIONINFO),)
73
74dnl Checks for header files.
75AC_HEADER_STDC
76AC_HEADER_SYS_WAIT
77AC_CHECK_HEADERS(strings.h sys/ioctl.h unistd.h)
78
79dnl Add CFLAGS for embeded perl
80FOO=`perl -MExtUtils::Embed -e ccopts`
81echo Adding perl CFLAGS ${FOO}
82CFLAGS=${CFLAGS}\ ${FOO}
83
84dnl Add LDFLAGS for embeded perl
85FOO=`perl -MExtUtils::Embed -e ldopts`
86echo Adding perl LDFLAGS ${FOO}
87LDFLAGS=${LDFLAGS}\ ${FOO}
88
89dnl Checks for typedefs, structures, and compiler characteristics.
90AC_CHECK_FILE(/usr/share/terminfo, AC_DEFINE(TERMINFO, "/usr/share/terminfo"),
91  AC_CHECK_FILE(/usr/share/lib/terminfo, AC_DEFINE(TERMINFO, "/usr/share/lib/terminfo"),
92  AC_MSG_ERROR(No terminfo found for this system)))
93
94dnl Checks for library functions.
95dnl AC_PROG_GCC_TRADITIONAL
96dnl AC_CHECK_FUNCS(gethostname strdup)
97
98AC_OUTPUT(Makefile)
Note: See TracBrowser for help on using the repository browser.