diff --git a/lzo.changes b/lzo.changes index 8f859f0..73a7563 100644 --- a/lzo.changes +++ b/lzo.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sat Oct 30 19:05:43 UTC 2010 - cristian.rodriguez@opensuse.org + +- Use GCC visibility. + ------------------------------------------------------------------- Thu Feb 11 12:30:25 CET 2010 - rguenther@suse.de diff --git a/lzo.spec b/lzo.spec index 9b7a4fb..b3afffa 100644 --- a/lzo.spec +++ b/lzo.spec @@ -104,9 +104,18 @@ Authors: %prep %setup -q %patch1 - %build +export CFLAGS="%optflags -fvisibility=hidden" %configure --enable-shared --disable-static --libdir=/%{_lib} + +#On windows, the build system defines __LZO_EXPORT1 to +# __attribute__((dllexport))) which we can abuse to make +#use of GCC visibility. ;-) +#see http://gcc.gnu.org/wiki/Visibility +#If you remove this, you must disable -fvisibility=hidden in CFLAGS! + +echo '#define __LZO_EXPORT1 __attribute__ ((visibility ("default")))' >> config.h + %{__make} %{?_smp_mflags} %check