summaryrefslogtreecommitdiff
path: root/src/Makefile_Ecore_Cxx.am
diff options
context:
space:
mode:
authorSavio Sena <savio@expertisesolutions.com.br>2014-05-03 00:55:51 +0200
committerCedric Bail <cedric.bail@free.fr>2014-05-03 00:56:32 +0200
commit46b6e8a563bd429690e7bffba4e98d06aa40798d (patch)
treeb7a2aebfc32bcc6d7a2600072a00d69a9f68d9a1 /src/Makefile_Ecore_Cxx.am
parent64c6c63725d96f03baf34b660ca71e13b29078c1 (diff)
eolian_cxx: initial version of the EFL C++ Bindings Generator.
Summary: This patch adds 'eolian_cxx' -- a C++ bindings generator -- to the EFL tree. Eolian Cxx uses Eolian API to read .eo files and generate .eo.hh. It relies/depends on Eo Cxx and Eina Cxx (both non-generated bindings). src/bin/eolian_cxx: The eolian_cxx program. src/lib/eolian_cxx: A header-only library that implements the C++ code generation that binds the .eo classes. =Examples= src/examples/eolian_cxx/eolian_cxx_simple_01.cc: The simplest example, it just uses some "dummy" generated C++ classes. src/examples/eolian_cxx/eolian_cxx_inherit_01.cc: Illustrates how pure C++ classes inherit from .eo generated classes. src/examples/evas/evas_cxx_rectangle.cc: More realistic example using the generated bindings Evas Cxx. Still a bit shallow because we don't have full fledged .eo descriptions yet, but will be improved. =Important= The generated code is not supported and not a stable API/ABI. It is here to gather people interest and get review before we set things in stone for release 1.11. @feature Reviewers: cedric, smohanty, raster, stefan_schmidt CC: felipealmeida, JackDanielZ, cedric, stefan Differential Revision: https://phab.enlightenment.org/D805 Signed-off-by: Cedric Bail <cedric.bail@free.fr>
Diffstat (limited to 'src/Makefile_Ecore_Cxx.am')
-rw-r--r--src/Makefile_Ecore_Cxx.am48
1 files changed, 43 insertions, 5 deletions
diff --git a/src/Makefile_Ecore_Cxx.am b/src/Makefile_Ecore_Cxx.am
index ff8efdca86..ec2b64a4c2 100644
--- a/src/Makefile_Ecore_Cxx.am
+++ b/src/Makefile_Ecore_Cxx.am
@@ -1,17 +1,43 @@
1 1
2### Library 2### Library
3 3
4installed_ecorecxxmainheadersdir = $(includedir)/ecore_cxx-@VMAJ@ 4installed_ecorecxxmainheadersdir = $(includedir)/ecore-cxx-@VMAJ@
5dist_installed_ecorecxxmainheaders_DATA = \ 5dist_installed_ecorecxxmainheaders_DATA = bindings/ecore_cxx/Ecore.hh
6bindings/ecore_cxx/Ecore.hh 6
7if HAVE_CXX11
8
9generated_ecore_cxx_bindings = \
10lib/ecore/ecore_poll.eo.hh \
11lib/ecore/ecore_job.eo.hh \
12lib/ecore/ecore_idler.eo.hh \
13lib/ecore/ecore_idle_exiter.eo.hh \
14lib/ecore/ecore_animator.eo.hh \
15lib/ecore/ecore_parent.eo.hh
16
17BUILT_SOURCES += \
18lib/ecore/Ecore.eo.hh \
19$(generated_ecore_cxx_bindings)
20
21installed_ecorecxxheadersdir = $(includedir)/ecore-cxx-@VMAJ@
22dist_installed_ecorecxxheaders_DATA = \
23lib/ecore/Ecore.eo.hh \
24$(generated_ecore_cxx_bindings)
25
26lib/ecore/Ecore.eo.hh:
27 @echo -e "#ifndef EFL_CXX_ECORE_HH\n#define EFL_CXX_ECORE_HH\n" > $(top_builddir)/src/lib/ecore/Ecore.eo.hh
28 @echo -e "#ifdef EFL_BETA_API_SUPPORT" >> $(top_builddir)/src/lib/ecore/Ecore.eo.hh
29 @for i in $(generated_ecore_cxx_bindings); do echo "#include <$$(basename $$i)>" >> $(top_builddir)/src/lib/ecore/Ecore.eo.hh; done
30 @echo -e "#endif\n\n#endif\n" >> $(top_builddir)/src/lib/ecore/Ecore.eo.hh
31
32endif
7 33
8### Unit tests 34### Unit tests
9 35
10if EFL_ENABLE_TESTS 36if EFL_ENABLE_TESTS
11if HAVE_CXX11 37if HAVE_CXX11
12 38
13check_PROGRAMS += tests/ecore_cxx/ecore_cxx_suite 39check_PROGRAMS += tests/ecore_cxx/ecore_cxx_suite tests/ecore_cxx/cxx_compile_test
14TESTS += tests/ecore_cxx/ecore_cxx_suite 40TESTS += tests/ecore_cxx/ecore_cxx_suite tests/ecore_cxx/cxx_compile_test
15 41
16tests_ecore_cxx_ecore_cxx_suite_SOURCES = \ 42tests_ecore_cxx_ecore_cxx_suite_SOURCES = \
17tests/ecore_cxx/ecore_cxx_suite.cc \ 43tests/ecore_cxx/ecore_cxx_suite.cc \
@@ -20,6 +46,7 @@ tests/ecore_cxx/ecore_cxx_test_safe_call.cc
20tests_ecore_cxx_ecore_cxx_suite_CPPFLAGS = -I$(top_builddir)/src/lib/efl \ 46tests_ecore_cxx_ecore_cxx_suite_CPPFLAGS = -I$(top_builddir)/src/lib/efl \
21-I$(top_srcdir)/src/bindings/ecore_cxx \ 47-I$(top_srcdir)/src/bindings/ecore_cxx \
22-I$(top_srcdir)/src/bindings/eina_cxx \ 48-I$(top_srcdir)/src/bindings/eina_cxx \
49-I$(top_srcdir)/src/bindings/eo_cxx \
23-DTESTS_SRC_DIR=\"$(top_srcdir)/src/tests/ecore_cxx\" \ 50-DTESTS_SRC_DIR=\"$(top_srcdir)/src/tests/ecore_cxx\" \
24-DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/ecore_cxx\" \ 51-DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/ecore_cxx\" \
25@CHECK_CFLAGS@ \ 52@CHECK_CFLAGS@ \
@@ -32,5 +59,16 @@ tests_ecore_cxx_ecore_cxx_suite_LDADD = \
32tests_ecore_cxx_ecore_cxx_suite_DEPENDENCIES = \ 59tests_ecore_cxx_ecore_cxx_suite_DEPENDENCIES = \
33@USE_ECORE_INTERNAL_LIBS@ 60@USE_ECORE_INTERNAL_LIBS@
34 61
62tests_ecore_cxx_cxx_compile_test_SOURCES = tests/ecore_cxx/cxx_compile_test.cc
63tests_ecore_cxx_cxx_compile_test_CPPFLAGS = -I$(top_builddir)/src/lib/efl -I$(top_builddir)/src/lib/efl \
64-I$(top_srcdir)/src/bindings/ecore_cxx \
65-I$(top_srcdir)/src/bindings/eina_cxx \
66-I$(top_srcdir)/src/bindings/eo_cxx \
67-DTESTS_SRC_DIR=\"$(top_srcdir)/src/tests/ecore_cxx\" \
68-DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/ecore_cxx\" \
69@CHECK_CFLAGS@ @ECORE_CFLAGS@ @EINA_CFLAGS@
70tests_ecore_cxx_cxx_compile_test_LDADD = @CHECK_LIBS@ @USE_ECORE_LIBS@
71tests_ecore_cxx_cxx_compile_test_DEPENDENCIES = @USE_ECORE_INTERNAL_LIBS@
72
35endif 73endif
36endif 74endif