comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » About call_external, AUTO_GLUE and gcc
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
About call_external, AUTO_GLUE and gcc [message #39564] Fri, 28 May 2004 18:54 Go to previous message
profxtjb is currently offline  profxtjb
Messages: 22
Registered: October 2003
Junior Member
I have been working on call_external to some C stuff I have, and today
I was messing with the AUTO_GLUE keyword, but I need a small helping
hand to get it all to work gracefully for me.

Specifically, if I compile and link 'try_glue4.c', containing a
function IDL_INT try( IDL_INT *k), that for example returns *k + 30,
viz.

% gcc -fPIC -c try_glue4.c
% ld -bundle -t -o try_glue4.so try_glue4.o

I get a nice piece of work out of call_external, viz.

IDL> result = call_external('try_glue4.so', 'try', 22, /AUTO_GLUE,
/I_VALUE)
IDL> print,result
52

It all works sweet. Great.

However, if I go back and add some new computation to my function
'try' in the source file 'try_glue4.c' and then save and recompile and
relink to 'try_glue4.so', then the next time I call_external to
'try_glue4.so' there is a repeat of the initial function computation.
It does not use the new function computation.

OK, I can save the changed source file to 'try_glue5.c' and go through
the process with that new file. It seems like you should be able to
flip one of the option switches on gcc or ld so that you can work on
one source file. Or is it some feature of AUTO_GLUE that produces
this trouble.

It is a small matter, but it would sure speed up my work if I could
get this sorted out, learning a bit more about gcc along the way.

GRACIAS
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: Bug in ISHFT? (NOT)
Next Topic: CURVEFIT

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:15:05 PDT 2025

Total time taken to generate the page: 0.00491 seconds