first integration for xwalk
authorStephane Desneux <stephane.desneux@open.eurogiciel.org>
Thu, 13 Mar 2014 13:32:15 +0000 (14:32 +0100)
committerStephane Desneux <stephane.desneux@open.eurogiciel.org>
Thu, 13 Mar 2014 13:32:15 +0000 (14:32 +0100)
Change-Id: I11eb82d22a2cf3a643a14bc722720a5fb795ca4d
Signed-off-by: Stephane Desneux <stephane.desneux@open.eurogiciel.org>
install_widgets.sh
launchpad [deleted file]
packaging/wrt-widgets.spec
prepare_widgets.sh
wrt [deleted file]

index 84ccc7b..6376c72 100755 (executable)
@@ -16,40 +16,45 @@ fi
 for wgt in $wgtdir/*.wgt
 do 
     echo "installing $wgt"
-    wrt-installer -i $wgt
+       if [ -x /usr/bin/wrt-installer ]; then
+               wrt-installer -i $wgt
+       else
+               xwalkctl -i $wgt
+       fi
 done
 
-
 repo=/opt/usr/apps/
 chmod -R a+rw /opt/dbspace/
 
-wrt-launcher --list |
-awk 'NR>2{print $2, $5, $6}' |
-while read name packid appid
-do
-    bin=$repo/$packid/bin/$appid
-    for x in $repo/$packid/res/wgt/*[iI][cC][oO][nN]*; do
-       if [[ -f $x ]]; then
-           res=$(file -b $x|cut -d , -f 2|tr -d ' '|egrep '[0-9]+x[0-9]+')
-           if [[ -n "$res" ]]; then
-               diric=/usr/share/icons/hicolor/$res/apps
-               [[ -d $diric ]] || mkdir -p $diric
-               cp $x $diric/$name.png
-           fi
-       fi
-   done
-    desk=/usr/share/applications/$name.desktop
-    cat << EOC > $desk
-[Desktop Entry]
-Type=Application
-Name=$name
-Exec=$bin
-Icon=$name
-Terminal=false
-Categories=WRT;Game
+if [ -x /usr/bin/wrt-launcher ]; then
+       wrt-launcher --list |
+       awk 'NR>2{print $2, $5, $6}' |
+       while read name packid appid
+       do
+               bin=$repo/$packid/bin/$appid
+               for x in $repo/$packid/res/wgt/*[iI][cC][oO][nN]*; do
+               if [[ -f $x ]]; then
+                       res=$(file -b $x|cut -d , -f 2|tr -d ' '|egrep '[0-9]+x[0-9]+')
+                       if [[ -n "$res" ]]; then
+                       diric=/usr/share/icons/hicolor/$res/apps
+                       [[ -d $diric ]] || mkdir -p $diric
+                       cp $x $diric/$name.png
+                       fi
+               fi
+          done
+               desk=/usr/share/applications/$name.desktop
+               cat << EOC > $desk
+       [Desktop Entry]
+       Type=Application
+       Name=$name
+       Exec=$bin
+       Icon=$name
+       Terminal=false
+       Categories=WRT;Game
 EOC
-done
+       done
+fi
 
-update-desktop-database
-xdg-icon-resource forceupdate
+#update-desktop-database
+#xdg-icon-resource forceupdate
 
diff --git a/launchpad b/launchpad
deleted file mode 100644 (file)
index 844ad4c..0000000
--- a/launchpad
+++ /dev/null
@@ -1,2 +0,0 @@
-DISPLAY=:0
-XAUTHORITY=/run/.x11WRT
index 588ea72..fbe246b 100644 (file)
@@ -6,17 +6,9 @@ Group:      Web Framework/Web Run Time
 License:    Apache-2.0
 BuildArch:  noarch
 Source0:    %{name}-%{version}.tar.gz
-Requires:   wrt
-Requires:   wrt-commons
-Requires:   wrt-installer 
-Requires:   wrt-plugins-tizen
-Requires:   wrt-security
-##  Requires:   daemon-launch-config-pc
-##  Requires:   dbus-config-pc
-Requires:   libprivilege-control-conf
 
 %description
-Wrt-widgets prepare a suitable pc oriented environment to install WRT widgets
+Wrt-widgets prepare a suitable pc oriented environment to install Web apps
 After installing wrt-widgets, launch install_widgets.sh script as root to install them.
 
 %prep
@@ -30,14 +22,6 @@ mkdir -p %{buildroot}/%{_bindir}
 cp install_widgets.sh %{buildroot}/%{_bindir}
 cp prepare_widgets.sh %{buildroot}/%{_bindir}
 
-if [ ! -d %{buildroot}/%{_sysconfdir}/sysconfig ]
-then
-       mkdir -p %{buildroot}/%{_sysconfdir}/sysconfig
-fi
-cp wrt %{buildroot}/%{_sysconfdir}/sysconfig/
-cp launchpad %{buildroot}/%{_sysconfdir}/sysconfig/
-
-
 if [ ! -d %{buildroot}/%{_datadir}/widget_demo ]
 then
     mkdir -p  %{buildroot}/%{_datadir}/widget_demo
@@ -51,5 +35,3 @@ cp -r *.wgt %{buildroot}/%{_datadir}/widget_demo/
 %{_datadir}/widget_demo/*.wgt
 %attr(755,root,root) %{_bindir}/install_widgets.sh
 %attr(755,root,root) %{_bindir}/prepare_widgets.sh
-%attr(644,root,root) %{_sysconfdir}/sysconfig/wrt
-%attr(644,root,root) %{_sysconfdir}/sysconfig/launchpad
index 739ccc1..daff164 100755 (executable)
@@ -2,23 +2,25 @@
 
 ##### vconf create table from settings package #########################
 # Set vconf values with -g/-u options
-GOPTION="-g 6514"
 
 rm -rf /opt/data/setting/set_info
 
 #### Bluetotth API ####################################################
-vconftool $GOPTION set -t string db/menu_widget/regionformat "en_GB.UTF-8"
-vconftool $GOPTION set -t int db/menu_widget/regionformat_time1224 "1"
-vconftool $GOPTION set -t string db/setting/accessibility/font_name "HelveticaNeue"
+vconftool set -t string db/menu_widget/regionformat "en_GB.UTF-8"
+vconftool set -t int db/menu_widget/regionformat_time1224 "1"
+vconftool set -t string db/setting/accessibility/font_name "HelveticaNeue"
 
 ########################################################################
 #  PC Specific Environment settings
 
 
 mkdir -p /opt/share/packages
-rm /opt/dbspace/.wrt*
-wrt_commons_create_clean_db.sh
-wrt_reset_db.sh
+rm -f /opt/dbspace/.wrt*
+
+if [ -x /usr/bin/wrt-client ]; then
+       wrt_commons_create_clean_db.sh
+       wrt_reset_db.sh
+fi
 pkg_initdb
 ail_initdb
 
diff --git a/wrt b/wrt
deleted file mode 100644 (file)
index 844ad4c..0000000
--- a/wrt
+++ /dev/null
@@ -1,2 +0,0 @@
-DISPLAY=:0
-XAUTHORITY=/run/.x11WRT