forked from knik0/faac
-
Notifications
You must be signed in to change notification settings - Fork 2
/
configure.ac
66 lines (52 loc) · 1.65 KB
/
configure.ac
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
AC_PREREQ(2.50)
AC_INIT(faac, 1.29.9.2, https://sourceforge.net/p/faac/bugs/)
AC_CONFIG_AUX_DIR(.)
AM_INIT_AUTOMAKE([subdir-objects])
AM_CONFIG_HEADER(config.h)
AH_TOP([#ifndef CONFIG_H
#define CONFIG_H])
AH_BOTTOM([#endif /* CONFIG_H */])
AC_ARG_ENABLE( drm, [ --enable-drm Digital Radio Mondiale support], enable_drm=$enableval, enable_drm=no)
AC_DEFUN([MY_DEFINE], [ AC_DEFINE($1, 1, [define if needed]) ])
CFLAGS=${CFLAGS:-"-O2 -Wall -fexceptions"}
AC_PROG_CC
AC_PROG_CXX
AM_PROG_LIBTOOL
AC_CHECK_HEADERS(getopt.h immintrin.h)
AC_CHECK_DECL(strcasecmp, MY_DEFINE(HAVE_STRCASECMP))
AC_CHECK_LIB(gnugetopt, getopt_long)
dnl Check for DRM mode
if test "x$enable_drm" = "xyes"; then
AC_DEFINE(DRM, 1, [Define if you want to encode for DRM])
AM_CONDITIONAL(USE_DRM, true)
CFLAGS="$CFLAGS -DDRM"
else
AM_CONDITIONAL(USE_DRM, false)
fi
AM_CONDITIONAL(MINGW, test "$host_os" = "mingw32")
AM_CONDITIONAL(CPUSSE, test "$host_cpu" = "x86_64" || test "$host_cpu" = "i686")
AC_CHECK_TOOL(WINDRES, windres)
AC_C_BIGENDIAN
dnl Checks for header files required for mp4.h
AC_HEADER_STDC
AC_SYS_LARGEFILE
AC_CHECK_HEADERS(stdint.h inttypes.h)
AC_CHECK_HEADERS(mathf.h)
AC_CHECK_HEADERS(float.h)
AC_CHECK_DECL(strchr, MY_DEFINE(HAVE_STRCHR))
AC_CHECK_DECL(memcpy, MY_DEFINE(HAVE_MEMCPY))
AC_CHECK_DECL(strsep, MY_DEFINE(HAVE_STRSEP))
AC_CHECK_HEADERS(sys/time.h)
AC_HEADER_TIME
AC_TYPE_OFF_T
AC_CHECK_TYPES([in_port_t, socklen_t], , ,
[#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>])
AC_CHECK_MEMBERS(fpos_t.__pos,,, [#include <stdio.h>])
AC_OUTPUT([
common/Makefile
libfaac/Makefile
frontend/Makefile
include/Makefile
Makefile])