Trent's Development Tools &
Personal Libraries
Note: all the stuff on this page is open source or free software (eg
subject to the GNU [lesser] GPL). However, most are subject to
copyright.
Quick access: Mini Makefile Generic Makefile
(view).
Editing / Essential Software Libraries
FTE - The Folding Text
Editor
FTE is the best editor ever, IMHO. It's responsive, never crashes, has full indentation support, syntax
highlighting, fast buffer switching, easy incorporation with make, and
oodles of other features. It's a cinch to use over X-Win and remains
usable over dialup. Folding is also handy, but I tend not to use it
much - I can see the benefit in something like java files though. It's
open source; maintained at Sourceforge and has a home page
and a project page
with the latest cvs and releases. I've hacked the
code myself to do a few things like smarter block commenting, and the
configuration files are a little confusing so I've set it up "the way I
like it" on staff and on ugrad, and you should be able to run it by just going
~tapted/bin/ft
at a command prompt, which will run a script to set you up. There's
also console versions (no X Server required -- just PuTTY
or similar),
but I haven't set them up (cos I don't use them). If you want to
continue my hackage, there's my modified fte
source and linux binaries
with all the console stuff (sfte, nfte, vfte). You might also want to
look at the script I'm using to run it on
staff and on ugrad.
GNU Common C++2
Get it.
Get it
now. Don't waste a single second more. Don't you dare write any socket
code in C++, nor any threading until you've looked at this library.
You'd
need to have a very good reason not to use it. An essential extension
to the
STL, aims to be platform independent (but has a little way to go --
works best on full posix-compliant systems). It's well documented and
mostly bug free. The exception model has been a bit buggy for me at
times though. It has oodles more features. There's also extensions
to it and a
very decent doxygen-generated
documentation
for it. On staff,
I've got it set up for you in
~tapted/include/
~tapted/lib/
so if you want to use it, use the flag
-I/usr/staff/tapted/include
for compilation (#include <cc++/thread.h> //for example). And use
the flags
-L/usr/staff/tapted/lib -lccgnu2
for linking. Depending what parts you used, you may also need
-lpthread
and
-ldl
Sorry, I haven't been borked setting it up on ugrad as well.
wxWindows
wxWindows
is a cross-platform GUI library for C++. It's good. It's even about to
be developed for embedded platforms (ARM/PocketPC/WindowsCE/etc).
Unfortunately,
there's not yet a good free IDE for it, but there's one
in development and a decent-looking
commercial Dialog Editor
Source manipulation
Doxygen
No program since has got me as excited as doxygen did when I
first delved into
its plethora of features. It keeps getting better too - the most
recent addition being UML-style inheritance and collaboration diagrams,
and call graphs. It's a documentation generator similar to javadoc but
orders of magnitudes better. I used it to generate all the
documentation
for my own source included as part of these devTools. There is also
mkDoxy, which is a
Perl script to make doxygen docs for Makefiles.
GNU Enscript
GNU
Enscript is a typesetter for program code. It's by far the best
I've come across, but credit goes to Dave Symonds for pointing me to
it. IMHO, it's the only way
to print code out; if it's about to be marked, for example. I've
written
oodles of shell scripts to make it easier to use and get (what I think
is)
the best out of all the oodles of stuff it can do. I'll put them up
soon.
For now, just try
~tapted/bin/code2ps <files>
or
~tapted/bin/code2ps2 <files>
for 2-up landscape. It should work on staff or ugrad. It will make a
file
firstfile.ext-all.ps containing everything with a table of contents and
it will use ext to determine the language.
Java Tools
As well as FTE, doxygen and enscript,
the following will probably come in handy.
jikes
Jikes
is IBM's Java compiler. javac sucks because it's actually written in
Java (don't ask me how they compiled it orignally) therefore it is
heinously slow. Jikes is written in C/C++ and gives much better error
messages (use -E if you want single lines for FTE -- you can specify
this in mmake). The only caveat is that it needs
to know where your jdk (for the java library), so make sure you have a
line something like
export CLASSPATH=$CLASSPATH:/usr/local/j2sdk1.4.1_01/jre/lib/rt.jar
at the end of your .bashrc or .bash_profile. Jikes is
installed on ugrad.
mmake
mmake
is just a shell script to make Makefiles
for Java. It's pretty handy, smoothing the transition from java source
(packages) to libraries (classpath) to jar files and documentation. It
also good because it encourages good organisation of files used in the
development process. By default it uses jikes. It will make a make file
that will turn out a lot faster than javac *.java for ordinary
development too. mmake is just a shell script and so is tiny - get it.
My Libraries - Linux Programming
Playing WAV Files
Playing WAV files (or any sound file) in linux from C++ source is a
bitch. GNU
Common C++2 has a neat sound
extension package for manipulating audio CDs, but the WAV file
support is just for manipulating the bytes, not actually sending it to
a sound card. SDL can do bits of it, but the API is a
rather heinous and it doesn't yet support recording.
I used to go on about an SDL wrapper I wrote at this point. But that
also turned out to be quite insufficient. So more recently, I wrote a
reasonably sophistiated mixer using portaudio and libsndfile. Some documentation is in a subdirectory, or start at the AudioSystem class reference.
My Libraries - Platform Independent
Random numbers
There's oodles of random number generators, nearly all are periodic.
The best one I've come accross is ISAAC
(Indirection, Shift, Accumulate, Add,
and Count), developed by Bob Jenkins. I've added some
extra
goodies (nrand, drand) to the C++ version by
Quinn Tyler Jackson (homepage is broken). This is my source; it also has some documentation.