On Thursday 05 August 2004 08:15, James Yonan wrote: > Matthias Andree <matthias.and...@gmx.de> said: > > > On Wed, 04 Aug 2004, Tomasz Chmielewski wrote: > > > > > I was thinking of an option like ./configure --compile-statically - and > > > with such compiled binary, I wouldn't have to install compilers, compile > > > OpenVPN, deinstall compilers on every machine I want it to run. > > > > My first attempt would probably be ./configure CC="gcc -static" - it's > > untested and may require the installation of static libraries on some > > systems. > > I've had success with 'gcc -static' when static libraries are present, as they > are by default on Gentoo Linux. > > James > I compiled it statically on FC3t1 with this change in the openvpn.spec file: --- cut --- %configure \ --enable-lzo \ --enable-crypto \ --enable-ssl \ --enable-pthread \ --enable-iproute2 \ --enable-strict \ --disable-profiling \ --enable-mtu-dynamic \ --enable-strict-options \ --disable-dependency-tracking
# <Hack_for_static_build> perl -i -p -e 's/^LDADD =/LDADD = -static -lssl -lcrypto -lkrb5 -lk5crypto -lresolv -lcom_err/' Makef ile # </Hack_for_static_build> %{__make} %{?_smp_mflags} --- cut --- It worked (openvpn --test-crypto --secret mysecret) on FC3t1, FC2, FC1 and Mandrake 8.2. -- Regards, Doncho N. Gunchev Registered Linux User #291323 at counter.li.org GPG-Key-ID: 1024D/DA454F79 http://pgp.mit.edu Key fingerprint = 684F 688B C508 C609 0371 5E0F A089 CB15 DA45 4F79