Someone asked me to build a package for Netsurf. I had never heard of Netsurf before. It turns out that Netsurf is a cross-platform web browser which also runs on Linux. Its rendering engine is written from scratch, therefore the browser does not share code with any of the big browsers. Netsurf is actively developed and has a healthy community. A new version was released last week – 3.7.
Functionally speaking, this browser is not as versatile or capable as other modern browsers, but its advantage is that it is small, fast, suited for low-end hardware, and more importantly: it works on the Linux framebuffer. This means that you can have a basic graphical web browser on your server console. It looks better than “links -g”.
Note: even though Netsurf comes with both a GTK version (netsurf-gtk) and a framebuffer version (netsurf-fb), even the framebuffer binary make heavy use of X.Org and freetype libraries. So if you want to use the framebuffer browser on a server console, you need to install the X series anyway.
How to make Netsurf work on the Linux framebuffer, i.e. on the console?
- Add your user to the “input” group so you can use the mouse (i.e. the /dev/input/mice device node) using the command (as root):
# gpasswd -a your_username input
If you are currently logged on, you need to logout and login again to make this change effective. - Determine the width and height of your framebuffer console to make maximal use of your screen dimensions (netsurf on a framebuffer defaults to a window of 800×600 pixels) by querying the /sys virtual filesystem and look for the characteristics of the fb0 framebuffer device:
# cat /sys/class/graphics/fb0/virtual_size
This will return width and height in pixels, comma-separated. In my case I get “1920,1080”. - Read the available documentation to learn about the limitations.
With the above taken care of, start the Netsurf framebuffer browser with:
$ netsurf-fb -w <width> -h <height>
… where <width> and <height> are the values obtained from the command further up.
Curious? Get the package from my regular repository (http://www.slackware.com/~alien/slackbuilds/) or any of its mirrors.
If you want to compile netsurf yourself, you’ll also need two dependencies, “perl-html-tagset” and “perl-html-parser“.
Awesome! Never heard about it as well and this is exactly what I need!
Big thanks to devs and Eric!
How many programs actually would work with the framebuffer?
When I tried to run netsurf-fb is complained about not finding libvncserver.so.1 and slackware-current is only at 0.9.11. 🙁
Jim
jim, the libvncserver.so.1.0.0 library is part of the libvncserver-0.9.11 package in Slackware-current.
Note that the netsurf package that I built for Slackware 14.2 depends on libvncserver.so.0… are you perhaps running Slackware 14.2 instead of -current and installed the wrong package?
Yes, it was a 14.2 system. I looked closer and fixed the problem. I’ll look at netsurf a bit more later when I have a few extra minutes.
Thanks,
Jim
Hi Eric,
thank you for providing the package.
I noticed that https://duckduckgo.com/ shows a blank page in both gtk and fb interfaces. Instead, if you add “html” at the end of the url it seems to load it correctly.
Christiano, interesting find! Indeed the site works with “/html/” appended.
Netsurf has more of these quirks/incompatibilities, it is still nice to use because it is so fast.
Yes, I agree!
seems fast and stream. Long way togo. does not read the schema for youtube sighn in
Hi I am using ssh to get the server from a chrome book. I am running an orange pi one with armbian 16.04 followed your instructions and it did this Unable to init SDL: Unable to open a console terminal
thanks
jwp, I do not publish a netsurf package for armbian. This is a Slackware blog.
And you will not get the framebuffer program working through an ssh session, you need to be logged on to the actual machine console.