X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=packaging%2Fail.spec;h=570a4ff1efd41964eec419b7d53ce77308f018d6;hb=refs%2Fchanges%2F34%2F34334%2F2;hp=e12447868c625040c0ab86bafc32cb0f1f78833a;hpb=d50c6b4dd4a45eb4fa472e7e7f38775bfd764544;p=platform%2Fcore%2Fappfw%2Fail.git diff --git a/packaging/ail.spec b/packaging/ail.spec index e124478..570a4ff 100755 --- a/packaging/ail.spec +++ b/packaging/ail.spec @@ -7,7 +7,6 @@ Group: Application Framework/Libraries Source0: %{name}-%{version}.tar.gz Source1001: ail.manifest BuildRequires: cmake -BuildRequires: vconf-keys-devel BuildRequires: pkgconfig(db-util) BuildRequires: pkgconfig(dlog) BuildRequires: pkgconfig(libsmack) @@ -24,6 +23,7 @@ Application Information Library package Summary: Application Information Library Development files Requires: libail = %{version}-%{release} Requires: pkgconfig(libtzplatform-config) +Requires: pkgconfig(libsmack) %description devel Application Information Library Development files package @@ -33,7 +33,7 @@ Application Information Library Development files package cp %{SOURCE1001} . %build -CFLAGS+=" -fpic" +CFLAGS="$CFLAGS -fpic" %if 0%{?tizen_build_binary_release_type_eng} export CFLAGS="$CFLAGS -DTIZEN_ENGINEER_MODE" @@ -42,55 +42,53 @@ export FFLAGS="$FFLAGS -DTIZEN_ENGINEER_MODE" %endif %cmake . -DTZ_SYS_RW_DESKTOP_APP=%TZ_SYS_RW_DESKTOP_APP \ - -DBUILD_PKGTYPE=rpm \ - -DSMACK=Off + -DBUILD_PKGTYPE=rpm %__make %{?_smp_mflags} %install %make_install -mkdir -p %{buildroot}%{TZ_SYS_DB}/ -mkdir -p %{buildroot}%{TZ_SYS_RW_DESKTOP_APP}/ - %post -/sbin/ldconfig -vconftool set -t string db/ail/ail_info "0" -f -s system::vconf_inhouse -vconftool set -t string db/menuscreen/desktop "0" -f -s system::vconf_inhouse -vconftool set -t string db/menu_widget/language "en_US.utf8" -f -s system::vconf_inhouse -chsmack -a User %TZ_SYS_CONFIG/db/ail -chsmack -a User %TZ_SYS_CONFIG/db/ail/ail_info -chsmack -a User %TZ_SYS_CONFIG/db/menuscreen -chsmack -a User %TZ_SYS_CONFIG/db/menuscreen/desktop -chsmack -a User %TZ_SYS_CONFIG/db/menu_widget -chsmack -a User %TZ_SYS_CONFIG/db/menu_widget/language - -CHDBGID="6010" - -update_DAC_for_db_file() -{ - if [ ! -f $@ ]; then - touch $@ - fi - - chown :$CHDBGID $@ 2>/dev/null - if [ $? -ne 0 ]; then - echo "Failed to change the owner of $@" - fi - chmod 664 $@ 2>/dev/null - if [ $? -ne 0 ]; then - echo "Failed to change the perms of $@" - fi -} -ail_initdb 2>/dev/null +ldconfig +# Create tizenglobalapp user needed for global installation +useradd -d %TZ_SYS_RW_APP -m %TZ_SYS_GLOBALAPP_USER -r -c "system user for common applications" -g root + +#mkdir -p %%TZ_SYS_RW_APP/.config/xwalk-service/applications +#cd %%TZ_SYS_RW_APP/ +#ln -s .config/xwalk-service/applications/ + +vconftool set -t string db/ail/ail_info "0" -f -s User +vconftool set -t string db/menuscreen/desktop "0" -f -s User +vconftool set -t string db/menu_widget/language "en_US.utf8" -f -s User + mkdir -p %{TZ_SYS_RO_DESKTOP_APP} mkdir -p %{TZ_SYS_RW_DESKTOP_APP} +mkdir -p %{TZ_SYS_RW_APP} mkdir -p %{TZ_SYS_DB} - -update_DAC_for_db_file %{TZ_SYS_DB}/.app_info.db -update_DAC_for_db_file %{TZ_SYS_DB}/.app_info.db-journal -chsmack -a 'User' %{TZ_SYS_DB}/.app_info.db* - +mkdir -p %{TZ_SYS_RW_ICONS}/default/small + +chsmack -a '*' %{TZ_SYS_DB} +chsmack -a '*' %{TZ_SYS_RW_APP} +chsmack -a '*' %{TZ_SYS_RW_DESKTOP_APP} +chsmack -a '*' %{TZ_SYS_RO_DESKTOP_APP} +chsmack -a '*' %{TZ_SYS_RW_ICONS} +chsmack -a '*' %{TZ_SYS_RW_ICONS}/default +chsmack -a '*' %{TZ_SYS_RW_ICONS}/default/small/ + +chmod g+w %{TZ_SYS_RW_DESKTOP_APP} +chmod g+w %{TZ_SYS_RO_DESKTOP_APP} +chown %TZ_SYS_GLOBALAPP_USER:root %{TZ_SYS_RW_DESKTOP_APP} +chown %TZ_SYS_GLOBALAPP_USER:root %{TZ_SYS_RO_DESKTOP_APP} +chown %TZ_SYS_GLOBALAPP_USER:root %{TZ_SYS_RW_APP} +chown %TZ_SYS_GLOBALAPP_USER:root %{TZ_SYS_DB} +chown %TZ_SYS_GLOBALAPP_USER:root %{TZ_SYS_DB} +chown %TZ_SYS_GLOBALAPP_USER:root -R %{TZ_SYS_RW_ICONS} + +ail_createdb 2>/dev/null +ail_syncdb 2>/dev/null +chsmack -a '*' %{TZ_SYS_DB}/.app_info.db* + %postun /sbin/ldconfig if [ $1 == 0 ]; then @@ -100,9 +98,13 @@ fi %files %manifest %{name}.manifest %license LICENSE -%dir %{TZ_SYS_RW_DESKTOP_APP} -%{_bindir}/ail_initdb -%{_bindir}/ail_initdb +%attr(06775,root,root) %{_bindir}/ail_createdb +%attr(0775,root,root) %{_bindir}/ail_createdb_user +%attr(06775,root,root) %{_bindir}/ail_syncdb +%attr(0775,root,root) %{_bindir}/ail_syncdb_user +#obsolete tools +%attr(06775,root,root) %{_bindir}/ail_initdb +%attr(0775,root,root) %{_bindir}/ail_initdb_user %{_bindir}/ail_fota %{_bindir}/ail_desktop %{_bindir}/ail_filter