2 Summary: A multimedia daemon
5 Group: System/Libraries
7 Source0: %{name}-%{version}.tar.gz
8 Source1: muse-server.service
10 Source3: muse-server-vd_product_tv.path
11 Source4: muse-server-vd_product_tv.service
12 Source5: muse-server-vd_product_audio.service
13 Source6: %{name}.notstrip
15 BuildRequires: pkgconfig(libsystemd)
16 BuildRequires: pkgconfig(capi-system-info)
17 BuildRequires: pkgconfig(capi-system-runtime-info)
18 BuildRequires: pkgconfig(cynara-client)
19 BuildRequires: pkgconfig(cynara-creds-socket)
20 BuildRequires: pkgconfig(cynara-session)
21 BuildRequires: pkgconfig(dlog)
22 BuildRequires: pkgconfig(gio-2.0)
23 BuildRequires: pkgconfig(glib-2.0)
24 BuildRequires: pkgconfig(gmodule-2.0)
25 BuildRequires: pkgconfig(gstreamer-1.0)
26 BuildRequires: pkgconfig(gstreamer-base-1.0)
27 BuildRequires: pkgconfig(iniparser)
28 BuildRequires: pkgconfig(json-c)
29 BuildRequires: pkgconfig(libtbm)
30 BuildRequires: pkgconfig(libtzplatform-config)
31 BuildRequires: pkgconfig(mm-common)
32 BuildRequires: pkgconfig(storage)
33 %if "%{tizen_profile_name}" == "tv"
34 BuildRequires: pkgconfig(libresourced)
35 BuildRequires: pkgconfig(lwipc)
36 BuildRequires: pkgconfig(ttrace)
38 BuildRequires: pkgconfig(mm-resource-manager)
41 BuildRequires: pkgconfig(gmock)
44 Requires(post): /sbin/ldconfig
45 Requires(postun): /sbin/ldconfig
46 Requires: security-config
52 Summary: A Media Daemon library in Tizen (Development)
53 Group: Multimedia/Service
54 Requires: %{name} = %{version}-%{release}
61 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
62 export CFLAGS="$CFLAGS -DSYSCONFDIR=\\\"%{_sysconfdir}\\\""
63 export CXXFLAGS="$CXXFLAGS -DSYSCONFDIR=\\\"%{_sysconfdir}\\\""
65 %if 0%{?sec_build_binary_debug_enable}
66 export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE -D_GNU_SOURCE"
67 export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE -D_GNU_SOURCE"
68 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE -D_GNU_SOURCE"
72 export CFLAGS+=" -fprofile-arcs -ftest-coverage -DMUSE_GCOV_TEST "
73 export CXXFLAGS+=" -fprofile-arcs -ftest-coverage -DMUSE_GCOV_TEST "
74 export LDFLAGS+=" -lgcov "
77 %if ("%{_vd_cfg_product_type}" == "AUDIO") || ("%{_vd_cfg_product_type}" == "TV") || ("%{_vd_cfg_product_type}" == "LFD") || ("%{_vd_cfg_product_type}" == "HTV") || ("%{_vd_cfg_product_type}" == "AV") || ("%{_vd_cfg_product_type}" == "IWB") || ("%{_vd_cfg_product_type}" == "WALL")
78 export CFLAGS+=" -DMUSE_REGISTER_VIP -DMUSE_USE_LWIPC -DMUSE_TTRACE_LOG"
79 %cmake . -DCMAKE_INSTALL_PREFIX=/usr -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DLIBDIR=%{_libdir} -DTZ_SYS_DATA=%TZ_SYS_DATA -DMUSE_REGISTER_VIP=1 -DMUSE_TTRACE_LOG=1 -DMUSE_USE_LWIPC=1
81 export CFLAGS+=" -DMUSE_USE_POWER_OFF_STATE_CHANGE -DMUSE_USE_EXTERNAL_STORAGE_STATE_CHANGE -DMUSE_USE_WATCHDOG"
82 %cmake . -DCMAKE_INSTALL_PREFIX=/usr -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DLIBDIR=%{_libdir} -DTZ_SYS_DATA=%TZ_SYS_DATA -DMUSE_GTESTS_BUILD=%{?gtests:1}%{!?gtests:0}
92 %if ("%{_vd_cfg_product_type}" == "AUDIO")
93 mkdir -p %{buildroot}%{_unitdir}/stater.target.wants
94 install -m 0644 %SOURCE5 %{buildroot}%{_unitdir}/muse-server.service
95 %install_service starter.target.wants muse-server.service
97 mkdir -p %{buildroot}%{_sysconfdir}/notstrip
98 install -m 0644 %SOURCE6 %{buildroot}%{_sysconfdir}/notstrip/%{name}.notstrip
100 %if ("%{_vd_cfg_product_type}" == "TV") || ("%{_vd_cfg_product_type}" == "LFD") || ("%{_vd_cfg_product_type}" == "HTV") || ("%{_vd_cfg_product_type}" == "AV") || ("%{_vd_cfg_product_type}" == "IWB") || ("%{_vd_cfg_product_type}" == "WALL")
101 mkdir -p %{buildroot}%{_unitdir}/basic.target.wants
102 install -m 0644 %SOURCE4 %{buildroot}%{_unitdir}/muse-server.service
103 %install_service basic.target.wants muse-server.service
105 mkdir -p %{buildroot}%{_sysconfdir}/notstrip
106 install -m 0644 %SOURCE6 %{buildroot}%{_sysconfdir}/notstrip/%{name}.notstrip
107 install -m 0644 %SOURCE3 %{buildroot}%{_unitdir}/muse-server.path
109 mkdir -p %{buildroot}%{_unitdir}/multi-user.target.wants
110 install -m 0644 %SOURCE1 %{buildroot}%{_unitdir}/muse-server.service
111 %install_service multi-user.target.wants muse-server.service
116 mkdir -p %{buildroot}/var/log/%{name}
117 mkdir -p %{buildroot}%{TZ_SYS_DATA}/%{name}
120 install -m 0644 %SOURCE2 %{buildroot}%{TZ_SYS_DATA}/%{name}/gtest.input
126 chown multimedia_fw:multimedia_fw %{TZ_SYS_DATA}/%{name}
127 chown multimedia_fw:multimedia_fw /var/log/%{name}
128 chsmack -a "System::Shared" %{TZ_SYS_DATA}/%{name}
129 chsmack -a "System::Shared" /var/log/%{name}
131 %postun -p /sbin/ldconfig
135 %manifest %{name}.manifest
136 %{_libdir}/libmuse-*.so.*
137 %license LICENSE.APLv2
138 %{_unitdir}/muse-server.service
139 %if ("%{_vd_cfg_product_type}" == "AUDIO")
140 %{_unitdir}/starter.target.wants/muse-server.service
142 %if ("%{_vd_cfg_product_type}" == "TV") || ("%{_vd_cfg_product_type}" == "LFD") || ("%{_vd_cfg_product_type}" == "HTV") || ("%{_vd_cfg_product_type}" == "AV") || ("%{_vd_cfg_product_type}" == "IWB") || ("%{_vd_cfg_product_type}" == "WALL")
143 %{_unitdir}/basic.target.wants/muse-server.service
145 %{_unitdir}/multi-user.target.wants/muse-server.service
148 %if ("%{_vd_cfg_product_type}" == "TV") || ("%{_vd_cfg_product_type}" == "LFD") || ("%{_vd_cfg_product_type}" == "HTV") || ("%{_vd_cfg_product_type}" == "AV") || ("%{_vd_cfg_product_type}" == "IWB") || ("%{_vd_cfg_product_type}" == "WALL")
149 %{_unitdir}/muse-server.path
151 %if ("%{_vd_cfg_product_type}" == "AUDIO") || ("%{_vd_cfg_product_type}" == "TV") || ("%{_vd_cfg_product_type}" == "LFD") || ("%{_vd_cfg_product_type}" == "HTV") || ("%{_vd_cfg_product_type}" == "AV") || ("%{_vd_cfg_product_type}" == "IWB") || ("%{_vd_cfg_product_type}" == "WALL")
152 %{_sysconfdir}/notstrip/%{name}.notstrip
154 %{TZ_SYS_DATA}/%{name}
159 %{TZ_SYS_DATA}/%{name}/gtest.input
160 %{_bindir}/gtest-muse-server
164 %{_includedir}/media/*.h
165 %{_libdir}/pkgconfig/*.pc