Qalculate!, My New Favorite Calculator

Over the past few years I acquired a bad habit of using search engines for basic calculations and conversions. I’m not talking about the stuff you should just do in your head — not quite that bad, but about the fact that most Linux distros don’t seem to ship with a calculator by default. So I finally got around to testing some programs and Qalculate! does all I want. You can install it on Debian using sudo apt install qalculate-gtk. There’s a list of features on the website. Enjoy a few screenshots.

qalculate-conversion-celsius-fs8
Celsius to Fahrenheit.
qalculate-conversion-km-fs8
Kilometer to mile.
qalculate-conversion-money-fs8
Euro to Dollar.

I hope you’ll like it too!

CommentsTags: , ,

libGL error in Steam and Broken Age in Debian Stretch

After some update or other, Broken Age refused to start.

$ ./start.sh 
Running Broken Age
libGL error: unable to load driver: radeonsi_dri.so
libGL error: driver pointer missing
libGL error: failed to load driver: radeonsi
libGL error: unable to load driver: swrast_dri.so
libGL error: failed to load driver: swrast
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  155 (GLX)
  Minor opcode of failed request:  3 (X_GLXCreateContext)
  Value in failed request:  0x0
  Serial number of failed request:  91
  Current serial number in output stream:  92

Oh well, let’s give it a little hand, shall we?

LD_PRELOAD='/usr/lib/i386-linux-gnu/libstdc++.so.6 /lib/i386-linux-gnu/libgpg-error.so.0' ./start.sh

This loads the included libraries before any others, in order to override the incompatible libraries shipped with the program in question. The same trick also works for Steam. If gaming is your goal, you should probably stick to whatever version of Ubuntu is supported best. I’m just pleased that I can play the occasional game like Oxenfree (no preloading required, mind you) or Broken Age on my workhorse without having to install any stability-reducing binary blobs.

Comments (1)Tags: ,

Fix No gksu(do) Permissions Prompt on Gparted, Synaptic, Mounting Drives, Etc. in Debian

I run Debian Stretch (testing) as my daily driver, and at some point I stopped being able to start programs like start Synaptic, Gparted, Synaptic etc. without manually typing gksu(do). The solution is as simple as it is seemingly unnecessary and stupid:

sudo apt install policykit-1-gnome

The problem is apparent upon reading the description:

This implementation was originally designed for GNOME 2, but most
GNOME-based desktop environments, including GNOME 3, GNOME Flashback,
MATE and Cinnamon, have their own built-in PolicyKit agents and no
longer use this one. The remaining users of this implementation
are XFCE and Unity.

Reported as Debian bug #843224. My first?


D’oh, I wrote this on November 5, 2016. I’ll still publish it anyway in case it’ll still help someone searching for a solution.

CommentsTags: ,

Scanning with an HP MFP (multi-function peripheral) on Debian

You need to install hplip. It looks like something’s still off about the colors compared to Ubuntu and Windows, and I can’t figure out what the difference is. Alas. :/ Also, don’t buy HP.

CommentsTags: , , ,

Less is More

A minimal Debian install comes without the ability to view man pages. Fair enough, it’s minimal after all. But they can be quite useful. A sudo apt install man later results in man pages being shown. That’s all, folks? Unnfortunately not, because the man pages are shown using the more command, which doesn’t allow for scrolling up and down with the arrow keys or j and k, Pg Up and Pg Dn, and all the other usual niceties. To fix you need to sudo apt install less, a “pager program similar to more.” And better, at least on any machine with sufficient RAM. Meaning anything anyone is likely to use in 2016, or probably also in 1990 for that matter.

CommentsTags: ,

Let’s Encrypt on Debian/Jessie

Wow, that was easy. I’ve been reading about Let’s Encrypt all over the place, and I wouldn’t like any snooping on my feeds password, now would I?

  1. Add the jessie-backports repository.
  2. sudo apt install -t jessie-backports certbot python-certbot-apache
  3. sudo letsencrypt --apache -d example.com [-d subdomain.example.com]

This stuff expires every 90 days, so you still need a cron job to renew.

sudo crontab -e

Let’s say 4 at night every Sunday.

* 4 * * 0 letsencrypt renew >> /var/log/letsencrypt-renew.log

Neat!

CommentsTags: , ,

xorg.conf: EmulateWheel stopped working on libinput update

I didn’t spot it in the Debian changelog, but apparently the latest libinput10 update on Debian/stretch (unstable) broke my EmulateWheel option. Because the scroll ring on my trackball is broken, it’s all I’ve got. It’s also rather nice on trackballs without any kind of scrolling functionality at all, such as the Logitech Trackman Marble.

Let’s start by examining my current xorg.conf:

$ cat /etc/X11/xorg.conf 
Section "InputClass"
	Identifier	"Kensington Trackball"
	MatchProduct	"Kensington Expert Mouse"
	Option		"SendCoreEvents" "True"
	Option		"ButtonMapping" "0 1 2 4 5 6 7 3"
	Option		"EmulateWheel" "True"
	Option		"EmulateWheelButton" "1"
EndSection

Scanning man xinput doesn’t list any entries for those options anymore, but it does contain the following:

Option "ScrollButton" "int"
Designates a button as scroll button. If the ScrollMethod is button and the button is logically held down, x/y axis movement is converted into scroll events.
Option "ScrollMethod" "string"
Enables a scroll method. Permitted values are none, twofinger, edge, button. Not all devices support all options. If an option is unsupported, the default scroll option for this device is used.

Note how this would allow you to disable two-finger scroll on e.g. our Wacom drawing tablet if you don’t like it. (But I do!) In any case, adjusting my xorg.conf accordingly:

Section "InputClass"
        Identifier      "Kensington Trackball"
        MatchProduct    "Kensington Expert Mouse"
        Option          "SendCoreEvents" "True"
        Option          "ButtonMapping" "0 1 2 4 5 6 7 3"
        Option          "ScrollMethod" "button"
        Option          "ScrollButton" "1"
EndSection

Works like a charm. Better yet, it now also scrolls horizontally. Which can be disabled with Option "HorizontalScrolling" "false" if you so desire. All’s well that ends well.

CommentsTags: , ,

Debian: International Fonts

Ubuntu comes with a large swath of international fonts installed by default, but Debian requires a little more attention. Although I can’t read the languages, I can recognize which script is which. Besides, boxes are just ugly.

  • East Asian: apt-get install ttf-arphic-uming ttf-wqy-zenhei ttf-sazanami-mincho ttf-sazanami-gothic ttf-unfonts-core (source)
  • Indic: apt-get install ttf-indic-fonts (source)
  • All together: apt-get install ttf-arphic-uming ttf-wqy-zenhei ttf-sazanami-mincho ttf-sazanami-gothic fonts-unfonts-core ttf-indic-fonts

These are merely the ones that I missed the most. I may update this post in the future.

Comments (1)Tags: , ,