-
Notifications
You must be signed in to change notification settings - Fork 24
/
configure.ac
87 lines (76 loc) · 2.72 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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
dnl -*- Autoconf -*-
dnl Process this file with autoconf to produce a configure script.
AC_INIT([opencore-amr], [0.1.3], [http://sourceforge.net/projects/opencore-amr/])
AC_CONFIG_AUX_DIR(.)
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([tar-ustar foreign])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
AM_MAINTAINER_MODE
dnl Various options for configure
AC_ARG_ENABLE([compile-c],
[AS_HELP_STRING([--enable-compile-c],
[enable compiling as C program (default is yes)])],
[compile_as_c=$enableval],
[compile_as_c=yes])
AC_ARG_ENABLE([gcc-armv5],
[AS_HELP_STRING([--enable-gcc-armv5],
[enable GCC specific ARMv5 assembler (default is no)])],
[gcc_armv5=$enableval], [gcc_armv5=no])
AC_ARG_ENABLE([amrnb-encoder],
[AS_HELP_STRING([--enable-amrnb-encoder],
[enable AMR-NB encoder (default is yes)])],
[amrnb_encoder=$enableval], [amrnb_encoder=yes])
AC_ARG_ENABLE([amrnb-decoder],
[AS_HELP_STRING([--enable-amrnb-decoder],
[enable AMR-NB decoder (default is yes)])],
[amrnb_decoder=$enableval], [amrnb_decoder=yes])
AC_ARG_ENABLE([examples],
[AS_HELP_STRING([--enable-examples],
[enable example encoding/decoding programs (default is no)])],
[examples=$enableval], [examples=no])
dnl Automake conditionals to set
AM_CONDITIONAL(COMPILE_AS_C, test x$compile_as_c = xyes)
AM_CONDITIONAL(GCC_ARMV5, test x$gcc_armv5 = xyes)
AM_CONDITIONAL(AMRNB_ENCODER, test x$amrnb_encoder = xyes)
AM_CONDITIONAL(AMRNB_DECODER, test x$amrnb_decoder = xyes)
AM_CONDITIONAL(EXAMPLES, test x$examples = xyes)
dnl Checks for programs.
AC_PROG_CXX
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_MAKE_SET
dnl Setup for libtool
LT_INIT
dnl Checks for libraries.
AC_CHECK_LIB([m], [main])
dnl Checks for header files.
AC_CHECK_HEADERS([stdint.h stdlib.h string.h])
dnl Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
AC_C_INLINE
AC_TYPE_INT16_T
AC_TYPE_INT32_T
AC_TYPE_INT64_T
AC_TYPE_INT8_T
AC_TYPE_UINT16_T
AC_TYPE_UINT32_T
AC_TYPE_UINT64_T
AC_TYPE_UINT8_T
dnl Checks for library functions.
AC_FUNC_MALLOC
AC_CHECK_FUNCS([memset])
dnl OpenCORE AMR soname version to use
dnl goes by ‘current[:revision[:age]]’ with the soname ending up as
dnl current.age.revision.
OPENCORE_AMRNB_VERSION=0:3:0
OPENCORE_AMRWB_VERSION=0:3:0
AC_SUBST(OPENCORE_AMRNB_VERSION)
AC_SUBST(OPENCORE_AMRWB_VERSION)
AC_CONFIG_FILES([Makefile
amrnb/Makefile
amrwb/Makefile
test/Makefile
amrnb/opencore-amrnb.pc
amrwb/opencore-amrwb.pc])
AC_OUTPUT