aboutsummaryrefslogtreecommitdiffstats
path: root/src/Makefile_Emotion.am
diff options
context:
space:
mode:
authorGustavo Sverzut Barbieri <barbieri@gmail.com>2013-01-14 22:36:23 +0000
committerGustavo Sverzut Barbieri <barbieri@gmail.com>2013-01-14 22:36:23 +0000
commitb1bc5aeb24d6dd0faf97c2d1d6c6781798a7fbe9 (patch)
treeebffce52ddbab71c6da6c2e07eeca7382abf15f6 /src/Makefile_Emotion.am
parentedbus: Dont call dispatch_name_owner_change() if we get a error message (diff)
downloadefl-b1bc5aeb24d6dd0faf97c2d1d6c6781798a7fbe9.tar.gz
efl: simplify automake.
Instead of -I$(top_srcdir)... -I$(top_builddir)... and then do it for the .la, use the EFL_ macros to generate the contents to be used in automake files. There is a nasty bit that libtool will parse Makefile*.am and will not get _DEPENDENCIES from _LIBADD and _LDADD if these are in @REPLACEMENT@. To solve this we must explicitly set _DEPENDENCIES. The contents of this is almost the same as _LIBADD or _LDADD with the "_INTERNAL_" replacement name. I hope the code will be result will be shorter and consistent as there is less places to change when we add/remove dependencies. Statistics are quite impressive (diffstat): {{{ 37 files changed, 663 insertions(+), 1599 deletions(-) }}} SVN revision: 82785
Diffstat (limited to 'src/Makefile_Emotion.am')
-rw-r--r--src/Makefile_Emotion.am103
1 files changed, 28 insertions, 75 deletions
diff --git a/src/Makefile_Emotion.am b/src/Makefile_Emotion.am
index 45a2dedad0..085f2b4e53 100644
--- a/src/Makefile_Emotion.am
+++ b/src/Makefile_Emotion.am
@@ -3,45 +3,6 @@
lib_LTLIBRARIES += \
lib/emotion/libemotion.la
-EMOTION_COMMON_CPPFLAGS = \
--I$(top_srcdir)/src/lib/eina \
--I$(top_builddir)/src/lib/eina \
--I$(top_srcdir)/src/lib/eo \
--I$(top_builddir)/src/lib/eo \
--I$(top_srcdir)/src/lib/ecore \
--I$(top_builddir)/src/lib/ecore \
--I$(top_srcdir)/src/lib/ecore_x \
--I$(top_builddir)/src/lib/ecore_x \
--I$(top_srcdir)/src/lib/ecore_input \
--I$(top_builddir)/src/lib/ecore_input \
--I$(top_srcdir)/src/lib/ecore_evas \
--I$(top_builddir)/src/lib/ecore_evas \
--I$(top_srcdir)/src/lib/eet \
--I$(top_builddir)/src/lib/eet \
--I$(top_srcdir)/src/lib/evas \
--I$(top_builddir)/src/lib/evas \
--I$(top_srcdir)/src/lib/eio \
--I$(top_builddir)/src/lib/eio \
--I$(top_srcdir)/src/lib/eeze \
--I$(top_builddir)/src/lib/eeze \
--I$(top_srcdir)/src/lib/emotion \
--I$(top_builddir)/src/lib/emotion \
-@EFL_COV_CFLAGS@ \
-@EMOTION_CFLAGS@
-
-EMOTION_COMMON_LDADD = \
-lib/eina/libeina.la \
-lib/eo/libeo.la \
-lib/ecore/libecore.la \
-lib/eet/libeet.la \
-lib/evas/libevas.la \
-lib/eio/libeio.la \
-@EFL_COV_LIBS@
-
-if EMOTION_HAVE_V4L2
-EMOTION_COMMON_LDADD += lib/eeze/libeeze.la
-endif
-
installed_emotionmainheadersdir = $(includedir)/emotion-@VMAJ@
dist_installed_emotionmainheaders_DATA = lib/emotion/Emotion.h
@@ -54,20 +15,14 @@ lib/emotion/emotion_webcam.c \
lib/emotion/emotion_modules.c \
lib/emotion/emotion_main.c
-EMOTION_COMMON_LIBADD = $(EMOTION_COMMON_LDADD) @EMOTION_LIBS@
-EMOTION_COMMON_LDADD += @EMOTION_LDFLAGS@
-EMOTION_COMMON_USER_LIBADD = $(EMOTION_COMMON_LIBADD) lib/emotion/libemotion.la
-EMOTION_COMMON_USER_LDADD = $(EMOTION_COMMON_LDADD) lib/emotion/libemotion.la
-
lib_emotion_libemotion_la_CPPFLAGS = \
-$(EMOTION_COMMON_CPPFLAGS) \
-DPACKAGE_BIN_DIR=\"$(bindir)\" \
-DPACKAGE_LIB_DIR=\"$(libdir)\" \
-DPACKAGE_DATA_DIR=\"$(datadir)/emotion\" \
-DPACKAGE_BUILD_DIR=\"`pwd`/$(top_builddir)\" \
--DEFL_EMOTION_BUILD
-
-lib_emotion_libemotion_la_LIBADD = $(EMOTION_COMMON_LIBADD)
+@EMOTION_CFLAGS@
+lib_emotion_libemotion_la_LIBADD = @EMOTION_LIBS@
+lib_emotion_libemotion_la_DEPENDENCIES = @EMOTION_INTERNAL_LIBS@
lib_emotion_libemotion_la_LDFLAGS = @EFL_LTLIBRARY_FLAGS@
## Modules
@@ -86,11 +41,12 @@ emotionmodulexinedir = $(libdir)/emotion/modules/xine/$(MODULE_ARCH)
emotionmodulexine_LTLIBRARIES = modules/emotion/xine/module.la
modules_emotion_xine_module_la_SOURCES = $(EMOTION_XINE_SOURCES)
modules_emotion_xine_module_la_CPPFLAGS = \
-$(EMOTION_COMMON_CPPFLAGS) \
+@EMOTION_CFLAGS@ \
@EMOTION_MODULE_XINE_CFLAGS@
modules_emotion_xine_module_la_LIBADD = \
-$(EMOTION_COMMON_USER_LIBADD) \
+@USE_EMOTION_LIBS@ \
@EMOTION_MODULE_XINE_LIBS@
+modules_emotion_xine_module_la_DEPENDENCIES = @USE_EMOTION_INTERNAL_LIBS@
modules_emotion_xine_module_la_LDFLAGS = -module @EFL_LTMODULE_FLAGS@
modules_emotion_xine_module_la_LIBTOOLFLAGS = --tag=disable-static
endif
@@ -107,28 +63,24 @@ modules/emotion/gstreamer/emotion_sink.c
if EMOTION_STATIC_BUILD_GSTREAMER
lib_emotion_libemotion_la_SOURCES += $(EMOTION_GSTREAMER_SOURCES)
-if HAVE_ECORE_X
-EMOTION_COMMON_LDADD += \
-lib/ecore_evas/libecore_evas.la \
-lib/ecore_x/libecore_x.la
-endif
else
if EMOTION_BUILD_GSTREAMER
emotionmodulegstreamerdir = $(libdir)/emotion/modules/gstreamer/$(MODULE_ARCH)
emotionmodulegstreamer_LTLIBRARIES = modules/emotion/gstreamer/module.la
modules_emotion_gstreamer_module_la_SOURCES = $(EMOTION_GSTREAMER_SOURCES)
modules_emotion_gstreamer_module_la_CPPFLAGS = \
-$(EMOTION_COMMON_CPPFLAGS) \
+@EMOTION_CFLAGS@ \
@EMOTION_MODULE_GSTREAMER_CFLAGS@
modules_emotion_gstreamer_module_la_LIBADD = \
-$(EMOTION_COMMON_USER_LIBADD) \
+@USE_EMOTION_LIBS@ \
@EMOTION_MODULE_GSTREAMER_LIBS@
+modules_emotion_gstreamer_module_la_DEPENDENCIES = @USE_EMOTION_INTERNAL_LIBS@
modules_emotion_gstreamer_module_la_LDFLAGS = -module @EFL_LTMODULE_FLAGS@
modules_emotion_gstreamer_module_la_LIBTOOLFLAGS = --tag=disable-static
if HAVE_ECORE_X
-modules_emotion_gstreamer_module_la_LIBADD += \
-lib/ecore_evas/libecore_evas.la \
-lib/ecore_x/libecore_x.la
+modules_emotion_gstreamer_module_la_CPPFLAGS += @ECORE_X_CFLAGS@ @ECORE_EVAS_CFLAGS@
+modules_emotion_gstreamer_module_la_LIBADD += @USE_ECORE_X_LIBS@ @USE_ECORE_EVAS_LIBS@
+modules_emotion_gstreamer_module_la_DEPENDENCIES += @USE_ECORE_X_INTERNAL_LIBS@ @USE_ECORE_EVAS_INTERNAL_LIBS@
endif
endif
endif
@@ -146,12 +98,12 @@ emotionmodulegenericdir = $(libdir)/emotion/modules/generic/$(MODULE_ARCH)
emotionmodulegeneric_LTLIBRARIES = modules/emotion/generic/module.la
modules_emotion_generic_module_la_SOURCES = $(EMOTION_GENERIC_SOURCES)
modules_emotion_generic_module_la_CPPFLAGS = \
-$(EMOTION_COMMON_CPPFLAGS) \
+@EMOTION_CFLAGS@ \
-DPACKAGE_BIN_DIR=\"$(bindir)\" \
-DPACKAGE_LIB_DIR=\"$(libdir)\" \
-DPACKAGE_DATA_DIR=\"$(datadir)/emotion\"
-modules_emotion_generic_module_la_LIBADD = \
-$(EMOTION_COMMON_USER_LIBADD)
+modules_emotion_generic_module_la_LIBADD = @USE_EMOTION_LIBS@
+modules_emotion_generic_module_la_DEPENDENCIES = @USE_EMOTION_INTERNAL_LIBS@
modules_emotion_generic_module_la_LDFLAGS = -module @EFL_LTMODULE_FLAGS@
modules_emotion_generic_module_la_LIBTOOLFLAGS = --tag=disable-static
endif
@@ -170,11 +122,15 @@ emotionedjeexternal_LTLIBRARIES = edje_external/emotion/module.la
edje_external_emotion_module_la_SOURCES = \
edje_external/emotion/emotion.c
edje_external_emotion_module_la_CPPFLAGS = \
-$(EMOTION_COMMON_CPPFLAGS) \
-$(EDJE_COMMON_CPPFLAGS)
+@EDJE_CFLAGS@ \
+@EMOTION_CFLAGS@ \
+-DPACKAGE_DATA_DIR=\"$(datadir)/emotion\"
edje_external_emotion_module_la_LIBADD = \
-$(EMOTION_COMMON_USER_LIBADD) \
-$(EDJE_COMMON_USER_LIBADD)
+@USE_EDJE_LIBS@ \
+@USE_EMOTION_LIBS@
+edje_external_emotion_module_la_DEPENDENCIES = \
+@USE_EDJE_INTERNAL_LIBS@ \
+@USE_EMOTION_INTERNAL_LIBS@
edje_external_emotion_module_la_LDFLAGS = -module @EFL_LTMODULE_FLAGS@
edje_external_emotion_module_la_LIBTOOLFLAGS = --tag=disable-static
@@ -190,18 +146,15 @@ tests_emotion_emotion_test_SOURCES = \
tests/emotion/emotion_test_main.c
tests_emotion_emotion_test_CPPFLAGS = \
-$(EMOTION_COMMON_CPPFLAGS) \
--I$(top_srcdir)/src/lib/edje \
--I$(top_builddir)/src/lib/edje \
-DPACKAGE_BIN_DIR=\"$(bindir)\" \
-DPACKAGE_LIB_DIR=\"$(libdir)\" \
-DPACKAGE_DATA_DIR=\"$(datadir)/emotion\" \
--DPACKAGE_BUILD_DIR=\"`pwd`/$(top_builddir)\"
+-DPACKAGE_BUILD_DIR=\"`pwd`/$(top_builddir)\" \
+@EDJE_CFLAGS@ \
+@EMOTION_CFLAGS@
-tests_emotion_emotion_test_LDADD = \
-$(EMOTION_COMMON_USER_LDADD) \
-lib/ecore_evas/libecore_evas.la \
-lib/edje/libedje.la
+tests_emotion_emotion_test_LDADD = @USE_EDJE_LIBS@ @USE_EMOTION_LIBS@
+tests_emotion_emotion_test_DEPENDENCIES = @USE_EDJE_INTERNAL_LIBS@ @USE_EMOTION_INTERNAL_LIBS@
tests/emotion/data/theme.edj: tests/emotion/data/theme.edc bin/edje/edje_cc
@$(MKDIR_P) tests/emotion/data