public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: lrtaylor@micron.com
To: <kalinabears@iinet.net.au>
Cc: <gcc-help@gcc.gnu.org>
Subject: RE: Convert dynamic lib to static lib
Date: Fri, 15 Oct 2004 23:05:00 -0000	[thread overview]
Message-ID: <363801FFD7B74240A329CEC3F7FE4CC4030963B1@ntxboimbx07.micron.com> (raw)

Since the .o files are in the static libraries, that makes me think that
you're not linking to them correctly, or that behind the scenes, the
Perl module's Makefiles are still causing it to link to the shared DLLs.
That is, it may not be a problem with your libraries, but the way that
the PGPlot Makefiles are configured.  I guess that my point is that
maybe you need to consider changing directions and take a look at that
possibility before you spend too much time trying to rebuild your
libraries...

Thanks,
Lyle


-----Original Message-----
From: gcc-help-owner@gcc.gnu.org [mailto:gcc-help-owner@gcc.gnu.org] On
Behalf Of Sisyphus
Sent: Friday, October 15, 2004 4:51 PM
Cc: gcc
Subject: Re: Convert dynamic lib to static lib

Eljay Love-Jensen wrote:
> Hi Rob,
> 
> I don't know of any way to make a dynamically linked library (.dll or 
> .so) into a statically linked archive library (.lib or .a).
> 
> I believe you'll have to recompile the source of the two .dll's (or at

> minimum, ar together the .o files - presuming there's no DLL 
> instrumentation that happens to the object files at compile time) as
an 
> archive library instead of a shared library.
>

I found that I could extract the object files from the 2 '.a' files 
(with 'ar x') and then re-archive those object files with 'ar rc' ... 
but that just gets me back to where I started, and the dll's are still 
needed at runtime.

I'll have a crack at building a static library from source.

Thanks Eljay.

The folowing is superfluous and waaaay OT, but if anyone wants to offer 
some thoughts, they're welcome.

The project is to get the perl module 'PGPLOT-2.18' built. It actually 
compiles fine, but when I come to use it, I immediately get the fatal 
error that a particular "procedure entry point" in the pgplot.dll could 
not be found. I thought that if I could build the perl module against a 
static build of pgplot then, if the problem did not go away, it might 
present itself as something I knew how to deal with .... for I have 
absolutely no idea of how to deal with this current manifestation :-)

When I build C apps against this pgplot shared library, there is 
absolutely no problem .... so it's something in the PGPLOT-2.18 perl 
source that's triggering the problem. I've spent hours hacking at the 
source, trying to locate a cause for the error, but it still eludes me.

 From what I can gather, the complaint that the "procedure entry point 
for foo could not be found" is just telling me that the "foo" function 
aint in the dll, but it was expected to be there. But this particular 
"foo" isn't even mentioned in the perl module source.

I've tried contacting both the author of the perl module and the builder

of the pgplot shared library - but neither has replied (as is their
right).

So near and yet so far ....

Cheers,
Rob

             reply	other threads:[~2004-10-15 23:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-10-15 23:05 lrtaylor [this message]
2004-10-16  1:18 ` Sisyphus
  -- strict thread matches above, loose matches on Subject: below --
2004-10-15  9:31 Sisyphus
2004-10-15 11:17 ` Eljay Love-Jensen
2004-10-15 22:56   ` Sisyphus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=363801FFD7B74240A329CEC3F7FE4CC4030963B1@ntxboimbx07.micron.com \
    --to=lrtaylor@micron.com \
    --cc=gcc-help@gcc.gnu.org \
    --cc=kalinabears@iinet.net.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).