-#sbs-git:slp/pkgs/w/wrt-commons wrt-commons 0.2.67
+#git:framework/web/wrt-commons wrt-commons 0.2.115
Name: wrt-commons
Summary: Wrt common library
-Version: 0.2.67
+Version: 0.2.115
Release: 1
Group: Development/Libraries
License: Apache License, Version 2.0
BuildRequires: pkgconfig(openssl)
BuildRequires: pkgconfig(libiri)
BuildRequires: pkgconfig(libidn)
+BuildRequires: pkgconfig(cryptsvc)
+BuildRequires: pkgconfig(dukgenerator)
+Requires: libcryptsvc
%description
Wrt common library
%prep
%setup -q
+%define with_tests 0
+%if "%{WITH_TESTS}" == "ON" || "%{WITH_TESTS}" == "Y" || "%{WITH_TESTS}" == "YES" || "%{WITH_TESTS}" == "TRUE" || "%{WITH_TESTS}" == "1"
+ %define with_tests 1
+%endif
+
%build
+
export LDFLAGS+="-Wl,--rpath=%{_libdir} -Wl,--hash-style=both -Wl,--as-needed"
cmake . -DVERSION=%{version} \
-DDPL_LOG="OFF" \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
- -DCMAKE_BUILD_TYPE=%{?build_type:%build_type}
+ -DCMAKE_BUILD_TYPE=%{?build_type:%build_type} \
+ %{?WITH_TESTS:-DWITH_TESTS=%WITH_TESTS}
make %{?jobs:-j%jobs}
%install
# Set Smack label for db files
chsmack -a 'wrt-commons::db_wrt' /opt/dbspace/.wrt.db
chsmack -a 'wrt-commons::db_wrt' /opt/dbspace/.wrt.db-journal
-chsmack -a 'wrt-commons::db_wrt_autosave' /opt/dbspace/.wrt_autosave.db
-chsmack -a 'wrt-commons::db_wrt_autosave' /opt/dbspace/.wrt_autosave.db-journal
+chsmack -a 'wrt-commons::db_wrt_custom_handler' /opt/usr/dbspace/.wrt_custom_handler.db
+chsmack -a 'wrt-commons::db_wrt_custom_handler' /opt/usr/dbspace/.wrt_custom_handler.db-journal
echo "[WRT] wrt-commons postinst done ..."
%manifest wrt-commons.manifest
%{_libdir}/*.so
%{_libdir}/*.so.*
-/usr/share/wrt-engine/*
-%attr(775,root,root) %{_bindir}/wrt_commons_reset_db.sh
-%attr(775,root,root) %{_bindir}/wrt_commons_create_clean_db.sh
+%{_datadir}/wrt-engine/*
%{_datadir}/license/%{name}
+%attr(755,root,root) %{_bindir}/wrt_commons_create_clean_db.sh
+%attr(755,root,root) %{_bindir}/wrt_commons_reset_db.sh
+%if %{with_tests}
+ %attr(755,root,root) %{_bindir}/wrt-commons-tests-*
+ %attr(755,root,root) %{_bindir}/wrt_dao_tests_prepare_db.sh
+ %attr(755,root,root) %{_bindir}/wrt_db_localization_prepare.sh
+ %{_datadir}/dbus-1/services/org.tizen.DBusTestService.service
+ /opt/share/wrt/wrt-commons/tests/*
+ /opt/share/widget/tests/localization/*
+%endif
%files devel
%{_includedir}/dpl-efl/*