[Date Prev] [Date Next] [Thread Prev] [Thread Next] Date Index Thread Index Search archive:
Date:Mon Jul 15 15:17:34 2002 
Subject:Re: Forwarded Re: Quick external problem? 
From:mhl 
Volume-ID:1020715.01 

Hi all,

I have managed to get external load to work for previous .so files. The 
.so file I'm trying to load now consists of the three C files compiled 
against other libraries. I was hoping that I was missing something 
obvious when trying to load.

Normally if there is an error in the .so file ie. headers don't match up 
  then it will specify which values/symbols it can't match. In the 
current example poplog fails to find any of the symbols, which is why I 
suspect it to be something to do with the way I'm loading the file??

One interesting point which I have just come across is if I have 
mismatched one of the headers in the poplog file to the header in the 
.so file. The first time I compile the poplog file it complains about 
all the symbols/values ie. it can't find any of the functions. The 
second time I compile the file (in the same pop session) it only 
complains about the mismatched header??

As a consequence I've noticed (with the mismatched header fixed) the 
file doesn't complain the second time I load??

I've included a sample of the error messages below...

The first time I compile (in Xemacs) I get something like,...

: ;;; Compiling buffer rti.p
;;; Warning: can't open shared object rti.so
;;; 	(Inappropriate ioctl for device)
;;; Error: can't find value for symbol getAttributeHandle
;;; Error: can't find value for symbol getAttributeName
;;; Error: can't find value for symbol getObjectClassName
;;; Error: can't find value for symbol getObjectClassHandle
;;; Error: can't find value for symbol enableTimeRegulation
;;; Error: can't find value for symbol 
attributeOwnershipAcquisitionIfAvailable
;;; Error: can't find value for symbol 
unconditionalAttributeOwnershipDivesture
;;; Error: can't find value for symbol requestObjectAttributeValueUpdate
;;; Error: can't find value for symbol requestClassAttributeValueUpdate
;;; Error: can't find value for symbol deleteObjectInstance
;;; Error: can't find value for symbol updateAttributeValues
;;; Error: can't find value for symbol registerObjectInstance
;;; Error: can't find value for symbol subscribeObjectClassAttributes
;;; Error: can't find value for symbol publishObjectClass
;;; Error: can't find value for symbol resignFederationExecution
;;; Error: can't find value for symbol joinFederationExecution
;;; Error: can't find value for symbol destroyFederationExecution
;;; Error: can't find value for symbol createFederationExecution

;;; MISHAP - ERRORS ACCESSING EXTERNAL SYMBOLS (see above)
;;; FILE     :  /tmp/emacsxaF_9t   LINE NUMBER:  432
;;; DOING    :  external_do_load exload_do_batch_load external 
pop_setpop_comp
;;; 	iler


The second time with one function renamed ('t' missing),...


: ;;; Compiling buffer rti.p
;;; Error: can't find value for symbol geAttributeHandle

;;; MISHAP - ERRORS ACCESSING EXTERNAL SYMBOLS (see above)
;;; FILE     :  /tmp/emacsxaFtFL   LINE NUMBER:  432
;;; DOING    :  external_do_load exload_do_batch_load external 
pop_setpop_compiler


If the 't' isn't missing then the second time I compile I get no errors? 
I've added a simple function into the .so file to test if the functions 
work after the second compile and they do work?!

However if I add a printf statement to this simple test function I get a 
stack error...

;;; MISHAP - ste: STACK EMPTY (missing argument? missing result?)
;;; DOING    :  new_pop_ext_call pop_setpop_compiler

I know I had 'printf' and 'cout' statements in my original simple 
example any ideas why it doesn't like them now?

Cheers

Mike





Aaron Sloman wrote:
> I have just noticed that the examples in REF external
> use "exload".
> 
> Have you tried that? Do those examples work?
> 
> Is your .so file produced from a C program?
> 
> Aaron


-- 
Mike

mhl@cs.nott.ac.uk
http://www.cs.nott.ac.uk/~mhl/