Google Chrome natively running on Gentoo Linux

Comments // Written on Jun 05, 2009 // Open Source

This is just a quick & (very) dirty trick to run Google Chrome on Gentoo Linux using a precompiled debian package instead of compiling the enormous source tarball.

Step 1. Download the Deb

Get your browser to Developer Download page for Linux x86 and accept Google Terms of service.

Step 2. Unpack the unpackable

Open a terminal emulator and cd to your download directory ( mine is Desktop )

cd ~/Desktop
mv google-chrome-unstable_current_i386.deb /tmp
cd /tmp
ar x google-chrome-unstable_current_i386.deb
tar xvf data.tar.gz
sudo cp opt/google/chrome /opt/ -r
sudo ln -s /google/chrome/chrome /usr/bin/

Step 3. Link some libs

Chrome requires some libs which I didn’t find in my gentoo portage tree. Probably I could update nss and nspr but I prefer using stable ebuilds so I decided to manually link some missing libs…

ln -s /usr/lib/nss/libnss3.so.12 /usr/lib/libnss3.so.1d
ln -s /usr/lib/nss/libnssutil3.so.12 /usr/lib/libnssutil3.so.1d
ln -s /usr/lib/nss/libsmime3.so.12 /usr/lib/libsmime3.so.1d
ln -s /usr/lib/nss/libssl3.so.12 /usr/lib/libssl3.so.1d
ln -s /usr/lib/nspr/libplds4.so.7 /usr/lib/libplds4.so.0d
ln -s /usr/lib/nspr/libplc4.so.7 /usr/lib/libplc4.so.0d
ln -s /usr/lib/nspr/libnspr4.so.7 /usr/lib/libnspr4.so.0d

Step 4. Run it

If you want to simply launch it you just need to run chrome from anywhere.
If you want to create a launcher you can use chrome as command and choose an icon from /opt/chrome/

This is just a pre-release and many features are missing. Anyway I’m quite happy about having the possibility to try out Google Chrome without compiling it (it would be a cpu suicide I believe) and I noticed that it seems incredibly fast on launching. Maybe it’s because not all features have been built in, but it’s impressive in any case!

Here’s a screen I made from my Gentoo Box

Google chrome on Gentoo

Bash Completition on Gentoo

Comments // Written on Dec 03, 2008 // Open Source

Here’s how to get a personalized and satisfactory completion on Gentoo installations..

Fisrt of all you need an use flag set widely in your system so that every software you are going to emerge (or re-emerge) if is capable will be added to your completition choices. To do so just open our magic make.conf with your favourite editor (I use vim, you can use emacs, nano, pico…i don’t really care about wars)
# vim /etc/make.conf
then find the USE variable and add inside it the string
bash-completion
Now you have the option to re-emerge all previously installed programs that have bash-completition USE flag. To do so just do
# emerge -a --newuse world
Right now you got the correct completitions available but to use them you need to install the bash completition ebuild so…
# emerge -avtD app-shells/bash-completion app-shells/gentoo-bashcomp
After emerging the ELOG will tell you to add a string to your .bashrc to enable it. So for each user you want to enable bash completition just edit their own .bashrc.
$ vim ~/.bashrc
Obviously you can do it for root account too (for emerge f.e.)
# vim /root/.bashrc
Right now you got it configured but no program is really affecting your bash shell. To do so I suggest you to use eselect (if you don’t have it just emerge it).

Fist of all use eselect to list all your available programs
# eselect bashcomp list
Then just choose wisely the programs you would like to add and insert them using their ID (the number beetween squares [] ).
# eselect bashcomp enable 1

Done! I usually like adding just a few completition like the emerge one (called gentoo, it adds other completitions then emerge alone) , subversion and git…

asdBG on Gtk-Apps and Gnome Files

Comments // Written on Nov 26, 2008 // Open Source

I submitted asdGB to the two most used gnome apps websites. You can find my work on the following links

Gtk Apps

Gnome Files

Gentoo Autounmask Loop Bug

Comments // Written on Nov 19, 2008 // Open Source

I noticed that even upgrading to latest version of autounmask (0.21 on my portage tree) I got the same loop bug of the previous versions.

Exactly like for the previous version the problem regards an infinite loop generating when unmasking a package and it’s caused by not understanding the PortageXS function getArch(). To avoid the problem and using this wonderful tool without PortageXS it’s possible to manually set the arch on the bin file.

Just open it with your favorite editor as Root
su
vim /usr/bin/autounmask

Then find this line
my $arch = $pxs->getArch();
comment it and add this other
my $arch = 'amd64';
obviously replacing amd64 with your arch.

An apple a day…

Comments // Written on Oct 15, 2008 // Others

#!bin bash
apple=`emerge --sync && layman -S && update-eix && emerge -D world && revdep-rebuild`
An $apple a day keeps the doctor away