source: configure.ac @ 3da3afe

debianrelease-1.10release-1.4release-1.5release-1.6release-1.7release-1.8release-1.9
Last change on this file since 3da3afe was 3da3afe, checked in by Sam Hartman <hartmans@debian.org>, 15 years ago
Remove unneeded dependency on krb5 and krb4 Barnowl links against libkrb4, libk5crypto and libkrb5 and uses symbols from none of the above. Remove these link-time dependencies. This might break static builds but Kerberos no longer provides static libraries. The dependency on libkrb4 is problematic for Debian as libkrb4.so is being removed.
  • Property mode set to 100644
File size: 3.9 KB
RevLine 
[1aee7d9]1dnl $Id$
[7d4fbcd]2dnl Process this file with autoconf to produce a configure script.
3AC_INIT(owl.c)
4
5AC_CONFIG_HEADER(config.h)
6
7AC_PROG_CC
8
9dnl If we're using GCC, enable all warnings
10if test "$GCC" = yes; then
11     CFLAGS="$CFLAGS -Wall -g";
12fi
13
14dnl Check for Athena
15AC_MSG_CHECKING(for /usr/athena/include)
16if test -d /usr/athena/include; then
17        CFLAGS=${CFLAGS}\ -I/usr/athena/include
[e6449bc]18        CPPFLAGS=${CPPFLAGS}\ -I/usr/athena/include
[7d4fbcd]19        AC_MSG_RESULT(yes)
20else
21        AC_MSG_RESULT(no)
22fi
23AC_MSG_CHECKING(for /usr/athena/lib)
24if test -d /usr/athena/lib; then
[1d7e094]25        LDFLAGS=${LDFLAGS}\ -L/usr/athena/lib
[7d4fbcd]26        AC_MSG_RESULT(yes)
27else
28        AC_MSG_RESULT(no)
29fi
30
[fe39450]31dnl Check for kerberosIV include
[18e28a4]32AC_MSG_CHECKING(for kerberosIV)
[fe39450]33if test -d /usr/include/kerberosIV; then
34        CFLAGS=${CFLAGS}\ -I/usr/include/kerberosIV
35        CPPFLAGS=${CPPFLAGS}\ -I/usr/include/kerberosIV
36        AC_MSG_RESULT(yes)
[18e28a4]37elif test -d /usr/local/include/kerberosIV; then
38        CFLAGS=${CFLAGS}\ -I/usr/local/include/kerberosIV
39        CPPFLAGS=${CPPFLAGS}\ -I/usr/local/include/kerberosIV
40        AC_MSG_RESULT(yes)
[fe39450]41else
42        AC_MSG_RESULT(no)
43fi
[87afe92]44PROTECT_CFLAGS=${PROTECT_CFLAGS-"-fstack-protector"}
45SAVE_CFLAGS=$CFLAGS
46CFLAGS="$CFLAGS $PROTECT_CFLAGS"
47AC_MSG_CHECKING(whether protection cflags work)
48AC_COMPILE_IFELSE(int i;,
49    [AC_MSG_RESULT(yes)],
50    [AC_MSG_RESULT(no)
51    CFLAGS=$SAVE_CFLAGS])
[fe39450]52
[87afe92]53
54AC_CHECK_LIB(ssp, __stack_chk_guard)
[d54035d]55AC_CHECK_LIB(ncursesw, initscr,, AC_MSG_ERROR(No libncursesw found.))
[7d4fbcd]56AC_CHECK_LIB(com_err, com_err)
57AC_CHECK_LIB(nsl, gethostbyname)
58AC_CHECK_LIB(socket, socket)
[8298425]59dnl AC_CHECK_LIB(des425, req_act_vno)
60AC_CHECK_LIB(des425, des_cbc_encrypt)
[d09e5a1]61AC_CHECK_LIB(resolv, res_search)
[09489b89]62dnl AC_CHECK_LIB(zephyr, ZGetSender,, AC_MSG_ERROR(No zephyr library found.))
63AC_CHECK_LIB(zephyr, ZGetSender)
[ac70242]64AC_CHECK_LIB(zephyr, ZInitLocationInfo, AC_DEFINE([HAVE_LIBZEPHYR_ZINITLOCATIONINFO], [], [Have ZInitLocationInfo]),)
65
[7ccc780]66AC_ARG_ENABLE([athstatic], AS_HELP_STRING([--enable-athstatic],
67                                          [Statically link libraries in /usr/athena/lib]),
68                                          [ATHSTATIC=./athstatic],
69                                          [ATHSTATIC=])
70
[dc2ad79]71AC_CHECK_FUNCS(use_default_colors resizeterm des_string_to_key des_key_sched des_ecb_encrypt)
[e51b410]72
[ac70242]73AC_MSG_CHECKING(for des_ecb_encrypt prototype)
74AC_TRY_COMPILE([#include <des.h>
75int des_ecb_encrypt(char foo[], char bar[], des_key_schedule baz, int qux);],
76[int foo = des_ecb_encrypt(0,0,0,0);],
77ac_cv_des_ecb_encrypt_proto=no,
78ac_cv_des_ecb_encrypt_proto=yes)
79AC_MSG_RESULT($ac_cv_des_ecb_encrypt_proto)
80if test "$ac_cv_des_ecb_encrypt_proto" = yes; then
81        AC_DEFINE([HAVE_DES_ECB_ENCRYPT_PROTO], [], [have proto for des_ecb_encrypt])
82fi
[7d4fbcd]83
84dnl Checks for header files.
85AC_HEADER_STDC
86AC_HEADER_SYS_WAIT
[e8b95f8]87AC_CHECK_HEADERS(strings.h sys/ioctl.h sys/filio.h unistd.h com_err.h)
[7d4fbcd]88
89dnl Add CFLAGS for embeded perl
90FOO=`perl -MExtUtils::Embed -e ccopts`
91echo Adding perl CFLAGS ${FOO}
92CFLAGS=${CFLAGS}\ ${FOO}
93
[e51b410]94dnl Find the location of perl XSUBPP
[8ee73f8d]95AC_MSG_CHECKING(for the perl xsubpp precompiler)
[6794f72]96XSUBPPDIR="`(perl -MExtUtils::MakeMaker -e 'print ExtUtils::MakeMaker->new({NAME => qw(owl)})->tool_xsubpp;') | grep \^XSUBPPDIR | sed -e 's/XSUBPPDIR = //g;'`"
[8ee73f8d]97if test -n "${XSUBPPDIR}"; then
98   AC_MSG_RESULT(${XSUBPPDIR})
99else
100   AC_MSG_ERROR(not found)
101fi
102
[4ad3480]103if test -f "${XSUBPPDIR}/typemap"; then
104   XSUBPPFLAGS="-typemap ${XSUBPPDIR}/typemap"
105else
106   XSUBPPFLAGS=""
107fi
108
[18e28a4]109dnl Add LDFLAGS for embedded perl
[3f21b8e]110FOO=`perl -MExtUtils::Embed -e ldopts`
[7d4fbcd]111echo Adding perl LDFLAGS ${FOO}
112LDFLAGS=${LDFLAGS}\ ${FOO}
113
[34509d5]114dnl Add CFLAGS and LDFLAGS for glib-2.0
115PKG_CHECK_MODULES(GLIB,glib-2.0)
116
117echo Adding glib-2.0 CFLAGS ${GLIB_CFLAGS}
[d9337637]118CFLAGS="${GLIB_CFLAGS} ${CFLAGS}"
[34509d5]119echo Adding glib-2.0 LDFLAGS ${GLIB_LIBS}
[d9337637]120LDFLAGS="${GLIB_LIBS} ${LDFLAGS}"
[34509d5]121
122
[7d4fbcd]123dnl Checks for typedefs, structures, and compiler characteristics.
124
[15bd5ef]125AC_SUBST(XSUBPPDIR)
[4ad3480]126AC_SUBST(XSUBPPFLAGS)
[7ccc780]127AC_SUBST(ATHSTATIC)
[8ee73f8d]128
[ac70242]129AC_PROG_INSTALL
130
[d09e5a1]131AC_CONFIG_SUBDIRS(libfaim)
132
[7d4fbcd]133AC_OUTPUT(Makefile)
Note: See TracBrowser for help on using the repository browser.