Add monitor plugin requires for install dependency
[platform/core/connectivity/stc-manager.git] / packaging / stc-manager.spec
index b379e73..fbcc37b 100644 (file)
@@ -1,6 +1,6 @@
 Name:       stc-manager
 Summary:    STC(Smart Traffic Control) manager
-Version:    0.0.72
+Version:    0.0.92
 Release:    0
 Group:      Network & Connectivity/Other
 License:    Apache-2.0
@@ -40,6 +40,7 @@ A smart traffic control manager to manage traffic counting and bandwidth limitat
 Summary: STC manager application status plugin
 BuildRequires: pkgconfig(bundle)
 BuildRequires: pkgconfig(syspopup-caller)
+Requires:      stc-manager-plugin-monitor
 
 %description plugin-appstatus
 A smart traffic control manager extension for application status plugin
@@ -47,25 +48,56 @@ A smart traffic control manager extension for application status plugin
 %package plugin-exception
 Summary: STC manager exception list plugin
 BuildRequires:  pkgconfig(pkgmgr-info)
+Requires:      stc-manager-plugin-monitor
 
 %description plugin-exception
 A smart traffic control manager extension for exception list plugin
 
 %package plugin-procfs
 Summary: STC manager exception proc file system plugin
+Requires:      stc-manager-plugin-monitor
 
 %description plugin-procfs
 A smart traffic control manager extension for proc file system plugin
 
+%package plugin-pcap
+Summary: STC manager exception packet capture plugin
+BuildRequires:  libpcap-devel
+
+%description plugin-pcap
+A smart traffic control manager extension for packet capture plugin
+
+%package plugin-tether
+Summary: Tethering plugin for data usage of tethering clients
+Requires:      stc-manager-plugin-monitor
+
+%description plugin-tether
+A smart traffic control manager extension for tethering client data usage plugin
+
+%package plugin-monitor
+Summary: Monitor plugin for data usage of clients
+
+%description plugin-monitor
+A smart traffic control manager extension for monitoring client data usage plugin
+
+%package plugin-firewall
+Summary: Firewall plugin for managing firewall rules
+
+%description plugin-firewall
+A smart traffic control manager extension for firewall plugin
+
 %prep
 %setup -q
 chmod 644 %{SOURCE0}
 
 %build
 
-export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE -D_GNU_SOURCE"
-export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE -D_GNU_SOURCE"
-export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+export CFLAGS="$CFLAGS -D_GNU_SOURCE"
+export CXXFLAGS="$CXXFLAGS -D_GNU_SOURCE"
+
+%if "%{tizen_profile_name}" == "tv"
+       CFLAGS+=" -DTIZEN_TV_EXT"
+%endif
 
 %cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} \
        -DBIN_DIR=%{_bindir} \
@@ -108,6 +140,9 @@ ln -s ../stc-manager.service %{buildroot}%{_libdir}/systemd/system/multi-user.ta
 mkdir -p %{buildroot}%{_sysconfdir}/dbus-1/system.d
 cp resources/dbus/stc-manager.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/stc-manager.conf
 
+mkdir -p %{buildroot}%{_datadir}/dbus-1/system-services/
+cp resources/dbus/net.stc-manager.service %{buildroot}%{_datadir}/dbus-1/system-services/net.stc-manager.service
+
 %files
 %manifest %{name}.manifest
 %license LICENSE
@@ -117,11 +152,12 @@ cp resources/dbus/stc-manager.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/st
 %attr(644,root,root) %{_libdir}/systemd/system/stc-manager.service
 %attr(644,root,root) %{_libdir}/systemd/system/multi-user.target.wants/stc-manager.service
 
-%attr(755,root,root) /%{_localstatedir}/lib/stc
+%attr(755,network_fw,network_fw) /%{_localstatedir}/lib/stc
 %attr(600,root,root) /%{_localstatedir}/lib/stc/exceptions
 
 #DBus DAC
 %attr(644,root,root) %{_sysconfdir}/dbus-1/system.d/*
+%attr(644,root,root) %{_datadir}/dbus-1/system-services/*
 
 %if %{?enable_database} == YES
 %config(noreplace) %attr(660, root, root) %{database_full_path}
@@ -144,3 +180,19 @@ cp resources/dbus/stc-manager.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/st
 %files plugin-procfs
 %manifest %{name}.manifest
 %attr(500,root,root) %{_libdir}/stc-plugin-procfs.so
+
+%files plugin-pcap
+%manifest %{name}.manifest
+%attr(500,root,root) %{_libdir}/stc-plugin-pcap.so
+
+%files plugin-tether
+%manifest %{name}.manifest
+%attr(500,root,root) %{_libdir}/stc-plugin-tether.so
+
+%files plugin-monitor
+%manifest %{name}.manifest
+%attr(500,root,root) %{_libdir}/stc-plugin-monitor.so
+
+%files plugin-firewall
+%manifest %{name}.manifest
+%attr(500,root,root) %{_libdir}/stc-plugin-firewall.so