I managed to get the build working on snow leopord. The problems are many fold. First, scons from macports depends on python 2.6, which fink insists on compiling for itself.. Also, the fink dependencies for the python packages (like yaml), are installed for macports python 2.6, NOT the system 2.6.
Furthermore, the fink python 2.6 builds as a framework, but it's broken. Consequently, when you build fife, it builds against the system python. Furthermore, the system python is installed as "python" but the macports python 2.6 is installed as "python2.6"
So to fix the problem you have do one of:
1)
Fix the python2.6 framework so that fife can link against it. Then fix all references to "python" in the tops of scripts to be "python2.6" (or symlink python2.6 as python, probably in ~/bin or something).
OR
2)
Install the extra python modules somewhere and add that to your PYTHONLIBDIR environment variable, and use the system python to link. A complication here is that the mac build of fife explictly tries to use the headers from macports python 2.6, so you'll have to fix the darwin build of fife if you go down this route.
I opted for (1).
After installing the macport dependencies:
$ cd /opt/local/Library/Frameworks/Python.framework
$ cd Versions
$ ln -s 2.6 Current
$ cd ..
$ ln -s Versions/Current/Python Python
$ ln -s Versions/Current/Headers Headers
$ ln -s Versions/Current/Resources Resources
Then clean and rebuild fife. If you've done this correctly, you should be able to use otool to see if it's linking against macports python.
$ otool -L <fife-dir>/build/release/_fife.so
Examine the output and make sure it's linking against the macports python and NOT the system python. If it is, you should be able to go to your unknown-horizons directory and type:
$ python2.6 run_uh.py
You must explictly call python2.6 otherwise the #! in run_uh.py wlll call into "python" which is the system python and doesn't have the modules installed.
*an annoyance with this whole process is that macports will install both python 2.6 and python 2.7. This means that the python framework in /opt/local will contain both a python 2.6 and python 2.7 dir. However several of the dependencies available in fink are /only/ available as python 2.6 builds, so I made "2.6" the "Current" version in the framework to ensure that everything links against the version that appears to have better support.