Python embedded - linking problem on Linux - trying again
Kim Petersen
kp at kyborg.dk
Mon Aug 12 09:50:26 EDT 2002
When creating an embedded python in an RM/Cobol-85 interpretor, i have
the following problem:
It seems that i have to link all the modules (the .so's) that i need
with the new dynamic link library, isn't it at all possible to make it
(the python embedded interpretor) just find the .so's like the regular
interpretor does?
Below is the snippet from the Makefile that i use to compile the new .so
CC=gcc -DLINUX -DHAVE_TERMIOS_H=0 \
-DDYNAMIC_LIBRARIES_SUPPORTED-DUSING_GCC
CFLAGS=-fPIC -rdynamic
LDFLAGS=-L/usr/lib/python1.5/config
COPTIMIZE=-w -O3 -m486 -fomit-frame-pointer -pipe
LIBS=-ldl -lpython1.5 -lm -lpthread -ltk
DLLS=/usr/lib/python1.5/lib-dynload/*.so
/usr/lib/python1.5/site-packages/_pgmodule.so
FILES=usrsub.c rmc85.c
CGI=/var/www/cgi-bin
/usr/bin/rmcobolso/pyrmc85.so: rmc85.c rmc85.h
@echo Making pyrmc85.so
@$(CC) -shared $(CFLAGS) $(LDFLAGS) \
$(COPTIMIZE) -D__NOUSR_SUB__ -o $@ rmc85.c $(DLLS) $(LIBS)
--
Med Venlig Hilsen / Regards
Kim Petersen - Kyborg A/S
IT - Innovationshuset
Havnepladsen 2
7100 Vejle
Tlf. +4576408183 || Fax. +4576408188
More information about the Python-list
mailing list