summaryrefslogtreecommitdiff
path: root/legacy/eet/m4/efl_binary.m4
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2010-02-28 17:27:38 +0000
committerVincent Torri <vincent.torri@gmail.com>2010-02-28 17:27:38 +0000
commit9129d1d30a6c98210a6c1fe2388309de7066e771 (patch)
treeb6964b8921258c60cbf9a42f20fbda271d19741f /legacy/eet/m4/efl_binary.m4
parent43908b19051e3a996e55fbd5d500d8b5c37f999a (diff)
abort when pthread is requested but not found
patch by Albin Tonnerre SVN revision: 46655
Diffstat (limited to 'legacy/eet/m4/efl_binary.m4')
-rw-r--r--legacy/eet/m4/efl_binary.m437
1 files changed, 36 insertions, 1 deletions
diff --git a/legacy/eet/m4/efl_binary.m4 b/legacy/eet/m4/efl_binary.m4
index 0fe85ab6ae..08732564dc 100644
--- a/legacy/eet/m4/efl_binary.m4
+++ b/legacy/eet/m4/efl_binary.m4
@@ -1,7 +1,7 @@
1dnl Copyright (C) 2010 Vincent Torri <vtorri at univ-evry dot fr> 1dnl Copyright (C) 2010 Vincent Torri <vtorri at univ-evry dot fr>
2dnl That code is public domain and can be freely used or copied. 2dnl That code is public domain and can be freely used or copied.
3 3
4dnl Macro that check if a binary is built or not 4dnl Macro that checks if a binary is built or not
5 5
6dnl Usage: EFL_ENABLE_BIN(binary) 6dnl Usage: EFL_ENABLE_BIN(binary)
7dnl Call AC_SUBST(BINARY_PRG) (BINARY is the uppercase of binary, - being tranformed into _) 7dnl Call AC_SUBST(BINARY_PRG) (BINARY is the uppercase of binary, - being tranformed into _)
@@ -42,3 +42,38 @@ AM_CONDITIONAL(BUILD_[]UP, test "x$have_[]m4_defn([DOWN])" = "xyes")
42AS_IF([test "x$have_[]m4_defn([DOWN])" = "xyes"], [$2], [$3]) 42AS_IF([test "x$have_[]m4_defn([DOWN])" = "xyes"], [$2], [$3])
43 43
44]) 44])
45
46dnl Macro that specifies the binary to be used
47
48dnl Usage: EFL_WITH_BIN(binary, package, msg)
49dnl Call AC_SUBST(BINARY_PRG) (BINARY is the uppercase of binary, - being tranformed into _)
50dnl Define with_binary (- is tranformed into _)
51dnl Define conditional BUILD_BINARY (BINARY is the uppercase of binary, - being tranformed into _)
52
53AC_DEFUN([EFL_WITH_BIN],
54[
55
56m4_pushdef([UP], m4_translit([[$1]], [-a-z], [_A-Z]))dnl
57m4_pushdef([DOWN], m4_translit([[$1]], [-A-Z], [_a-z]))dnl
58
59AC_REQUIRE([PKG_PROG_PKG_CONFIG])
60AC_MSG_NOTICE([$PKG_CONFIG])
61
62with_[]m4_defn([DOWN])=m4_esyscmd($PKG_CONFIG --variable=prefix $2)/bin/m4_defn([DOWN])
63
64dnl configure option
65
66AC_ARG_WITH([$1],
67 [AC_HELP_STRING([--with-$1-bin=PATH], [specify a specific path to ]DOWN)],
68 [
69 with_[]m4_defn([DOWN])=$withval
70 _efl_msg="( explicitely set)"
71 ])
72
73AC_MSG_NOTICE([$msg: ]m4_defn([DOWN])[$_efl_msg])
74
75AC_SUBST(with_[]m4_defn([DOWN]))
76
77AS_IF([test "x$have_[]m4_defn([DOWN])" = "xyes"], [$4], [$5])
78
79])