This page describes how I went about compiling parseltongue on OS X - all 3rd party dependencies were satisfied using macports
Getting the Sources
I obtained parseltongue2.0 and its main dependency Obit from the main parseltongue wiki page
Compiling Obit
The configure script did not do completely the correct thing for OS X even with a fair bit of prompting
./configure --prefix=/opt/local --with-gsl=/opt/local --with-xmlrpc=/opt/local --with-xmlrpc-includes=/opt/local --with-cfitsio=/opt/local --with-fftw3=/opt/local --with-plplot=/opt/local --with-pgplot=/opt/local LDFLAGS=-L/opt/local/lib
There were still some problems with hanging -L and -l (i.e. without an associated value) in some makefiles that I commented out. There were also a couple of file edits necessary
- Index: ObitRPC.h
===================================================================
--- ObitRPC.h (revision 261)
+++ ObitRPC.h (working copy)
@@ -30,7 +30,7 @@
#include <xmlrpc_client.h>
#include <xmlrpc_server.h>
-#include <xmlrpc_server_abyss.h>
+//#include <xmlrpc_server_abyss.h>
#include <xmlrpc-c/base.h>
#include <xmlrpc-c/client.h>
#include <xmlrpc-c/server.h> - Index: ObitSystem.c
===================================================================
--- ObitSystem.c (revision 261)
+++ ObitSystem.c (working copy)
@@ -29,9 +29,9 @@
#include <sys/times.h>
/* Bah humbug */
# ifndef CLK_TCK
-# include <bits/types.h>
-extern long int __sysconf (int);
-# define CLK_TCK ((__clock_t) __sysconf (2)) /* 2 is _SC_CLK_TCK */
+# include <unistd.h>
+
+# define CLK_TCK ((__clock_t) __sysconf (_SC_CLK_TCK)) /* 2 is _SC_CLK_TCK */
# endif
#include "Obit.h"
#include "ObitSystem.h"
The main problem that remained was that the final link of the shareable module for python did not do the correct thing - eventually ust did a manual edit of the commandline to remove -R and to add -F/opt/local/Library/Frameworks/ -framework python to link correctly.
Compiling parseltongue
The standard config make procedure worked without drama.
Compiling pyrap
Got the source from googlecode and built the current version. The main gotcha's for OS X are that the toplevel batchbuild.py script does not allow all the scons switches for libpyrap to be set - The solution is to go into the libpyrap directory and manually run scons with --enable-rpath --framework-path=/opt/local/Library/Frameworks/. It is then possible to run the batchbuild.py script as scons caches the values.