File: configure.in

package info (click to toggle)
plastimatch 1.10.0%2Bdfsg.1-1
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 48,324 kB
  • sloc: cpp: 126,131; sh: 5,845; ansic: 2,867; lisp: 907; makefile: 63; pascal: 62; cs: 19; fortran: 15
file content (107 lines) | stat: -rw-r--r-- 3,071 bytes parent folder | download | duplicates (7)
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
dnl $Id: configure.in 65 2010-01-29 12:19:16Z naoaki $
dnl
dnl
dnl Exported and configured variables:
dnl CFLAGS
dnl LDFLAGS
dnl INCLUDES


dnl ------------------------------------------------------------------
dnl Initialization for autoconf
dnl ------------------------------------------------------------------
AC_PREREQ(2.59)
AC_INIT
AC_CONFIG_SRCDIR([lib/lbfgs.c])


dnl ------------------------------------------------------------------
dnl Initialization for automake
dnl ------------------------------------------------------------------
AM_INIT_AUTOMAKE(liblbfgs, 1.9)
AC_CONFIG_HEADERS(config.h)
AM_MAINTAINER_MODE


dnl ------------------------------------------------------------------
dnl Checks for program
dnl ------------------------------------------------------------------
AC_PROG_LIBTOOL
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_MAKE_SET


dnl ------------------------------------------------------------------
dnl Initialization for variables
dnl ------------------------------------------------------------------
CFLAGS="${ac_save_CFLAGS}"
LDFLAGS="${ac_save_LDFLAGS}"
INCLUDES="-I\$(top_srcdir) -I\$(top_srcdir)/include"



dnl ------------------------------------------------------------------
dnl Checks for header files.
dnl ------------------------------------------------------------------
AC_HEADER_STDC
AC_CHECK_HEADERS(xmmintrin.h emmintrin.h)



dnl ------------------------------------------------------------------
dnl Checks for debugging mode
dnl ------------------------------------------------------------------
AC_ARG_ENABLE(
    debug,
    [AS_HELP_STRING(
        [--enable-debug],
        [build for debugging]
        )],
    [CFLAGS="-DDEBUG -O -g ${CFLAGS}"],
    [CFLAGS="-O3 -ffast-math ${CFLAGS}"]
)

dnl ------------------------------------------------------------------
dnl Checks for profiling mode
dnl ------------------------------------------------------------------
AC_ARG_ENABLE(
    profile,
    [AS_HELP_STRING(
        [--enable-profile],
        [build for profiling]
	)],
    [CFLAGS="-DPROFILE -pg ${CFLAGS}"]
)

dnl ------------------------------------------------------------------
dnl Checks for SSE2 build
dnl ------------------------------------------------------------------
AC_ARG_ENABLE(
    sse2,
    [AS_HELP_STRING(
        [--enable-sse2],
        [enable SSE2 optimization routines]
        )],
    [CFLAGS="-msse2 -DUSE_SSE ${CFLAGS}"]
)

dnl ------------------------------------------------------------------
dnl Checks for library functions.
dnl ------------------------------------------------------------------
AC_CHECK_LIB(m, fabs)



dnl ------------------------------------------------------------------
dnl Export variables
dnl ------------------------------------------------------------------
AC_SUBST(CFLAGS)
AC_SUBST(LDFLAGS)
AC_SUBST(INCLUDES)

dnl ------------------------------------------------------------------
dnl Output the configure results.
dnl ------------------------------------------------------------------
AC_CONFIG_FILES(Makefile lib/Makefile sample/Makefile)
AC_OUTPUT