SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed")
INCLUDE(FindPkgConfig)
-
-IF(TIZEN_FEATURE_APP2SD_PLUGIN)
- ADD_DEFINITIONS("-DTIZEN_FEATURE_APP2SD_PLUGIN")
- ADD_DEFINITIONS("-DTIZEN_FEATURE_APP2SD_DMCRYPT_ENCRYPTION")
- ADD_SUBDIRECTORY(plugin/app2sd)
-ENDIF(TIZEN_FEATURE_APP2SD_PLUGIN)
-
-# app2ext library
pkg_check_modules(app2ext_libpkgs REQUIRED dlog glib-2.0)
FOREACH(flag ${app2ext_libpkgs_CFLAGS})
SET(CMAKE_C_FLAGS "${EXTRA_CFLAGS} ${APP2EXT_CFLAGS}")
ADD_DEFINITIONS("-DLIBPREFIX=\"${LIB_INSTALL_DIR}\"")
+ADD_DEFINITIONS("-DTIZEN_FEATURE_APP2SD_DMCRYPT_ENCRYPTION")
# Local include directories
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/inc)
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/app2sd.pc DESTINATION ${LIB_INSTALL_DIR}/pkgconfig)
INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/inc/ DESTINATION include)
-IF(TIZEN_FEATURE_APP2SD_PLUGIN)
+ADD_SUBDIRECTORY(plugin/app2sd)
ADD_SUBDIRECTORY(test)
-ENDIF(TIZEN_FEATURE_APP2SD_PLUGIN)
BuildRequires: pkgconfig(pkgmgr)
BuildRequires: cmake
-%if "%{?profile}" == "common"
-%define tizen_feature_app2sd_plugin 1
-%endif
-
-%if "%{?profile}" == "mobile"
-%define tizen_feature_app2sd_plugin 1
-%endif
-
-%if "%{?profile}" == "tv"
-%define tizen_feature_app2sd_plugin 1
-%endif
-
%description
Tizen application installation on external memory
%description test
Tizen application installation on external memory (test)
+%package plugin
+Summary: app2sd server and plugin library
+Group: Application Framework/Package Management
+
+%description plugin
+app2sd server and plugin library
+
%prep
%setup -q
%build
-%if 0%{?tizen_feature_app2sd_plugin}
-_APP2SD_PLUGIN=ON
-%else
-_APP2SD_PLUGIN=OFF
-%endif
-
-%cmake . -DUNITDIR=%{_unitdir} \
- -DTIZEN_FEATURE_APP2SD_PLUGIN:BOOL=${_APP2SD_PLUGIN}
+%cmake . -DUNITDIR=%{_unitdir}
make %{?jobs:-j%jobs}
%postun -p /sbin/ldconfig
%files
-%manifest app2sd.manifest
+%manifest %{name}.manifest
%defattr(-,root,root,-)
%{_libdir}/libapp2ext.so.*
-%if 0%{?tizen_feature_app2sd_plugin}
-%{_libdir}/libapp2sd.so*
-%{_bindir}/app2sd-server
-%{_unitdir}/app2sd-server.service
-%{_datadir}/dbus-1/system-services/org.tizen.app2sd.service
-%config %{_sysconfdir}/dbus-1/system.d/org.tizen.app2sd.conf
-%endif
/usr/share/license/%{name}
%files devel
%defattr(-,root,root,-)
%{_includedir}/*.h
%{_libdir}/pkgconfig/app2sd.pc
-%if 0%{?tizen_feature_app2sd_plugin}
-%{_libdir}/libapp2sd.so
-%endif
%{_libdir}/libapp2ext.so
-%if 0%{?tizen_feature_app2sd_plugin}
%files test
%defattr(-,root,root,-)
%{_bindir}/test_app2ext
-%endif
+
+%files plugin
+%{_libdir}/libapp2sd.so*
+%{_bindir}/app2sd-server
+%{_unitdir}/app2sd-server.service
+%{_datadir}/dbus-1/system-services/org.tizen.app2sd.service
+%config %{_sysconfdir}/dbus-1/system.d/org.tizen.app2sd.conf