Zany80 The emulation-centric IDE © Noam Preil 2017 - 2020.

Warning: this guide is outdated. It does not apply to 0.2.0 onwards.

Building for Linux

Warning: there are some things this guide assumes you know. If you encounter any trouble, please ask for help on the #zany80 channel on irc.freenode.net

Assumptions:

Building Zany80 for Linux is extremely simple. The first thing to do is, of course, to download the source code. There are multiple places you can do this, but the easiest way by far is to use git.

These examples use /home/user/Builds/Zany80 for the build folder.

user@hostname:~/Builds$ git clone https://github.com/Zany80/Zany80
Cloning into 'Zany80'...
remote: Enumerating objects: 167, done.
remote: Counting objects: 100% (167/167), done.
remote: Compressing objects: 100% (105/105), done.
remote: Total 2194 (delta 74), reused 142 (delta 52), pack-reused 2027
Receiving objects: 100% (2194/2194), 12.98 MiB | 3.22 MiB/s, done.
Resolving deltas: 100% (1239/1239), done.
user@hostname:~/Builds$ cd Zany80
user@hostname:~/Builds/Zany80$

Once you have the source code, the rest is extremely simple. The build is handled by the build tool "fips", which is very lightweight and part of the repository already.

First, a configuration needs to be set. This can be done with

./fips set config linux-ENVIRONMENT-TYPE

For example, to create a release build using GNU Make, use the following:

user@hostname:~/Builds/Zany80$ ./fips set config linux-make-release
'config' set to 'linux-make-release' in project 'Zany80'

For a debug build, replace release with debug in the configuration name. For a full list of configurations, execute

user@hostname:~/Builds/Zany80$ ./fips list configs

There are a lot of configuration options, so you may want to pipe the output to less to make it more readable. It might also be useful to pipe the output to grep linux to hide the non-linux configurations.

Once you have a configuration set, it's time to generate the build files.

user@hostname:~/Builds/Zany80$ ./fips gen

As this is the first build, it will first download some needed files.

In the end, you should see something like this:

-- Configuring done
-- Generating done
-- Build files have been written to: /home/user/Builds/Zany80/build/fips-build/Zany80/linux-make-release
1 configs generated

If you're using an IDE (for instance, the linux-eclipse-release config), you should now be able to import the project, though further configuration may be required. For Eclipse, I suggest modifying the build configuration of the Zany80-Release project to invoke bash -c "./fips build linux-eclipse-release" instead of the default gmake. This is necessary so that Zany80's custom build command can move the plugins into a location that Zany80 can access them.

Building can be done via ./fips build, and you can run Zany80 via ./fips run zany80.

If you want to build a .tar.gz and a .deb package, you can run ./fips make package, and you should see (after some noise about the dependencies) something like this:

[100%] Built target zany80
Run CPack packaging tool...
CPack: Create package using TGZ
CPack: Install projects
CPack: - Run preinstall target for: Zany80
CPack: - Install project: Zany80
CPack: Create package
CPack: - package: /home/user/Builds/Zany80/build/fips-build/Zany80/linux-make-release/Zany80-0.0.3.5-Linux.tar.gz generated.
CPack: Create package using DEB
CPack: Install projects
CPack: - Run preinstall target for: Zany80
CPack: - Install project: Zany80
CPack: Create package
CPack: - package: /home/user/Builds/Zany80/build/fips-build/Zany80/linux-make-release/Zany80-0.0.3.5-Linux.deb generated.
1 configs built