Name: libpng
-Version: 1.6.13
-Release: 1
-License: Zlib
+Version: 1.6.40
+Release: 0
+License: Libpng
Summary: A library of functions for manipulating PNG image format files
-Url: http://www.libpng.org/pub/png/
+Url: http://www.libpng.org/pub/png/libpng.html
Group: System/Libraries
Source: %{name}-%{version}.tar.bz2
Source1001: libpng.manifest
+
+BuildRequires: cmake
BuildRequires: zlib-devel
%description
%package devel
Summary: Development tools for programs to manipulate PNG image format files
Group: Development/Libraries
-Requires: %{name} = %{version}
+Requires: %{name} = %{version}-%{release}
Requires: zlib-devel
%description devel
cp %{SOURCE1001} .
%build
-
-%configure \
- --disable-static \
-%ifarch %arm armv7l armv7el aarch64
- --enable-arm-neon=check
+%ifarch %{arm}
+CFLAGS+=" -D_ARCH_ARM_ -mfpu=neon"
%endif
+%cmake . -DPNG_STATIC=OFF \
+ -DSKIP_INSTALL_PROGRAMS=ON \
+ -DSKIP_INSTALL_EXPORT=ON \
+%ifarch %{arm}
+ -DPNG_ARM_NEON=on \
+%else
+ -DPNG_ARM_NEON=off \
+%endif
+ %{?ubsan: -DPNG_ARM_NEON=off}
-make %{?_smp_mflags}
+make %{?jobs:-j%jobs}
%install
%make_install