Tcl/Tk

Ljung Magnus etxmljg@REDACTED
Mon Mar 27 11:27:36 CEST 2000


Hi!

I want to add an Erlang programming language interface to a Tcl/Tk
application. I'm using the erl_interface to C with the libraries libei.a
and liberl_interface.a. Compiling and inking a stand-alone application
C-Erlang works. When compiling a loadable package to Tcl/Tk adding a Tcl
command using one of the Erlang C library function something goes wrong.
Loading the shared library in tclsh I get the error:  relocation error:
file /home/etxmljg/application/app.o: symbol erl_init_nothreads:
referenced symbol not found

I guess this means that the runtime linker cant find the function in the
Erlang library. The result is the same for PTHREADS and STHREADS as
well. Is there any environment variable that I have missed or does it
depend on how the Erlang libraries have been compiled?

Compiler flags used:
gcc -O2 -shared -fPIC -R/EDUP/Otp/0/lib/erl_interface-3.2/lib
-I/EDUP/Tcl/0/include/ -L/EDUP/Tcl/0/lib
-I/EDUP/Otp/0/lib/erl_interface-3.2/include
-L/EDUP/Otp/0/lib/erl_interface-3.2/lib  \
 -lerl_interface -lei -lm -ltcl app.c -o app.so

Regards // Magnus




More information about the erlang-questions mailing list