-
Notifications
You must be signed in to change notification settings - Fork 25
/
configure.ac
65 lines (54 loc) · 1.45 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
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.59])
AC_INIT([kytea], [0.4.8], [[email protected]])
# Intialize automake
AM_INIT_AUTOMAKE([-Wall] [foreign])
AM_PROG_AR()
AC_CONFIG_SRCDIR([src/lib/kytea.cpp])
AC_CONFIG_HEADERS([src/include/kytea/config.h])
AC_CONFIG_FILES([
Makefile
kytea.pc
src/Makefile
src/include/Makefile
src/lib/Makefile
src/lib/liblinear/Makefile
src/lib/liblinear/blas/Makefile
src/bin/Makefile
src/test/Makefile
src/api/Makefile
data/Makefile
])
AC_CONFIG_MACRO_DIR([m4])
AC_PROG_LIBTOOL
# set CFLAGS and CXXFLAGS for maximal optimization
if test -n "${CXXFLAGS}"; then
user_set_cxxflags=yes
fi
AC_PROG_CXX
if test X$user_set_cxxflags != Xyes; then
CXXFLAGS="-std=c++14 -g -Wall -O3"
fi
if test -n "${CFLAGS}"; then
user_set_cflags=yes
fi
AC_PROG_CC
if test X$user_set_cflags != Xyes; then
CFLAGS="-g -Wall -O3"
fi
# Checks for features.
AC_ARG_ENABLE(quantize,
[ --enable-quantize Quantize the model, resulting in smaller but possibly less accurate models)],
[], [enable_quantize=yes])
if test "x$enable_quantize" = xno; then
AC_DEFINE([DISABLE_QUANTIZE], [1], [Disable quantizing])
else
AC_DEFINE([DISABLE_QUANTIZE], [0], [Enable quantizing])
fi
# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
AC_C_INLINE
AC_TYPE_SIZE_T
AC_LANG([C++])
AC_OUTPUT