Raspberry Pi 4 compiled chess engines

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Ras
Posts: 2488
Joined: Tue Aug 30, 2016 8:19 pm
Full name: Rasmus Althoff

Re: Raspberry Pi 4 compiled chess engines

Post by Ras »

Pi4Chess wrote: Mon Nov 16, 2020 11:53 pmDon't i have to put aarch64 instead of armv8 ?
The "Makefile" file lists the available CPU options, and the Stockfish devs called that one "armv8", but it's for ARM 64 bit.
Rasmus Althoff
https://www.ct800.net
Ras
Posts: 2488
Joined: Tue Aug 30, 2016 8:19 pm
Full name: Rasmus Althoff

Re: Raspberry Pi 4 compiled chess engines

Post by Ras »

And here's another one, my own engine CT800 v1.41 (around 2400 on CCRL): https://www.ct800.net/download.htm

You download and use your file manager to extract the ZIP file on the Raspi. In the extracted folder, you go into "source", then into "application-uci". Right-click on the file "make_ct800_linux.sh" and click "Properties". Go to the "Permissions" tab and check that the "Execute" checkbox is ticked. Then double-click that file, and your file manager should ask you whether to run this in a terminal. Do that, and in the previously empty folder "output", a new file "CT800_V1.41" appears - that's the engine program. Since it compiled on the Raspi itself, it's right for that system.
Rasmus Althoff
https://www.ct800.net
Pi4Chess
Posts: 253
Joined: Mon Nov 16, 2020 12:13 pm
Full name: Manuel Rivera

Re: Raspberry Pi 4 compiled chess engines

Post by Pi4Chess »

Ras wrote: Tue Nov 17, 2020 12:06 am And here's another one, my own engine (around 2400 on CCRL): https://www.ct800.net/download.htm

You download and use your file manager to extract the ZIP file on the Raspi. In the extracted folder, you go into "source", then into "application-uci". Right-click on the file "make_ct800_linux.sh" and click "Properties". Go to the "Permissions" tab and check that the "Execute" checkbox is ticked. Then double-click that file, and your file manager should ask you whether to run this in a terminal. Do that, and in the previously empty folder "output", a new file "CT800_V1.41" appears - that's the engine program.
It worked !! Thank you very much ! I was precisely looking at your website and yes i will compile your engine also :-)

It will be 64 bits also ?

Now i am trying to compile every open source engine i am going to see for my little raspberry but i think there will be more troubles to fo it right :-)
If i manage i will post some compressed files with the engines i succeded compiling.
Again thank you for your help. I don't understand why there was no Stockfish 12 in the ubuntu repositories since it is that easy to do it...
Ras
Posts: 2488
Joined: Tue Aug 30, 2016 8:19 pm
Full name: Rasmus Althoff

Re: Raspberry Pi 4 compiled chess engines

Post by Ras »

Pi4Chess wrote: Tue Nov 17, 2020 12:15 amIt worked !!
Congrats! :D The specific way to compile varies from engine to engine, but you mostly have either such a "Makefile" as basis (like with Stockfish), or build scripts (like with mine).
It will be 64 bits also ?
Yes, the Linux build script uses whatever the system has where it is compiling. So, on a 64 bit Raspi, this will give you a 64 bit engine. If you register it in Arena, it will tell its name, and that includes whether it's 32 or 64 bit.
Now i am trying to compile every open source engine i am going to see for my little raspberry but i think there will be more troubles to fo it right :-)
Given that you succeeded with your first compile that easily, most engines that have a Linux versions will be similarly easy. And the best, you can do that whenever you want.
I don't understand why there was no Stockfish 12 in the ubuntu repositories since it is that easy to do it...
That's because Ubuntu 20.04 was released in April 2020, hence the name, but Stockfish 12 was only released in September 2020. Ubuntu 20.04 is a "long term support" (LTS) release where they don't update the programs except for security fixes. The advantage is that updates are unlikely to break anything - the downside is that applications aren't available in the newest release.
Rasmus Althoff
https://www.ct800.net
Pi4Chess
Posts: 253
Joined: Mon Nov 16, 2020 12:13 pm
Full name: Manuel Rivera

Re: Raspberry Pi 4 compiled chess engines

Post by Pi4Chess »

Ras wrote: Tue Nov 17, 2020 12:30 am
Given that you succeeded with your first compile that easily, most engines that have a Linux versions will be similarly easy. And the best, you can do that whenever you want.

That's because Ubuntu 20.04 was released in April 2020, hence the name, but Stockfish 12 was only released in September 2020. Ubuntu 20.04 is a "long term support" (LTS) release where they don't update the programs except for security fixes. The advantage is that updates are unlikely to break anything - the downside is that applications aren't available in the newest release.
I have already compiled 8 other engines (the easiest ones with makefile) :-)
Some others give errors for missing files or because bad flags or asking for clang instead of gcc.

I will learn thx to your showing a beginning "how to".
Ras
Posts: 2488
Joined: Tue Aug 30, 2016 8:19 pm
Full name: Rasmus Althoff

Re: Raspberry Pi 4 compiled chess engines

Post by Ras »

Pi4Chess wrote: Tue Nov 17, 2020 11:21 amasking for clang instead of gcc.
You can go into the package manager (probably Synaptic) and install the packages "clang" and "clang-10" (plus whatever the package manager also recommends), then clang should be available. :)
Rasmus Althoff
https://www.ct800.net
Pi4Chess
Posts: 253
Joined: Mon Nov 16, 2020 12:13 pm
Full name: Manuel Rivera

Re: Raspberry Pi 4 compiled chess engines

Post by Pi4Chess »

I changed clang by gcc in the makefile 😁