Gervais Mulongoy
|
Linking against dynamic shared lib has dep on static lib
|
Gervais Mulongoy
11/06/2009 5:08 PM
post41575
|
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.
|
|
|