Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 137 lines (117 sloc) 4.05 kb
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
1 dnl DNA define([AC_CACHE_LOAD], )dnl
1ffd1ec Nicolas Niclausse add configure scripts to detect erlang installation directory and comman...
nniclausse authored
2
c4378c6 Nicolas Niclausse update mailing list.
nniclausse authored
3 AC_INIT([tsung], m4_normalize(m4_include([vsn.mk])),[tsung-users@process-one.net])
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
4 AC_PREREQ(2.59c)
5 AC_COPYRIGHT(Copyright (C) 2008 Nicolas Niclausse)
5345a3b Nicolas Niclausse rename idx-tsunami to tsung step 3
nniclausse authored
6 AC_CONFIG_SRCDIR(src/tsung/tsung.erl)
13dfdfd Nicolas Niclausse update configure & Makefile
nniclausse authored
7 dnl AM_INIT_AUTOMAKE()
8
6b34bf4 Nicolas Niclausse merge from 1.3.1 branch
nniclausse authored
9 AC_CACHE_LOAD
10
13dfdfd Nicolas Niclausse update configure & Makefile
nniclausse authored
11 AC_SUBST([CONFIG_STATUS_DEPENDENCIES],[vsn.mk])
12 AC_SUBST([CONFIGURE_DEPENDENCIES],[vsn.mk])
1ffd1ec Nicolas Niclausse add configure scripts to detect erlang installation directory and comman...
nniclausse authored
13
bc45901 Nicolas Niclausse improved configure: add --with-erlang option and xmerl PATH detection (c...
nniclausse authored
14 AC_PATH_PROG(SED, sed)
15
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
16 AC_LANG(Erlang)
bc45901 Nicolas Niclausse improved configure: add --with-erlang option and xmerl PATH detection (c...
nniclausse authored
17 AC_ARG_WITH(erlang, [ --with-erlang=PREFIX path to erlc and erl ])
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
18 AC_ERLANG_PATH_ERLC(erlc, $with_erlang:$with_erlang/bin:$PATH)
19 AC_ERLANG_PATH_ERL(erl, $with_erlang:$with_erlang/bin:$PATH)
1ffd1ec Nicolas Niclausse add configure scripts to detect erlang installation directory and comman...
nniclausse authored
20
55e9c60 Nicolas Niclausse no longer install beam files in erlang root dir. Use configure setup ins...
nniclausse authored
21 AC_PREFIX_PROGRAM(erl)
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
22 AC_ERLANG_SUBST_ROOT_DIR()
1ffd1ec Nicolas Niclausse add configure scripts to detect erlang installation directory and comman...
nniclausse authored
23
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
24 AC_MSG_CHECKING(for Erlang/OTP '-hybrid' option)
94ec7aa Nicolas Niclausse hybrid and shared must work with smp
nniclausse authored
25 if ! $ERL -noshell -hybrid -smp 2 -s init stop 2> /dev/null; then
9faae4b Mickaël Rémond * Make sure SVN properties are correctly set.
mremond authored
26 AC_MSG_RESULT(no)
27 else
28 AC_MSG_RESULT(yes)
29 ERL_OPTS="-hybrid $ERL_OPTS"
30 fi
31
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
32 dnl check for xmerl include path
33 AC_ERLANG_CHECK_LIB(xmerl)
34 AC_ERLANG_CHECK_LIB(ssl)
35 AC_ERLANG_CHECK_LIB(crypto)
75e5ccf Nicolas Niclausse make ssl work with R14A (TSUN-157)
nniclausse authored
36 AC_ERLANG_CHECK_LIB(public_key)
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
37
38 dnl check if ssl is working
39 AC_CACHE_CHECK([if Erlang/OTP SSL application is running fine],
40 [erlang_cv_ssl_runnable],
41 [erlang_cv_ssl_runnable=no
42 AC_RUN_IFELSE(
43 [AC_LANG_PROGRAM([], [dnl
44 case application:start(ssl) of
45 ok -> ok;
46 Err -> halt(1)
47 end,
48 halt(0)])],
49 [erlang_cv_ssl_runnable=yes
50 ERLANG_APPLICATIONS="kernel,stdlib,ssl"],
75e5ccf Nicolas Niclausse make ssl work with R14A (TSUN-157)
nniclausse authored
51 [
52 AC_RUN_IFELSE(
53 [AC_LANG_PROGRAM([], [dnl
54 application:start(crypto),
55 application:start(public_key),
56 case application:start(ssl) of
57 ok -> ok;
58 Err -> halt(1)
59 end,
60 halt(0)])],
61 [erlang_cv_ssl_runnable=yes
62 ERLANG_APPLICATIONS="kernel,stdlib,crypto,public_key,ssl"],
63 [ERLANG_APPLICATIONS="kernel,stdlib"
64 AC_MSG_RESULT(WARNING: ssl application is not working properly !!!)])
65 ])
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
66 ])
67
75e5ccf Nicolas Niclausse make ssl work with R14A (TSUN-157)
nniclausse authored
68
69
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
70 dnl check if crypto is working
71 AC_CACHE_CHECK([if Erlang/OTP crypto application is running fine],
72 [erlang_cv_crypto_runnable],
73 [erlang_cv_crypto_runnable=no
74 AC_RUN_IFELSE(
75 [AC_LANG_PROGRAM([], [dnl
76 case application:start(crypto) of
77 ok ->
78 case catch crypto:md5("toto") of
79 <<247,29,190,82,98,138,63,131,167,122,180,148,129,117,37, 198>> -> ok;
80 _ ->
81 halt(1)
82 end;
83 Err ->
84 erlang:display([Err]),
85 halt(1)
86 end,
87 halt(0) ])],
88 [ erlang_cv_crypto_runnable=yes
89 ERLANG_APPLICATIONS="$ERLANG_APPLICATIONS,crypto" ],
90 [ AC_MSG_RESULT([WARNING: crypto application is not working properly !!!])]) ])
91
92 dnl check if orelse is allowed in guards
93 AC_CACHE_CHECK([if orelse is allowed in guards],
94 [erlang_cv_orelse],
95 [erlang_cv_orelse=no
96 AC_RUN_IFELSE(
97 [AC_LANG_PROGRAM([], [dnl
98 case 3 of
99 A when A > 3 orelse A < 2 -> ok;
100 _ -> bad
101 end,
102 halt(0)])],
103 [erlang_cv_orelse=yes],
104 [AC_MSG_RESULT(WARNING: orelse/andalso not allowed in guards: XPATH parsing will be disabled !!!)])
105 ])
106
107
108 AC_SUBST(erlang_cv_orelse)
bc45901 Nicolas Niclausse improved configure: add --with-erlang option and xmerl PATH detection (c...
nniclausse authored
109 AC_SUBST(ERL_OPTS)
6c54808 Nicolas Niclausse check for ssl and crypto app at compile time (TSUN-63)
nniclausse authored
110 AC_SUBST(ERLANG_APPLICATIONS)
5345a3b Nicolas Niclausse rename idx-tsunami to tsung step 3
nniclausse authored
111 AC_SUBST(DTD,[tsung-1.0.dtd])
112 AC_SUBST(TEMPLATES_SUBDIR,[tsung/templates])
1ffd1ec Nicolas Niclausse add configure scripts to detect erlang installation directory and comman...
nniclausse authored
113
114 AC_PROG_MAKE_SET
115 AC_PROG_INSTALL
116
e567459 Nicolas Niclausse - update makefile/configure scripts for tsung-plotter (TSUN-89)
nniclausse authored
117 AS_AC_EXPAND(EXPANDED_LIBDIR, "$libdir/tsung")
118 AC_MSG_NOTICE(Storing library files in $EXPANDED_LIBDIR)
119 AS_AC_EXPAND(EXPANDED_SHAREDIR, "$datadir/tsung")
120 AC_MSG_NOTICE(Storing data files in $EXPANDED_SHAREDIR)
121
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
122 AC_CONFIG_FILES([\
123 Makefile \
124 tsung.spec \
125 tsung.sh \
4c0948f Nicolas Niclausse split tsung command into tsung and tsung-recorder (TSUN-113)
nniclausse authored
126 tsung-recorder.sh \
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
127 examples/*.xml \
128 src/tsung_stats.pl \
e567459 Nicolas Niclausse - update makefile/configure scripts for tsung-plotter (TSUN-89)
nniclausse authored
129 src/tsung-plotter/tsplot.py \
54a7fac Nicolas Niclausse - use autoconf erlang builtin support in configure.in
nniclausse authored
130 src/log2tsung.pl \
131 src/tsung_controller/tsung_controller.app.src \
132 src/tsung_recorder/tsung_recorder.app.src \
133 src/tsung/tsung.app.src \
134 ])
13dfdfd Nicolas Niclausse update configure & Makefile
nniclausse authored
135
136 AC_OUTPUT
Something went wrong with that request. Please try again.