Wednesday, February 17, 2021

Chess on Manjaro for Raspberry Pi 4 - installing Stockfish Engine on KNights

Playing around on my Manjaro KDE for Raspberri Pi 4B (8GB RAM model) - so far so good - movie playback on mpv is good, Youtube vids are acceptable at default (I am not picky as I look for quality of content rather than mindless high-def vides of nonsensical sunsets, pictures of apes or pretty girls in bright dresses walking down a street etc. - so at around 480 it is good for me), I have all the tools that I need to start working and make this little device a daily driver.

 

Online chess via lichess and chess.com are good - surprisingly the bundled Firefox browser works better on chess.com than on my openSUSE Leap notebook. Lichess is always good on any Frefox/Chromium-based browsers on any platforms.


KNights - the "default" chess app for the KDE Plasma environments is available but there is no Stockfish engine that I can install from Pacman. So since I have pretty much outplayed default chess engine GNU Chess - I was itching to get Stockfish installed on this Manjaro ARM. 


Here was how I got Stockfish installed:

  1. Go to the Stockfish Engine site and download the 64-bit version - at this time Stockfish is at version 12 https://stockfishchess.org/files/stockfish_12_linux_x64.zip

  2. Unzip the downloaded archive - stockfish_12_linux_x64.zip -d /opt

  3. Create a symlink to /usr/bin - ln -s /opt/stockfish_20090216_x64 /usr/bin/stockfish

  4. Launch the KNights application -> Settings -> Configure KNights

  5. Click on Computer Engines and then Auto-Detect

  6. You should now see Stockfish listed


Thursday, September 6, 2018

Make Font Rendering in Fedora 28 Great Again

While I am a mostly openSUSE user, due to some work requirements, I found myself in need of a Fedora installation. Bought a wonderfully refurbished Dell Latitude E5450 with an i5 CPU, 16GB RAM and 1TB HDD online and installed the latest Fedora Workstation  on it - since I use UK English and US English keyboard layout - I had to reconfigure the keyboard mapping post installation by localectl set-keymap us 

However the font rendering is still relatively inferior compared to openSUSE and Ubuntu (and its clones) - perhaps Fedora's insistence on sticking closely to vanilla upstream could be the issue.

Since I will be spending a lot of time working on this Fedora notebook, something needs to be done.

Grab the webcore-fonts and webcore-fonts-vista (with Microsoft TTF + Callibri, Consolas etc) packages from here and here - just download the RPMs meant for openSUSE Leap 15 and install them.

Install the adobe-source-code-pro-fonts RPM

Enable the rpmfusion-free repo and install the freetype-freeworld package.

Create /etc/fonts/local.conf and put in the following:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
  <match target="pattern">
    <test compare="eq" name="family" qual="any">
      <string>Arial</string>
    </test>
    <edit binding="same" mode="assign" name="family">
      <string>Noto Sans</string>
    </edit>
  </match>
  <match target="pattern">
    <edit name="dpi" mode="assign">96</edit>
  </match>
  <match target="font">
    <edit mode="assign" name="antialias" >
      <bool>true</bool>
    </edit>
  </match>
  <match target="font">
    <edit mode="assign" name="hinting" >
      <bool>true</bool>
    </edit>
  </match>
  <match target="font">
    <edit mode="assign" name="hintstyle" >
      <const>hintslight</const>
    </edit>
  </match>
  <match target="font">
    <edit mode="assign" name="rgba" >
      <const>rgb</const>
    </edit>
  </match>
  <match target="font">
    <edit mode="assign" name="lcdfilter">
      <const>lcddefault</const>
    </edit>
  </match>
  <alias binding="strong">
    <family>sans-serif</family>
    <prefer>
      <family>Open Sans</family>
    </prefer>
  </alias>
  <alias binding="strong">
    <family>serif</family>
    <prefer>
      <family>Bitstream Charter</family>
    </prefer>
  </alias>
  <alias binding="strong">
    <family>monospace</family>
    <prefer>
      <family>Source Code Pro</family>
    </prefer>
  </alias>
</fontconfig>

Reboot the computer and you are good to go.

Some of the details are from https://esc.sh/blog/fix-ugly-fonts-in-fedora/

Saturday, July 8, 2017

GNOME Chess and Stockfish 8 Engine

I am a life-long chess and FOSS enthusiast and often play my favourite game on my Linux desktops either on the excellent multi-platform PyChess or GNOME Chess. I prefer the latter simply for its cleaner interface.

I wanted to add a really strong chess engine like Stockfish but the standard repository for my openSUSE 42.2 is hosting an earlier version (version 7 vs. the current 8).

So, off I went and downloaded the Linux binaries for Stockfish 8 from its home site. It is a simple zipped archive that contains the binaries for the engine.

I extracted the archive to /opt (/opt/stockfish-8-linux) and proceeded to edit the GNOME Chess engines config file (/etc/gnome-chess/engines.conf); the config file already has a list of chess engines that it supports, so I proceeded to the Stockfish portion and changed the binary= line to the exact location of the Stockfish binary i.e. /opt/stockfish-8-linux/Linux/stockfish_8_64.

And now off to bash heads with the latest and greatest from the Stockfish project.

Friday, August 12, 2016

Webcore and Infinality Ultimate on openSUSE Leap is awesome

Previously I wrote about using Infinality Ultimate to make the font rendering on my openSUSE Leap looking fabulous. Well, Yuzery Yusoff in the OpenSUSE Malaysia FB group added that he also added the webcore fonts to even make it more fabulous.

Here are his comments :

" My steps installing infinality ultimate:
1. Google "infinality ultimate opensuse"
2. Add repo frm http://download.opensuse.org/.../home:nick31:INFINALITY... ( coz im using tumbleweed)
3. Open yast>software management and view repo. Choose repo for infinality and switch to it and follow further installation
3. After finish with installation, i find "webcore" repo and install "webcore" and "webcore-vista" fonts
4. After finish install both of microsoft fonts, open terminal and type this: sudo fc-presets set
5. It will prompt for choices. I enter no 3 which is meant for ms ( micro$oft)
6. Restart your computer

There u go. The fonts absolutely better, even better than in Windows for me laa..

Because I'm dealing with my peers who still using Windows and Office suite, i need to install WPS Office for exact compatibility

Done. No more just looking tru windows. I ran out from the gates. Go to the open field and play around there...in the open world...hahaha
"

And my - the effects are really astounding!!

Better font rendering with Infinality Ultimate for openSUSE Leap

Infinality-ultimate is a set of patches that improves the font-rendering in Linux systems.

I use openSUSE Leap 42.1 and fialed to look for a 1-Click Install  at OBS. Google search yielded a repo for 13.2 and retracing my way up to its parent dir, I found the repo directory for Leap at http://download.opensuse.org/repositories/home:/nick31:/INFINALITY-ULTIMATE/openSUSE_Leap_42.1/

As usual I added it via CLI:
# zypper ar -f http://download.opensuse.org/repositories/home:/nick31:/INFINALITY-ULTIMATE/openSUSE_Leap_42.1/ Infinality_Ultimate

and refreshed the new repo
# zypper ref Infinality_Ultimate

Since I already have the Infinality repo's fontoconfig installed, I need to force an update from the new repo

# zypper dup --from Infinality_Ultimate

After a reboot, my fonts are indeed much better, especially in my Chrome and Chromium browsers that has been giving me less than perfect fonts.

Anything that runs Qt and generally all now look amazing.

Thursday, June 30, 2016

Fixing Totem error ("Missing plugings") when playing vids in openSUSE Leap

Totem, the default video player for the GNOME 3 desktop has always been a difficult beast to tame when I am using openSUSE. My primary work machine runs openSUSE Leap and as predicted, Totem isn't running - no matter what manner of gstreamer plugins added/removed or removing the ~/.cache/gstreamer-1.0 directory nothing works.

Posting in the openSUSE group in FB got me a reply from a gentleman (https://www.facebook.com/NMMoendjen?fref=ufi) who suggested that I should install xine. That jigged my memory and I recalled installing the w32codecs package to make Totem work. Did a zypper search but couldn't find w32codec package even in the Packman repo for Leap.

Going through OBS, a preliminary search yielded w32codec packages for Tumbleweed and 13.x. Not Good! I trawled through the repository manually it yielded me the YMP for it at http://software.opensuse.org/ymp/home:vadimuzzz/openSUSE_42.1/w32codecs.ymp.

If you have trouble installing the package from 1-Click Install, download the package and use zypper to manually install it. Just ignore the "Problem: nothing provides libstdc++.so.5 needed by w32codecs-1.0-20110133.1.x86_64" error message.

Totem is alive again.....

Fixing Totem error ("Missing plugings") when playing vids in openSUSE Leap

Totem, the default video player for the GNOME 3 desktop has always been a difficult beast to tame when I am using openSUSE. My primary work machine runs openSUSE Leap and as predicted, Totem isn't running - no matter what manner of gstreamer plugins added/removed or removing the ~/.cache/gstreamer-1.0 directory nothing works.

Posting in the openSUSE group in FB got me a reply from a gentleman (https://www.facebook.com/NMMoendjen?fref=ufi) who suggested that I should install xine. That jigged my memory and I recalled installing the w32codecs package to make Totem work. Did a zypper search but couldn't find w32codec package even in the Packman repo for Leap.

Going through OBS, a preliminary search yielded w32codec packages for Tumbleweed and 13.x. Not Good! I trawled through the repository manually it yielded me the YMP for it at http://software.opensuse.org/ymp/home:vadimuzzz/openSUSE_42.1/w32codecs.ymp.

If you have trouble installing the package from 1-Click Install, download the package and use zypper to manually install it. Just ignore the "Problem: nothing provides libstdc++.so.5 needed by w32codecs-1.0-20110133.1.x86_64" error message.

Totem is alive again.....