3 Name: com.samsung.dali-demo
4 Summary: The OpenGLES Canvas Core Demo
7 Group: System/Libraries
9 URL: https://review.tizen.org/git/?p=platform/core/uifw/dali-demo.git;a=summary
10 Source0: %{name}-%{version}.tar.gz
12 Requires(post): /sbin/ldconfig
13 Requires(postun): /sbin/ldconfig
16 BuildRequires: pkgconfig
17 BuildRequires: pkgconfig(capi-appfw-application)
18 BuildRequires: pkgconfig(capi-media-player)
19 BuildRequires: pkgconfig(dlog)
20 BuildRequires: gettext-tools
21 BuildRequires: pkgconfig(dali-core)
22 BuildRequires: pkgconfig(dali-toolkit)
24 #need libtzplatform-config for directory if tizen version is 3.x
25 %if 0%{?tizen_version_major} >= 3
26 BuildRequires: pkgconfig(libtzplatform-config)
29 # DALi C++ applications always run on dali-adaptor.
30 BuildRequires: pkgconfig(dali-adaptor)
33 The OpenGLES Canvas Core Demo is a collection of examples and demonstrations
34 of the capability of the toolkit.
36 ##############################
38 ##############################
42 #Use TZ_PATH when tizen version is 3.x
44 %if "%{tizen_version_major}" == "2"
45 %define dali_app_ro_dir /usr/apps/com.samsung.dali-demo/
46 %define dali_xml_file_dir /usr/share/packages/
47 %define dali_icon_dir /usr/share/icons/
48 %define smack_rule_dir /etc/smack/accesses2.d/
50 %define dali_app_ro_dir %TZ_SYS_RO_APP/com.samsung.dali-demo/
51 %define dali_xml_file_dir %TZ_SYS_RO_PACKAGES
52 %define dali_icon_dir %TZ_SYS_RO_ICONS
53 %define smack_rule_dir %TZ_SYS_SMACK/accesses2.d/
56 %define dali_app_res_dir %{dali_app_ro_dir}/res/
57 %define dali_app_exe_dir %{dali_app_ro_dir}/bin/
58 %define locale_dir %{dali_app_res_dir}/locale
59 %define local_style_dir ../../resources/style/mobile
61 ##############################
63 ##############################
66 CXXFLAGS+=" -Wall -g -O2"
67 LDFLAGS+=" -Wl,--rpath=$PREFIX/lib -Wl,--as-needed"
70 CXXFLAGS+=" -D_ARCH_ARM_"
73 cd %{_builddir}/%{name}-%{version}/build/tizen
75 cmake -DDALI_APP_DIR=%{dali_app_ro_dir} \
76 -DLOCALE_DIR=%{locale_dir} \
77 -DDALI_APP_RES_DIR=%{dali_app_res_dir} \
79 -DCMAKE_BUILD_TYPE=Debug \
81 -DLOCAL_STYLE_DIR=%{local_style_dir} \
82 -DINTERNATIONALIZATION:BOOL=OFF \
87 ##############################
89 ##############################
93 %make_install DALI_APP_DIR=%{dali_app_ro_dir}
94 %make_install DDALI_APP_RES_DIR=%{dali_app_res_dir}
96 mkdir -p %{buildroot}%{dali_xml_file_dir}
97 cp -f %{_builddir}/%{name}-%{version}/%{name}.xml %{buildroot}%{dali_xml_file_dir}
99 mkdir -p %{buildroot}%{dali_icon_dir}
100 mv %{buildroot}/%{dali_app_res_dir}/images/%{name}.png %{buildroot}%{dali_icon_dir}
101 mv %{buildroot}/%{dali_app_res_dir}/images/dali-examples.png %{buildroot}%{dali_icon_dir}
103 %if 0%{?enable_dali_smack_rules} && !%{with wayland}
104 mkdir -p %{buildroot}%{smack_rule_dir}
105 cp -f %{_builddir}/%{name}-%{version}/%{name}.rule %{buildroot}%{smack_rule_dir}
109 ##############################
111 ##############################
116 ##############################
118 ##############################
123 ##############################
124 # Files in Binary Packages
125 ##############################
128 %if 0%{?enable_dali_smack_rules}
129 %manifest com.samsung.dali-demo.manifest-smack
131 %manifest com.samsung.dali-demo.manifest
133 %defattr(-,root,root,-)
134 %{dali_app_exe_dir}/dali-demo
135 %{dali_app_exe_dir}/dali-examples
136 %{dali_app_exe_dir}/*.example
137 %{dali_app_exe_dir}/dali-builder
138 %{dali_app_res_dir}/images/*
139 %{dali_app_res_dir}/game/*
140 %{dali_app_res_dir}/videos/*
141 %{dali_app_res_dir}/models/*
142 %{dali_app_res_dir}/scripts/*
143 %{dali_app_res_dir}/shaders/*
144 %{dali_app_res_dir}/style/*
145 %{dali_app_res_dir}/style/images/*
146 %{dali_xml_file_dir}/%{name}.xml
149 %if 0%{?enable_dali_smack_rules} && !%{with wayland}
150 %config %{smack_rule_dir}/%{name}.rule