Author Topic: static lib naming - Why is prefixed with "lib" the name I give?  (Read 6939 times)

*ptr

  • Guest
static lib naming - Why is prefixed with "lib" the name I give?
« on: September 29, 2005, 07:36:17 am »
Hi.

Can somebody help me? Please. When I try to make a static lib project on linux (debian/ubuntu/fedora), and I specify
the output file name like dbg/smplfsys.a, and tell to C::B that is a static lib, why after compilation he makes:
ar -r dbg/libsmplfsys.a .objs/full/smplfsys.o
after that try to run ranlib in a normal way like:
   ranlib dbg/smplfsys.a
Of course, I get the following error.
ranlib: 'dbg/smplfsys.a': No such file

If can somebody tell me how to tell the linker from C::B to make my lib with the name that I specify
in the "output filename" field

Many Thanx Beforehand
*ptr

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4315
    • Code::Blocks IDE
Re: static lib naming - Why is prefixed with "lib" the name I give?
« Reply #1 on: September 29, 2005, 08:46:20 am »
Go to Settings->Compiler->Other and see what's the build method. Direct or make?
Be patient!
This bug will be fixed soon...

*ptr

  • Guest
Re: static lib naming - Why is prefixed with "lib" the name I give?
« Reply #2 on: September 29, 2005, 08:59:53 am »
Thanks for suggestions Yiannis.
But I need to invoke the compiler directly. (I work on a project that converts some makefiles to C::B prj files).

But meanwhile I found under the Advanced Compiler Settings, under the others tab, have a field named:
Library prefix (e.g. lib):
which was set to "lib". I remove the specified string, and now I can build my lib correctly.

It's my fault, I guess C::B have a lots of goodies inside, just to know how to work with these.....

Anyway, C::B is the BEST IDE!!!

Thanx again