标签:linux chrome 谷歌 浏览器 installer
用firefox总感觉很慢,有时候还假死。经过网上一番搜寻,试过各种方法,终于安装成功。
一 下载
在个google官网下载的浏览器安装一直报错:
sudo rpm -ivh Downloads/google-chrome-stable_current_i386.rpm [sudo] password for hakits: warning: Downloads/google-chrome-stable_current_i386.rpm: Header V4 DSA/SHA1 Signature, key ID 7fac5991: NOKEY error: Failed dependencies: libstdc++.so.6(GLIBCXX_3.4.15) is needed by google-chrome-stable-42.0.2311.90-1.i386
Create a file called /etc/yum.repos.d/google-chrome.repo and add the following lines of code to it.
[google-chrome] name=google-chrome baseurl=http://dl.google.com/linux/chrome/rpm/stable/$basearch enabled=1 gpgcheck=1 gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub也报相同的错误。
需要更新安装g++,下载地址:
http://ftp.tsukuba.wide.ad.jp/software/gcc/releases/gcc-4.8.1/gcc-4.8.1.tar.bz2
gcc-4.8.1.tar.bz2 解压: tar -jxvfgcc-4.8.1.tar.bz2 |
cd gcc-4.8.1
./contrib/download_prerequisites
新建目录用于存放编译结果:
mkdir gcc-build-4.8.1
进入新目录,并执行configure命令,产生makefile://以下只编译了C++
cd gcc-build-4.8.1
../gcc-4.8.1/configure --enable-checking=release --enable-languages=c,c++ --disable-multilib
编译 : // 耗时很长,如果是多核的话可以添加 -j 后面加想要使用的cpu数
make
安装:
make install
安装完成检查版本:
g++ --version
g++ (GCC) 4.8.1
但是此时/usr/lib/libstdc++.so.6 还是软连接/usr/lib/libstdc++.so.6.0.13先去掉此连接:
rm -rf /usr/lib/libstdc++.so.6 -> /usr/lib/libstdc++.so.6.0.13
再新建连接:
ln -s /usr/local/lib/libstdc++.so.6.0.18 /usr/lib/libstdc++.so.6查看库:
strings /usr/lib/libstdc++.so.6 | grep GLIBC GLIBCXX_3.4 GLIBCXX_3.4.1 GLIBCXX_3.4.2 GLIBCXX_3.4.3 GLIBCXX_3.4.4 GLIBCXX_3.4.5 GLIBCXX_3.4.6 GLIBCXX_3.4.7 GLIBCXX_3.4.8 GLIBCXX_3.4.9 GLIBCXX_3.4.10 GLIBCXX_3.4.11 GLIBCXX_3.4.12 GLIBCXX_3.4.13 GLIBCXX_3.4.14 GLIBCXX_3.4.15 GLIBCXX_3.4.16 GLIBCXX_3.4.17 GLIBCXX_3.4.18 GLIBCXX_3.4.19 GLIBC_2.3 GLIBC_2.0 GLIBC_2.1 GLIBC_2.1.3 GLIBC_2.3.2 GLIBC_2.2 GLIBCXX_FORCE_NEW GLIBCXX_DEBUG_MESSAGE_LENGTH安装依然报相同的错误。
最后找到方法,重新下载:http://people.centos.org/hughesjr/chromium/6/i386/RPMS/
我选择的是:chromium-31.0.1650.63-2.el6.i686.rpm
参考:1
由于在linux系统上打开网页速度比在windows下慢好多,所以觉得换个浏览器,就想装个chrome,这个流程很蛮波折的,最后成功了,先记录一下。
我的系统为centos6.4, 32位。
问题: 首先从官网上下了一个google-chrome-stable-33.0.1750.146-1.i386.rpm,试图安装:
rpm -i google*
时报错Requires: libstdc++.so.6(GLIBCXX_3.4.15)
缺少库,查看 /usr/lib下的libstdc++.so.6,
strings /usr/lib/libstdc++.so.6 | grep GLIBC
返回结果没有GLIBCXX_3.4.15,继续查看
ls -l /usr/lib/libstdc++.so.6
发现/usr/lib/libstdc++.so.6 -> /usr/lib/libstdc++.so.6.0.13
需要更新libstdc++.so.6版本,直接
yum updatelibstdc++.so.6 或者 gcc
说是已经是最新的了,所以只能从网上下,但是从网上下的不一定对,就重新自己编译gcc
(1)编译 gcc
下载gcc 4.8.1源码包:
http://gcc.gnu.org/mirrors.html 从中选取日本的镜像网站,因为下载速度快,其他的很慢
从http://ftp.tsukuba.wide.ad.jp/software/gcc/releases/gcc-4.8.1/ 中选择
gcc-4.8.1.tar.bz2 解压: tar -jxvfgcc-4.8.1.tar.bz2 |
cd gcc-4.8.1
./contrib/download_prerequisites
新建目录用于存放编译结果:
mkdir gcc-build-4.8.1
进入新目录,并执行configure命令,产生makefile://以下只编译了C++
cd gcc-build-4.8.1
../gcc-4.8.1/configure --enable-checking=release --enable-languages=c,c++ --disable-multilib
编译 : // 耗时很长,如果是多核的话可以添加 -j 后面加想要使用的cpu数
make
安装:
make install
安装完成检查版本:
g++ --version
g++ (GCC) 4.8.1
但是此时/usr/lib/libstdc++.so.6 还是软连接/usr/lib/libstdc++.so.6.0.13先去掉此连接:
rm -rf /usr/lib/libstdc++.so.6 -> /usr/lib/libstdc++.so.6.0.13
再新建连接:
ln -s /usr/local/lib/libstdc++.so.6.0.18 /usr/lib/libstdc++.so.6
检查一下库:
strings /usr/lib/libstdc++.so.6 | grep GLIBC
返回结果有了GLIBCXX_3.4.15
(2)安装chrome
此时:
rpm -i google*
还是报相同的错,但是已经有了库,没有道理不对,后在
http://www.oschina.net/question/254443_115424
找到问题,chrome版本不对,重新下载:
http://people.centos.org/hughesjr/chromium/6/i386/RPMS/
我选择了chromium-31.0.1650.63-2.el6.i686.rpm
rpm -i google*
安装成功,点击应用程序按钮就看到了浏览器。
参考:2
Google Chrome is a freeware web browser developed by Google Inc. Google Chrome team proudly announced the release of Google Chrome 41 on March 03, 2015. The actual version is 41.0.2272.76 for Linux/Mac OS X and Windows operating system. This new version bundled with a number of exciting fixes, features and improvements, including:
If you would like to know more other cool features of this release, please visit at Google’s Chrome Features.
In this tutorial we will show you how we have practically installed Google Chrome 41 browser in one of our CentOS 7.0 server using Google’s own repository with Yum tool and a third party script from Richard Lloyd, which installs latest chrome version on RHEL/CentOS and Fedora versions.
By using Google’s official repository you will keep your Chrome browser up-to-date. However, it should also work on RHEL 7.0/6.x, CentOS 7.0/6.x and Fedora 21-15 versions as well.
Create a file called /etc/yum.repos.d/google-chrome.repo and add the following lines of code to it.
[google-chrome] name=google-chrome baseurl=http://dl.google.com/linux/chrome/rpm/stable/$basearch enabled=1 gpgcheck=1 gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub
First, check whether the latest version available from the Google’s own repository using following yum command.
# yum info google-chrome-stable
Do you see the highlighted output in the above image, that clearly telling that the latest version of chrome is available from repository. So, let’s install it using yum command as shown below, which will automatically install all needed dependencies.
# yum install google-chrome-stable
Update : Sadly, the Google Chrome browser no longer supports the most famous commercial distribution RHEL 6.x and its free clones such as CentOS and Scientific Linux.
Yes, they’ve discontinued support for RHEL 6.X version as of Google Chrome and on other side, latest Firefox and Opera browsers run successfully on the same platforms.
Luckily, there is a script developed by Richard Lloyd, that automatically download and install latest Google Chrome browser by picking libraries from a more recent released distro and put those libraries in (/opt/google/chrome/lib) directory and then you can able to run Google Chrome on RHEL/CentOS 6.x versions.
# wget http://chrome.richardlloyd.org.uk/install_chrome.sh # chmod u+x install_chrome.sh # ./install_chrome.sh
Google Chrome Installer 6.10 on the i686 platform (C) Richard K. Lloyd 2014 <rklloyd@gmail.com> *** Creating temporary directory /tmp/chrome_install ... *** Changing working directory to /tmp/chrome_install ... *** Checking for an update to install_chrome.sh ... *** Downloading version.dat (please wait) ... --2014-11-21 23:59:04-- http://chrome.richardlloyd.org.uk/version.dat Resolving chrome.richardlloyd.org.uk... 193.110.246.53 Connecting to chrome.richardlloyd.org.uk|193.110.246.53|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 5 [text/plain] Saving to: “version.dat” 100%[=====================================================================================================================>] 5 --.-K/s in 0s 2014-11-21 23:59:09 (783 KB/s) - “version.dat” saved [5/5] *** install_chrome.sh is already the latest version (6.10) - continuing ...
Start browser with non-root user.
# google-chrome &
Welcome screen of Chrome web browser.
Exploring www.tecmint.com with cool Chrome web browser.
Google Chrome Cheat Sheet: This free ebook contains dozens of other helpful keyboard shortcuts that will help you on how to use Google Chrome efficiently.
标签:linux chrome 谷歌 浏览器 installer
原文地址:http://blog.csdn.net/hanglinux/article/details/45334239