Project Home
Project Home
Source Code
Source Code
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Linking against dynamic shared lib has dep on static lib: (4 Items)
   
Linking against dynamic shared lib has dep on static lib  
Hello:

I have a case where in trying to build the attached dummy project, it failed:

make[3]: *** No rule to make target `libm1Lib.a', needed by `/home/gmulongoy/tickets/90067/qnxMakeProblem/m1Prg/x86/o/
m1Prg'.  Stop.

I quickly remedied the situation by doing the following:
# rm -rf stage/
# cp -a m1Lib/x86/so m1Lib/x86/a
# make install

If a similar project is prepared using the IDE a file named .qnx_internal.mk is included which resolves the above.

My question is what is the correct way to link against a shared lib such that it doesn't generate the dep for the static

 library from the command line?


The dummy project is attached, do the following to repro:

cd to the qnxMakeProblem directory and type "make install".
Now you should see the Problem:
...make[3]: *** No rule to make target `libm1Lib.a', needed by...

Note: creating a dummy file also permits the build - "touch stage/x86/lib/libm1Lib.a"

Thanks,

Gervais

ps. It seems that defining the library to build in LIBS implies that there should be both variants so and a - which in 
this case wasn't required.
Attachment: Text qnxmakeproblem.tar.gz 821 bytes
Re: Linking against dynamic shared lib has dep on static lib  
bump.
Re: Linking against dynamic shared lib has dep on static lib  
This was added to track dependencies.  There is already a PR complaining about the fact that you have to install both
static and shared versions to silence make.

http://przilla.ott.qnx.com/bugzilla/show_bug.cgi?id=58417

Gervais Mulongoy wrote:
> Hello:
> 
> I have a case where in trying to build the attached dummy project, it failed:
> 
> make[3]: *** No rule to make target `libm1Lib.a', needed by `/home/gmulongoy/tickets/90067/qnxMakeProblem/m1Prg/x86/o/

> m1Prg'.  Stop.
> 
> I quickly remedied the situation by doing the following:
> # rm -rf stage/
> # cp -a m1Lib/x86/so m1Lib/x86/a
> # make install
> 
> If a similar project is prepared using the IDE a file named .qnx_internal.mk is included which resolves the above.
> 
> My question is what is the correct way to link against a shared lib such that it doesn't generate the dep for the 
static
>  library from the command line?
> 
> 
> The dummy project is attached, do the following to repro:
> 
> cd to the qnxMakeProblem directory and type "make install".
> Now you should see the Problem:
> ...make[3]: *** No rule to make target `libm1Lib.a', needed by...
> 
> Note: creating a dummy file also permits the build - "touch stage/x86/lib/libm1Lib.a"
> 
> Thanks,
> 
> Gervais
> 
> ps. It seems that defining the library to build in LIBS implies that there should be both variants so and a - which in
 this case wasn't required.
> 
> 
> 
> 
> _______________________________________________
> 
> General
> http://community.qnx.com/sf/go/post41575

-- 
cburgess@qnx.com
RE: Linking against dynamic shared lib has dep on static lib  
I didn't know about the PR, Thanks Colin.

-----Original Message-----
From: Colin Burgess [mailto:community-noreply@qnx.com] 
Sent: November 16, 2009 4:43 PM
To: general-toolchain
Subject: Re: Linking against dynamic shared lib has dep on static lib

This was added to track dependencies.  There is already a PR complaining
about the fact that you have to install both static and shared versions
to silence make.

http://przilla.ott.qnx.com/bugzilla/show_bug.cgi?id=58417

Gervais Mulongoy wrote:
> Hello:
> 
> I have a case where in trying to build the attached dummy project, it
failed:
> 
> make[3]: *** No rule to make target `libm1Lib.a', needed by 
> `/home/gmulongoy/tickets/90067/qnxMakeProblem/m1Prg/x86/o/
> m1Prg'.  Stop.
> 
> I quickly remedied the situation by doing the following:
> # rm -rf stage/
> # cp -a m1Lib/x86/so m1Lib/x86/a
> # make install
> 
> If a similar project is prepared using the IDE a file named
.qnx_internal.mk is included which resolves the above.
> 
> My question is what is the correct way to link against a shared lib 
> such that it doesn't generate the dep for the static  library from the
command line?
> 
> 
> The dummy project is attached, do the following to repro:
> 
> cd to the qnxMakeProblem directory and type "make install".
> Now you should see the Problem:
> ...make[3]: *** No rule to make target `libm1Lib.a', needed by...
> 
> Note: creating a dummy file also permits the build - "touch
stage/x86/lib/libm1Lib.a"
> 
> Thanks,
> 
> Gervais
> 
> ps. It seems that defining the library to build in LIBS implies that
there should be both variants so and a - which in this case wasn't
required.
> 
> 
> 
> 
> _______________________________________________
> 
> General
> http://community.qnx.com/sf/go/post41575

--
cburgess@qnx.com



_______________________________________________

General
http://community.qnx.com/sf/go/post42048