76aeb88c43da0af0ee743ee856a3dc7ee023755a
[platform/core/uifw/dali-adaptor.git] / packaging / dali-adaptor.spec
1 # NOTES
2 # This spec file is used to build DALi Adaptor for different Tizen Profiles
3 # Current profiles are:  Mobile, TV, Wearable, Common
4 #
5 # The profile variable is defined outside of the spec file in a build.conf file.
6 # It will contain the profile and whether or not to build with X11 or Wayland
7 #
8 # gbs will try to download the build.conf for the platform automatically from the repo location when
9 # performing a gbs build ( use gbs build -v to see it download location) E.g.
10 # http://download.tizen.org/snapshots/tizen/tv/tizen-tv/repos/arm-wayland/packages/repodata/xxxx-build.conf.gz
11
12 # Do not provide .so automatically for the extensions.
13 # This if statement is for backward compatibility with GBM/Obsolete build systems
14 %if "%{?profile}" != "wearable" && "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
15 %global __provides_exclude_from ^.*\\.(wearable|mobile|tv|ivi|common)$
16 %endif
17
18 Name:       dali2-adaptor
19 Summary:    The DALi Tizen Adaptor
20 Version:    2.3.11
21 Release:    1
22 Group:      System/Libraries
23 License:    Apache-2.0 and BSD-3-Clause and MIT
24 URL:        https://review.tizen.org/git/?p=platform/core/uifw/dali-adaptor.git;a=summary
25 Source0:    %{name}-%{version}.tar.gz
26
27 Requires(post): /sbin/ldconfig
28 Requires(postun): /sbin/ldconfig
29 Requires:       giflib
30
31 %define tizen_platform_config_supported 1
32 BuildRequires:  pkgconfig(libtzplatform-config)
33
34 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
35 # if wearable || "undefined"
36 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
37 BuildRequires:  pkgconfig(capi-appfw-watch-application)
38 BuildRequires:  pkgconfig(appcore-watch)
39 %endif
40
41 BuildRequires:  pkgconfig(screen_connector_provider)
42 BuildRequires:  pkgconfig(gles20)
43 BuildRequires:  pkgconfig(glesv2)
44 BuildRequires:  pkgconfig(ttrace)
45
46 BuildRequires:  dali2-devel
47 BuildRequires:  dali2-integration-devel
48
49 BuildRequires:  pkgconfig
50 BuildRequires:  gawk
51 BuildRequires:  cmake
52 BuildRequires:  giflib-devel
53 BuildRequires:  pkgconfig(fontconfig)
54 BuildRequires:  libjpeg-turbo-devel
55 BuildRequires:  pkgconfig(vconf)
56 BuildRequires:  tts-devel
57 BuildRequires:  pkgconfig(dlog)
58 BuildRequires:  libdrm-devel
59 BuildRequires:  pkgconfig(libexif)
60 BuildRequires:  pkgconfig(libpng)
61 BuildRequires:  pkgconfig(egl)
62 BuildRequires:  libcurl-devel
63 BuildRequires:  pkgconfig(harfbuzz)
64 BuildRequires:  hyphen-devel
65 BuildRequires:  fribidi-devel
66
67 BuildRequires:  pkgconfig(capi-system-info)
68 BuildRequires:  pkgconfig(capi-system-sensor)
69
70 BuildRequires:  pkgconfig(cairo)
71
72 BuildRequires:  pkgconfig(wayland-egl)
73 BuildRequires:  pkgconfig(wayland-client)
74 BuildRequires:  pkgconfig(input-method-client)
75 BuildRequires:  wayland-devel
76 BuildRequires:  wayland-extension-client-devel
77
78 # WebP support only from Tizen 6 onwards
79 %if 0%{?tizen_version_major} >= 6
80 BuildRequires:  pkgconfig(libwebp)
81 BuildRequires:  pkgconfig(libwebpdecoder)
82 BuildRequires:  pkgconfig(libwebpdemux)
83 BuildRequires:  pkgconfig(libwebpmux)
84 %endif
85
86 # We use ecore mainloop
87 %if 0%{?tizen_version_major} >= 5
88 BuildRequires:  pkgconfig(ecore-wl2)
89 BuildRequires:  pkgconfig(wayland-egl-tizen)
90 %else
91 BuildRequires:  pkgconfig(ecore-wayland)
92 %endif
93
94 # We need tbm_surface in tizen 3.0 wayland
95 BuildRequires:  pkgconfig(libtbm)
96
97 # for the adaptor
98 BuildRequires:  pkgconfig(app-core-ui-cpp)
99 BuildRequires:  pkgconfig(appcore-widget-base)
100 BuildRequires:  pkgconfig(bundle)
101 BuildRequires:  pkgconfig(capi-appfw-app-common)
102 BuildRequires:  pkgconfig(capi-appfw-app-control)
103 BuildRequires:  pkgconfig(ecore-imf)
104
105 BuildRequires:  pkgconfig(capi-system-system-settings)
106
107 # for ATSPI (Accessibility) support
108 BuildRequires:  pkgconfig(eldbus)
109
110 # for feedback plugin
111 BuildRequires:  pkgconfig(mm-sound)
112 BuildRequires:  pkgconfig(feedback)
113 BuildRequires:  pkgconfig(component-based-core-base)
114
115
116 %if ( 0%{?tizen_version_major} == 6 && 0%{?tizen_version_minor} >= 5 ) || 0%{?tizen_version_major} >= 7
117 BuildRequires:  pkgconfig(thorvg)
118 %endif
119
120 # For ASAN test
121 %if "%{vd_asan}" == "1" || "%{asan}" == "1"
122 BuildRequires: asan-force-options
123 BuildRequires: asan-build-env
124 BuildRequires: libasan
125 %endif
126
127 # for multiprofile
128 Requires:   %{name}-compat = %{version}-%{release}
129 Recommends: %{name}-profile_common = %{version}-%{release}
130
131 %description
132 The DALi Tizen Adaptor provides a Tizen specific implementation of the dali-core
133 platform abstraction and application shell
134
135 ###########################################
136 # Dali adapter for profiles
137 ###########################################
138
139 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
140 # if mobile || "undefined"
141 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
142 %package profile_mobile
143 Summary:        The DALi Tizen Adaptor for mobile
144 Provides:       %{name}-compat = %{version}-%{release}
145 Conflicts:      %{name}-profile_tv
146 Conflicts:      %{name}-profile_wearable
147 Conflicts:      %{name}-profile_ivi
148 Conflicts:      %{name}-profile_common
149 Requires:       %{name}
150 %description profile_mobile
151 The DALi Tizen Adaptor for mobile.
152 %endif
153
154 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
155 # if tv ||"undefined"
156 %if "%{?profile}" != "wearable" && "%{?profile}" != "common" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
157 %package profile_tv
158 Summary:        The DALi Tizen Adaptor for tv
159 Provides:       %{name}-compat = %{version}-%{release}
160 Conflicts:      %{name}-profile_mobile
161 Conflicts:      %{name}-profile_wearable
162 Conflicts:      %{name}-profile_ivi
163 Conflicts:      %{name}-profile_common
164 Requires:       %{name}
165 %description profile_tv
166 The DALi Tizen Adaptor for tv.
167 %endif
168
169 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
170 # if wearable || "undefined"
171 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
172 %package profile_wearable
173 Summary:        The DALi Tizen Adaptor for wearable
174 Provides:       %{name}-compat = %{version}-%{release}
175 Conflicts:      %{name}-profile_mobile
176 Conflicts:      %{name}-profile_tv
177 Conflicts:      %{name}-profile_ivi
178 Conflicts:      %{name}-profile_common
179 Requires:       %{name}
180 %description profile_wearable
181 The DALi Tizen Adaptor for wearable.
182 %endif
183
184 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
185 # if ivi ||"undefined"
186 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "common" && "%{?profile}" != "mobile"
187 %package profile_ivi
188 Summary:        The DALi Tizen Adaptor for ivi
189 Provides:       %{name}-compat = %{version}-%{release}
190 Conflicts:      %{name}-profile_mobile
191 Conflicts:      %{name}-profile_wearable
192 Conflicts:      %{name}-profile_tv
193 Conflicts:      %{name}-profile_common
194 Requires:       %{name}
195 %description profile_ivi
196 The DALi Tizen Adaptor for ivi.
197 %endif
198
199 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
200 # if common ||"undefined"
201 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
202 # Currently Tizen Common we use does not have wayland extensions like xdg-shell
203 %package profile_common
204 Summary:        The DALi Tizen Adaptor for common
205 Provides:       %{name}-compat = %{version}-%{release}
206 Conflicts:      %{name}-profile_mobile
207 Conflicts:      %{name}-profile_wearable
208 Conflicts:      %{name}-profile_tv
209 Conflicts:      %{name}-profile_ivi
210 Requires:       %{name}
211 %description profile_common
212 The DALi Tizen Adaptor for common.
213 %endif
214
215 ##############################
216 # devel
217 ##############################
218 %package devel
219 Summary:    Development components for the DALi Tizen Adaptor
220 Group:      Development/Building
221 Requires:   %{name} = %{version}-%{release}
222 Requires:   %{name}-integration-devel = %{version}-%{release}
223
224 %description devel
225 Development components for the DALi Tizen Adaptor - public headers and package configs
226
227 ##############################
228 # integration-devel
229 ##############################
230 %package integration-devel
231 Summary:    Integration development package for the Adaptor
232 Group:      Development/Building
233 Requires:   %{name} = %{version}-%{release}
234
235 %description integration-devel
236 Integration development package for the Adaptor - headers for integrating with an adaptor library.
237
238 ##############################
239 # Dali Feedback Plugin
240 ##############################
241 %package dali2-feedback-plugin
242 Summary:    Plugin to play haptic and audio feedback for Dali
243 Group:      System/Libraries
244 Requires:   %{name} = %{version}-%{release}
245 %description dali2-feedback-plugin
246 Feedback plugin to play haptic and audio feedback for Dali
247
248 #Use TZ_PATH when tizen version is 3.x or greater
249 %define dali_data_rw_dir         %TZ_SYS_RO_SHARE/dali/
250 %define dali_data_ro_dir         %TZ_SYS_RO_SHARE/dali/
251 %define font_preloaded_path      %TZ_SYS_RO_SHARE/fonts/
252 %define font_downloaded_path     %TZ_SYS_SHARE/fonts/
253 %define font_application_path    %TZ_SYS_RO_SHARE/app_fonts/
254 %define font_configuration_file  %TZ_SYS_ETC/fonts/conf.avail/99-slp.conf
255
256 %define user_shader_cache_dir    %{dali_data_ro_dir}/core/shaderbin/
257 %define dali_plugin_sound_files  /plugins/sounds/
258
259 ##############################
260 # Preparation
261 ##############################
262 %prep
263 %setup -q
264
265
266 ##############################
267 # Build
268 ##############################
269 %build
270 PREFIX+="/usr"
271 CXXFLAGS+=" -Wall -g -Os -fPIC -fvisibility-inlines-hidden -fdata-sections -ffunction-sections -DGL_GLEXT_PROTOTYPES"
272 LDFLAGS+=" -Wl,--rpath=%{_libdir} -Wl,--as-needed -Wl,--gc-sections -lttrace -Wl,-Bsymbolic-functions "
273
274 %ifarch %{arm}
275 CXXFLAGS+=" -D_ARCH_ARM_ -lgcc"
276 %endif
277
278 CFLAGS+=" -DWAYLAND"
279 CXXFLAGS+=" -DWAYLAND"
280 cmake_flags=" -DENABLE_WAYLAND=ON -DENABLE_ATSPI=ON"
281
282 %if 0%{?enable_streamline}
283 cmake_flags+=" -DENABLE_TRACE_STREAMLINE=ON"
284 %else
285 cmake_flags+=" -DENABLE_TRACE=ON"
286 %endif
287
288 # Use this conditional when Tizen version is 5.x or greater
289 %if 0%{?tizen_version_major} >= 5
290 CXXFLAGS+=" -DOVER_TIZEN_VERSION_5"
291
292 # Need Ecore-Wayland2 when Tizen version is 5.x or greater
293 CFLAGS+=" -DECORE_WAYLAND2 -DEFL_BETA_API_SUPPORT"
294 CXXFLAGS+=" -DECORE_WAYLAND2 -DEFL_BETA_API_SUPPORT"
295 cmake_flags+=" -DENABLE_ECORE_WAYLAND2=ON"
296 %endif
297
298 # Use this conditional when Tizen version is 7.x or greater
299 %if 0%{?tizen_version_major} >= 7
300 CXXFLAGS+=" -DOVER_TIZEN_VERSION_7"
301 %endif
302
303 # Use this conditional when Tizen version is 8.x or greater
304 %if 0%{?tizen_version_major} >= 8
305 CXXFLAGS+=" -DOVER_TIZEN_VERSION_8"
306 %endif
307
308 %if "%{vd_asan}" == "1" || "%{asan}" == "1"
309 CFLAGS+=" -fsanitize=address"
310 CXXFLAGS+=" -fsanitize=address"
311 LDFLAGS+=" -fsanitize=address"
312 %endif
313
314 %if 0%{?enable_debug}
315 cmake_flags+=" -DCMAKE_BUILD_TYPE=Debug"
316 %endif
317
318 %if 0%{?enable_logging}
319 cmake_flags+=" -DENABLE_NETWORK_LOGGING=ON"
320 %endif
321
322 libtoolize --force
323 cd %{_builddir}/%{name}-%{version}/build/tizen
324
325 DALI_DATA_RW_DIR="%{dali_data_rw_dir}" ; export DALI_DATA_RW_DIR
326 DALI_DATA_RO_DIR="%{dali_data_ro_dir}"  ; export DALI_DATA_RO_DIR
327 FONT_PRELOADED_PATH="%{font_preloaded_path}" ; export FONT_PRELOADED_PATH
328 FONT_DOWNLOADED_PATH="%{font_downloaded_path}" ; export FONT_DOWNLOADED_PATH
329 FONT_APPLICATION_PATH="%{font_application_path}"  ; export FONT_APPLICATION_PATH
330 FONT_CONFIGURATION_FILE="%{font_configuration_file}" ; export FONT_CONFIGURATION_FILE
331 %if 0%{?tizen_platform_config_supported}
332 TIZEN_PLATFORM_CONFIG_SUPPORTED="%{tizen_platform_config_supported}" ; export TIZEN_PLATFORM_CONFIG_SUPPORTED
333 %endif
334
335 cmake_flags+=" -DCMAKE_INSTALL_PREFIX=$PREFIX"
336 cmake_flags+=" -DCMAKE_INSTALL_LIBDIR=%{_libdir}"
337 cmake_flags+=" -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir}"
338 cmake_flags+=" -DENABLE_TIZEN_MAJOR_VERSION=%{tizen_version_major}"
339 cmake_flags+=" -DENABLE_FEEDBACK=YES"
340 cmake_flags+=" -DENABLE_APPFW=YES"
341 cmake_flags+=" -DCOMPONENT_APPLICATION_SUPPORT=YES"
342
343 # Set up the build via Cmake
344 #######################################################################
345 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
346 # if mobile || "undefined"
347 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
348
349 mkdir -p mobile
350 pushd mobile
351
352 cmake -DENABLE_PROFILE=MOBILE $cmake_flags ..
353
354 # Build.
355 make %{?jobs:-j%jobs}
356 popd
357
358 %endif
359
360 #######################################################################
361 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
362 # if tv ||"undefined"
363 %if "%{?profile}" != "wearable" && "%{?profile}" != "common" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
364
365 mkdir -p tv
366 pushd tv
367
368 cmake -DENABLE_PROFILE=TV $cmake_flags ..
369
370 # Build.
371 make %{?jobs:-j%jobs}
372 popd
373
374 %endif
375
376 #######################################################################
377 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
378 # if wearable || "undefined"
379 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
380
381 mkdir -p wearable
382 pushd wearable
383
384 cmake -DENABLE_PROFILE=WEARABLE $cmake_flags ..
385
386 # Build.
387 make %{?jobs:-j%jobs}
388 popd
389
390 %endif
391
392 #######################################################################
393 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
394 # if ivi ||"undefined"
395 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "common" && "%{?profile}" != "mobile"
396
397 mkdir -p ivi
398 pushd ivi
399
400 cmake -DENABLE_PROFILE=IVI $cmake_flags ..
401
402 # Build.
403 make %{?jobs:-j%jobs}
404 popd
405
406 %endif
407
408 #######################################################################
409 # common
410 # This is for backward-compatibility. This does not deteriorate 4.0 Configurability
411 # if common ||"undefined"
412 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
413
414 mkdir -p common
415 pushd common
416
417 cmake -DENABLE_PROFILE=COMMON $cmake_flags ..
418
419 # Build.
420 make %{?jobs:-j%jobs}
421 popd
422
423 %endif
424
425 ##############################
426 # Installation
427 ##############################
428 %install
429 rm -rf %{buildroot}
430
431 pushd %{_builddir}/%{name}-%{version}/build/tizen
432
433 # if mobile || "undefined"
434 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
435 pushd mobile
436 %make_install
437 %if "%{?profile}" != "mobile"
438 pushd  %{buildroot}%{_libdir}
439 cp libdali2-adaptor.so.*.*.* libdali2-adaptor.so.mobile # If we're only building this profile, then there's no need to copy the lib
440 popd
441 make clean # So that we can gather symbol/size information for only one profile if we're building all profiles
442 %endif
443 popd
444 %endif
445
446 # if tv ||"undefined"
447 %if "%{?profile}" != "wearable" && "%{?profile}" != "common" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
448 pushd tv
449 %make_install
450 %if "%{?profile}" != "tv"
451 pushd  %{buildroot}%{_libdir}
452 cp libdali2-adaptor.so.*.*.* libdali2-adaptor.so.tv # If we're only building this profile, then there's no need to copy the lib
453 popd
454 make clean # So that we can gather symbol/size information for only one profile if we're building all profiles
455 %endif
456 popd
457 %endif
458
459 # if wearable || "undefined"
460 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
461 pushd wearable
462 %make_install
463 %if "%{?profile}" != "wearable"
464 pushd  %{buildroot}%{_libdir}
465 cp libdali2-adaptor.so.*.*.* libdali2-adaptor.so.wearable # If we're only building this profile, then there's no need to copy the lib
466 popd
467 make clean # So that we can gather symbol/size information for only one profile if we're building all profiles
468 %endif
469 popd
470 %endif
471
472 # if ivi ||"undefined"
473 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "common" && "%{?profile}" != "mobile"
474 pushd ivi
475 %make_install
476 %if "%{?profile}" != "ivi"
477 pushd  %{buildroot}%{_libdir}
478 cp libdali2-adaptor.so.*.*.* libdali2-adaptor.so.ivi # If we're only building this profile, then there's no need to copy the lib
479 popd
480 make clean # So that we can gather symbol/size information for only one profile if we're building all profiles
481 %endif
482 popd
483 %endif
484
485 # if common ||"undefined"
486 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
487 pushd common
488 %make_install
489 # No clean so we can gather symbol/size information for the common profile
490 popd
491 %endif
492
493 # Create a symbolic link in integration-api to preserve legacy repo build
494 pushd %{buildroot}%{_includedir}/dali/integration-api
495 ln -sf adaptor-framework adaptors
496 popd
497
498 ##############################
499 # Upgrade order:
500 # 1 - Pre Install new package
501 # 2 - Install new package
502 # 3 - Post install new package
503 # 4 - Pre uninstall old package
504 # 5 - Remove files not overwritten by new package
505 # 6 - Post uninstall old package
506 ##############################
507
508 ##############################
509 # Adaptor package Commands
510 %pre
511 exit 0
512
513 %post
514 pushd %{_libdir}
515 for i in mobile tv wearable ivi; do [[ -f libdali2-adaptor.so.$i ]] && ln -sf libdali2-adaptor.so.$i libdali2-adaptor.so.2.0.0; done
516 popd
517 /sbin/ldconfig
518 exit 0
519
520 %preun
521 exit 0
522
523 %postun
524 /sbin/ldconfig
525 exit 0
526
527 ##############################
528 # Mobile Profile Commands
529 # if mobile || "undefined"
530 # No need to create a symbolic link on install required if only building this profile
531 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
532 %post profile_mobile
533 %if "%{?profile}" != "mobile"
534 pushd %{_libdir}
535 ln -sf libdali2-adaptor.so.mobile libdali2-adaptor.so.2.0.0
536 popd
537 %endif
538 /sbin/ldconfig
539 exit 0
540
541 %postun profile_mobile
542 /sbin/ldconfig
543 exit 0
544 %endif
545
546 ##############################
547 # TV Profile Commands
548 # No need to create a symbolic link on install required if only building this profile
549 %if "%{?profile}" != "wearable" && "%{?profile}" != "common" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
550 %post profile_tv
551 %if "%{?profile}" != "tv"
552 pushd %{_libdir}
553 ln -sf libdali2-adaptor.so.tv libdali2-adaptor.so.2.0.0
554 popd
555 %endif
556 /sbin/ldconfig
557 exit 0
558
559 %postun profile_tv
560 /sbin/ldconfig
561 exit 0
562 %endif
563
564 ##############################
565 # Wearable Profile Commands
566 # No need to create a symbolic link on install required if only building this profile
567 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
568 %post profile_wearable
569 %if "%{?profile}" != "wearable"
570 pushd %{_libdir}
571 ln -sf libdali2-adaptor.so.wearable libdali2-adaptor.so.2.0.0
572 popd
573 %endif
574 /sbin/ldconfig
575 exit 0
576
577 %postun profile_wearable
578 /sbin/ldconfig
579 exit 0
580 %endif
581
582 ##############################
583 # IVI Profile Commands
584 # No need to create a symbolic link on install required if only building this profile
585 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "common" && "%{?profile}" != "mobile"
586 %post profile_ivi
587 %if "%{?profile}" != "ivi"
588 pushd %{_libdir}
589 ln -sf libdali2-adaptor.so.ivi libdali2-adaptor.so.2.0.0
590 popd
591 %endif
592 /sbin/ldconfig
593 exit 0
594
595 %postun profile_ivi
596 /sbin/ldconfig
597 exit 0
598 %endif
599
600 ##############################
601 # Common Profile Commands
602 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
603 %post profile_common
604 /sbin/ldconfig
605 exit 0
606
607 %postun profile_common
608 /sbin/ldconfig
609 exit 0
610 %endif
611
612 ##############################
613 # Files in Binary Packages
614 ##############################
615
616 %files
617 %manifest dali-adaptor.manifest
618 %defattr(-,root,root,-)
619 %dir %{user_shader_cache_dir}
620 %{_bindir}/*
621 %license LICENSE
622 %defattr(-,root,root,-)
623 %{_libdir}/libdali2-adaptor.so
624 %{_libdir}/libdali2-adaptor.so.2
625 %{_libdir}/libdali2-adaptor.so.2.0.0
626
627 #################################################
628
629 %files dali2-feedback-plugin
630 %manifest dali-adaptor.manifest
631 %defattr(-,root,root,-)
632 %{_libdir}/libdali2-feedback-plugin.so*
633 %{dali_plugin_sound_files}/*
634
635 #################################################
636
637 # if common ||"undefined"
638 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
639 %files profile_common
640 %manifest dali-adaptor.manifest
641 # default .so files are housed in the main pkg.
642 %endif
643
644 # if mobile || "undefined"
645 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
646 %files profile_mobile
647 %manifest dali-adaptor.manifest
648 %defattr(-,root,root,-)
649 %if "%{?profile}" != "mobile"
650 %{_libdir}/libdali2-adaptor.so.mobile
651 %endif
652 %endif
653
654 # if tv ||"undefined"
655 %if "%{?profile}" != "wearable" && "%{?profile}" != "common" && "%{?profile}" != "ivi" && "%{?profile}" != "mobile"
656 %files profile_tv
657 %manifest dali-adaptor.manifest
658 %defattr(-,root,root,-)
659 %if "%{?profile}" != "tv"
660 %{_libdir}/libdali2-adaptor.so.tv
661 %endif
662 %endif
663
664 # if wearable || "undefined"
665 %if "%{?profile}" != "mobile" && "%{?profile}" != "tv" && "%{?profile}" != "ivi" && "%{?profile}" != "common"
666 %files profile_wearable
667 %manifest dali-adaptor.manifest
668 %defattr(-,root,root,-)
669 %if "%{?profile}" != "wearable"
670 %{_libdir}/libdali2-adaptor.so.wearable
671 %endif
672 %endif
673
674 # if ivi ||"undefined"
675 %if "%{?profile}" != "wearable" && "%{?profile}" != "tv" && "%{?profile}" != "common" && "%{?profile}" != "mobile"
676 %files profile_ivi
677 %manifest dali-adaptor.manifest
678 %defattr(-,root,root,-)
679 %if "%{?profile}" != "ivi"
680 %{_libdir}/libdali2-adaptor.so.ivi
681 %endif
682 %endif
683
684 %files devel
685 %defattr(-,root,root,-)
686 %{_includedir}/dali/dali.h
687 %{_includedir}/dali/public-api/*
688 %{_includedir}/dali/devel-api/*
689 %{_includedir}/dali/doc/*
690 %{_libdir}/pkgconfig/dali2-adaptor.pc
691
692 %files integration-devel
693 %defattr(-,root,root,-)
694 %{_includedir}/dali/integration-api/adaptor-framework/*
695 %{_includedir}/dali/integration-api/adaptors
696 %{_libdir}/pkgconfig/dali2-adaptor-integration.pc