Accepting request 180468 from home:elvigia:branches:graphics

- Build with LFS_CFLAGS in 32 bit archs otherwise calls such 
 as png_image_begin_read_from_file() or png_image_write_to_file()
 will fail to read/write huge images.
- Build with Full RELRO as this library is a possible consumer
  of malicuous images/files.

OBS-URL: https://build.opensuse.org/request/show/180468
OBS-URL: https://build.opensuse.org/package/show/graphics/libpng16?expand=0&rev=29
This commit is contained in:
Dr. Werner Fink 2013-06-22 21:47:51 +00:00 committed by Git OBS Bridge
parent 5f57c77f76
commit a1dab95854
2 changed files with 15 additions and 8 deletions

View File

@ -1,3 +1,13 @@
-------------------------------------------------------------------
Fri Jun 21 18:36:31 UTC 2013 - crrodriguez@opensuse.org
- Build with LFS_CFLAGS in 32 bit archs otherwise calls such
as png_image_begin_read_from_file() or png_image_write_to_file()
will fail to read/write huge images.
- Build with Full RELRO as this library is a possible consumer
of malicuous images/files.
-------------------------------------------------------------------
Fri Apr 26 07:15:01 UTC 2013 - pgajdos@suse.com

View File

@ -98,16 +98,13 @@ about libpng version.
%setup -n libpng-%{version}
%build
# We'll never use the old pgcc-2.95.1 with the buggy -O3, so having
# the -O3 that is originally used should work.
# Substitute the -O2 to -O3 because I'm not sure if simply appending
# it will preserve(not override) the detailed opt flags used in RPM_OPT_FLAGS:
CFLAGS="`echo $RPM_OPT_FLAGS|sed 's/-O2/-O3/'` -DPNG_SKIP_SETJMP_CHECK" \
./configure --prefix=/usr \
--libdir=%{_libdir} \
--mandir=%{_mandir} \
export CFLAGS="%optflags -O3 -DPNG_SKIP_SETJMP_CHECK $(getconf LFS_CFLAGS)"
export LDFLAGS="-Wl,-z,relro,-z,now"
%configure \
--disable-static \
--with-libpng-compat=no
make %{?_smp_mflags}
%check
make check