Check-in [83ee6544bd]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview

SHA1 Hash:83ee6544bdb336b0c6e5f83cb79b81f479429244
Date: 2013-02-21 07:31:56
User: root
Comment:pemasu: allow google-chrome to run as root

Tags And Properties
Changes

Changes to woof-code/rootfs-skeleton/usr/local/petget/hacks-postinstall.sh

@@ -2,10 +2,11 @@
 #this is for hacks needed to fix a package, that might not have been done elsewhere.
 #called from /usr/local/petget/installpkg.sh
 #package that has just been installed is passed in on commandline.
 #120924 DejaVu font no good for non-Latin languages. 120925 add korean.
 #130122 xsane: remove warning about running as root.
+#130221 pemasu: google-chrome run as root.
 
 INSTALLEDPKG="$1" #ex: vlc_2.0.3-0ubuntu0.12.04.1_i386, without .deb
 
 case $INSTALLEDPKG in
  vlc-nox_*)
@@ -15,10 +16,35 @@
   if [ -f /usr/bin/bbe ];then #bbe is a sed-like utility for binary files.
    if [ -f /usr/bin/vlc  ];then
     bbe -e 's/geteuid/getppid/' /usr/bin/vlc > /tmp/vlc-temp1
     mv -f /tmp/vlc-temp1 /usr/bin/vlc
     chmod 755 /usr/bin/vlc
+   fi
+  fi
+ ;;
+ google-chrome-*) #130221 pemasu.
+  if [ -f /usr/bin/bbe ];then #bbe is a sed-like utility for binary files.
+   if [ -f /opt/google/chrome/chrome  ];then
+    bbe -e 's/geteuid/getppid/' /opt/google/chrome/chrome > /tmp/chrome-temp1
+    mv -f /tmp/chrome-temp1 /opt/google/chrome/chrome
+    chmod 755 /opt/google/chrome/chrome
+    ln -s /opt/google/chrome/chrome /usr/bin/google-chrome
+    ln -s /opt/google/chrome/product_logo_48.png /usr/share/pixmaps/google-chrome.png
+    CHROMEDESKTOP="`find /usr/share/applications -mindepth 1 -maxdepth 1 -iname '*chrome*.desktop'`"
+    if [ "$CHROMEDESKTOP" = "" ];then #precaution.
+     echo '[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Name=Google Chrome web browser
+GenericName=Google Chrome
+Comment=Google Chrome web browser
+Exec=google-chrome
+Terminal=false
+Type=Application
+Icon=google-chrome.png
+Categories=WebBrowser;' > /usr/share/applications/google-chrome.desktop
+    fi
    fi
   fi
  ;;
  jwm_theme_*)
   #120924 DejaVu font no good for non-Latin languages...