Vivien Kraus wrote:
> I don’t know how to do it at the moment; the
> configure script automatically gets a --enable-shared=… flag but I
> can’t find a trace of it in config.log, and I don’t know how to use it.
> Could you elaborate on how to get a value for BUILDING_SHARED with
> autoconf?

A couple of lines in configure.ac should do it:

  if test "$enable_shared" = yes; then
    shared=1
  else
    shared=0
  fi
  AC_DEFINE_UNQUOTED([BUILDING_SHARED], [$shared], [Define when --enable-shared 
is used.])

> Also, if both shared and static libraries are compiled, does
> it mean that they should get compiled twice, with different compiler
> flags?

Libtool automatically arranges for the compilation units to be compiled
twice, in this case.

Bruno




Reply via email to