summaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorGustavo Sverzut Barbieri <barbieri@gmail.com>2012-12-07 17:18:17 +0000
committerGustavo Sverzut Barbieri <barbieri@gmail.com>2012-12-07 17:18:17 +0000
commit892c64297ece6c9f1ef1bbb8cdd0355de69133ec (patch)
treedf933358ff4cdf5ca9491c8acf9f1e8a9b9b9c59 /m4
parent65507985183367fc2376daddaa366630fae81431 (diff)
efl: begin (still partial!) to make an uniform choice of engines ecore/evas
still lots to do, but some improvements: - ecore_evas does not inherit pkg-config from modules since modules are SO - renamed internal ecore evas define from SOFTWARE_BUFFER to BUFFER, to make consistent. SVN revision: 80473
Diffstat (limited to 'm4')
-rw-r--r--m4/ecore_check_module.m424
-rw-r--r--m4/evas_check_engine.m4120
2 files changed, 73 insertions, 71 deletions
diff --git a/m4/ecore_check_module.m4 b/m4/ecore_check_module.m4
index 8d0d76b..2ceda79 100644
--- a/m4/ecore_check_module.m4
+++ b/m4/ecore_check_module.m4
@@ -48,6 +48,30 @@ m4_popdef([UP])
48m4_popdef([DOWN]) 48m4_popdef([DOWN])
49]) 49])
50 50
51dnl use: ECORE_EVAS_MODULE(name, want, [DEPENDENCY-CHECK-CODE])
52AC_DEFUN([ECORE_EVAS_MODULE],
53[
54m4_pushdef([UP], m4_translit([[$1]], [-a-z], [_A-Z]))dnl
55m4_pushdef([DOWN], m4_translit([[$1]], [-A-Z], [_a-z]))dnl
56
57have_ecore_evas_[]m4_defn([DOWN])="no"
58want_module="$2"
59
60if test "x$have_ecore_evas" = "xyes"; then
61 if test "x$want_module" = "xyes" || test "x$want_module" = "xstatic"; then
62 $3
63
64 AC_DEFINE([BUILD_ECORE_EVAS_]m4_defn([UP]), [1], [Support for $1 Engine in Ecore_Evas])
65 have_ecore_evas_[]m4_defn([DOWN])="yes"
66 fi
67fi
68
69AM_CONDITIONAL([BUILD_ECORE_EVAS_]UP, [test "x$have_ecore_evas_]m4_defn([DOWN])[" = "xyes"])
70
71m4_popdef([UP])
72m4_popdef([DOWN])
73])
74
51dnl use: ECORE_EVAS_CHECK_MODULE_FULL(foo-bar, evas-module, want, description, backend[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]) 75dnl use: ECORE_EVAS_CHECK_MODULE_FULL(foo-bar, evas-module, want, description, backend[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
52AC_DEFUN([ECORE_EVAS_CHECK_MODULE_FULL], 76AC_DEFUN([ECORE_EVAS_CHECK_MODULE_FULL],
53[ 77[
diff --git a/m4/evas_check_engine.m4 b/m4/evas_check_engine.m4
index 7362377..4a654c5 100644
--- a/m4/evas_check_engine.m4
+++ b/m4/evas_check_engine.m4
@@ -1,20 +1,4 @@
1 1
2dnl use: EVAS_CHECK_ENGINE_DEP_BUFFER(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
3
4AC_DEFUN([EVAS_CHECK_ENGINE_DEP_BUFFER],
5[
6
7have_dep="yes"
8evas_engine_[]$1[]_cflags=""
9evas_engine_[]$1[]_libs=""
10
11AC_SUBST([evas_engine_$1_cflags])
12AC_SUBST([evas_engine_$1_libs])
13
14AS_IF([test "x${have_dep}" = "xyes"], [$4], [$5])
15
16])
17
18dnl use: EVAS_CHECK_ENGINE_DEP_SOFTWARE_XLIB(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]) 2dnl use: EVAS_CHECK_ENGINE_DEP_SOFTWARE_XLIB(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
19 3
20AC_DEFUN([EVAS_CHECK_ENGINE_DEP_SOFTWARE_XLIB], 4AC_DEFUN([EVAS_CHECK_ENGINE_DEP_SOFTWARE_XLIB],
@@ -581,60 +565,6 @@ AS_IF([test "x${have_dep}" = "xyes"], [$4], [$5])
581 565
582]) 566])
583 567
584dnl use: EVAS_CHECK_ENGINE_DEP_FB(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
585
586AC_DEFUN([EVAS_CHECK_ENGINE_DEP_FB],
587[
588
589have_dep="no"
590evas_engine_[]$1[]_cflags=""
591evas_engine_[]$1[]_libs=""
592
593AC_CHECK_HEADER([linux/fb.h], [have_dep="yes"])
594
595AC_SUBST([evas_engine_$1_cflags])
596AC_SUBST([evas_engine_$1_libs])
597
598AS_IF([test "x${have_dep}" = "xyes"], [$4], [$5])
599
600])
601
602
603dnl use: EVAS_CHECK_ENGINE_DEP_PSL1GHT(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
604
605AC_DEFUN([EVAS_CHECK_ENGINE_DEP_PSL1GHT],
606[
607
608have_dep="no"
609evas_engine_[]$1[]_cflags=""
610evas_engine_[]$1[]_libs=""
611
612AC_CHECK_HEADER([rsx/rsx.h], [have_dep="yes"])
613
614AC_SUBST([evas_engine_$1_cflags])
615AC_SUBST([evas_engine_$1_libs])
616
617AS_IF([test "x${have_dep}" = "xyes"], [$4], [$5])
618
619])
620
621
622dnl use: EVAS_CHECK_ENGINE_DEP_WAYLAND_SHM(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
623
624AC_DEFUN([EVAS_CHECK_ENGINE_DEP_WAYLAND_SHM],
625[
626
627have_dep="yes"
628evas_engine_[]$1[]_cflags=""
629evas_engine_[]$1[]_libs=""
630
631AC_SUBST([evas_engine_$1_cflags])
632AC_SUBST([evas_engine_$1_libs])
633
634AS_IF([test "x${have_dep}" = "xyes"], [$4], [$5])
635
636])
637
638 568
639dnl use: EVAS_CHECK_ENGINE_DEP_WAYLAND_EGL(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]]) 569dnl use: EVAS_CHECK_ENGINE_DEP_WAYLAND_EGL(engine, simple, want_static[, ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
640 570
@@ -678,9 +608,57 @@ AS_IF([test "x${have_dep}" = "xyes"], [$4], [$5])
678]) 608])
679 609
680 610
681dnl use: EVAS_CHECK_ENGINE(engine, want_engine, simple, description) 611dnl use: EVAS_ENGINE(name, want_engine, [DEPENDENCY-CHECK-CODE])
612dnl
613dnl defines BUILD_ENGINE_NAME if it should be built
614dnl defines BUILD_STATIC_BUILD_NAME if should be built statically
615dnl
616dnl will call DEPENDENCY-CHECK-CODE if it should be built,
617dnl if some dependency fail just call AC_MSG_ERROR() to abort.
682 618
619AC_DEFUN([EVAS_ENGINE],
620[
621m4_pushdef([UP], m4_translit([$1], [-a-z], [_A-Z]))dnl
622m4_pushdef([DOWN], m4_translit([$1], [-A-Z], [_a-z]))dnl
683 623
624want_engine="$2"
625want_static_engine="no"
626have_engine="no"
627have_evas_engine_[]DOWN="no"
628
629evas_engine_[]m4_defn([DOWN])[]_cflags=""
630evas_engine_[]m4_defn([DOWN])[]_libs=""
631
632if test "x${want_engine}" = "xyes" -o "x${want_engine}" = "xstatic"; then
633 $3
634
635 have_engine="yes"
636 if test "x${want_engine}" = "xstatic" ; then
637 have_evas_engine_[]DOWN="static"
638 want_static_engine="yes"
639 else
640 have_evas_engine_[]DOWN="yes"
641 fi
642fi
643
644AC_DEFINE_IF(BUILD_ENGINE_[]UP, [test "${have_engine}" = "yes"],
645 [1], [Build $1 Evas engine])
646AM_CONDITIONAL(BUILD_ENGINE_[]UP, [test "${have_engine}" = "yes"])
647
648AC_DEFINE_IF(EVAS_STATIC_BUILD_[]UP, [test "${want_static_engine}" = "yes"],
649 [1], [Build $1 Evas engine inside libevas])
650AM_CONDITIONAL(EVAS_STATIC_BUILD_[]UP, [test "${want_static_engine}" = "yes"])
651
652AC_SUBST([evas_engine_]m4_defn([DOWN])[_cflags])
653AC_SUBST([evas_engine_]m4_defn([DOWN])[_libs])
654
655m4_popdef([UP])
656m4_popdef([DOWN])
657])
658
659
660
661dnl use: EVAS_CHECK_ENGINE(engine, want_engine, simple, description)
684AC_DEFUN([EVAS_CHECK_ENGINE], 662AC_DEFUN([EVAS_CHECK_ENGINE],
685[ 663[
686 664