summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
Diffstat (limited to 'm4')
-rw-r--r--m4/ac_attribute.m447
-rw-r--r--m4/ac_path_generic.m4137
-rw-r--r--m4/efl_binary.m479
-rw-r--r--m4/efl_check_funcs.m4435
-rw-r--r--m4/efl_check_libs.m4119
-rw-r--r--m4/efl_compiler_flag.m457
-rw-r--r--m4/efl_doxygen.m494
-rw-r--r--m4/efl_path_max.m436
-rw-r--r--m4/efl_tests.m465
9 files changed, 0 insertions, 1069 deletions
diff --git a/m4/ac_attribute.m4 b/m4/ac_attribute.m4
deleted file mode 100644
index 23479a9..0000000
--- a/m4/ac_attribute.m4
+++ /dev/null
@@ -1,47 +0,0 @@
-dnl Copyright (C) 2004-2008 Kim Woelders
-dnl Copyright (C) 2008 Vincent Torri <vtorri at univ-evry dot fr>
-dnl That code is public domain and can be freely used or copied.
-dnl Originally snatched from somewhere...
-
-dnl Macro for checking if the compiler supports __attribute__
-
-dnl Usage: AC_C___ATTRIBUTE__
-dnl call AC_DEFINE for HAVE___ATTRIBUTE__ and __UNUSED__
-dnl if the compiler supports __attribute__, HAVE___ATTRIBUTE__ is
-dnl defined to 1 and __UNUSED__ is defined to __attribute__((unused))
-dnl otherwise, HAVE___ATTRIBUTE__ is not defined and __UNUSED__ is
-dnl defined to nothing.
-
-AC_DEFUN([AC_C___ATTRIBUTE__],
-[
-
-AC_MSG_CHECKING([for __attribute__])
-
-AC_CACHE_VAL([ac_cv___attribute__],
- [AC_TRY_COMPILE(
- [
-#include <stdlib.h>
-
-int func(int x);
-int foo(int x __attribute__ ((unused)))
-{
- exit(1);
-}
- ],
- [],
- [ac_cv___attribute__="yes"],
- [ac_cv___attribute__="no"]
- )])
-
-AC_MSG_RESULT($ac_cv___attribute__)
-
-if test "x${ac_cv___attribute__}" = "xyes" ; then
- AC_DEFINE([HAVE___ATTRIBUTE__], [1], [Define to 1 if your compiler has __attribute__])
- AC_DEFINE([__UNUSED__], [__attribute__((unused))], [Macro declaring a function argument to be unused])
- else
- AC_DEFINE([__UNUSED__], [], [Macro declaring a function argument to be unused])
-fi
-
-])
-
-dnl End of ac_attribute.m4
diff --git a/m4/ac_path_generic.m4 b/m4/ac_path_generic.m4
deleted file mode 100644
index d427241..0000000
--- a/m4/ac_path_generic.m4
+++ /dev/null
@@ -1,137 +0,0 @@
-dnl @synopsis AC_PATH_GENERIC(LIBRARY [, MINIMUM-VERSION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
-dnl
-dnl Runs a LIBRARY-config script and defines LIBRARY_CFLAGS and LIBRARY_LIBS
-dnl
-dnl The script must support `--cflags' and `--libs' args.
-dnl If MINIMUM-VERSION is specified, the script must also support the
-dnl `--version' arg.
-dnl If the `--with-library-[exec-]prefix' arguments to ./configure are given,
-dnl it must also support `--prefix' and `--exec-prefix'.
-dnl (In other words, it must be like gtk-config.)
-dnl
-dnl For example:
-dnl
-dnl AC_PATH_GENERIC(Foo, 1.0.0)
-dnl
-dnl would run `foo-config --version' and check that it is at least 1.0.0
-dnl
-dnl If so, the following would then be defined:
-dnl
-dnl FOO_CFLAGS to `foo-config --cflags`
-dnl FOO_LIBS to `foo-config --libs`
-dnl
-dnl At present there is no support for additional "MODULES" (see AM_PATH_GTK)
-dnl (shamelessly stolen from gtk.m4 and then hacked around a fair amount)
-dnl
-dnl @author Angus Lees <gusl@cse.unsw.edu.au>
-
-AC_DEFUN([AC_PATH_GENERIC],
-[dnl
-dnl we're going to need uppercase, lowercase and user-friendly versions of the
-dnl string `LIBRARY'
-pushdef([UP], translit([$1], [a-z], [A-Z]))dnl
-pushdef([DOWN], translit([$1], [A-Z], [a-z]))dnl
-
-dnl
-dnl Get the cflags and libraries from the LIBRARY-config script
-dnl
-AC_ARG_WITH(DOWN-prefix,
- [ --with-]DOWN[-prefix=PFX Prefix where $1 is installed (optional)],
- DOWN[]_config_prefix="$withval", DOWN[]_config_prefix="")
-AC_ARG_WITH(DOWN-exec-prefix,
- [ --with-]DOWN[-exec-prefix=PFX Exec prefix where $1 is installed (optional)],
- DOWN[]_config_exec_prefix="$withval", DOWN[]_config_exec_prefix="")
-
- if test x$DOWN[]_config_exec_prefix != x ; then
- DOWN[]_config_args="$DOWN[]_config_args --exec-prefix=$DOWN[]_config_exec_prefix"
- if test x${UP[]_CONFIG+set} != xset ; then
- UP[]_CONFIG=$DOWN[]_config_exec_prefix/bin/DOWN-config
- fi
- fi
- if test x$DOWN[]_config_prefix != x ; then
- DOWN[]_config_args="$DOWN[]_config_args --prefix=$DOWN[]_config_prefix"
- if test x${UP[]_CONFIG+set} != xset ; then
- UP[]_CONFIG=$DOWN[]_config_prefix/bin/DOWN-config
- fi
- fi
-
- AC_PATH_PROG(UP[]_CONFIG, DOWN-config, no)
- ifelse([$2], ,
- AC_MSG_CHECKING(for $1),
- AC_MSG_CHECKING(for $1 - version >= $2)
- )
- no_[]DOWN=""
- if test "$UP[]_CONFIG" = "no" ; then
- no_[]DOWN=yes
- else
- UP[]_CFLAGS="`$UP[]_CONFIG $DOWN[]_config_args --cflags`"
- UP[]_LIBS="`$UP[]_CONFIG $DOWN[]_config_args --libs`"
- ifelse([$2], , ,[
- DOWN[]_config_major_version=`$UP[]_CONFIG $DOWN[]_config_args \
- --version | sed 's/[[^0-9]]*\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\).*/\1/'`
- DOWN[]_config_minor_version=`$UP[]_CONFIG $DOWN[]_config_args \
- --version | sed 's/[[^0-9]]*\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\).*/\2/'`
- DOWN[]_config_micro_version=`$UP[]_CONFIG $DOWN[]_config_args \
- --version | sed 's/[[^0-9]]*\([[0-9]]*\).\([[0-9]]*\).\([[0-9]]*\).*/\3/'`
- DOWN[]_wanted_major_version="regexp($2, [\<\([0-9]*\)], [\1])"
- DOWN[]_wanted_minor_version="regexp($2, [\<\([0-9]*\)\.\([0-9]*\)], [\2])"
- DOWN[]_wanted_micro_version="regexp($2, [\<\([0-9]*\).\([0-9]*\).\([0-9]*\)], [\3])"
-
- # Compare wanted version to what config script returned.
- # If I knew what library was being run, i'd probably also compile
- # a test program at this point (which also extracted and tested
- # the version in some library-specific way)
- if test "$DOWN[]_config_major_version" -lt \
- "$DOWN[]_wanted_major_version" \
- -o \( "$DOWN[]_config_major_version" -eq \
- "$DOWN[]_wanted_major_version" \
- -a "$DOWN[]_config_minor_version" -lt \
- "$DOWN[]_wanted_minor_version" \) \
- -o \( "$DOWN[]_config_major_version" -eq \
- "$DOWN[]_wanted_major_version" \
- -a "$DOWN[]_config_minor_version" -eq \
- "$DOWN[]_wanted_minor_version" \
- -a "$DOWN[]_config_micro_version" -lt \
- "$DOWN[]_wanted_micro_version" \) ; then
- # older version found
- no_[]DOWN=yes
- echo -n "*** An old version of $1 "
- echo -n "($DOWN[]_config_major_version"
- echo -n ".$DOWN[]_config_minor_version"
- echo ".$DOWN[]_config_micro_version) was found."
- echo -n "*** You need a version of $1 newer than "
- echo -n "$DOWN[]_wanted_major_version"
- echo -n ".$DOWN[]_wanted_minor_version"
- echo ".$DOWN[]_wanted_micro_version."
- echo "***"
- echo "*** If you have already installed a sufficiently new version, this error"
- echo "*** probably means that the wrong copy of the DOWN-config shell script is"
- echo "*** being found. The easiest way to fix this is to remove the old version"
- echo "*** of $1, but you can also set the UP[]_CONFIG environment to point to the"
- echo "*** correct copy of DOWN-config. (In this case, you will have to"
- echo "*** modify your LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf"
- echo "*** so that the correct libraries are found at run-time)"
- fi
- ])
- fi
- if test "x$no_[]DOWN" = x ; then
- AC_MSG_RESULT(yes)
- ifelse([$3], , :, [$3])
- else
- AC_MSG_RESULT(no)
- if test "$UP[]_CONFIG" = "no" ; then
- echo "*** The DOWN-config script installed by $1 could not be found"
- echo "*** If $1 was installed in PREFIX, make sure PREFIX/bin is in"
- echo "*** your path, or set the UP[]_CONFIG environment variable to the"
- echo "*** full path to DOWN-config."
- fi
- UP[]_CFLAGS=""
- UP[]_LIBS=""
- ifelse([$4], , :, [$4])
- fi
- AC_SUBST(UP[]_CFLAGS)
- AC_SUBST(UP[]_LIBS)
-
- popdef([UP])
- popdef([DOWN])
-])
diff --git a/m4/efl_binary.m4 b/m4/efl_binary.m4
deleted file mode 100644
index fc2f200..0000000
--- a/m4/efl_binary.m4
+++ /dev/null
@@ -1,79 +0,0 @@
-dnl Copyright (C) 2010 Vincent Torri <vtorri at univ-evry dot fr>
-dnl That code is public domain and can be freely used or copied.
-
-dnl Macro that checks if a binary is built or not
-
-dnl Usage: EFL_ENABLE_BIN(binary)
-dnl Call AC_SUBST(BINARY_PRG) (BINARY is the uppercase of binary, - being transformed into _)
-dnl Define have_binary (- is transformed into _)
-dnl Define conditional BUILD_BINARY (BINARY is the uppercase of binary, - being transformed into _)
-
-AC_DEFUN([EFL_ENABLE_BIN],
-[
-
-m4_pushdef([UP], m4_translit([[$1]], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWN], m4_translit([[$1]], [-A-Z], [_a-z]))dnl
-
-have_[]m4_defn([DOWN])="yes"
-
-dnl configure option
-
-AC_ARG_ENABLE([$1],
- [AC_HELP_STRING([--disable-$1], [disable building of ]DOWN)],
- [
- if test "x${enableval}" = "xyes" ; then
- have_[]m4_defn([DOWN])="yes"
- else
- have_[]m4_defn([DOWN])="no"
- fi
- ])
-
-AC_MSG_CHECKING([whether to build ]DOWN[ binary])
-AC_MSG_RESULT([$have_[]m4_defn([DOWN])])
-
-if test "x$have_[]m4_defn([DOWN])" = "xyes"; then
- UP[]_PRG=DOWN[${EXEEXT}]
-fi
-
-AC_SUBST(UP[]_PRG)
-
-AM_CONDITIONAL(BUILD_[]UP, test "x$have_[]m4_defn([DOWN])" = "xyes")
-
-AS_IF([test "x$have_[]m4_defn([DOWN])" = "xyes"], [$2], [$3])
-
-])
-
-dnl Macro that specifies the binary to be used
-
-dnl Usage: EFL_WITH_BIN(binary, package, msg)
-dnl Call AC_SUBST(BINARY_PRG) (BINARY is the uppercase of binary, - being transformed into _)
-dnl Define with_binary (- is transformed into _)
-dnl Define conditional BUILD_BINARY (BINARY is the uppercase of binary, - being transformed into _)
-
-AC_DEFUN([EFL_WITH_BIN],
-[
-
-m4_pushdef([UP], m4_translit([[$1]], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWN], m4_translit([[$1]], [-A-Z], [_a-z]))dnl
-
-AC_REQUIRE([PKG_PROG_PKG_CONFIG])
-AC_MSG_NOTICE([$PKG_CONFIG])
-
-with_[]m4_defn([DOWN])=m4_esyscmd($PKG_CONFIG --variable=prefix $2)/bin/m4_defn([DOWN])
-
-dnl configure option
-
-AC_ARG_WITH([$1],
- [AC_HELP_STRING([--with-$1-bin=PATH], [specify a specific path to ]DOWN)],
- [
- with_[]m4_defn([DOWN])=$withval
- _efl_msg="( explicitely set)"
- ])
-
-AC_MSG_NOTICE([$msg: ]m4_defn([DOWN])[$_efl_msg])
-
-AC_SUBST(with_[]m4_defn([DOWN]))
-
-AS_IF([test "x$have_[]m4_defn([DOWN])" = "xyes"], [$4], [$5])
-
-])
diff --git a/m4/efl_check_funcs.m4 b/m4/efl_check_funcs.m4
deleted file mode 100644
index 3714969..0000000
--- a/m4/efl_check_funcs.m4
+++ /dev/null
@@ -1,435 +0,0 @@
-dnl Copyright (C) 2012 Vincent Torri <vincent dot torri at gmail dot com>
-dnl This code is public domain and can be freely used or copied.
-
-dnl Macros that check functions availability for the EFL:
-
-dnl dirfd
-dnl dladdr
-dnl dlopen
-dnl fnmatch
-dnl iconv
-dnl setxattr (an al.)
-dnl shm_open
-
-
-dnl _EFL_CHECK_FUNC_DIRFD is for internal use
-dnl _EFL_CHECK_FUNC_DIRFD(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_DIRFD],
-[
-AC_LINK_IFELSE(
- [
- AC_LANG_PROGRAM(
- [[
-#ifdef HAVE_DIRENT_H
-# include <dirent.h>
-#endif
- ]],
- [[
-int main(void)
-{
- DIR *dirp;
- return dirfd(dirp);
-}
- ]])
- ],
- [_efl_have_fct="yes"],
- [_efl_have_fct="no"])
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-])
-
-dnl _EFL_CHECK_FUNC_DLADDR_PRIV is for internal use
-dnl _EFL_CHECK_FUNC_DLADDR_PRIV(EFL, LIB, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_DLADDR_PRIV],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-LIBS_save="${LIBS}"
-LIBS="${LIBS} $2"
-AC_LINK_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#define _GNU_SOURCE
-#include <dlfcn.h>
- ]],
- [[
-int res = dladdr(0, 0);
- ]])],
- [
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} $2"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} $2"
- _efl_have_fct="yes"
- ],
- [_efl_have_fct="no"])
-
-LIBS="${LIBS_save}"
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$3], [$4])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_DLADDR is for internal use
-dnl _EFL_CHECK_FUNC_DLADDR(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_DLADDR],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-case "$host_os" in
- mingw*)
- _efl_have_fct="yes"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} -ldl"
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} -ldl"
- ;;
- *)
- _efl_have_fct="no"
-
-dnl Check is dladdr is in libc
- _EFL_CHECK_FUNC_DLADDR_PRIV([$1], [], [_efl_have_fct="yes"], [_efl_have_fct="no"])
-
-dnl Check is dlopen is in libdl
- if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_DLADDR_PRIV([$1], [-ldl], [_efl_have_fct="yes"], [_efl_have_fct="no"])
- fi
- ;;
-esac
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_DLOPEN_PRIV is for internal use
-dnl _EFL_CHECK_FUNC_DLOPEN_PRIV(EFL, LIB, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_DLOPEN_PRIV],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-LIBS_save="${LIBS}"
-LIBS="${LIBS} $2"
-AC_LINK_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#include <dlfcn.h>
- ]],
- [[
-void *h = dlopen(0, 0);
- ]])],
- [
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} $2"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} $2"
- _efl_have_fct="yes"
- ],
- [_efl_have_fct="no"])
-
-LIBS="${LIBS_save}"
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$3], [$4])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_DLOPEN is for internal use
-dnl _EFL_CHECK_FUNC_DLOPEN(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_DLOPEN],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-case "$host_os" in
- mingw*)
- _efl_have_fct="yes"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} -ldl"
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} -ldl"
- ;;
- *)
- _efl_have_fct="no"
-
-dnl Check is dlopen is in libc
- _EFL_CHECK_FUNC_DLOPEN_PRIV([$1], [], [_efl_have_fct="yes"], [_efl_have_fct="no"])
-
-dnl Check is dlopen is in libdl
- if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_DLOPEN_PRIV([$1], [-ldl], [_efl_have_fct="yes"], [_efl_have_fct="no"])
- fi
- ;;
-esac
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_FNMATCH_PRIV is for internal use
-dnl _EFL_CHECK_FUNC_FNMATCH_PRIV(EFL, LIB, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_FNMATCH_PRIV],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-LIBS_save="${LIBS}"
-LIBS="${LIBS} $2"
-AC_LINK_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#include <stdlib.h>
-#include <fnmatch.h>
- ]],
- [[
-int g = fnmatch(NULL, NULL, 0);
- ]])],
- [
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} $2"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} $2"
- _efl_have_fct="yes"
- ],
- [_efl_have_fct="no"])
-
-LIBS="${LIBS_save}"
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$3], [$4])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_FNMATCH is for internal use
-dnl _EFL_CHECK_FUNC_FNMATCH(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_FNMATCH],
-[
-case "$host_os" in
- mingw*)
- _efl_have_fct="yes"
- ;;
- *)
-dnl Check is fnmatch is in libc
- _EFL_CHECK_FUNC_FNMATCH_PRIV([$1], [], [_efl_have_fct="yes"], [_efl_have_fct="no"])
-
-dnl Check is fnmatch is in libfnmatch
- if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_FNMATCH_PRIV([$1], [-lfnmatch], [_efl_have_fct="yes"], [_efl_have_fct="no"])
- fi
-
-dnl Check is fnmatch is in libiberty
- if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_FNMATCH_PRIV([$1], [-liberty], [_efl_have_fct="yes"], [_efl_have_fct="no"])
- fi
- ;;
-esac
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-])
-
-dnl _EFL_CHECK_FUNC_ICONV_PRIV is for internal use
-dnl _EFL_CHECK_FUNC_ICONV_PRIV(EFL, LIB, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_ICONV_PRIV],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-LIBS_save="${LIBS}"
-LIBS="${LIBS} $2"
-AC_LINK_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#include <stdlib.h>
-#include <iconv.h>
- ]],
- [[
-iconv_t ic;
-size_t count = iconv(ic, NULL, NULL, NULL, NULL);
- ]])],
- [
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} $2"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} $2"
- _efl_have_fct="yes"
- ],
- [_efl_have_fct="no"])
-
-LIBS="${LIBS_save}"
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$3], [$4])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_ICONV is for internal use
-dnl _EFL_CHECK_FUNC_ICONV(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_ICONV],
-[
-AC_ARG_WITH([iconv-link],
- AC_HELP_STRING([--with-iconv-link=ICONV_LINK], [explicitly specify an iconv link option]),
- [
- _efl_have_fct="yes"
- iconv_libs=${withval}
- ],
- [_efl_have_fct="no"])
-
-AC_MSG_CHECKING([for explicit iconv link options])
-if test "x${iconv_libs}" = "x" ; then
- AC_MSG_RESULT([no explicit iconv link option])
-else
- AC_MSG_RESULT([${iconv_libs}])
-fi
-
-dnl Check is iconv is in libc
-if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_ICONV_PRIV([$1], [], [_efl_have_fct="yes"], [_efl_have_fct="no"])
-fi
-
-dnl Check is iconv is in libiconv
-if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_ICONV_PRIV([$1], [-liconv], [_efl_have_fct="yes"], [_efl_have_fct="no"])
-fi
-
-dnl Check is iconv is in libiconv_plug
-if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_ICONV_PRIV([$1], [-liconv_plug], [_efl_have_fct="yes"], [_efl_have_fct="no"])
-fi
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-])
-
-dnl _EFL_CHECK_FUNC_SETXATTR is for internal use
-dnl _EFL_CHECK_FUNC_SETXATTR(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_SETXATTR],
-[
-AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#include <stdlib.h>
-#include <sys/types.h>
-#include <sys/xattr.h>
- ]],
- [[
-size_t tmp = listxattr("/", NULL, 0);
-tmp = getxattr("/", "user.ethumb.md5", NULL, 0);
-setxattr("/", "user.ethumb.md5", NULL, 0, 0);
- ]])],
- [_efl_have_fct="yes"],
- [_efl_have_fct="no"])
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-])
-
-dnl _EFL_CHECK_FUNC_SHM_OPEN_PRIV is for internal use
-dnl _EFL_CHECK_FUNC_SHM_OPEN_PRIV(EFL, LIB, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_SHM_OPEN_PRIV],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-LIBS_save="${LIBS}"
-LIBS="${LIBS} $2"
-AC_LINK_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#include <sys/mman.h>
-#include <sys/stat.h> /* For mode constants */
-#include <fcntl.h> /* For O_* constants */
- ]],
- [[
-int fd;
-
-fd = shm_open("/dev/null", O_RDONLY, S_IRWXU | S_IRWXG | S_IRWXO);
- ]])],
- [
- m4_defn([UPEFL])[]_LIBS="$m4_defn([UPEFL])[]_LIBS $2"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} $2"
- _efl_have_fct="yes"
- ],
- [_efl_have_fct="no"])
-
-LIBS="${LIBS_save}"
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$3], [$4])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_FUNC_SHM_OPEN is for internal use
-dnl _EFL_CHECK_FUNC_SHM_OPEN(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_FUNC_SHM_OPEN],
-[
-_efl_have_fct="no"
-
-dnl Check is shm_open is in libc
-_EFL_CHECK_FUNC_SHM_OPEN_PRIV([$1], [],
- [_efl_have_fct="yes"],
- [_efl_have_fct="no"])
-
-dnl Check is shm_open is in librt
-if test "x${_efl_have_fct}" = "xno" ; then
- _EFL_CHECK_FUNC_SHM_OPEN_PRIV([$1], [-lrt],
- [_efl_have_fct="yes"],
- [_efl_have_fct="no"])
-fi
-
-AS_IF([test "x${_efl_have_fct}" = "xyes"], [$2], [$3])
-])
-
-dnl Macro that checks function availability
-dnl
-dnl EFL_CHECK_FUNC(EFL, FUNCTION)
-dnl AC_DEFINE : EFL_HAVE_FUNCTION (FUNCTION being replaced by its value)
-dnl result in efl_func_function (function being replaced by its value)
-
-AC_DEFUN([EFL_CHECK_FUNC],
-[
-m4_pushdef([UP], m4_translit([$2], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWN], m4_translit([$2], [-A-Z], [_a-z]))dnl
-
-m4_default([_EFL_CHECK_FUNC_]m4_defn([UP]))($1, [have_fct="yes"], [have_fct="no"])
-
-if test "x$2" = "xsetxattr" ; then
- AC_MSG_CHECKING([for extended attributes])
-else
- AC_MSG_CHECKING([for ]m4_defn([DOWN]))
-fi
-
-AC_MSG_RESULT([${have_fct}])
-
-if test "x${have_fct}" = "xyes" ; then
- if test "x$2" = "xsetxattr" ; then
- AC_DEFINE([HAVE_XATTR], [1], [Define to 1 if you have the `listxattr', `setxattr' and `getxattr' functions.])
- else
- AC_DEFINE([HAVE_]m4_defn([UP]), [1], [Define to 1 if you have the `]m4_defn([DOWN])[' function.])
- fi
-fi
-
-efl_func_[]m4_defn([DOWN])="${have_fct}"
-
-m4_popdef([DOWN])
-m4_popdef([UP])
-])
-
-dnl Macro that iterates over a sequence of space separated functions
-dnl and that calls EFL_CHECK_FUNC() for each of these functions
-dnl
-dnl EFL_CHECK_FUNCS(EFL, FUNCTIONS)
-
-AC_DEFUN([EFL_CHECK_FUNCS],
-[
-m4_foreach_w([fct], [$2], [EFL_CHECK_FUNC($1, m4_defn([fct]))])
-])
diff --git a/m4/efl_check_libs.m4 b/m4/efl_check_libs.m4
deleted file mode 100644
index b1c3789..0000000
--- a/m4/efl_check_libs.m4
+++ /dev/null
@@ -1,119 +0,0 @@
-dnl Copyright (C) 2012 Vincent Torri <vincent dot torri at gmail dot com>
-dnl This code is public domain and can be freely used or copied.
-
-dnl Macro that check dependencies libraries for the EFL:
-
-dnl libjpeg
-dnl zlib
-
-dnl _EFL_CHECK_LIB_LIBJPEG is for internal use
-dnl _EFL_CHECK_LIB_LIBJPEG(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_LIB_LIBJPEG],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-AC_CHECK_HEADER([jpeglib.h],
- [have_dep="yes"],
- [
- AC_MSG_ERROR(["Cannot find jpeglib.h. Make sure your CFLAGS environment variable contains include lines for the location of this file"])
- have_dep="no"
- ])
-
-if test "x${have_dep}" = "xyes" ; then
- AC_CHECK_LIB([jpeg], [jpeg_std_error],
- [
- have_dep="yes"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} -ljpeg"
- ],
- [
- AC_MSG_ERROR("Cannot find libjpeg library. Make sure your LDFLAGS environment variable contains include lines for the location of this file")
- have_dep="no"
- ])
-fi
-
-AS_IF([test "x${have_dep}" = "xyes"], [$2], [$3])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl _EFL_CHECK_LIB_ZLIB is for internal use
-dnl _EFL_CHECK_LIB_ZLIB(EFL, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
-
-AC_DEFUN([_EFL_CHECK_LIB_ZLIB],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWNEFL], m4_translit([$1], [-A-Z], [_a-z]))dnl
-
-PKG_CHECK_EXISTS([zlib],
- [
- _efl_have_lib="yes"
- requirements_pc_[]m4_defn([DOWNEFL])="${requirements_pc_[]m4_defn([DOWNEFL])} zlib"
- ],
- [
- _efl_have_lib="no"
- ])
-
-if test "x${_efl_have_lib}" = "xno" ; then
- AC_CHECK_HEADER([zlib.h],
- [_efl_have_lib="yes"],
- [
- AC_MSG_ERROR(["Cannot find zlib.h. Make sure your CFLAGS environment variable contains include lines for the location of this file"])
- _efl_have_lib="no"
- ])
-
- if test "x${_efl_have_lib}" = "xyes" ; then
- AC_CHECK_LIB([z], [zlibVersion],
- [
- _efl_have_lib="yes"
- requirements_libs_[]m4_defn([DOWNEFL])="${requirements_libs_[]m4_defn([DOWNEFL])} -lz"
- ],
- [
- AC_MSG_ERROR(["Cannot find libjpeg library. Make sure your LDFLAGS environment variable contains include lines for the location of this file"])
- _efl_have_lib="no"
- ])
- fi
-fi
-
-AS_IF([test "x${_efl_have_lib}" = "xyes"], [$2], [$3])
-
-m4_popdef([DOWNEFL])
-m4_popdef([UPEFL])
-])
-
-dnl Macro that checks for a library
-dnl
-dnl EFL_CHECK_LIB(EFL, LIBRARY)
-dnl AC_DEFINE : EFL_HAVE_LIBRARY (LIBRARY being replaced by its value)
-
-AC_DEFUN([EFL_CHECK_LIB],
-[
-m4_pushdef([UP], m4_translit([$2], [-a-z], [_A-Z]))dnl
-m4_pushdef([DOWN], m4_translit([$2], [-A-Z], [_a-z]))dnl
-
-m4_default([_EFL_CHECK_LIB_]m4_defn([UP]))($1, [have_lib="yes"], [have_lib="no"])
-
-AC_MSG_CHECKING([for ]m4_defn([DOWN]))
-AC_MSG_RESULT([${have_lib}])
-
-if test "x${have_lib}" = "xyes" ; then
- AC_DEFINE([HAVE_]m4_defn([UP]), [1], [Define to 1 if the `]m4_defn([DOWN])[' library is installed.])
-fi
-
-efl_lib_[]m4_defn([DOWN])="${have_lib}"
-
-m4_popdef([DOWN])
-m4_popdef([UP])
-])
-
-dnl Macro that iterates over a sequence of white separated libraries
-dnl and that calls EFL_CHECK_LIB() for each of these libraries
-dnl
-dnl EFL_CHECK_LIBS(EFL, LIBRARIES)
-
-AC_DEFUN([EFL_CHECK_LIBS],
-[
-m4_foreach_w([lib], [$2], [EFL_CHECK_LIB($1, m4_defn([lib]))])
-])
diff --git a/m4/efl_compiler_flag.m4 b/m4/efl_compiler_flag.m4
deleted file mode 100644
index 618c6a6..0000000
--- a/m4/efl_compiler_flag.m4
+++ /dev/null
@@ -1,57 +0,0 @@
-dnl Copyright (C) 2010 Vincent Torri <vtorri at univ-evry dot fr>
-dnl and Albin Tonnerre <albin dot tonnerre at gmail dot com>
-dnl That code is public domain and can be freely used or copied.
-
-dnl Macro that checks if a compiler flag is supported by the compiler.
-
-dnl Usage: EFL_COMPILER_FLAG(flag)
-dnl flag is added to CFLAGS if supported.
-
-AC_DEFUN([EFL_COMPILER_FLAG],
-[
-
-CFLAGS_save="${CFLAGS}"
-CFLAGS="${CFLAGS} $1"
-
-AC_LANG_PUSH([C])
-AC_MSG_CHECKING([whether the compiler supports $1])
-
-AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM([[]])],
- [have_flag="yes"],
- [have_flag="no"])
-AC_MSG_RESULT([${have_flag}])
-
-if test "x${have_flag}" = "xno" ; then
- CFLAGS="${CFLAGS_save}"
-fi
-AC_LANG_POP([C])
-
-])
-
-dnl Macro that checks if a linker flag is supported by the compiler.
-
-dnl Usage: EFL_LINKER_FLAG(flag)
-dnl flag is added to CFLAGS if supported (will be passed to ld anyway).
-
-AC_DEFUN([EFL_LINKER_FLAG],
-[
-
-CFLAGS_save="${CFLAGS}"
-CFLAGS="${CFLAGS} $1"
-
-AC_LANG_PUSH([C])
-AC_MSG_CHECKING([whether the compiler supports $1])
-
-AC_LINK_IFELSE(
- [AC_LANG_PROGRAM([[]])],
- [have_flag="yes"],
- [have_flag="no"])
-AC_MSG_RESULT([${have_flag}])
-
-if test "x${have_flag}" = "xno" ; then
- CFLAGS="${CFLAGS_save}"
-fi
-AC_LANG_POP([C])
-
-])
diff --git a/m4/efl_doxygen.m4 b/m4/efl_doxygen.m4
deleted file mode 100644
index 7324af3..0000000
--- a/m4/efl_doxygen.m4
+++ /dev/null
@@ -1,94 +0,0 @@
-dnl Copyright (C) 2008 Vincent Torri <vtorri at univ-evry dot fr>
-dnl That code is public domain and can be freely used or copied.
-
-dnl Macro that check if doxygen is available or not.
-
-dnl EFL_CHECK_DOXYGEN([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
-dnl Test for the doxygen program
-dnl Defines efl_doxygen
-dnl Defines the automake conditionnal EFL_BUILD_DOC
-dnl
-AC_DEFUN([EFL_CHECK_DOXYGEN],
-[
-
-dnl
-dnl Disable the build of the documentation
-dnl
-AC_ARG_ENABLE([doc],
- [AC_HELP_STRING(
- [--disable-doc],
- [Disable documentation build @<:@default=enabled@:>@])],
- [
- if test "x${enableval}" = "xyes" ; then
- efl_enable_doc="yes"
- else
- efl_enable_doc="no"
- fi
- ],
- [efl_enable_doc="yes"])
-
-AC_MSG_CHECKING([whether to build documentation])
-AC_MSG_RESULT([${efl_enable_doc}])
-
-if test "x${efl_enable_doc}" = "xyes" ; then
-
-dnl Specify the file name, without path
-
- efl_doxygen="doxygen"
-
- AC_ARG_WITH([doxygen],
- [AC_HELP_STRING(
- [--with-doxygen=FILE],
- [doxygen program to use @<:@default=doxygen@:>@])],
-
-dnl Check the given doxygen program.
-
- [efl_doxygen=${withval}
- AC_CHECK_PROG([efl_have_doxygen],
- [${efl_doxygen}],
- [yes],
- [no])
- if test "x${efl_have_doxygen}" = "xno" ; then
- echo "WARNING:"
- echo "The doxygen program you specified:"
- echo "${efl_doxygen}"
- echo "was not found. Please check the path and make sure "
- echo "the program exists and is executable."
- AC_MSG_WARN([no doxygen detected. Documentation will not be built])
- fi
- ],
- [AC_CHECK_PROG([efl_have_doxygen],
- [${efl_doxygen}],
- [yes],
- [no])
- if test "x${efl_have_doxygen}" = "xno" ; then
- echo "WARNING:"
- echo "The doxygen program was not found in your execute path."
- echo "You may have doxygen installed somewhere not covered by your path."
- echo ""
- echo "If this is the case make sure you have the packages installed, AND"
- echo "that the doxygen program is in your execute path (see your"
- echo "shell manual page on setting the \$PATH environment variable), OR"
- echo "alternatively, specify the program to use with --with-doxygen."
- AC_MSG_WARN([no doxygen detected. Documentation will not be built])
- fi
- ])
-else
- efl_have_doxygen="no"
-fi
-
-dnl
-dnl Substitution
-dnl
-AC_SUBST([efl_doxygen])
-
-if ! test "x${efl_have_doxygen}" = "xyes" ; then
- efl_enable_doc="no"
-fi
-
-AM_CONDITIONAL(EFL_BUILD_DOC, test "x${efl_have_doxygen}" = "xyes")
-
-AS_IF([test "x$efl_have_doxygen" = "xyes"], [$1], [$2])
-])
-
-dnl End of efl_doxygen.m4
diff --git a/m4/efl_path_max.m4 b/m4/efl_path_max.m4
deleted file mode 100644
index f57bfd2..0000000
--- a/m4/efl_path_max.m4
+++ /dev/null
@@ -1,36 +0,0 @@
-dnl Check for PATH_MAX in limits.h, and define a default value if not found
-dnl This is a workaround for systems not providing PATH_MAX, like GNU/Hurd
-
-dnl EFL_CHECK_PATH_MAX([DEFAULT_VALUE_IF_NOT_FOUND])
-dnl
-dnl If PATH_MAX is not defined in <limits.h>, defines it
-dnl to DEFAULT_VALUE_IF_NOT_FOUND if it exists, or fallback
-dnl to using 4096
-
-AC_DEFUN([EFL_CHECK_PATH_MAX],
-[
-
-default_max=m4_default([$1], "4096")
-AC_LANG_PUSH([C])
-
-AC_MSG_CHECKING([for PATH_MAX in limits.h])
-AC_COMPILE_IFELSE(
- [AC_LANG_PROGRAM(
- [[
-#include <limits.h>
- ]],
- [[
-int i = PATH_MAX;
- ]])],
- [AC_MSG_RESULT([yes])],
- [
- AC_DEFINE_UNQUOTED([PATH_MAX],
- [${default_max}],
- [default value since PATH_MAX is not defined])
- AC_MSG_RESULT([no: using ${default_max}])
- ])
-
-AC_LANG_POP([C])
-
-])
-dnl end of efl_path_max.m4
diff --git a/m4/efl_tests.m4 b/m4/efl_tests.m4
deleted file mode 100644
index d8554e1..0000000
--- a/m4/efl_tests.m4
+++ /dev/null
@@ -1,65 +0,0 @@
-dnl Copyright (C) 2008-2012 Vincent Torri <vtorri at univ-evry dot fr>
-dnl That code is public domain and can be freely used or copied.
-
-dnl Macro that check if tests programs are wanted and if yes, if
-dnl the Check library is available.
-dnl the lcov program is available.
-
-dnl Usage: EFL_CHECK_TESTS(EFL[, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]])
-dnl Define the automake conditionnal EFL_ENABLE_TESTS
-
-AC_DEFUN([EFL_CHECK_TESTS],
-[
-m4_pushdef([UPEFL], m4_translit([$1], [-a-z], [_A-Z]))dnl
-
-dnl configure option
-
-AC_ARG_ENABLE([tests],
- [AC_HELP_STRING([--enable-tests], [enable tests @<:@default=disabled@:>@])],
- [
- if test "x${enableval}" = "xyes" ; then
- _efl_enable_tests="yes"
- else
- _efl_enable_tests="no"
- fi
- ],
- [_efl_enable_tests="no"])
-
-AC_MSG_CHECKING([whether tests are built])
-AC_MSG_RESULT([${_efl_enable_tests}])
-
-AC_REQUIRE([PKG_PROG_PKG_CONFIG])
-
-if test "x${_efl_enable_tests}" = "xyes" ; then
- PKG_CHECK_MODULES([CHECK],
- [check >= 0.9.5],
- [dummy="yes"],
- [_efl_enable_tests="no"])
-fi
-
-efl_enable_coverage="no"
-if test "x${_efl_enable_tests}" = "xyes" ; then
- AC_CHECK_PROG(have_lcov, [lcov], [yes], [no])
- if test "x$have_lcov" = "xyes" ; then
- m4_defn([UPEFL])[]_CFLAGS="${m4_defn([UPEFL])[]_CFLAGS} -fprofile-arcs -ftest-coverage"
- m4_defn([UPEFL])[]_LIBS="${m4_defn([UPEFL])[]_LIBS} -lgcov"
-# remove any optimisation flag and force debug symbols
- if test "x${prefer_assert}" = "xno"; then
- m4_defn([UPEFL])[]_CFLAGS="${m4_defn([UPEFL])[]_CFLAGS} -DNDEBUG"
- else
- m4_defn([UPEFL])[]_CFLAGS="${m4_defn([UPEFL])[]_CFLAGS} -g -O0 -DDEBUG"
- fi
- efl_enable_coverage="yes"
- else
- AC_MSG_WARN([lcov is not found, disable profiling instrumentation])
- fi
-fi
-
-AM_CONDITIONAL(EFL_ENABLE_TESTS, test "x${_efl_enable_tests}" = "xyes")
-
-AS_IF([test "x$_efl_enable_tests" = "xyes"], [$2], [$3])
-
-m4_popdef([UPEFL])
-])
-
-dnl End of efl_tests.m4