aboutsummaryrefslogtreecommitdiffstats
path: root/src/Makefile_Eolian_Js.am
blob: 7e4e760e250a5a64b8fa99a29184856becce7a9b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138

if HAVE_JS

### Binary
bin_PROGRAMS += bin/eolian_js/eolian_js

bin_eolian_js_eolian_js_SOURCES = \
    bin/eolian_js/main.cc

bin_eolian_js_eolian_js_CPPFLAGS = -I$(top_builddir)/src/lib/efl \
-I$(top_srcdir)/src/bin/eolian_js \
-I$(top_srcdir)/src/bindings/js/eina_js \
-I$(top_srcdir)/src/bindings/js/eo_js \
@EOLIAN_JS_CFLAGS@ \
@EINA_CXX_CFLAGS@ \
@EO_CXX_CFLAGS@ \
@EFL_CFLAGS@ \
@ECORE_CXX_CFLAGS@ \
@EOLIAN_CXX_CFLAGS@

bin_eolian_js_eolian_js_LDADD = @USE_EO_LIBS@ @USE_EOLIAN_LIBS@
bin_eolian_js_eolian_js_DEPENDENCIES = @USE_EO_INTERNAL_LIBS@ @USE_EOLIAN_INTERNAL_LIBS@

# generate C++ bindings before compiling C++ files for JS binding
if HAVE_AM_16
bin/eolian_js/eolian_js-main.$(OBJEXT): $(efl_eolian_cxx_hh) $(efl_eolian_cxx_impl_hh)
else
bin/eolian_js/bin_eolian_js_eolian_js-main.$(OBJEXT): $(efl_eolian_cxx_hh) $(efl_eolian_cxx_impl_hh)
endif
include Makefile_Eolian_Js_Helper.am

### Unit tests

if EFL_ENABLE_TESTS
if HAVE_NODEJS

TESTS += tests/eolian_js/eolian_js_suite.sh

check_LTLIBRARIES += tests/eolian_js/libeolian_js_suite.la

tests/eolian_js/eolian_js_suite.sh: tests/eolian_js/eolian_js_suite_mod.node
tests/eolian_js/eolian_js_suite_mod.node: tests/eolian_js/libeolian_js_suite.la
	$(AM_V_CP)$(CP) $(top_builddir)/src/tests/eolian_js/.libs/libeolian_js_suite.so $(top_builddir)/src/tests/eolian_js/eolian_js_suite_mod.node

tests_eolian_js_libeolian_js_suite_la_SOURCES = \
tests/eolian_js/eolian_js_suite.cc \
tests/eolian_js/eolian_js_test_eolian_js_binding.cc \
tests/eolian_js/eolian_js_test_constructor_method_impl.c \
tests/eolian_js/eolian_js_test_test_object_impl.c

tests_eolian_js_libeolian_js_suite_la_CPPFLAGS = \
-I$(top_builddir)/src/lib/efl \
-I$(top_srcdir)/src/bin/eolian_js \
-I$(top_srcdir)/src/bindings/js/eina_js \
-I$(top_srcdir)/src/bindings/js/eo_js \
-I$(top_builddir)/src/tests/eolian_js \
-DTESTS_WD=\"`pwd`\" \
-DTESTS_SRC_DIR=\"$(top_srcdir)/src/tests/eolian_js\" \
-DPACKAGE_BUILD_DIR=\"$(abs_top_builddir)/src/tests/eolian_js\" \
-DPACKAGE_DATA_DIR=\"$(datadir)/eolian_js\" \
-DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/eolian_js\" \
@CHECK_CFLAGS@ @EOLIAN_CXX_CFLAGS@ @EINA_JS_CFLAGS@ @EO_JS_CFLAGS@ \
@EOLIAN_CFLAGS@ @EINA_CFLAGS@ @EO_CFLAGS@ @ECORE_CFLAGS@ @EINA_CXX_CFLAGS@ \
@EO_JS_CFLAGS@ @EO_CXX_CFLAGS@ @ECORE_CXX_CFLAGS@
tests_eolian_js_libeolian_js_suite_la_LIBADD = \
HECK_LIBS@ @USE_EO_LIBS@ @USE_EINA_LIBS@ @USE_EOLIAN_LIBS@ bindings/js/efl_js/libefl_js.la
tests_eolian_js_libeolian_js_suite_la_DEPENDENCIES = @USE_EINA_INTERNAL_LIBS@ @USE_EO_INTERNAL_LIBS@ 
tests_eolian_js_libeolian_js_suite_la_CFLAGS = $(tests_eolian_js_libeolian_js_suite_la_CXXFLAGS)
tests_eolian_js_libeolian_js_suite_la_LIBTOOLFLAGS = --tag=disable-static
tests_eolian_js_libeolian_js_suite_la_LDFLAGS = -rpath $(abs_top_builddir)/src/tests/eolian_js -rpath $(abs_top_builddir)/src/bin/efl_js @EFL_LTLIBRARY_FLAGS@

# if compiler_o_lo == yes, lo, otherwise $(OBJEXT)

if HAVE_AM_16
TESTS_EOLIAN_JS_OBJNAME = 
else
TESTS_EOLIAN_JS_OBJNAME = tests_eolian_js_
endif
tests/eolian_js/$(TESTS_EOLIAN_JS_OBJNAME)libeolian_js_suite_la-eolian_js_test_eolian_js_binding.l$(OBJEXT): tests/eolian_js/constructor_method_class.eo.js.cc tests/eolian_js/constructor_method_class.eo.h tests/eolian_js/test_object.eo.js.cc tests/eolian_js/test_object.eo.h
tests/eolian_js/$(TESTS_EOLIAN_JS_OBJNAME)libeolian_js_suite_la-eolian_js_test_constructor_method_impl.l$(OBJEXT): tests/eolian_js/constructor_method_class.eo.c
tests/eolian_js/$(TESTS_EOLIAN_JS_OBJNAME)libeolian_js_suite_la-eolian_js_test_test_object_impl.l$(OBJEXT): tests/eolian_js/test_object.eo.c


CLEANFILES += \
tests/eolian_js/constructor_method_class.eo.js.cc \
tests/eolian_js/constructor_method_class.eo.c \
tests/eolian_js/constructor_method_class.eo.h \
tests/eolian_js/test_object.eo.js.cc \
tests/eolian_js/test_object.eo.c \
tests/eolian_js/test_object.eo.h
else
check_PROGRAMS += tests/eolian_js/eolian_js_suite
TESTS += tests/eolian_js/eolian_js_suite

tests_eolian_js_eolian_js_suite_SOURCES = \
tests/eolian_js/eolian_js_suite.cc \
tests/eolian_js/eolian_js_test_eolian_js_binding.cc \
tests/eolian_js/eolian_js_test_constructor_method_impl.c \
tests/eolian_js/eolian_js_test_test_object_impl.c

tests/eolian_js/$(TESTS_EOLIAN_JS_OBJNAME)eolian_js_suite-eolian_js_test_eolian_js_binding.$(OBJEXT): tests/eolian_js/constructor_method_class.eo.js.cc tests/eolian_js/constructor_method_class.eo.h tests/eolian_js/test_object.eo.js.cc tests/eolian_js/test_object.eo.h
tests/eolian_js/$(TESTS_EOLIAN_JS_OBJNAME)eolian_js_suite-eolian_js_test_constructor_method_impl.$(OBJEXT): tests/eolian_js/constructor_method_class.eo.c
tests/eolian_js/$(TESTS_EOLIAN_JS_OBJNAME)eolian_js_suite-eolian_js_test_test_object_impl.$(OBJEXT): tests/eolian_js/test_object.eo.c

CLEANFILES += \
tests/eolian_js/constructor_method_class.eo.js.cc \
tests/eolian_js/constructor_method_class.eo.c \
tests/eolian_js/constructor_method_class.eo.h \
tests/eolian_js/test_object.eo.js.cc \
tests/eolian_js/test_object.eo.c \
tests/eolian_js/test_object.eo.h

tests_eolian_js_eolian_js_suite_CPPFLAGS = 	\
-I$(top_builddir)/src/lib/efl \
-I$(top_srcdir)/src/bin/eolian_js \
-I$(top_srcdir)/src/bindings/js/eina_js \
-I$(top_srcdir)/src/bindings/js/eo_js \
-I$(top_builddir)/src/tests/eolian_js \
-I$(top_srcdir)/src/tests/efl_js \
-DTESTS_WD=\"`pwd`\" \
-DTESTS_SRC_DIR=\"$(top_srcdir)/src/tests/eolian_js\" \
-DPACKAGE_BUILD_DIR=\"$(abs_top_builddir)\" \
-DPACKAGE_DATA_DIR=\"$(datadir)/eolian_js\" \
-DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/eolian_js\" \
@CHECK_CFLAGS@ @EOLIAN_CXX_CFLAGS@ @EINA_JS_CFLAGS@ @EO_JS_CFLAGS@ @EFL_JS_CFLAGS@ \
@EOLIAN_CFLAGS@ @EINA_CFLAGS@ @EO_CFLAGS@ @ECORE_CFLAGS@ @EINA_CXX_CFLAGS@ \
@EO_JS_CFLAGS@ @EO_CXX_CFLAGS@ @EFL_JS_CFLAGS@ @ECORE_CXX_CFLAGS@

tests_eolian_js_eolian_js_suite_LDADD = \
@CHECK_LIBS@ @USE_EO_LIBS@ @USE_EINA_LIBS@ @USE_EOLIAN_LIBS@ @USE_EVAS_LIBS@ bin/efl_js/efl.node
tests_eolian_js_eolian_js_suite_DEPENDENCIES = @USE_EOLIAN_INTERNAL_LIBS@ @USE_EVAS_INTERNAL_LIBS@
endif
endif

endif