Installation Notes for Serpent on Linux

Roger B. Dannenberg

There are two versions of serpent; two are command line programs and the others are graphical interface programs (32-bit Serpent is no longer maintained):
Serpent is currently released as an SVN repository and in three zip files (the "nnn" is the corresponding SVN version number):
The "src" zip file contains sources for all platforms. You have to build from sources on Linux systems.

Building From Sources

To build from sources, get the "src" zip file. You can also get the very latest sources from SourceForge using SVN (subversion, a configuration management tool). The Linux command to create a serpent directory (in the current directory) with the lastest sources is:
svn checkout svn://svn.code.sf.net/p/serpent/code/trunk serpent
or, if you are a developer and plan to commit changes back to SourceForge,
svn checkout svn+ssh://rbd@svn.code.sf.net/p/serpent/code/trunk serpent
Important: If your serpent directory contains trunk, tags, and branches, check the code above and try again. For these instructions to work, all the repository files in trunk must be copied to the local working copy named serpent. E.g. you should have serpent/README.txt, serpent/32bit, and serpent/64bit. After you install liblo, you should have serpent/../liblo.

The following instructions worked for Linux (Ubuntu 14.04 LTS, linked with wxWidgets 3.1.3

Important: Serpent Environment

Serpent uses the environment to figure out where to search for files.

You may want to copy executables to ~/bin. Then, if you set up your search path appropriately, you can run serpent or wxserpent from any command prompt and any current directory. You may need to modify your PATH environment variable to include the path(s) for serpent and wxserpent. Since serpent is in my ~/bin directory, I add this to my ~/.profile file:

PATH=$PATH:/Users/rbd/bin
export PATH

You also need to tell serpent (and wxserpent) where to search for serpent source (.srp) files. Chances are good you will be using bash, so the command is:

export SERPENTPATH=/Users/rbd/serpent/programs:/Users/rbd/serpent/lib:/Users/rbd/serpent/wxslib
You can put these commands into .profile in your home directory so they will be automatically run when you start a shell.

Testing:

Try these commands:

cd
serpent64
> print "hello world"
hello world
> exit()

cd ~/serpent/wxs
wxserpent64 init.srp
This will run the init.srp in the current directory (wxs), which is a good simple test. Then try typing print "hello world" into the window with the Eval button and click on Eval. Try
cd ~/serpent/wxslib
wxserpent64 wxs_test.srp
for more fun. You should see a screen like this:
Screen shot from wxs_test