* Fuck notepad and its fucking CRLFs.
This commit is contained in:
parent
16d1d7fa48
commit
1c8a34708d
166
configure.ac
166
configure.ac
@ -1,83 +1,83 @@
|
|||||||
# $Id: configure.ac 98 2006-09-22 16:27:37Z sam $
|
# $Id: configure.ac 98 2006-09-22 16:27:37Z sam $
|
||||||
|
|
||||||
AC_INIT(zzuf, 0.7)
|
AC_INIT(zzuf, 0.7)
|
||||||
|
|
||||||
AC_PREREQ(2.50)
|
AC_PREREQ(2.50)
|
||||||
AC_CONFIG_SRCDIR(src/zzuf.c)
|
AC_CONFIG_SRCDIR(src/zzuf.c)
|
||||||
AC_CONFIG_AUX_DIR(autotools)
|
AC_CONFIG_AUX_DIR(autotools)
|
||||||
AC_CANONICAL_SYSTEM
|
AC_CANONICAL_SYSTEM
|
||||||
|
|
||||||
AM_INIT_AUTOMAKE(zzuf, 0.7)
|
AM_INIT_AUTOMAKE(zzuf, 0.7)
|
||||||
AM_CONFIG_HEADER(config.h)
|
AM_CONFIG_HEADER(config.h)
|
||||||
|
|
||||||
AM_PROG_CC_C_O
|
AM_PROG_CC_C_O
|
||||||
AC_PROG_CPP
|
AC_PROG_CPP
|
||||||
AC_PROG_LIBTOOL
|
AC_PROG_LIBTOOL
|
||||||
|
|
||||||
case "${host_os}" in
|
case "${host_os}" in
|
||||||
*mingw32*)
|
*mingw32*)
|
||||||
DLL_LDFLAGS="-Wl,-l,imagehlp" # Trick libtool here
|
DLL_LDFLAGS="-Wl,-l,imagehlp" # Trick libtool here
|
||||||
WINSOCK2_LIBS="-lws2_32"
|
WINSOCK2_LIBS="-lws2_32"
|
||||||
ac_cv_func_recv=yes
|
ac_cv_func_recv=yes
|
||||||
ac_cv_func_recvfrom=yes
|
ac_cv_func_recvfrom=yes
|
||||||
ac_cv_func_socket=yes
|
ac_cv_func_socket=yes
|
||||||
ac_cv_func_accept=yes
|
ac_cv_func_accept=yes
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
AC_SUBST(WINSOCK2_LIBS)
|
AC_SUBST(WINSOCK2_LIBS)
|
||||||
AC_SUBST(DLL_LDFLAGS)
|
AC_SUBST(DLL_LDFLAGS)
|
||||||
|
|
||||||
AC_CHECK_HEADERS(windows.h winsock2.h io.h process.h unistd.h inttypes.h stdint.h getopt.h libc.h malloc.h dlfcn.h regex.h sys/socket.h sys/uio.h aio.h sys/mman.h sys/wait.h sys/resource.h sys/time.h)
|
AC_CHECK_HEADERS(windows.h winsock2.h io.h process.h unistd.h inttypes.h stdint.h getopt.h libc.h malloc.h dlfcn.h regex.h sys/socket.h sys/uio.h aio.h sys/mman.h sys/wait.h sys/resource.h sys/time.h)
|
||||||
|
|
||||||
AC_CHECK_FUNCS(setenv waitpid setrlimit gettimeofday fork kill pipe _pipe)
|
AC_CHECK_FUNCS(setenv waitpid setrlimit gettimeofday fork kill pipe _pipe)
|
||||||
AC_CHECK_FUNCS(open64 lseek64 mmap64 fopen64 fseeko _IO_getc getline getdelim __getdelim fgetln __srefill map_fd memalign posix_memalign aio_read accept socket readv pread recv recvfrom recvmsg mmap valloc sigaction)
|
AC_CHECK_FUNCS(open64 lseek64 mmap64 fopen64 fseeko _IO_getc getline getdelim __getdelim fgetln __srefill map_fd memalign posix_memalign aio_read accept socket readv pread recv recvfrom recvmsg mmap valloc sigaction)
|
||||||
|
|
||||||
AC_CHECK_TYPES(sighandler_t, [], [],
|
AC_CHECK_TYPES(sighandler_t, [], [],
|
||||||
[#define _GNU_SOURCE
|
[#define _GNU_SOURCE
|
||||||
#include <signal.h>])
|
#include <signal.h>])
|
||||||
AC_CHECK_TYPES(sig_t, [], [],
|
AC_CHECK_TYPES(sig_t, [], [],
|
||||||
[#include <signal.h>])
|
[#include <signal.h>])
|
||||||
AC_CHECK_TYPES(socklen_t, [], [],
|
AC_CHECK_TYPES(socklen_t, [], [],
|
||||||
[#include <sys/types.h>
|
[#include <sys/types.h>
|
||||||
#include <sys/socket.h>])
|
#include <sys/socket.h>])
|
||||||
|
|
||||||
AC_MSG_CHECKING(for read() prototype)
|
AC_MSG_CHECKING(for read() prototype)
|
||||||
AC_TRY_COMPILE([#include <unistd.h>],
|
AC_TRY_COMPILE([#include <unistd.h>],
|
||||||
[ssize_t read(int fd, void *buf, size_t count);],
|
[ssize_t read(int fd, void *buf, size_t count);],
|
||||||
[AC_MSG_RESULT(ssize_t read(... size_t);)
|
[AC_MSG_RESULT(ssize_t read(... size_t);)
|
||||||
AC_DEFINE(READ_USES_SSIZE_T, 1, [Define to 1 if read() uses ssize_t.])],
|
AC_DEFINE(READ_USES_SSIZE_T, 1, [Define to 1 if read() uses ssize_t.])],
|
||||||
[AC_MSG_RESULT(int read(... unsigned int);)])
|
[AC_MSG_RESULT(int read(... unsigned int);)])
|
||||||
|
|
||||||
AC_MSG_CHECKING(for recv() return value)
|
AC_MSG_CHECKING(for recv() return value)
|
||||||
ac_v_recv_t="int"
|
ac_v_recv_t="int"
|
||||||
AC_TRY_COMPILE([#include <sys/types.h>
|
AC_TRY_COMPILE([#include <sys/types.h>
|
||||||
#include <sys/socket.h>],
|
#include <sys/socket.h>],
|
||||||
[ssize_t recv(int s, void *buf, size_t len, int flags);],
|
[ssize_t recv(int s, void *buf, size_t len, int flags);],
|
||||||
[ac_v_recv_t="ssize_t"])
|
[ac_v_recv_t="ssize_t"])
|
||||||
AC_MSG_RESULT($ac_v_recv_t)
|
AC_MSG_RESULT($ac_v_recv_t)
|
||||||
AC_DEFINE_UNQUOTED(RECV_T, $ac_v_recv_t, [Define to the recv() return type])
|
AC_DEFINE_UNQUOTED(RECV_T, $ac_v_recv_t, [Define to the recv() return type])
|
||||||
|
|
||||||
AC_CHECK_FUNCS(getopt_long,
|
AC_CHECK_FUNCS(getopt_long,
|
||||||
[AC_DEFINE(HAVE_GETOPT_LONG, 1, Define to 1 if you have the `getopt_long' function.)],
|
[AC_DEFINE(HAVE_GETOPT_LONG, 1, Define to 1 if you have the `getopt_long' function.)],
|
||||||
[AC_CHECK_LIB(gnugetopt, getopt_long,
|
[AC_CHECK_LIB(gnugetopt, getopt_long,
|
||||||
[AC_DEFINE(HAVE_GETOPT_LONG, 1, Define to 1 if you have the `getopt_long' function.)
|
[AC_DEFINE(HAVE_GETOPT_LONG, 1, Define to 1 if you have the `getopt_long' function.)
|
||||||
GETOPT_LIBS="${GETOPT_LIBS} -lgnugetopt"])])
|
GETOPT_LIBS="${GETOPT_LIBS} -lgnugetopt"])])
|
||||||
AC_SUBST(GETOPT_LIBS)
|
AC_SUBST(GETOPT_LIBS)
|
||||||
|
|
||||||
AC_CHECK_LIB(m, log, [MATH_LIBS="-lm"])
|
AC_CHECK_LIB(m, log, [MATH_LIBS="-lm"])
|
||||||
AC_SUBST(MATH_LIBS)
|
AC_SUBST(MATH_LIBS)
|
||||||
AC_CHECK_LIB(dl, dlopen, [DL_LIBS="-ldl"])
|
AC_CHECK_LIB(dl, dlopen, [DL_LIBS="-ldl"])
|
||||||
AC_SUBST(DL_LIBS)
|
AC_SUBST(DL_LIBS)
|
||||||
|
|
||||||
# Optimizations
|
# Optimizations
|
||||||
CFLAGS="${CFLAGS} -g -O2 -fno-strength-reduce -fomit-frame-pointer"
|
CFLAGS="${CFLAGS} -g -O2 -fno-strength-reduce -fomit-frame-pointer"
|
||||||
# Code qui fait des warnings == code de porc == deux baffes dans ta gueule
|
# Code qui fait des warnings == code de porc == deux baffes dans ta gueule
|
||||||
CFLAGS="${CFLAGS} -Wall -W -Wpointer-arith -Wcast-align -Wcast-qual -Wstrict-prototypes -Wshadow -Waggregate-return -Wmissing-prototypes -Wnested-externs -Wsign-compare"
|
CFLAGS="${CFLAGS} -Wall -W -Wpointer-arith -Wcast-align -Wcast-qual -Wstrict-prototypes -Wshadow -Waggregate-return -Wmissing-prototypes -Wnested-externs -Wsign-compare"
|
||||||
|
|
||||||
AC_OUTPUT([
|
AC_OUTPUT([
|
||||||
Makefile
|
Makefile
|
||||||
src/Makefile
|
src/Makefile
|
||||||
doc/Makefile
|
doc/Makefile
|
||||||
test/Makefile
|
test/Makefile
|
||||||
])
|
])
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user