2 # Copyright (c) 2017 Samsung Electronics Co., Ltd.
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
17 # Build the Dali Adaptor library
20 ############# INCLUDE FILE LISTS #############
23 base_adaptor_src_dir = ../../../adaptors/base
24 include ../../../adaptors/base/file.list
26 # Platform Abstraction
27 tizen_platform_abstraction_src_dir = ../../../platform-abstractions/tizen
28 portable_platform_abstraction_src_dir = ../../../platform-abstractions/portable
29 include ../../../platform-abstractions/tizen/file.list
32 text_src_dir = ../../../text
33 include ../../../text/file.list
36 adaptor_integration_api_dir = ../../../adaptors/integration-api
37 include ../../../adaptors/integration-api/file.list
40 adaptor_common_dir = ../../../adaptors/common
41 include ../../../adaptors/common/file.list
44 adaptor_ecore_common_dir = ../../../adaptors/ecore/common
45 include ../../../adaptors/ecore/common/file.list
50 adaptor_ecore_wayland_dir = ../../../adaptors/ecore/wayland
51 include ../../../adaptors/ecore/wayland/file.list
54 adaptor_x11_dir = ../../../adaptors/x11
55 include ../../../adaptors/x11/file.list
60 adaptor_ubuntu_dir = ../../../adaptors/ubuntu
61 include ../../../adaptors/ubuntu/file.list
65 adaptor_tizen_dir = ../../../adaptors/tizen
67 include ../../../adaptors/tizen/file-3.list
69 include ../../../adaptors/tizen/file.list
74 adaptor_mobile_dir = ../../../adaptors/mobile
75 include ../../../adaptors/mobile/file.list
78 adaptor_wearable_dir = ../../../adaptors/wearable
79 include ../../../adaptors/wearable/file.list
82 adaptor_tv_dir = ../../../adaptors/tv
83 include ../../../adaptors/tv/file.list
86 adaptor_public_api_dir = ../../../adaptors/public-api
87 include ../../../adaptors/public-api/file.list
89 # Devel API ( for use by Toolkit)
90 adaptor_devel_api_dir = ../../../adaptors/devel-api
91 include ../../../adaptors/devel-api/file.list
95 static_libraries_libunibreak_src_dir = ../../../text/dali/internal/libunibreak
96 include ../../../text/dali/internal/libunibreak/file.list
98 static_libraries_glyphy_src_dir = ../../../text/dali/internal/glyphy
99 include ../../../text/dali/internal/glyphy/file.list
101 static_libraries_image_resampler_src_dir = ../../../third-party/image-resampler
102 include ../../../third-party/image-resampler/file.list
105 package_doxy_dir = ../../../doc
106 include ../../../doc/file.list
108 ############# source files #############
109 adaptor_internal_src_files = $(adaptor_tizen_framework_efl_src_files) \
110 $(adaptor_ecore_common_internal_src_files)
115 adaptor_internal_src_files += $(adaptor_common_internal_src_files) \
116 $(adaptor_common_internal_default_profile_src_files) \
117 $(adaptor_tizen_internal_src_files) \
118 $(adaptor_tizen_internal_non_mobile_src_files) \
119 $(static_libraries_libunibreak_src_files)
124 adaptor_internal_src_files += $(adaptor_ecore_wayland_tizen_internal_src_files) \
125 $(adaptor_ecore_wayland_internal_default_profile_src_files)
127 adaptor_internal_src_files += $(adaptor_wayland_tizen_internal_src_files)
128 endif # USE_ECORE_WAYLAND
130 adaptor_internal_src_files += $(adaptor_tizen_internal_egl_extension_src_files) \
131 $(adaptor_tizen_internal_native_image_src_files)
133 adaptor_internal_src_files += $(adaptor_x11_tizen_internal_src_files) \
134 $(adaptor_common_internal_egl_extension_src_files) \
135 $(adaptor_x11_internal_default_profile_src_files)
137 endif # COMMON_PROFILE
143 adaptor_internal_src_files += $(adaptor_common_internal_src_files) \
144 $(adaptor_common_internal_default_profile_src_files) \
145 $(adaptor_ubuntu_internal_src_files) \
146 $(adaptor_x11_ubuntu_internal_src_files) \
147 $(adaptor_x11_internal_default_profile_src_files) \
148 $(static_libraries_libunibreak_src_files) \
149 $(adaptor_common_internal_egl_extension_src_files)
151 endif # UBUNTU_PROFILE
157 adaptor_internal_src_files += $(adaptor_common_internal_src_files) \
158 $(adaptor_common_internal_mobile_profile_src_files) \
159 $(adaptor_tizen_internal_src_files) \
160 $(static_libraries_libunibreak_src_files)
165 adaptor_internal_src_files += $(adaptor_ecore_wayland_tizen_internal_src_files)
167 adaptor_internal_src_files += $(adaptor_wayland_tizen_internal_src_files)
168 endif # USE_ECORE_WAYLAND
170 adaptor_internal_src_files += $(adaptor_tizen_internal_egl_extension_src_files) \
171 $(adaptor_tizen_internal_native_image_src_files) \
172 $(adaptor_common_internal_wayland_mobile_profile_src_files)
174 adaptor_internal_src_files += $(adaptor_x11_tizen_internal_src_files) \
175 $(adaptor_common_internal_egl_extension_src_files) \
176 $(adaptor_common_internal_x_mobile_profile_src_files)
179 endif # MOBILE_PROFILE
184 adaptor_internal_src_files += $(adaptor_common_internal_src_files) \
185 $(adaptor_common_internal_mobile_profile_src_files) \
186 $(adaptor_tizen_internal_src_files) \
187 $(static_libraries_libunibreak_src_files)
191 adaptor_internal_src_files += $(adaptor_ecore_wayland_tizen_internal_src_files)
193 adaptor_internal_src_files += $(adaptor_wayland_tizen_internal_src_files)
194 endif # USE_ECORE_WAYLAND
196 adaptor_internal_src_files += $(adaptor_tizen_internal_egl_extension_src_files) \
197 $(adaptor_tizen_internal_native_image_src_files) \
198 $(adaptor_tizen_internal_capture_src_files) \
199 $(adaptor_internal_wearable_profile_src_files) \
200 $(adaptor_common_internal_wayland_mobile_profile_src_files)
202 adaptor_internal_src_files += $(adaptor_x11_tizen_internal_src_files) \
203 $(adaptor_common_internal_egl_extension_src_files) \
204 $(adaptor_common_internal_x_mobile_profile_src_files)
213 adaptor_internal_src_files += $(adaptor_common_internal_src_files) \
214 $(adaptor_common_internal_tv_profile_src_files) \
215 $(adaptor_tizen_internal_src_files) \
216 $(adaptor_tizen_internal_non_mobile_src_files) \
217 $(static_libraries_libunibreak_src_files)
221 adaptor_internal_src_files += $(adaptor_ecore_wayland_tizen_internal_src_files)
223 adaptor_internal_src_files += $(adaptor_wayland_tizen_internal_src_files)
224 endif # USE_ECORE_WAYLAND
226 adaptor_internal_src_files += $(adaptor_tizen_internal_egl_extension_src_files) \
227 $(adaptor_tizen_internal_native_image_src_files)
229 adaptor_internal_src_files += $(adaptor_x11_tv_internal_src_files) \
230 $(adaptor_x11_internal_tv_profile_key_src_files) \
231 $(adaptor_common_internal_egl_extension_src_files)
239 adaptor_internal_src_files += $(adaptor_common_internal_src_files) \
240 $(adaptor_common_internal_mobile_profile_src_files) \
241 $(adaptor_tizen_internal_src_files) \
242 $(static_libraries_libunibreak_src_files)
247 adaptor_internal_src_files += $(adaptor_ecore_wayland_tizen_internal_src_files)
249 adaptor_internal_src_files += $(adaptor_wayland_tizen_internal_src_files)
250 endif # USE_ECORE_WAYLAND
252 adaptor_internal_src_files += $(adaptor_tizen_internal_egl_extension_src_files) \
253 $(adaptor_tizen_internal_native_image_src_files)
255 adaptor_internal_src_files += $(adaptor_x11_tizen_internal_src_files) \
256 $(adaptor_common_internal_egl_extension_src_files)
261 main_loop_integration_src_files = $(adaptor_common_internal_ecore_src_files)
262 input_event_handler_src_files = $(adaptor_ecore_x_event_handler_internal_src_files)
264 if ENABLE_VECTOR_BASED_TEXT_RENDERING
265 adaptor_internal_src_files += $(static_libraries_glyphy_src_files)
266 DALI_ADAPTOR_CFLAGS += -DENABLE_VECTOR_BASED_TEXT_RENDERING
269 pkgconfigdir = $(libdir)/pkgconfig
272 pkgconfig_DATA = dali-adaptor-cxx03.pc dali-adaptor-integration-cxx03.pc
274 pkgconfig_DATA = dali-adaptor.pc dali-adaptor-integration.pc
277 LIBDALI_ADAPTOR_LA_SOURCES = \
278 $(base_adaptor_src_files) \
279 $(main_loop_integration_src_files) \
280 $(tizen_platform_abstraction_src_files) \
281 $(text_abstraction_src_files) \
282 $(devel_api_src_files) \
283 $(public_api_src_files) \
284 $(adaptor_internal_src_files) \
285 $(input_event_handler_src_files) \
286 $(image_resampler_src_files)
289 if ENABLE_NETWORK_LOGGING
290 LIBDALI_ADAPTOR_LA_SOURCES += \
291 $(base_adaptor_networking_src_files)
294 libdali_adaptor_la_DEPENDENCIES =
296 # List include directories with more platform-specific (tizen) before portable root:
297 LIBDALI_ADAPTOR_LA_includes = \
299 -I../../../platform-abstractions/tizen \
300 -I../../../platform-abstractions/tizen/resource-loader \
301 -I../../../platform-abstractions/portable \
302 -I../../../platform-abstractions/ \
303 -I../../../adaptors/public-api \
304 -I../../../adaptors/integration-api \
305 -I../../../adaptors/public-api/adaptor-framework \
306 -I../../../adaptors/devel-api/adaptor-framework \
307 -I../../../adaptors/common \
308 -I../../../adaptors/base/interfaces \
309 -I../../../adaptors/ \
311 -I../../../text/dali/internal/libunibreak \
312 -I../../../third-party/image-resampler
315 LIBDALI_ADAPTOR_LA_includes += -I../../../adaptors/integration-api/wayland
318 LIBDALI_ADAPTOR_LA_includes += \
319 -I../../../adaptors/ecore/common \
320 -I../../../adaptors/ecore/wayland
322 LIBDALI_ADAPTOR_LA_includes += -I../../../adaptors/wayland \
323 -I../../../adaptors/wayland/input/text/imf \
324 -I../../../adaptors/wayland/clipboard
325 endif # USE_ECORE_WAYLADN
327 LIBDALI_ADAPTOR_LA_includes += \
328 -I../../../adaptors/tizen
330 LIBDALI_ADAPTOR_LA_includes += \
331 -I../../../adaptors/ecore/common \
332 -I../../../adaptors/x11 \
333 -I../../../adaptors/integration-api/x11
337 LIBDALI_ADAPTOR_LA_includes += \
338 -I../../../adaptors/ubuntu
340 LIBDALI_ADAPTOR_LA_includes += \
341 -I../../../adaptors/tizen
345 LIBDALI_ADAPTOR_LA_includes += \
346 -I../../../adaptors/wearable \
347 -I../../../adaptors/wearable/capture
350 daliDefaultThemeDir = ${dataReadWriteDir}/theme/
351 daliShaderbinCacheDir = ${dataReadOnlyDir}/core/shaderbin/
353 LIBDALI_ADAPTOR_LA_CXXFLAGS = \
354 -DDALI_DATA_RW_DIR="\"${daliReadWriteDir}\"" \
355 -DDALI_DATA_RO_DIR="\"${daliReadOnlyDir}\"" \
356 -DDALI_DEFAULT_FONT_CACHE_DIR="\"${daliDefaultFontCacheDir}\"" \
357 -DDALI_USER_FONT_CACHE_DIR="\"${daliUserFontCacheDir}\"" \
358 -DDALI_SHADERBIN_DIR="\"${daliShaderbinCacheDir}\"" \
359 -DDALI_DEFAULT_THEME_DIR="\"${daliDefaultThemeDir}\"" \
360 -DFONT_PRELOADED_PATH="\"${fontPreloadedPath}\"" \
361 -DFONT_DOWNLOADED_PATH="\"${fontDownloadedPath}\"" \
362 -DFONT_APPLICATION_PATH="\"${fontApplicationPath}\"" \
363 -DFONT_CONFIGURATION_FILE="\"${fontConfigurationFile}\"" \
364 -DTIZEN_PLATFORM_CONFIG_SUPPORTED=${tizenPlatformConfigSupported} \
365 -DNON_POWER_OF_TWO_TEXTURES \
366 -DDALI_COMPILATION -DDALI_ADAPTOR_COMPILATION \
367 -Werror -Wall -lgcc -Wold-style-cast\
368 $(LIBDALI_ADAPTOR_LA_includes) \
369 $(DALI_ADAPTOR_CFLAGS) \
371 $(OPENGLES20_CFLAGS) \
373 $(FONTCONFIG_CFLAGS) \
380 $(CAPI_SYSTEM_SENSOR_CFLAGS) \
384 $(TPKP_CURL_CFLAGS) \
387 # Todo, as soon as common repos are updated on build server remove this.
389 LIBDALI_ADAPTOR_LA_CXXFLAGS += -DWAYLAND_EXTENSIONS_SUPPORTED
392 LIBDALI_ADAPTOR_LA_CFLAGS = \
394 -DDALI_COMPILATION -DDALI_ADAPTOR_COMPILATION \
395 $(DALI_ADAPTOR_CFLAGS)
397 LIBDALI_ADAPTOR_LA_LIBADD = \
407 $(CAPI_SYSTEM_SENSOR_LIBS) \
419 # EVAS used indicator
420 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(EVAS_CFLAGS) \
422 $(ECORE_IPC_CFLAGS) \
426 LIBDALI_ADAPTOR_LA_LIBADD += $(ECORE_IPC_LIBS) \
431 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(CAPI_APPFW_APPLICATION_CFLAGS) \
432 $(CAPI_SYSTEM_SYSTEM_SETTINGS_CFLAGS) \
433 $(CAPI_SYSTEM_INFO_CFLAGS) \
437 LIBDALI_ADAPTOR_LA_LIBADD += $(CAPI_APPFW_APPLICATION_LIBS) \
438 $(CAPI_SYSTEM_SYSTEM_SETTINGS_LIBS) \
439 $(CAPI_SYSTEM_INFO_LIBS) \
442 if USE_APPFW_EFL_BASE
443 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(ELEMENTARY_CFLAGS)
445 LIBDALI_ADAPTOR_LA_LIBADD += $(ELEMENTARY_LIBS)
448 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(BUNDLE_CFLAGS) \
449 $(CAPI_APPFW_COMMON_CFLAGS) \
450 $(CAPI_APPFW_CONTROL_CFLAGS) \
451 $(CAPI_APPFW_WIDGET_BASE_CFLAGS) \
452 $(ECORE_IMF_CFLAGS) \
456 LIBDALI_ADAPTOR_LA_LIBADD += $(BUNDLE_LIBS) \
457 $(CAPI_APPFW_COMMON_LIBS) \
458 $(CAPI_APPFW_CONTROL_LIBS) \
459 $(CAPI_APPFW_WIDGET_BASE_LIBS) \
464 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(ELEMENTARY_CFLAGS)
466 LIBDALI_ADAPTOR_LA_LIBADD += $(ELEMENTARY_LIBS)
470 # This is to avoid having to include wayland-egl.h everywhere
471 LIBDALI_ADAPTOR_LA_CXXFLAGS += -DWL_EGL_PLATFORM
472 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(WAYLAND_CFLAGS)
473 LIBDALI_ADAPTOR_LA_LIBADD += $(WAYLAND_LIBS)
475 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(X11_CFLAGS)
476 LIBDALI_ADAPTOR_LA_LIBADD += $(X11_LIBS)
477 LIBDALI_ADAPTOR_LA_LIBADD += $(ECORE_X_LIBS)
481 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(HAPTIC_CFLAGS)
485 LIBDALI_ADAPTOR_LA_CXXFLAGS += \
487 $(EFL_ASSIST_CFLAGS) \
488 $(NATIVE_BUFFER_CFLAGS) \
489 $(NATIVE_BUFFER_POOL_CFLAGS)
491 LIBDALI_ADAPTOR_LA_LIBADD += \
493 $(NATIVE_BUFFER_LIBS) \
494 $(NATIVE_BUFFER_POOL_LIBS)
498 LIBDALI_ADAPTOR_LA_CXXFLAGS += \
500 $(EFL_ASSIST_CFLAGS) \
501 $(SCREENCONNECTORPROVIDER_CFLAGS) \
502 $(APPCORE_WATCH_CFLAGS)
504 LIBDALI_ADAPTOR_LA_LIBADD += \
505 $(SCREENCONNECTORPROVIDER_LIBS) \
506 $(APPCORE_WATCH_LIBS)
510 LIBDALI_ADAPTOR_LA_CXXFLAGS += $(HAPTIC_CFLAGS)
511 LIBDALI_ADAPTOR_LA_LIBADD +=
515 LIBDALI_ADAPTOR_LA_CXXFLAGS += \
517 $(EFL_ASSIST_CFLAGS) \
518 $(NATIVE_BUFFER_CFLAGS) \
519 $(NATIVE_BUFFER_POOL_CFLAGS)
521 LIBDALI_ADAPTOR_LA_LIBADD += \
523 $(NATIVE_BUFFER_LIBS) \
524 $(NATIVE_BUFFER_POOL_LIBS)
528 LIBDALI_ADAPTOR_LA_LIBADD += -ljpeg
532 tizenadaptorpublicapidir = $(devincludepath)/dali/public-api
533 tizenadaptorpublicapi_HEADERS = $(public_api_header_files)
535 tizenadaptordevelapidir= $(devincludepath)/dali/devel-api
537 tizenadaptorintegrationapidir = $(devincludepath)/dali/integration-api/adaptors
538 tizenadaptorintegrationapi_HEADERS = $(adaptor_integration_api_header_files)
541 tizenadaptorintegrationwaylandapidir = $(devincludepath)/dali/integration-api/adaptors
542 tizenadaptorintegrationwaylandapi_HEADERS = $(adaptor_integration_wayland_api_header_files)
543 tizenadaptorintegrationwaylandapi_HEADERS += $(adaptor_integration_ecore_wayland_api_header_files)
545 tizenadaptorintegrationx11apidir = $(devincludepath)/dali/integration-api/adaptors
546 tizenadaptorintegrationx11api_HEADERS = $(adaptor_integration_x11_api_header_files)
549 tizenadaptorframeworkpublicapidir = $(tizenadaptorpublicapidir)/adaptor-framework
550 tizenadaptorframeworkpublicapi_HEADERS = $(public_api_adaptor_framework_header_files)
552 tizenadaptorframeworkdevelapidir = $(tizenadaptordevelapidir)/adaptor-framework
553 tizenadaptorframeworkdevelapi_HEADERS = $(devel_api_adaptor_framework_header_files)
555 tizentextabstractiondevelapidir = $(tizenadaptordevelapidir)/text-abstraction
556 tizentextabstractiondevelapi_HEADERS = $(text_abstraction_header_files)
559 tizenadaptorframeworkpublicapi_HEADERS += $(public_api_adaptor_tizen_header_files)
562 tizenadaptorframeworkdevelapi_HEADERS += $(devel_api_adaptor_tizen_x11_header_files)
565 endif # NOT UBUNTU_PROFILE
567 tizenadaptordaliheaderdir = $(devincludepath)/dali
568 tizenadaptordaliheader_HEADERS = $(adaptor_dali_header_file)
570 tizenadaptorpublicapi_HEADERS += $(adaptor_dali_wearable_header_file)
572 tizenwatchpublicapidir = $(tizenadaptorpublicapidir)/watch
573 tizenwatchpublicapi_HEADERS = $(public_dali_watch_header_files)
575 tizencapturepublicapidir = $(tizenadaptorpublicapidir)/capture
576 tizencapturepublicapi_HEADERS = $(public_dali_capture_header_files)
579 $(MKDIR_P) ${DESTDIR}/${daliUserFontCacheDir} ${DESTDIR}/${daliShaderbinCacheDir}
581 # Install resource log analyzer script
582 bin_SCRIPTS = ../../../adaptors/scripts/dalireslog.sh
584 # package doxygen file (contains doxygen grouping information)
585 packagedoxydir = $(devincludepath)/dali/doc
586 packagedoxy_HEADERS = $(package_doxy_files)
592 lib_LTLIBRARIES = libdali-adaptor.la
594 libdali_adaptor_la_SOURCES = $(LIBDALI_ADAPTOR_LA_SOURCES)
595 libdali_adaptor_la_includes = $(LIBDALI_ADAPTOR_LA_INCLUDES)
596 libdali_adaptor_la_CFLAGS = $(LIBDALI_ADAPTOR_LA_CFLAGS)
597 libdali_adaptor_la_CXXFLAGS = $(LIBDALI_ADAPTOR_LA_CXXFLAGS)
598 libdali_adaptor_la_LIBADD = $(LIBDALI_ADAPTOR_LA_LIBADD)
602 lib_LTLIBRARIES = libdali-adaptor-cxx11.la
604 libdali_adaptor_cxx11_la_SOURCES = $(LIBDALI_ADAPTOR_LA_SOURCES)
605 libdali_adaptor_cxx11_la_includes = $(LIBDALI_ADAPTOR_LA_INCLUDES)
606 libdali_adaptor_cxx11_la_CFLAGS = $(LIBDALI_ADAPTOR_LA_CFLAGS)
607 libdali_adaptor_cxx11_la_CXXFLAGS = $(LIBDALI_ADAPTOR_LA_CXXFLAGS)
608 libdali_adaptor_cxx11_la_LIBADD = $(LIBDALI_ADAPTOR_LA_LIBADD)
613 noinst_PROGRAMS = linker.test
615 linker_test_SOURCES = linker-test.cpp
617 linker_test_CXXFLAGS = \
618 -DDALI_ADAPTOR_COMPILATION \
619 -I../../../adaptors/common \
620 -I../../../adaptors/public-api \
621 -I../../../adaptors/integration-api \
622 -I../../../adaptors/base/interfaces \
623 -I../../../adaptors/public-api/adaptor-framework \
624 -I../../../adaptors/devel-api/adaptor-framework \
625 $(DALI_ADAPTOR_CFLAGS) \
632 linker_test_CXXFLAGS += \
633 -I../../../adaptors/integration-api/wayland
636 linker_test_CXXFLAGS += \
637 -I../../../adaptors/integration-api/x11
640 linker_test_LDADD = \
648 linker_test_LDADD += libdali-adaptor.la
649 linker_test_DEPENDENCIES = libdali-adaptor.la
654 rm -rf $(libdir)/libdali-adaptor.so
655 rm -rf $(libdir)/libdali-adaptor-cxx03.so
656 ln -s $(libdir)/libdali-adaptor.so.0.0.* $(libdir)/libdali-adaptor-cxx03.so
661 linker_test_LDADD += libdali-adaptor-cxx11.la
662 linker_test_DEPENDENCIES = libdali-adaptor-cxx11.la
667 rm -rf $(libdir)/libdali-adaptor-cxx11.so
668 rm -rf $(libdir)/libdali-adaptor.so
669 ln -s $(libdir)/libdali-adaptor-cxx11.so.0.0.* $(libdir)/libdali-adaptor.so