October 21, 2010
No Gnome in Maverick Meerkat
I am a little surprised that no one has yet commented on how there is no longer a Gnome entry in the Ubuntu Maverick Meerkat login screen. Instead, you have various options for "Ubuntu Desktop Edition." When you select "Ubuntu Desktop Edition" you get something that looks, acts, smells, and sounds almost exactly like Gnome. For now.
October 19, 2010
Enabling touchpad clicking and edge scrolling in Squeeze
Gnome has a mouse configuration interface that lets you enable touchpad clicking and scrolling. But if you are a Debian Squeeze user and prefer Xfce, LXDE, or some handmade alternative, you will find that your touchpad's clicking and edge scrolling won't work [1]. You'll also find that those functions don't work in the GDM login screen even if you do use Gnome. No probs. The fix is easy.
To fix:
If you don't like the idea of changing system config files, you can use synclient in a startup script to enable things as well.
Useful links:
[1] At least at the time of this writing. When Squeeze is eventually released, this may change.
To fix:
- Open /usr/share/X11/xorg.conf.d/50-synaptics.conf (as root) in an editor.
- Add the text
Option "TapButton1" "1"
Option "VertEdgeScroll" "1"
betweenSection "InputClass"andEndSection. - Save, reboot and enjoy.
If you don't like the idea of changing system config files, you can use synclient in a startup script to enable things as well.
Useful links:
- http://fedoraforum.org/forum/showthread.php?t=244594
- http://www.linuxquestions.org/questions/slackware-14/touchpad-doesnt-click-anymore-after-updating-to-current-732251/#post3572230
[1] At least at the time of this writing. When Squeeze is eventually released, this may change.
October 14, 2010
Fixing brightnes control, etc. on a Samsung R510 with Debian Squeeze
I finally got around to installing Linux on my Samsung R510 laptop. One of the problems with Samsung laptops is that they don't play well with some Linux standards. One example is the brightness control--it just doesn't work. There are some other issues that are less irritating, but this one is the worst for me.
There is a fix for these ails that was developed for Ubuntu (some of which is also at Google code.). The problem is that my current distribution of choice is Debian Testing (Squeeze). The good news is that these bits developed for Ubuntu can be used in Squeeze as well.
We need to install three different packages: easy-slow-down-manager, samsung-backlight, and samsung-tools. Here's what I did after installing Squeeze with Gnome on the R510:
easy-slow-down-manager
Download the Maverick *.deb for easy-slow-down-manager from from https://launchpad.net/~voria/+archive/ppa and install it directly with gdebi or your favorite package installer. It's all DKMS source code, so installing the package in Squeeze should be ok.
samsung-backlight
Downloaded the Maverick *.deb for samsung-backlight from from https://launchpad.net/~voria/+archive/ppa and install it directly with gdebi or your favorite package installer. Like easy-slow-down-manager, it's all DKMS source, so installing the package in Squeeze should be ok.
With a lot of Samsung laptops, we'd be done with these two packages. Sadly, the R510 needs some extra love. The following is taken almost verbatim from http://www.voria.org/forum/viewtopic.php?f=3&t=516&start=0&hilit=r510
First (as root):
In the Samsung section you will see a line with *N130*|*N140* etc. Add |*R510* there
Do the same for:
Next, add "acpi_backlight=vendor" to grub:
and add "acpi_backlight=vendor" to the line
Save the file and then update grub:
samsung-tools
It may or may not be ok to install the Ubuntu package for samsung-tools on Squeeze, but since it's got binaries in it, this is risky. I decided to download the sources and build a package on the Squeeze-equipped R510 instead. Start by getting some build tools:
Then from https://launchpad.net/~voria/+archive/ppa get the Maverick *.tar.gz sources for samsung-tools. Expand the *.tar.gz and inside the directory that has the debian directory (i.e., not in the debian directory, but in the directory immediately above), open a term and:
and add comment like "Compiled for Debian." Close the editor and in the term build the package with:
You may need to add additional dependencies if it fails. Pay attention to the error messages. Assuming it completes, this will generate a *.deb package file. Install it using gdebi or whatever.
After rebooting, you should now have working brightness buttons and a host of other working {Fn}-{Fsomething} keys. You will also have a new app under System->Preferences->Samsung Tools Preferences that you can use to change keybindings, etc and/or run as a Gnome panel app.
If it doesn't work
If the above doesn't work, you may be interested in playing with brightung. I haven't played with it except to confirm that (as root)
changes the brightness on my R510.
There is a fix for these ails that was developed for Ubuntu (some of which is also at Google code.). The problem is that my current distribution of choice is Debian Testing (Squeeze). The good news is that these bits developed for Ubuntu can be used in Squeeze as well.
We need to install three different packages: easy-slow-down-manager, samsung-backlight, and samsung-tools. Here's what I did after installing Squeeze with Gnome on the R510:
easy-slow-down-manager
Download the Maverick *.deb for easy-slow-down-manager from from https://launchpad.net/~voria/+archive/ppa and install it directly with gdebi or your favorite package installer. It's all DKMS source code, so installing the package in Squeeze should be ok.
samsung-backlight
Downloaded the Maverick *.deb for samsung-backlight from from https://launchpad.net/~voria/+archive/ppa and install it directly with gdebi or your favorite package installer. Like easy-slow-down-manager, it's all DKMS source, so installing the package in Squeeze should be ok.
With a lot of Samsung laptops, we'd be done with these two packages. Sadly, the R510 needs some extra love. The following is taken almost verbatim from http://www.voria.org/forum/viewtopic.php?f=3&t=516&start=0&hilit=r510
First (as root):
# gedit /lib/udev/rules.d/95-keyboard-force-release.rulesIn the Samsung section you will see a line with *N130*|*N140* etc. Add |*R510* there
Do the same for:
# gedit /lib/udev/rules.d/95-keymap.rulesNext, add "acpi_backlight=vendor" to grub:
# gedit /etc/default/gruband add "acpi_backlight=vendor" to the line
GRUB_CMDLINE_LINUX_DEFAULT so it looks likeGRUB_CMDLINE_LINUX_DEFAULT="quiet acpi_backlight=vendor"Save the file and then update grub:
# update-grubsamsung-tools
It may or may not be ok to install the Ubuntu package for samsung-tools on Squeeze, but since it's got binaries in it, this is risky. I decided to download the sources and build a package on the Squeeze-equipped R510 instead. Start by getting some build tools:
# apt-get install build-essential devscripts fakerootThen from https://launchpad.net/~voria/+archive/ppa get the Maverick *.tar.gz sources for samsung-tools. Expand the *.tar.gz and inside the directory that has the debian directory (i.e., not in the debian directory, but in the directory immediately above), open a term and:
dch -l {your initials}and add comment like "Compiled for Debian." Close the editor and in the term build the package with:
dpkg-buildpackage -rfakeroot -us -ucYou may need to add additional dependencies if it fails. Pay attention to the error messages. Assuming it completes, this will generate a *.deb package file. Install it using gdebi or whatever.
After rebooting, you should now have working brightness buttons and a host of other working {Fn}-{Fsomething} keys. You will also have a new app under System->Preferences->Samsung Tools Preferences that you can use to change keybindings, etc and/or run as a Gnome panel app.
If it doesn't work
If the above doesn't work, you may be interested in playing with brightung. I haven't played with it except to confirm that (as root)
# setpci -s 00:02.0 F4.B={some-hex-number}changes the brightness on my R510.
Workaround for installing desktops in Squeeze
I've done a couple new Debian Testing installations in the last couple days and have noticed something strange in the installer. At a point in the installation process, you will be offered a menu of choices for major package bundles to be installed. If you want a desktop environment, you're supposed to select "Desktop environment." In the past when I did this, the following screen would offer you a choice of DTEs including Gnome, KDE, Xfce, and LXDE. However, the last few installs I tried did not. And exactly what it installs I'm not sure because I wasn't willing to wait 3 hours (at my connection speeds) for the download and install process to complete. So here's the workaround:
First, using the installer, install the system you want but do not install a desktop environment.
When the installation completes, login using the command line. Then become root
Next, make sure you have tasksel installed:
Finally, use tasksel to install your desktop. To install Gnome:
Reboot:
and when your computer restarts, you should be good to go.
First, using the installer, install the system you want but do not install a desktop environment.
When the installation completes, login using the command line. Then become root
suNext, make sure you have tasksel installed:
# apt-get install aptitude taskselFinally, use tasksel to install your desktop. To install Gnome:
# tasksel install gnome-desktop --new-installReboot:
# rebootand when your computer restarts, you should be good to go.
September 29, 2010
Scrpit for building Debian Squeeze libcairo2 with Ubuntu patches
[Update 2011-06-25: Indeed, you should consider this post obsolete. See this post for more info.]
[Update 2011-06-24: This whole business may be unnecessary as it appears installing a recent version of Iceweasel from http://mozilla.debian.net/ also installs new libcairo2 with decent font rendering. I've yet to do careful comparisons, but it's possible that this solves both "ugly rendering in general" as well as "ugly rendering in Firefox" issues.]
[Update 2011-03-06 Reader datSilencer points out that the location of the Arch patch has changed. I have updated the script to reflect the change.]
Based on the post I wrote earlier, which is itself based on work published in a CrunchBang Linux Forum thread and by quanliking, I put together a script for quasi-automatically building libcario2 for Squeeze using the Ubuntu and Arch patches.
You can get the script at http://download.tuxfamily.org/skinny/libcairo2-patched/build-libcairo2.sh.
Prerequisites
When it comes time to rebuild (i.e., after a new Debian release) you must start over with an empty directory. Or at the very least, you must rename the top-level folder named libcairo2 that your previous build generated. This is to make sure that you get the most recent everything and that there are no goofy problems that might lead to a build that melts Arctic ice or increases the mercury content of fish.
Todo
An obvious bit of low-hanging fruit is to make entering of version info interactive, but it's arguable that that would be easier and less error prone that editing the script.
To round this out, we also need an additional script or package that adds the needed files from Ubuntu's fontconfig-config package to /etc/fonts/conf.avail and /etc/fonts/conf.d.
Notes
I uploaded the i386 packages that I built for my own use to http://download.tuxfamily.org/skinny/libcairo2-patched. Feel free to try these if you don't feel like building them yourself. However, I'm not making any promises that I'll keep these up-to-date.
Legal disclaimer
I have tested the code and packages mentioned here to make sure they don't bruise kittens or eat children. However, I wrote and built this stuff for my own use and have made it available here with no warranty of any kind whatsoever in the hopes it might be useful to others. Use at your own risk.
[Update 2011-06-24: This whole business may be unnecessary as it appears installing a recent version of Iceweasel from http://mozilla.debian.net/ also installs new libcairo2 with decent font rendering. I've yet to do careful comparisons, but it's possible that this solves both "ugly rendering in general" as well as "ugly rendering in Firefox" issues.]
[Update 2011-03-06 Reader datSilencer points out that the location of the Arch patch has changed. I have updated the script to reflect the change.]
Based on the post I wrote earlier, which is itself based on work published in a CrunchBang Linux Forum thread and by quanliking, I put together a script for quasi-automatically building libcario2 for Squeeze using the Ubuntu and Arch patches.
You can get the script at http://download.tuxfamily.org/skinny/libcairo2-patched/build-libcairo2.sh.
Prerequisites
- Enable sources in your /etc/apt/sources.list (i.e., make sure sources.list has something similar to deb-src http://ftp.us.debian.org/debian/ squeeze main non-free contrib in it). If you make any changes, be sure to
# apt-get update # apt-get install build-essential devscripts fakeroot# apt-get build-dep cairo
- Download build-libcairo2.sh into the directory where you plan to build the packages. I recommend you start with a dedicated and empty directory.
- Open the script in a text editor and change the constants at the top as documented.
- Make the script executable and execute it:
$ chmod +x build-libcairo2.sh
$ ./build-libcairo2.sh - Part of the way through, it will prompt you to fill in a line that opens in your default CLI editor. Do what it asks.
- When it's finished, open a term and follow the directions to install.
When it comes time to rebuild (i.e., after a new Debian release) you must start over with an empty directory. Or at the very least, you must rename the top-level folder named libcairo2 that your previous build generated. This is to make sure that you get the most recent everything and that there are no goofy problems that might lead to a build that melts Arctic ice or increases the mercury content of fish.
Todo
An obvious bit of low-hanging fruit is to make entering of version info interactive, but it's arguable that that would be easier and less error prone that editing the script.
To round this out, we also need an additional script or package that adds the needed files from Ubuntu's fontconfig-config package to /etc/fonts/conf.avail and /etc/fonts/conf.d.
Notes
I uploaded the i386 packages that I built for my own use to http://download.tuxfamily.org/skinny/libcairo2-patched. Feel free to try these if you don't feel like building them yourself. However, I'm not making any promises that I'll keep these up-to-date.
Legal disclaimer
I have tested the code and packages mentioned here to make sure they don't bruise kittens or eat children. However, I wrote and built this stuff for my own use and have made it available here with no warranty of any kind whatsoever in the hopes it might be useful to others. Use at your own risk.
July 15, 2010
Firefox 3.6 with pretty fonts in Debian Squeeze (easier version)
[Update 2011-06-25: You should consider this post obsolete. See this post for more info.]
If all the Mercurial and Namoroka in my previous posts about building and installing Firefox 3.6 in Squeeze has your head spinning a bit, here's a simplified version that gets the sources via FTP. As was the case in the previous build, this version enables cairo so you get nicer font rendering. This version also configures the build to use official Mozilla Firefox branding so you don't get Deer Park icons and such.
Preproduction
1) Create a working directory. Use a file manger or whatever you are comfortable with to do this. I called mine ~/firefox-release.
2) Get all the tools and things you need to build Firefox. In a terminal as root (using su):
Get and build
1) Get the source code. Open a web browser or ftp client and go to ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/3.6.6/source/. Download firefox-3.6.6.source.tar.bz2 into ~/firefox-release. (If 3.6.6 is no longer the most recent version, then replace 3.6.6 above with whatever the most recent 3.6 happens to be.)
2) Extract the archive you downloaded. Use tar -jxvf *.tar.bz2 on the command line or whatever GUI tool you are comfortable with. This will give you a mozilla-1.9.2 directory inside ~/firefox-release.
3) Make a configuration file. Create a new file inside ~/firefox-release/mozilla-1.9.2 called mozconfig. Open mozconfig inside a text editor and paste in the following text:
Save the file and exit the editor.
3) Build the beast by opening a terminal in ~/firefox-release/mozilla-1.9.2 and entering the following command:
Once the compile is done, the binaries will be in
~/firefox-release/mozilla-1.9.2/ff-release/dist/bin/.
As a test, execute the file firefox to make it go.
"Install"
1) Copy the contents of the bin directory to /opt, converting links to actual files. Do not try to copy the files with a file manager because it probably won't convert the links to files--which will render your "install" nonfunctional. Instead, open a terminal and go to ~/firefox-release/mozilla-1.9.2/ff-release/dist/. Then become root (using su) and do:
You should now have a new directory in /opt called firefox-release. Inside it will be an executable file called firefox. If all went well, executing this file (NOT as root) will launch the browser.
2) Create a command that lets you launch the browser. As root, make a softlink from /usr/local/bin/firefox to /opt/firefox-release/firefox:
3) Create a desktop file to introduce the new stuff to the menu. As root, create a file called firefox-release.desktop in /usr/local/share/applications (adding any directories that aren't already present.) Paste the following into firefox-release.desktop:
Save the file and exit the editor.
You're done.
If all the Mercurial and Namoroka in my previous posts about building and installing Firefox 3.6 in Squeeze has your head spinning a bit, here's a simplified version that gets the sources via FTP. As was the case in the previous build, this version enables cairo so you get nicer font rendering. This version also configures the build to use official Mozilla Firefox branding so you don't get Deer Park icons and such.
Preproduction
1) Create a working directory. Use a file manger or whatever you are comfortable with to do this. I called mine ~/firefox-release.
2) Get all the tools and things you need to build Firefox. In a terminal as root (using su):
# apt-get build-dep iceweasel
# apt-get install libasound2-dev libcurl4-openssl-dev libnotify-dev libxt-dev libiw-dev mesa-common-dev autoconf2.13 yasm
# apt-get install libidl-devGet and build
1) Get the source code. Open a web browser or ftp client and go to ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/3.6.6/source/. Download firefox-3.6.6.source.tar.bz2 into ~/firefox-release. (If 3.6.6 is no longer the most recent version, then replace 3.6.6 above with whatever the most recent 3.6 happens to be.)
2) Extract the archive you downloaded. Use tar -jxvf *.tar.bz2 on the command line or whatever GUI tool you are comfortable with. This will give you a mozilla-1.9.2 directory inside ~/firefox-release.
3) Make a configuration file. Create a new file inside ~/firefox-release/mozilla-1.9.2 called mozconfig. Open mozconfig inside a text editor and paste in the following text:
. $topsrcdir/browser/config/mozconfig
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/ff-release
#mk_add_options MOZ_MAKE_FLAGS="-j4"
ac_add_options --disable-debug
ac_add_options --disable-tests
ac_add_options --enable-optimize
ac_add_options --enable-official-branding
ac_add_options --enable-system-cairoSave the file and exit the editor.
3) Build the beast by opening a terminal in ~/firefox-release/mozilla-1.9.2 and entering the following command:
make -f client.mkOnce the compile is done, the binaries will be in
~/firefox-release/mozilla-1.9.2/ff-release/dist/bin/.
As a test, execute the file firefox to make it go.
"Install"
1) Copy the contents of the bin directory to /opt, converting links to actual files. Do not try to copy the files with a file manager because it probably won't convert the links to files--which will render your "install" nonfunctional. Instead, open a terminal and go to ~/firefox-release/mozilla-1.9.2/ff-release/dist/. Then become root (using su) and do:
# cp -R -L bin /opt/firefox-release
# chown root:root -R /opt/firefox-releaseYou should now have a new directory in /opt called firefox-release. Inside it will be an executable file called firefox. If all went well, executing this file (NOT as root) will launch the browser.
2) Create a command that lets you launch the browser. As root, make a softlink from /usr/local/bin/firefox to /opt/firefox-release/firefox:
# ln -s /opt/firefox-release/firefox /usr/local/bin/firefox3) Create a desktop file to introduce the new stuff to the menu. As root, create a file called firefox-release.desktop in /usr/local/share/applications (adding any directories that aren't already present.) Paste the following into firefox-release.desktop:
[Desktop Entry]
Encoding=UTF-8
Name=Firefox Release
Comment=Browse the World Wide Web
GenericName=Web Browser
X-GNOME-FullName=Firefox Web Browser
Exec=firefox %u
Terminal=false
X-MultipleArgs=false
Type=Application
Icon=/opt/firefox-release/icons/mozicon128.png
Categories=Network;WebBrowser;
MimeType=text/html;text/xml;application/xhtml+xml;application/xml;application/vnd.mozilla.xul+xml;application/rss+xml;application/rdf+xml;image/gif;image/jpeg;image/png;
StartupWMClass=Firefox-bin
StartupNotify=true
Name[en_US]=Firefox ReleaseSave the file and exit the editor.
You're done.
July 14, 2010
Fixing OpenOffice.org font rendering in Debian Squeeze
I guess I'm on a roll with font rendering improvements...
After patching libcario2 in Squeeze, I noticed font rendering in OpenOffice.org was really awful. It may have been equally awful before and I never noticed. In any case, it's now something that needs attention.
Ugly fonts in OO.org have been reported under Ubuntu and other distributions as well. A good explanation of the problem (in Ubuntu, at least) and a workable solution is offered by Mike Kasic about halfway down the bug report at https://bugs.launchpad.net/ubuntu/+source/cairo/+bug/271283. I tried his suggestions on my Squeeze installation, and it worked. If you don't want to be bothered filtering through the bug report, here's the executive summary.
Fixing just the session
Open a terminal and do:
Making the fix persist across sessions
Apply the fix for all users all the time
As root:
Note: I have only tried the first two above. I have not tested applying the change to all users.
The fix also works on my Sabayon Linux 5 install that uses the lcdpatch in cairo.
After patching libcario2 in Squeeze, I noticed font rendering in OpenOffice.org was really awful. It may have been equally awful before and I never noticed. In any case, it's now something that needs attention.
Ugly fonts in OO.org have been reported under Ubuntu and other distributions as well. A good explanation of the problem (in Ubuntu, at least) and a workable solution is offered by Mike Kasic about halfway down the bug report at https://bugs.launchpad.net/ubuntu/+source/cairo/+bug/271283. I tried his suggestions on my Squeeze installation, and it worked. If you don't want to be bothered filtering through the bug report, here's the executive summary.
Fixing just the session
Open a terminal and do:
echo "Xft.lcdfilter: lcddefault" | xrdb -mergeMaking the fix persist across sessions
echo "Xft.lcdfilter: lcddefault" >> ~/.XresourcesApply the fix for all users all the time
As root:
# sudo sh -c 'echo "Xft.lcdfilter: lcddefault" > /etc/X11/Xresources/ lcd-filter- lcddefault'Note: I have only tried the first two above. I have not tested applying the change to all users.
The fix also works on my Sabayon Linux 5 install that uses the lcdpatch in cairo.
Subscribe to:
Posts (Atom)