Browse Source

updated chromium

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@5230 ec354946-7b23-47d6-9f5a-488ba84defc7
munepi 12 years ago
parent
commit
1e7ee45d35

+ 13 - 7
c/chromium/chromium-browser-vine.sh

@@ -9,11 +9,12 @@
 APPNAME=chromium
 LIBDIR=/usr/lib/chromium
 GDB=/usr/bin/gdb
+CHROME_SANDBOX=/usr/lib/chrome_sandbox
 
-# Let the Chromium aware MeeGo desktop environment.
-# For system proxy setting integration.
-GNOME_DESKTOP_SESSION_ID="this-is-deprecated"
-export GNOME_DESKTOP_SESSION_ID
+# # Let the Chromium aware MeeGo desktop environment.
+# # For system proxy setting integration.
+# GNOME_DESKTOP_SESSION_ID="this-is-deprecated"
+# export GNOME_DESKTOP_SESSION_ID
 
 usage () {
   echo "$APPNAME [-h|--help] [-g|--debug] [options] [URL]"
@@ -108,10 +109,15 @@ if [ ! -d ~/.config/chromium/Default ]; then
    }
 }
 EOF
-    # Set the default browser
-    $LIBDIR/xdg-settings set default-web-browser chromium-browser.desktop
+    # # Set the default browser
+    # $LIBDIR/xdg-settings set default-web-browser chromium-browser.desktop
 fi
 
+if [ ! -u $CHROME_SANDBOX ] ; then
+ SANDBOX="--no-sandbox"
+fi
+
+
 if [ $want_debug -eq 1 ] ; then
   if [ ! -x $GDB ] ; then
     echo "Sorry, can't find usable $GDB. Please install it."
@@ -126,6 +132,6 @@ if [ $want_debug -eq 1 ] ; then
   $GDB "$LIBDIR/$APPNAME" -x $tmpfile
   exit $?
 else
-  exec $LIBDIR/$APPNAME "--password-store=detect" "--enable-experimental-extension-apis" "--enable-plugins" "--enable-extensions" "--enable-user-scripts" "--enable-printing" "--enable-sync" "--auto-ssl-client-auth" "$@"
+  exec $LIBDIR/$APPNAME $SANDBOX "--password-store=detect" "--enable-experimental-extension-apis" "--enable-plugins" "--enable-extensions" "--enable-user-scripts" "--enable-printing" "--enable-sync" "--auto-ssl-client-auth" "$@"
 fi
 

+ 5 - 4
c/chromium/chromium-vendor-vine.patch.in

@@ -1,11 +1,12 @@
 --- src/webkit/glue/user_agent.cc
 +++ src/webkit/glue/user_agent.cc
-@@ -106,6 +106,7 @@ void BuildUserAgent(bool mimic_chrome1,
+@@ -134,6 +134,7 @@ void BuildUserAgent(bool mimic_chrome1,
    base::StringAppendF(
-       result,
+       &user_agent,
        "Mozilla/5.0 (%s%s) AppleWebKit/%d.%d"
 -      " (KHTML, like Gecko) %s Safari/%d.%d",
 +      " (KHTML, like Gecko) %s Safari/%d.%d"
 +      " Vine/RPM_VERSION",
-       mimic_windows ? "Windows " : kUserAgentPlatform,
-       BuildOSCpuInfo().c_str(),
+       kUserAgentPlatform,
+       webkit_glue::BuildOSCpuInfo().c_str(),
+       WEBKIT_VERSION_MAJOR,

+ 39 - 26
c/chromium/chromium14-vl.spec → c/chromium/chromium16-vl.spec

@@ -12,20 +12,22 @@
 #     -lvpx is sufficient.
 %define with_system_vpx 1
 
-#Name:           chromium14
+%global chrome_sandbox %{_prefix}/lib/chrome_sandbox
+
+#Name:           chromium15
 Name:           chromium
 Summary:        Google's opens source browser project
 Summary(ja):    Googleのオープンソースウェブブラウザ
 #'
-Version:        14.0.835.204
+Version:        16.0.912.57
 Release:        1%{?_dist_release}
 License:        BSD
 Group:          Applications/Internet
 Source0:        %{pkgname}-%{version}.tar.xz
 # Script used to create the %{pkgname}-%{version}.tar.xz archive from 
 # a official tarball: 
-# http://build.chromium.org/official/chromium-14.0.835.XXX.tar.bz2
-Source3:        pack_chromium14_source-vine.sh
+# http://gsdview.appspot.com/chromium-browser-official/chromium-16.0.910.XXX.tar.bz2
+Source3:        pack_chromium16_source-vine.sh
 # Official ffmpeg headers
 Source8:        ffmpeg-0.6-headers.tar.xz
 # Patch template which adds vendor to user agent
@@ -42,13 +44,13 @@ Source100:      chromium-browser-vine.sh
 ##!!Source101:      chromium-browser.desktop
 Source101:      chromium-browser-vine.desktop
 Source102:      chromium-browser.xml
-Source103:      chromium-browser-rpmlintrc
+#Source103:      chromium-browser-rpmlintrc
 ##!!Source104:      chromium-icons.tar.bz2
 
 %{?nosrc:NoSource: 0}
 
 # Provides:       chromium-unstable = %{version}-%{release}
-# Obsoletes:      chromium13
+# Obsoletes:      chromium13 chromium14 chromium15
 # Conflicts:      chromium-stable
 Provides:       chromium-stable = %{version}-%{release}
 Conflicts:      chromium-unstable
@@ -59,27 +61,25 @@ Conflicts:      chromium-unstable
 #Patch1:         chromium-gcc46.patch
 Patch4:         chromium-no-sqlite-debug.patch
 Patch8:         chromium-codechanges-zlib.patch
-Patch12:        chromium-no-test-sources.patch
+#Patch12:        chromium-no-test-sources.patch
 Patch13:        chromium-no-courgette.patch
 Patch14:        chromium-master-prefs-path.patch
 Patch17:        chromium-system-glew.patch
 Patch18:        chromium-system-expat.patch
-Patch19:        chromium-system-zlib.patch
+#Patch19:        chromium-system-zlib.patch
 Patch20:        chromium-6.0.425.0-ffmpeg-no-pkgconfig.patch
 Patch21:        chromium-7.0.542.0-media-probe.patch
 Patch25:        tcmalloc-factory.patch
 Patch26:        chromium-remoting-build-fix.diff
 Patch28:        chromium-7.0.500.0-system-speex.patch
-Patch29:        chromium-7.0.510.0-system-ffmpeg.patch
+#Patch29:        chromium-7.0.510.0-system-ffmpeg.patch
 Patch32:        chromium-7.0.542.0-system-libvpx.patch
-Patch34:        chromium-7.0.542.0-codechanges-system-minizip-v8.patch
+#Patch34:        chromium-7.0.542.0-codechanges-system-minizip-v8.patch
 Patch62:        chromium-norpath.patch
 Patch63:        chromium-6.0.406.0-system-gyp-v8.patch
 
-Patch999:       buildfix.patch
-
 # Vine
-Patch100:       chromium-14.0.835.31-no-tests.patch
+#Patch100:       chromium-15.0.874.116-no-tests.patch
 
 
 ##!!BuildRequires:  Mesa-devel
@@ -190,24 +190,23 @@ xz -dc %{SOURCE0} | %__tar -xf - || exit 1
 #%patch1 -p1
 %patch62 -p1
 %{?with_system_v8:%patch63 -p1}
-%patch100 -p1 -b .vine
-%patch4 -p1
+#%patch100 -p1 -b .vine
 %patch8 -p1
-%patch12 -p1
+#%patch12 -p1
 %patch13 -p1
 %patch14 -p1
 %patch17 -p1
 %patch18 -p1
-%patch19 -p1
+#%patch19 -p1
 %patch20 -p1
 %patch21 -p1
 %patch25 -p1
 %patch26 -p1
 %patch28 -p1
-%patch29 -p1
+#%patch29 -p1
 %{?with_system_vpx:%patch32 -p1}
 %{?with_system_v8:%patch34 -p1}
-%patch999 -p1
+%patch4 -p1
 
 
 pushd src/third_party/ffmpeg/
@@ -230,6 +229,9 @@ popd
 # apply vendor patch after substitution
 %__sed "s:RPM_VERSION:%{version}-%{release}:" %{SOURCE20} | patch -p0
 
+# Make sure that the requires legal files can be found
+%__cp -a src/AUTHORS src/LICENSE . || exit 1
+
 %build
 
 ## create make files
@@ -248,9 +250,8 @@ done
 pushd src
 
 ./build/gyp_chromium -f make build/all.gyp \
-    -Dlinux_sandbox_path=%{_libdir}/chromium/chrome-sandbox \
-    -Dlinux_sandbox_chrome_path=%{_libdir}/chromium/chromium-browser \
-    -Ddisable_nacl=1 \
+    -Dlinux_sandbox_path=%{chrome_sandbox} \
+    -Dlinux_sandbox_chrome_path=%{_libdir}/chromium/chromium \
     -Duse_openssl=0 \
     -Duse_system_ffmpeg=1 \
     -Duse_system_zlib=1 \
@@ -270,6 +271,7 @@ pushd src
     %{!?with_system_icu:-Duse_system_icu=0} \
     %{?_with_shared_library:-Dlibrary=shared_library} \
     -Dproprietary_codecs=1 \
+    -Ddisable_nacl=1 \
     -Djavascript_engine=v8 \
     -Dlinux_fpic=1 \
     -Ddisable_sse2=1 \
@@ -286,8 +288,10 @@ pushd src
     %endif
     ;
 
-#%__make -r %{?_smp_mflags} chrome BUILDTYPE=Release
-%__make -r %{?_smp_mflags} chrome V=1 BUILDTYPE=Release
+%__make -r %{?_smp_mflags} chrome V=1 BUILDTYPE=Release disable_nacl=1
+
+# Build the required SUID_SANDBOX helper
+%__make -r %{?_smp_mflags} chrome_sandbox V=1 BUILDTYPE=Release disable_nacl=1
 
 popd
 
@@ -296,12 +300,16 @@ popd
 
 %__mkdir -p %{buildroot}%{_bindir}
 %__install -m 755 %{SOURCE100} %{buildroot}%{_bindir}/chromium
+%ifarch x86_64
+mkdir -p %{buildroot}%{_prefix}/lib/
+%endif
 # x86_64 capable systems need this
 %__sed -i "s|/usr/lib/chromium|%{_libdir}/chromium|g" %{buildroot}%{_bindir}/chromium
 %__mkdir -p %{buildroot}%{_libdir}/chromium/
 %__mkdir -p %{buildroot}%{_mandir}/man1/
 pushd src/out/Release
-%__cp -a chrome.pak locales resources xdg-settings %{buildroot}%{_libdir}/chromium/
+%__cp -a chrome_sandbox %{buildroot}%{_prefix}/lib/
+%__cp -a chrome.pak locales resources xdg-mime xdg-settings %{buildroot}%{_libdir}/chromium/
 %__cp -a resources.pak %{buildroot}%{_libdir}/chromium/
 %__cp -a chrome %{buildroot}%{_libdir}/chromium/chromium
 %{?_with_shared_library:%__cp -a lib.target/lib*.so %{buildroot}%{_libdir}/chromium/}
@@ -379,7 +387,8 @@ fi || :
 %{_libdir}/chromium/chromium
 %{_libdir}/chromium/plugins/
 %{_libdir}/chromium/resources/
-%{_libdir}/chromium/xdg-settings
+%attr(755,root,root) %{_libdir}/chromium/xdg-settings
+%attr(755,root,root) %{_libdir}/chromium/xdg-mime
 %{_mandir}/man1/chrom*
 %{_datadir}/pixmaps/chromium-browser.png
 %{_datadir}/icons/hicolor/*/apps/chromium-browser.png
@@ -396,8 +405,12 @@ fi || :
 %exclude %{_libdir}/libavcodec.so.52
 %exclude %{_libdir}/libavutil.so.50
 %exclude %{_libdir}/libavformat.so.52
+%attr(4755,root,root) %{chrome_sandbox}
 
 %changelog
+* Sat Oct 29 2011 Munehiro Yamamoto <munepi@vinelinux.org> 15.0.874.116-1
+- updated to 15.0.874.116
+
 * Wed Oct 12 2011 Munehiro Yamamoto <munepi@vinelinux.org> 14.0.835.204-1
 - updated to 14.0.835.204
 - added BuildRequires: dbus-glib-devel

+ 0 - 0
c/chromium/pack_chromium14_source-vine.sh → c/chromium/pack_chromium16_source-vine.sh