J'ai essayé d'installer Pythonika sur mon Ubuntu 14.04 (64) avec Python 2.7.6. J'ai suivi la réponse de Salem, mais il y a quelques erreurs.
El Makefile.linux
# Set the paths according to your MathLink Developer Kit location.
# (The paths should not contain whitespaces)
MATHEMATICA_INSTALL_DIR = /usr/local/Wolfram/Mathematica/10.0
MLINKDIR = ${MATHEMATICA_INSTALL_DIR}/SystemFiles/Links/MathLink/DeveloperKit
SYS = Linux-x86-64
CADDSDIR = ${MLINKDIR}/${SYS}/CompilerAdditions
INCDIR = ${CADDSDIR}
LIBDIR = ${CADDSDIR}
MPREP = "${CADDSDIR}/mprep"
MCC = "${CADDSDIR}/mcc"
# Modify the following for Python versions other than 2.6
PYTHON_VERSION_MAJOR = 2
PYTHON_VERSION_MINOR = 7
# Path to the Python includes (modify according to Python version)
#
PYTHONINC = /usr/include/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/
PYTHONIKA = Pythonika
INCLUDES = -I${INCDIR} -I${PYTHONINC}
# libstdc++ and librt are, apparently, needed for correct compilation under Linux
# with libMLi3 statically linked
#
## Ununtu 14.04
LIBS = -L${LIBDIR} ${LIBDIR}/libML64i3.a -lstdc++ -lpthread -lm -lrt - lpython${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}
all : Pythonika
Pythonika: ${PYTHONIKA}.o ${PYTHONIKA}tm.o
${CC} ${INCLUDES} ${PYTHONIKA}.o ${PYTHONIKA}tm.o ${LIBS} -o ${PYTHONIKA}
${PYTHONIKA}tm.o: ${PYTHONIKA}.tm
${MPREP} ${PYTHONIKA}.tm -o ${PYTHONIKA}tm.c
${CC} -c ${PYTHONIKA}tm.c ${INCLUDES}
${PYTHONIKA}.o: ${PYTHONIKA}.c
${CC} -c ${PYTHONIKA}.c ${INCLUDES}
clean :
rm -f ${PYTHONIKA}tm.* ${PYTHONIKA}.o ${PYTHONIKA}
L'erreur est
cc -I/usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions -I/usr/include/python2.7/ Pythonika.o Pythonikatm.o -L/usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions /usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions/libML64i3.a -lstdc++ -lpthread -lm -lrt -lpython2.7 -o Pythonika
Pythonikatm.o: In function `MLAnswer':
Pythonikatm.c:(.text+0xba8): undefined reference to `MLWaitForLinkActivity'
/usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions/libML64i3.a(mluuid.cpp.o): In function `MathLink::MLUUID::stringRepresentation() const':
mluuid.cpp:(.text+0x7e): undefined reference to `uuid_unparse_upper'
/usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions/libML64i3.a(mluuid.cpp.o): In function `MathLink::MLUUID::operator=(std::basic_string<char, std::char_traits<char>, MathLink::MLStdAllocator<char> > const&)':
mluuid.cpp:(.text+0xd4): undefined reference to `uuid_parse'
/usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions/libML64i3.a(mluuid.cpp.o): In function `MathLink::MLUUID::MLUUID(std::basic_string<char, std::char_traits<char>, MathLink::MLStdAllocator<char> > const&)':
mluuid.cpp:(.text+0x17b): undefined reference to `uuid_parse'
/usr/local/Wolfram/Mathematica/10.0/SystemFiles/Links/MathLink/DeveloperKit/Linux-x86-64/CompilerAdditions/libML64i3.a(mluuid.cpp.o): In function `MathLink::MLUUID::MLUUID()':
mluuid.cpp:(.text+0x227): undefined reference to `uuid_generate'
collect2: error: ld returned 1 exit status
make: *** [Pythonika] Error 1