Colin McCormack wrote:
>
> Hi,
>
> Might I suggest you add the following line to Configure:
>
> "linux-dynamic", "gcc:-fPIC -DL_ENDIAN -DTERMIO -O3 -fomit-frame-pointer -m486
> -Wall -Wuninitialized::BN_LLONG $x86_gcc_des $x86_gcc_opts:$x86_elf_asm",
>
> and the attached file to the distribution. Then it should be fairly easy to
> generate .so files for linux.
>
> Note: I did the mkshared stuff by hand, so I haven't strictly tested it.
>
> Colin.
>
The point here is, that integrating building .so libraries into
configure
and Makefiles asks for more variables. And for make test there is the
need to install those shared libraries before the binaries will execute,
which will also need re-engineering some of the Makefile logic.
When the discussion about the autoconf / config / configure / make
depend
has lead to some conclusion about where to go, integrating .so will
probably be next.
In the meantime there are several ways to build shared libraries:
- libtool : easy and painless, but not available on all platforms
- mkshared.sh : uses hard-coded compile flags, which should be avoided
- a 'shared' target in the main Makefile (my favourite)
I am using the last method myself. In case someone wants to go this
way, I'll post it again. It relies on gnu ld.
Note that 'make clean' before and after compiling this '-fPIC' is
issued to ensure that the regular .a libraries are not compiled
with -fPIC.
MAJOR = 0
MINOR = 9.1
shared:
@for i in crypto ssl; do \
rm -f lib$$i.a lib$$i.so \
lib$$i.so.${MAJOR} lib$$i.so.${MAJOR}.${MINOR}; \
${MAKE} CFLAG='-fPIC ${CFLAG}' DIRS=$$i clean all || exit 1; \
${LD} \
-shared -o lib$$i.so.${MAJOR}.${MINOR} \
-soname lib$$i.so.${MAJOR} \
--whole-archive lib$$i.a || exit 1; \
rm -f lib$$i.a; make -C $$i clean || exit 1 ;\
done;
@set -x; \
for i in crypto ssl; do \
ln -s lib$$i.so.${MAJOR}.${MINOR} lib$$i.so.${MAJOR}; \
ln -s lib$$i.so.${MAJOR} lib$$i.so; \
done;
--
Niels Poppe - org.net bv <[EMAIL PROTECTED]>
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]