Category Archives: Gentoo

Links Saturday

Links SaturdayAnother good week for me. Learned a good deal about programming, and am still learning about regex’s – yeesh, and have been playing Wesnoth alot. All good. Here’s the links I discovered this week.

There’s a PPC version of the popular Rescue CD (PPCRCD) that I knew was built from Gentoo apparently the main version is too. I makes alot of sense with Gentoo being built form scratch.

Back in December, I wrote Comparison of Notetaking Applications Zim was an oasis from the abysmal desert that became Tomboy when I approached a hundred notes. A script to convert Tomboy to Zim was just what I needed. It wasn’t perfect but eventually the job got done. Well, I just heard from Bengt, the author of the script, that his script has been updated, If ever thought of trying another notetaking application nows a good opportunity. Thanks Bengt.

Gentoo’s once child star now turned Sabayon champion is said to be at times… mercurcial. I like that from people who know how to change things. lxnay pines about problems with DEPEND/RDEPEND

And lastly and most importantly of all, thanks to the democrats in the House who rejected immunity to telecoms and additional presidental authority to do wiretapping without a need for a warrant… Perhaps MightyMartin on slashdot said it best responding to:

“While obviously telecoms KNEW better, its hard to say ‘no’ to your nation’s president”

And that suggests that biggest problem with how the Presidency has evolved. The Presidency was not supposed to be some sort of regal position, save in the ceremonial respect (where the President is the equivalent of a king or emperor). If the President of the United States asks you to do something illegal, it is, under the law, no different than any other citizen of the United States asking you to do something illegal. You say no, because you’re opening yourself up to possible prosecution or civil reparations.

Wrote my First Ebuild

And it’s not that good. It works but something is wonky about it. I got lucky and picked out a program that’s small, I got unlucky that the program is a python script and I had to manually put in the pieces by hand. I like the process though. I started the night knowing absolutely nothing about ebuilds and end the night with a whole lot learned (thanks for the help nichoj). I love the directory and structure of programming – so direct. If you know what you’re doing you can do alot with a litte bit of code. I just discovered there is another one in bugzilla… crap (one that doesn’t have any bugs in it). Hmm, just looked a few days ago… So it goes. I did do some things better like using a creating a symlink instead of manually creating a bash start script and using ${PN}. Anyways I’m still proud enough to show it off: :)

# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit eutils python

DESCRIPTION="Alarm Clock is a personal alarm clock applet for the Gnome panel."

KEYWORDS="amd64 ~ppc x86"
LANGS="pl sr sr@latin"


src_compile() {
#   cd ${S}/po
#   for LANG in ${LANGS} ; do
#       msgfmt -cv -f -o ${LANG}.po
#       cp /usr/share/locale/${LANG}/LC_MESSAGES/
    echo "#!/bin/bash" > alarm-clock
    echo "cd /usr/share/alarm-clock" >> alarm-clock
    echo "python" >> alarm-clock

src_install() {
    insinto /usr/share/${PN}
    doins -r gfx sound

    insinto /usr/share/applications/
    doins alarm-clock.desktop

    insinto /usr/share/pixmaps
    doins gfx/alarm-clock.svg

    exeinto /usr/bin
    doexe alarm-clock

Update:It was nagging so updated the ebuild and it works now.

Ebuild 2 Overlay


Ebuild2overlay is available. This script comes in nice after grabbing an ebuild (e.g. from bugzilla) and not wanted to go thorough all the commands of putting it in the overlay. Adjust the keyword, and overlay variable to make itwork for you.

ebuild2overlay <category> <package.ebuild>

v.2 – I’ve added keyword support and fixed a few bugs. Thanks to the guys at for helping out.

v.3. – Cleaned up the code. Added checks for required tools. Wasn’t able to fix the remotedirectory bug. From what Ican tell you should be able to, “ebuild2overlay <category> </path/to/ebuild>” but currently you have to be in the current directory to use it.

# ebuild2overlay
#   grabs an ebuild and adds it the local overlay
#   adds architecture if needed
#   ebuild-overlay does not add patchs, add these to the "files" directory
#    in the package’s overlay directory.

# Todo/Bugs:
#   Allow script to run if ebuild is in separate directory.
#   Directory check for category can fail for incomplete categories –
#   (i.e "app-edi")
#   PKGDIR filter fails for revisioned ebuilds.
#   "ebuild2overlay category/package" argument possible?


# Usage – displays if full argument isn’t given.
if [[ -z "$EBUILD" ]]; then
    echo "ebuild2overlay <category> <package.ebuild>"
    echo " (must be in currect directory of ebuild)"

sleep 1

# Is Gentoolkit Installed?
if [[ -f "/usr/bin/ekeyword" ]]; then
    echo " * Gentoolkit-dev installed."; else
    echo " * Ekeyword program not found."
    echo " * ‘gentoolkit-dev’ needed to use this script."
    echo " * Exiting."

sleep 1

# Category matches Portage’s?
if [[ -d $PORTDIR/$CATEGORY ]]; then
    echo " * Valid Portage directory, continuing."; else
    echo " * Not a valid category directory!  Category must match an existing Portage directory."
    echo " * Exiting."

sleep 1

# Category directory in overlay exists?  If not create directory.
if [[ -d $PORTDIR_OVERLAY/$CATEGORY ]]; then
    echo " * Category directory already exists."; else
    echo " * Category directory created."

sleep 1

# Package directory exists?  If not create directory.
    echo " * Package directory already created."; else
    echo " * Package directory created."

sleep 1

# Move ebuild to overlay, keyword ebuild, digest
if [[ -f "$EBUILD" ]]; then
  echo " * Ebuild found, moving to appropriate directory."
  sleep 1
  echo " * Keywording Ebuild."
  sleep 1
  echo " * Building digest for ebuild"
  sleep 1
  echo " * Ebuild not found in specified directory."
  echo " * Exiting"

# Notes

# Filters (looks like it’s best to bash filters)

# Bash Filter – Remove the shortest matching pattern from right in variable
# EBUILD starting with ‘-‘ followed by any character "*".
# "${EBUILD%-*}"

# Awk
#PKGDIR=$(echo $EBUILD | awk -F- ‘{print $1 "-" $2}’)

Links Saturday

Links SaturdayGood weekend everybody. Hope everyone is having a good one. It’s been a good week for me, so I’ll wrap up my week Paul Harvey style.

Thanks to readers for pointing out this week in that there are a couple other alternates to the Gnome menu bar in GMB Alternates. This is the first time the author has heard of them and offer some intriguing choices. The earlier being Ubuntu System Panel. A python script that seems to gotten a lot of looks in the Ubuntu Forums. And the latter is Linux Mint’s default menu:


For those viewers that haven’t seen, I keep a Gentoo Linux Wiki install guide. Its a hobby of mine and I just love to give it polish from time to time. I’ve learned a good few bits about the install process since it’s last revision, and oops, fixed a number of neutrality errors. :|

The Links

That’s all from me, Goooooood Weekend!

Another Look at Gnome Menu Bar Alternatives


After reading a post yesterday that talked about replacing the Gnome’s built-in menu applet, I began thinking why not try out the replacements for my lead-weighted Gnome Menu Bar. One of the few expectancies I have of Gnome or any other UI is to respond nearly instantly to menu selections, and to have all common selections in one interface. Gnome Menu Bar has a hiccup to it so I’d thought I’d take a look at what else is being developed.

Reading Johan’s Blog it’s pointed out that there are really only two alternatives to Gnome’s Menu Bar: slab from Novell/Suse (aka Gnome Main Menu) and Gimmie, but there is also a third: Ubuntu System Panel.


Gimmie reminds me alot of an application called dragthing way back on Mac OS:

To install for Gentoo users, Gimmie has an ebuild that’s handy to build Gimmie with. Those that don’t want the extaraneous crud that comes with Gentoo’s gnome-python-desktop, emerging “gnome-python-desktop --nodeps -1” isn’t a problem. Gimmie installed fine after adding four or five dependencies.

Gimmie can be used as a panel applet or a separate dock, but the dock I found obstructive and too big so I’m just covering the panel applet.

Gimmie comes by default colored like a Miami night club, “Hello ladies.” But I’m glad there’s an option to not always have it on. They still hover green, blue, pink… but no big deal I guess.

The People and Library tabs contain contacts and the documents most often used. I didn’t look into these very much as I have my own way of organizing ppl and files but they seem like they can be pretty handy.

The Programs tab is what I would most use Gimmie for and it’s categorized conviently like Gnome Menu Bar.

The Linux tab contains everything else, control panels, places, devices and media.

Gimmie has about everything I need and is fast though not as fast as I would like as the rollover effects hang a bit.

  • + quick responsive
  • + nice variation of features
  • – rollover slight drag
  • – big big
  • ? “Linux Tab”?
  • ? Tomboy Notes support?

Slab a.k.a Gnome Main Menu

Suse’s custom Gnome menu has an ebuild for it too. I downloaded the ebuild (and all the patches), and updated which was outdated.

Gnome Main Menu feels like a trimmed down version of Gimmie and works exactly as it was designed to do: a lighter replacement for Gnome’s Menu Bar. It does take the same load time though (5 to 10 seconds) but once it does it’s nice and responsive. Gnome Main Menu has no applications setup by default – favorites must be added manually. I was hoping applications would get added by the frequency they are used but no luck. So I added my favorites and found that its really nice to be able to start these applications as quickly as I did. Despite this feature being really useful it also becomes a crutch as any applications that are not favorites had to be opened through launching a second window. Gnome Main Menu also creates a folder called Documents in my home directory. Not good. I have my own way of organizing my documents so this didn’t make me happy.

GMM is good in the basics. I like GMM’s hover buttons that give one click behavior over Gimmies double click one. Also, GMM has no preferences which surprisingly didn’t’ disturb me at all as it was well configured.

  • + Light, fast, mean and trim.
  • + easy to learn and use
  • – big size
  • – Document folder – oh boy.

Ubuntu System Panel

I haven’t tried USP but some people really like it. I’ll refer you to makeuseof for the review.


If I were to choose between the two, it would depend on my situation. Gimmie could be useful to beginners who could be sedated by finding most of what they need in the menu while GMM just works nice for basic (8-10) app users that don’t need the frills and likes the speed.

For now though… I’m sticking with Gnome’s Menu Bar. Though it doesn’t preload the menu and sometimes loses the cached icons its still the quickest way I can get to all the apps I need.

Quick Tip: Gnome Menu Bar has a built-in delay when sliding over categories. Add to or create a ~/.gtkrc-2.0 file and add:

vim ~/.gtkrc-2.0
gtk-menu-popup-delay = 0"| tee -a .gtkrc-2.0

for a lower menu delay (does cause a harmless gtk warning)

Ad-Blocker Not Required – Hosts File

Ad-Blocker Not Required - Hosts File

Note: Keep in mind that if the computer being used is pretty quick not a lot of difference is going to be seen blocking advertising. Also keep in mind that some our favorite sites need support from advertising and that news will come in advertising as well.

Update: Thanks to Ikem for finding the new script download (it is included at the bottom of the page). Also I want to not that I don’t use this method anymore and use Ad-block instead. The reason? Ad-block not does smart ad-blocking which is nice and I discovered that the addresses get stored bash’s cache with can slow bash up good.

One of the most used and handy features about Firefox is it Ad-blocker extension. As people and companies recklessly graffiti our Internet like a NASCAR Ford, it can be a strain on the eye as well as some pretty long download times. Ad-blocker does a good job but one can also use the hosts file.

Linux, Windows and Macs all have support for a hosts file. A hosts file is a list of resolved DNS addresses (IPs). By substituting the local loopback IP ( to known spammers addresses the hosts file can be used to filter out said domains.

Luckily for us, we don’t have to enter lists of spammers addresses (there are a few) but that a group of users are already involved doing it. The hosts files project have created a list of known spammer and advertising IP’s to enter into the hosts file. For Linux users, the process is very simple to add these IP’s to the hosts file. Look to the end of the page to the blog for the script. Here is a Linux script that can update the hosts file automagically. The dos2unix application will need to be installed to convert the text properly.

Support the project is encouraged. Put new IP of spammers in the hosts file and upload the hosts files to the project.

Reportedly as I saw on the Ubuntu forums the localhost address should be replace with a null-one as will wait for a timeout. This can be done by doing:

sudo sed -i 's_127.0.0.1_0.0.0.0_g' /etc/hosts

and then edit the file manually to change the line with localhost in it to localhost as this is needed.

Gentoo xterm-256color off by default?

Gentoo xterm-256color off by default?Update: It is advisable not to perform this update. For compatibility purposes with other terminal emulators best to leave this setting to eight bit.

I had an intuition that some off the colors in the terminal seemed a bit off. I’m new to this terminal dealie, and aftering discovering that a lot of vim themes looked poor I found out vim was using 8 bit color. I found the vim setting to fix this but it turns out that x term has been set to 8 bit color all along!

Astounded! Flabergasted! Yes I was. This isn’t an Atari!

Anyways, I tracked down a well-read post in the forums that discussed this and now got it set to 256 colors. To fix this:

Test the terminals color bit depth:

tput colors

Now load the 256 palatte into xterm

export TERM=xterm-256color

To keep settings for 256 colors export the xterm 256 color to ~/.bashrc

Is this the Gentoo default? Am I missing anything here that can relate to concerns of bugs?

LiveUSB on PPC

LiveUSB on PPCWiki doodling!

In my vast spare time this weekend I was able to explore the myth of putting a Linux distro on a USB flash drive and being able to boot it – a thought that not many have thought to do – yikes. Jentoo’s own is well done but lacks the Motorolla-IBM flavor. So I collected said bits and got as good a panorama as could be but didn’t escape atmosphere. The effort though was not all fruitless as the numbers are crunched on the GLW. Please be as hackish and wikify-uth as need be.

* GLW – LiveUSB on PPC 

Gentoo – A Quick User’s Perspective

I don’t usually get involved with politics on this blog, but I’d like to clarify how I think about Daniel Robbins offer to resume leadership of Gentoo, and Gentoo’s reply.

Gentoo is a great distribution. Gentoo is now run by developers who in there spare time contribute. This usually and almost always means working on portage. The developers producing ebuilds and creating portage primarily do it to create good systems for themselves. We as users benefit from this and to this point have little complained. But users are beginning to think of themselves as the red-headed step childs of the Gentoo family – mostly left to our own to enjoy the roof over our heads. And I think we users have become sick of it.

I have been reading developer blogs and am disturbed by their writings. Some quickly criticized saying Drobbins has no right to tell developers what to do, quickly citing the past incident when Drobbins previously returned. Most others just dodged the topic of a Gentoo leader and talked about the developer gap between users.

Grant Goodyear, the only real member of the Foundation, failed to file the paperwork for the Gentoo charter as whose only real function anymore is to file this paperwork – then shooed it in his blog.

Daniel tooks Grant’s blog as a no, and probably rightly so. It’s mostly defensive and defers the discussion to a mailing list.

Now some of the Developers have responded by creating the Gentoo User Relations page. It basically states that the developers are interesting in improving user relationships… But it appears is a reactionaryresponse and not a naturally motivated one. A marking of territory of sorts!?

Gentoo is a headless oligarchy. Meaning it has NO leadership, a bunch of priests acting in forced times as Pope. The current GMN will not last, the Gentoo user relations will not last, and the same dilapidated structure of Gentoo will deteriorate Gentoo if not fixed.

Yahoo as default email client

I’ve had a Yahoo account since Yahoo was best of search engines (yes quite a bit ago) – I still like it. Instead of using my ISP provided email address I’ve just used Yahoo. Yahoo Mail can be used as the default email client instead of using Evolution, Thunderbird… in Gnome. In other words links that point to “mailto:” will open in

I use a hidden folder at home that contains all my scripts:

gedit ~/.bin/yahoo-mailto

This nice bash script will direct Epiphany mailto links to yahoo:

qs=`echo $1 | sed ‘s/mailto:/To=/’ | sed ‘s/\?subject=/\&Subject=/’`
epiphany –new-tab “$qs&#8221;

Here’s an alternate as the above for some doesn’t always work:

URL=$(echo $1 | sed ‘s#mailto:##;s#?#\&#;s#\&subject=#\&Subj=#;s#(##;s#)##i;’)
epiphany –new-tab “$URL&#8221;

Make the script executable:

chmod +x ~/.bin/yahoo-mailto

To set it to the default application for mail in Gnome open Preferred Applications and select the script appended with a %s.

set email client

The script can also be used from the command line:


Thanks to Dhonn who built this bash script.

Stjerm Terminal

Browsing the Open Compositing forums a while back, I discovered a terminal called stjerm. Stjerm was designed to be a lightweight and un-obtrusive terminal. It toogles shown and hidden like you see in first-person-shooters by pressing a button. Stjerm was discontinued a couple years ago unfortunately, I’m still hoping the author will pick it up again. That said, it is still a great terminal for lightweight desktops.


Because of it’s status, Stjerm will require a special setup to get it to behave as you expected. I like Stjerm for about everything. The only thing that I need that Stjerm does not have is url recognition. Besides that I’m very happy with it.

For Gentoo users, you can grab an ebuild for it here. For Arch users, it’s in the AUR.

Stjerm uses the ~/.Xdefaults file for it’s permanent settings. However, some values are broken entirely, or will have to be entered through the command line options. The ~/.Xdefaults file:

! ~/.Xdefaults

! -config stjerm-0.11- !
! Some of these values are broken or can only be set through the command line.
! They are commented by (!!).  Command line arguments override Xdefault options.
stjerm.key: f12
stjerm.autohide: false          ! true*
stjerm.font: DejaVu Sans Mono 8
stjerm.background: #181C20      ! black*
stjerm.opacity: 70              ! range: 10–100 (full-none)
stjerm.scrollbar: right         ! none*, left, right
stjerm.lines: 2400              ! 1000*
stjerm.scroll: true             ! true* (auto-scroll on term fill)
!                  ! X shell to use
!stjerm.bgimage:                ! background image
!!stjerm.mod: shift             ! shift, control, alt, windows, none *
!!stjerm.keymod: control+f12
!!stjerm.foreground: gray       ! base font color
!!stjerm.allbold: false         ! true *
!!stjerm.border: thick          ! thin, thick, none *
!!sjterm.width: 519             ! in pixels
!!stjerm.height: 600
!!stjerm.position: bottomleft   ! top*, bottom, left, right
!!stjerm.showtab: two           ! never*, one, always
!!stjerm.tabpos: top            ! bottom*, top, left, right
!!stjerm.tablabel: 1            ! term*
!!stjerm.tabfill: false         ! true* (tab spans window?)
!!stjerm.color0: #181C20   ! black - regular
!!stjerm.color1: #A44245   ! red
!!stjerm.color2: #00BF00   ! green
!!stjerm.color3: #BBAD5B   ! yellow
!!stjerm.color4: #2B76C7   ! blue
!!stjerm.color5: #8B56A3   ! purple
!!stjerm.color6: #5BCEE4   ! cyan
!!stjerm.color7: #D4D7D0   ! white
!!stjerm.color8: #525952   ! black - bold
!!stjerm.color9: #A44245   ! red
!!stjerm.color10: #37A42B  ! green
!!stjerm.color11: #C4C29B  ! yellow
!!stjerm.color12: #2B76C7  ! blue
!!stjerm.color13: #8B56A3  ! purple
!!stjerm.color14: #71AAB3  ! cyan
!!stjerm.color15: #EAEAEA  ! white
!!stjerm.color16: #2e3436  ! needed because of bug

For command line arguments, it works best to put them in a .desktop file so that it appears in the menu. Then it is easy to start through there or through autostart options. A sample stjerm.desktop file:

[Desktop Entry]
GenericName=Stjerm Terminal
Exec=stjerm -ah false -p topright -s right -tf false -w 501 -h 300 -ab true -b thin -fg AEAEAE -c0 181C20 -c1 A44245 -c2 00BF00 -c3 C8C87A -c4 2B76C7 -c5 8B56A3 -c6 5BCEE4 -c7 D4D7D0 -c8 525952 -c9 A44245 -c10 37A42B -c11 CFCF91 -c12 2B76C7 -c13 8B56A3 -c14 71AAB3 -c15 EAEAEA -c16 2e3436

Put the stjerm.desktop file in ~/.local/share/applications/ to have it show up in the menu. To have Stjerm load when you login, link it to ~/.config/autostart/ (should work with most desktop environments):

ln -s ~/.local/share/applications/stjerm.desktop ~/.config/autostart/


I discovered that stjerm autohide function found me pressing the shortcut key often to unhide it, so I set -ah false so that the terminal stays on top. You can define your own terminal colors too. I tend to use slightly faded out colors to be easy on the eyes. The colors for reference:


  • new tab: ctrl-shift t
  • close tab: ctrl-shift w
  • next tab: ctrl-shift pageup
  • previous tab: ctrl-shift pagedown
  • exit: ctrl-shift q

A few more details about stjerm can be found in the man page.


Get every new post delivered to your Inbox.

Join 58 other followers