annotate configure.in @ 1:8b1883341c6f

Initial revision
author masneyb
date Mon, 05 Aug 2002 19:46:57 +0000
parents
children 5678b5179c35
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
1 dnl Process this file with autoconf to produce a configure script.
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
2
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
3 AC_INIT(lib/gftp.h)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
4
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
5 AM_CONFIG_HEADER(config.h)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
6 AM_INIT_AUTOMAKE(gftp,2.0.13)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
7
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
8 AC_ARG_ENABLE(gtk20, [ --enable-gtk20 Try and compile with GTK+ 2.0 if available], enable_gtk20=1, enable_gtk20=0)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
9 AC_ARG_ENABLE(gtkport, [ --disable-gtkport Disable compiling the GTK+ port], enable_gtkport=0, enable_gtkport=1)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
10 AC_ARG_ENABLE(textport, [ --disable-textport Disable compiling the text port], enable_textport=0, enable_textport=1)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
11 AC_ARG_ENABLE(dmalloc, [ --enable-dmalloc Enable the dmalloc library], enable_dmalloc=1, enable_dmalloc=0)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
12
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
13 AC_SUBST(PACKAGE)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
14 AC_SUBST(VERSION)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
15 AC_SUBST(PREFIX)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
16
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
17 ALL_LINGUAS="bg cs da de es fi fr it ja ko nl no pl pt_BR ru sv tr zh_CN.GB2312 zh_TW.Big5"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
18
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
19 AC_CANONICAL_HOST
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
20
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
21 AC_PROG_AWK
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
22 AC_PROG_CC
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
23 AC_PROG_INSTALL
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
24 AC_PROG_LN_S
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
25 AC_PROG_RANLIB
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
26 AC_PROG_MAKE_SET
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
27 AC_ISC_POSIX
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
28
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
29 AC_HEADER_DIRENT
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
30 AC_HEADER_STDC
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
31 AC_HEADER_SYS_WAIT
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
32 AC_CHECK_HEADERS(fcntl.h limits.h malloc.h strings.h sys/ioctl.h sys/time.h unistd.h)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
33
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
34 AC_C_CONST
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
35 AC_C_INLINE
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
36 AC_TYPE_MODE_T
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
37 AC_TYPE_PID_T
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
38 AC_TYPE_SIZE_T
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
39 AC_HEADER_TIME
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
40 AC_STRUCT_TM
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
41
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
42 AC_FUNC_ALLOCA
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
43 AC_PROG_GCC_TRADITIONAL
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
44 AC_FUNC_MMAP
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
45 AC_TYPE_SIGNAL
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
46 AC_FUNC_STRFTIME
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
47 AC_FUNC_UTIME_NULL
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
48 AC_CHECK_FUNCS(gai_strerror getaddrinfo getcwd gettimeofday getwd mkdir mktime putenv rmdir select socket strdup strstr strtod strtol uname)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
49
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
50 if test "x$enable_gtk20" = "x1" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
51 PKG_CHECK_MODULES(GLIB, glib-2.0 >= 1.3.8)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
52 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
53
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
54 if test "x$GFTP_TEXT" = "x" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
55 AM_PATH_GLIB(1.2.3, , AC_MSG_ERROR(gFTP needs GLIB 1.2.3 or higher))
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
56 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
57
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
58 GFTP_TEXT=""
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
59 EXTRA_LIBS=""
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
60 USE_READLINE="yes"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
61 READLINE_LIBS=""
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
62 if test "x$enable_textport" = "x1" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
63 AC_CHECK_LIB(socket, socket, EXTRA_LIBS="-lsocket")
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
64
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
65 AC_CHECK_LIB(nsl, gethostbyname, EXTRA_LIBS="$EXTRA_LIBS -lnsl")
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
66
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
67 AC_MSG_CHECKING([whether to use readline])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
68 AC_ARG_WITH(readline,
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
69 [ --with-readline turn on readline [default=yes, default tries -lncurses, -lcurses, -ltermcap]],
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
70 [case "${withval}" in
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
71 yes) USE_READLINE="yes" ; AC_MSG_RESULT([yes]) ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
72 no) USE_READLINE="no" ; AC_MSG_RESULT([no]) ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
73 only) USE_READLINE="yes"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
74 EXTRA_LIBREADLINE_DEPS=" "
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
75 AC_MSG_RESULT([yes (using only readline)]) ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
76 *) USE_READLINE="yes"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
77 EXTRA_LIBREADLINE_DEPS="${withval}"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
78 AC_MSG_RESULT([yes (using extra libraries ${withval})]) ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
79 esac],[AC_MSG_RESULT([${USE_READLINE}])])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
80
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
81 dnl Checks for libraries.
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
82 dnl When checking readline, check using extra libraries first.
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
83 dnl We want to protect against the link somehow succeeding, but only
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
84 dnl failing at runtime, as seems to happen on some BSD systems.
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
85 if test "$USE_READLINE" = yes ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
86 if test "$EXTRA_LIBREADLINE_DEPS" = "" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
87 unset ac_cv_lib_readline_readline
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
88 AC_CHECK_LIB(readline, readline, HAVE_LIBREADLINE=true,
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
89 HAVE_LIBREADLINE=false, -lncurses)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
90 if test x${HAVE_LIBREADLINE} = xtrue ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
91 echo " Using -lreadline -lncurses"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
92 EXTRA_LIBREADLINE_DEPS=-lncurses
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
93 AC_DEFINE(HAVE_LIBREADLINE, [1])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
94 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
95 unset ac_cv_lib_readline_readline
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
96 AC_CHECK_LIB(readline, readline, HAVE_LIBREADLINE=true,
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
97 HAVE_LIBREADLINE=false, -lcurses)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
98 if test x${HAVE_LIBREADLINE} = xtrue ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
99 echo " Using -lreadline -lcurses"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
100 EXTRA_LIBREADLINE_DEPS=-lcurses
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
101 AC_DEFINE(HAVE_LIBREADLINE, [1])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
102 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
103 unset ac_cv_lib_readline_readline
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
104 AC_CHECK_LIB(readline, readline, HAVE_LIBREADLINE=true,
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
105 HAVE_LIBREADLINE=false, -ltermcap)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
106 if test x${HAVE_LIBREADLINE} = xtrue ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
107 echo " Using -lreadline -ltermcap"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
108 EXTRA_LIBREADLINE_DEPS=-ltermcap
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
109 AC_DEFINE(HAVE_LIBREADLINE, [1])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
110 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
111 unset ac_cv_lib_readline_readline
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
112 AC_CHECK_LIB(readline, readline, HAVE_LIBREADLINE=true,
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
113 HAVE_LIBREADLINE=false)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
114 if test x${HAVE_LIBREADLINE} = xtrue ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
115 AC_DEFINE(HAVE_LIBREADLINE, [1])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
116 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
117 AC_DEFINE(HAVE_LIBREADLINE, [0])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
118 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
119 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
120 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
121 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
122 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
123 unset ac_cv_lib_readline_readline
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
124 AC_CHECK_LIB(readline, readline, HAVE_LIBREADLINE=true,
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
125 HAVE_LIBREADLINE=false, ${EXTRA_LIBREADLINE_DEPS})
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
126 if test x${HAVE_LIBREADLINE} = xtrue ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
127 echo " Using -lreadline ${EXTRA_LIBREADLINE_DEPS}"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
128 AC_DEFINE(HAVE_LIBREADLINE, [1])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
129 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
130 AC_DEFINE(HAVE_LIBREADLINE, [0])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
131 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
132 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
133 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
134 HAVE_LIBREADLINE=false
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
135 AC_DEFINE(HAVE_LIBREADLINE, [0])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
136 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
137 if test x${HAVE_LIBREADLINE} = xtrue; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
138 READLINE_LIBS="-lreadline ${EXTRA_LIBREADLINE_DEPS}"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
139 GFTP_TEXT="gftp-text"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
140 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
141 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
142
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
143 AC_CHECK_LIB(m, log10, EXTRA_LIBS="$EXTRA_LIBS -lm")
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
144
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
145 if test "x$enable_dmalloc" = "x1" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
146 AC_CHECK_LIB(dmalloc, dmalloc_shutdown, [
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
147 AC_DEFINE(HAVE_DMALLOC)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
148 EXTRA_LIBS="$EXTRA_LIBS -ldmalloc"])
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
149 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
150
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
151 AC_SUBST(EXTRA_LIBS)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
152 AC_SUBST(READLINE_LIBS)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
153 AC_SUBST(GFTP_TEXT)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
154
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
155 GFTP_GTK=""
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
156 PTHREAD_CFLAGS=""
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
157 PTHREAD_LIBS=""
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
158 if test "x$enable_gtkport" = "x1" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
159 if test "x$enable_gtk20" = "x1" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
160 PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 1.3.8, GFTP_GTK=gftp-gtk)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
161 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
162
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
163 if test "x$GFTP_GTK" = "x" ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
164 AM_PATH_GTK(1.2.3, GFTP_GTK=gftp-gtk, AC_MSG_WARN(gFTP needs GTK+ 1.2.3 or higher for the graphical version. Only building the text version))
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
165 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
166
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
167 if test "x$GFTP_GTK" = xgftp-gtk; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
168 AC_CHECK_LIB(pthread, pthread_create, PTHREAD_LIBS="-lpthread")
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
169
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
170 if test "x$PTHREAD_LIBS" = x ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
171 AC_CHECK_LIB(pthreads, pthread_create, PTHREAD_LIBS="-lpthreads")
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
172 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
173
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
174 if test "x$PTHREAD_LIBS" = x ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
175 AC_CHECK_LIB(c_r, pthread_create, PTHREAD_LIBS="-lc_r")
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
176 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
177
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
178 if test "x$PTHREAD_LIBS" = x ; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
179 echo ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
180 echo "Error: Cannot find the pthread libraries. If you don't have them installed," ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
181 echo "your X libraries probably aren't thread safe either. You can download the" ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
182 echo "pthread library and the thread safe X libraries from my webpage at" ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
183 echo "http://www.gftp.org/. Note the pthread library and the thread safe" ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
184 echo "X libraries on my webpage are for Linux libc5 machines ONLY" ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
185 echo ;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
186 exit
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
187 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
188
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
189 PTHREAD_CFLAGS="-D_REENTRANT"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
190
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
191 # I took some of these from the glib 1.3.3 configure.in
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
192 case $host in
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
193 *-hpux*)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
194 # From H.Merijn Brand <h.m.brand@hccnet.nl>
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
195 echo '#define pthread_attr_init(x) __pthread_attr_init_system(x)'
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
196 +>>confdefs.h
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
197 ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
198 *-aix*)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
199 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_THREAD_SAFE"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
200 if test x"$GCC" = xyes; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
201 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -mthreads"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
202 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
203 ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
204 *-freebsd*)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
205 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_THREAD_SAFE"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
206
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
207 # FreeBSD 2.2.x shiped with gcc 2.7.2.x, which doesn't support
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
208 # -mthreads flag.
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
209 ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
210 *-openbsd*)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
211 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_THREAD_SAFE"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
212 if test "x$PTHREAD_LIBS" = "x-lc_r"; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
213 PTHREAD_LIBS="-pthread"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
214 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
215 ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
216 *-sysv5uw7*) # UnixWare 7
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
217 if test "$GCC" != "yes"; then
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
218 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -Kthread"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
219 else
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
220 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -pthread"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
221 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
222 ;;
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
223 *-dg-dgux*) # DG/UX
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
224 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_POSIX4A_DRAFT10_SOURCE"
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
225 esac
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
226 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
227 fi
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
228 AC_SUBST(PTHREAD_CFLAGS)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
229 AC_SUBST(PTHREAD_LIBS)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
230 AC_SUBST(GFTP_GTK)
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
231
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
232 AM_GNU_GETTEXT
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
233
8b1883341c6f Initial revision
masneyb
parents:
diff changeset
234 AC_OUTPUT(Makefile intl/Makefile po/Makefile.in docs/Makefile docs/sample.gftp/Makefile src/gftp src/Makefile src/gtk/Makefile src/text/Makefile lib/Makefile gftp.spec)