gnucap-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnucap-devel] New gnucap development snapshot


From: al davis
Subject: Re: [Gnucap-devel] New gnucap development snapshot
Date: Thu, 7 Dec 2006 00:16:15 -0500
User-agent: KMail/1.9.5

On Wednesday 06 December 2006 23:46, Dan McMahill wrote:
> Also, I need to figure out what the right thing is for
> -rdynamic with that compiler.  But since we don't get that
> far it doesn't matter yet.

You may not need it.  It may be on by default.  I am sure that 
if it is needed, something like it is provided.

What it does is to export symbols to dynamic libraries loaded by 
dlopen.  If you don't do it, attaching a model with dlopen 
(attach command) will fail.

The way you find out if itis needed is as follows:

Remove a file that could be a plugin from the makefile.  Let's 
pick a simple one, how about the switch .. Remove d_switch.cc 
from the Makefile.  Relink.  The link should succeed, but the 
switch component is no longer supported.  If you try to access 
it you will get an error message.

Maybe an easier one to leave out might be "bm_pwl.cc" .. That is 
the PWL source that Spice has had forever.  The same ideas 
apply.  If you leave out the resistor, you might find that 
something else depends on it, so the resistor probably isn't a 
good choice.

Compile that file into a .so file ...

With gcc the command would be "g++ -fPIC -shared d_switch.cc".

Since I didn't name the output file, it will be called "a.out".

Now run the simulator.  Give the command "attach a.out".

The switch should work now.

If something is wrong, the attach will fail, hopefully with a 
useful message.

For another compiler, the procedure for compiling shared objects 
also needs to be determined.  This will become an important 
feature in the future.

For systems that can't deal with dynamic libraries, I suppose 
all the models could be compiled in as they are now.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]