PySoy: Intro to Linux Development 6
completed by: Stephan
mentors: Amaury Medeiros, Arc Riley, David Czech, Jon Neal, AJ Williams
While PySoy is intended to be cross-platform, its primarily developed on Linux which provides most (or all) of its dependencies packaged as system-wide shared libraries, an easy to use build system, and great community support.
If you already have Linux installed (or wish to do so), pick this as an introduction to developing PySoy.
This guide assumes no prior experience with Linux, shells, version control, build systems, or IRC. If you're an experienced Linux user, please just do this without claiming this task since you may only complete two beginner tasks and we have many to choose from.
Before getting started, you will want to connect to IRC (Internet Relay Chat) to get help should you run into any trouble. Your Linux distribution should have an IRC client, some examples include Empathy, Pidgin, and XChat. Use one of these to connect to
irc.freenode.net and join the
#CopyleftGames channel on Freenode. Say hi, and don't be discouraged if someone doesn't reply immediately - we're not always staring at the screen but there is generally always someone online. If you're new to Linux, you may also want to join the channel for your Linux distribution, (
#Arch, #Fedora, #Mint, #Ubuntu, etc).
Also, for the purpose of this task, keep notes on things that you have difficulty on. This will be needed to complete this task.
To get started, install Mercurial via your package manager. Each distribution (eg, Arch, Fedora, Mint, Ubuntu) has a package manager, just search for Mercurial and install it. Ask in IRC if you can't find the package manager or Mercurial in it.
Next, open a Terminal and type
hg clone http://hg.pysoy.org/libsoy to use Mercurial (the command "hg") to download the libsoy source code. This may take awhile because the "clone" command downloads every source file change that's ever been made over the last 7 years.
hg clone command has finished, change directories to the new libsoy folder with the
cd libsoy command. If you type
ls you will get a list of files in this directory.
INSTALL in the libsoy directory. You can type
less INSTALL, open the file in a graphical text editor like Gedit, or even load it in a web browser by typing
firefox INSTALL (or another browser, eg
chrome install). If you scroll down you'll find a section specific to your Linux distribution with directions you can usually just copy and paste to a terminal.
With all the libsoy dependencies installed, you should be able to type
./waf configure which will verify and find all the dependencies you installed in the previous step. If there's an error, ask for help.
Now you're ready to actually compile libsoy with the
./waf build command. This may take a few minutes the first time you run it, and you'll see several warnings which you can ignore for now.
If everything went well, type
sudo ./waf install to install libsoy. Generally this goes into
/usr/local with other software you compile and install by hand (vs with package manager).
Lets see what you've learned - type
cd ~ to return to your home directory and use Mercurial to clone
Change directory to the new
pysoy folder, read PySoy's
INSTALL for any additional directions, and use the same
waf commands to configure, build, and install as you did with libsoy.
Test your installation by changing to
examples directory and type
./CollideBlocks.py - if all went well, a window will pop up with checkered blocks with round edges spinning and smashing into each other. Hit the Print Screen key (or another method to take a screenshot) as proof of task completion.
While working on this task you should join and remain in #CopyleftGames on Freenode to get help, feedback, and guidance from mentors and other developers.
When you've done, post the screenshot and your notes to this task.