[Top][All Lists]

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

Re: "load" dynamic library example

From: Paul Smith
Subject: Re: "load" dynamic library example
Date: Tue, 07 Jan 2014 17:08:01 -0500

On Tue, 2014-01-07 at 21:52 +0100, Motiejus Jakštys wrote:

> I am trying to run a "load" example from manual[1] and get a failure:
> $ make-4.0/make
> Makefile:4: cannot open shared object file: No such file or 
> directory
> Makefile:4: *** failed to load.  Stop.
> However, if I compile manually and run, it works:
> $ gcc -shared -fPIC -o mk_temp.c -Imake-4.0
> $ make-4.0/make
> Temporary file: tmpfile.OpzU61
> Where can be the culprit? I am running Debian testing with a
> self-compiled Make. I expect make to compile the file before
> attempting to load it.

It would be very helpful if you provided your makefile; at least the
parts related to the shared object.  Without that it's hard to say
what's wrong.

One thing to be aware of is that there is no built-in rule in GNU make
that knows how to build a .so file, so unless you have defined a rule in
your makefile that shows how to build the file it won't be

To me it looks like either there is no such rule defined, or else for
some reason make is not considering the rule you did define.  Without
seeing your makefile I can't say.

reply via email to

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