[vlc-commits] [Git][videolan/vlc][master] 2 commits: contrib: png: build with CMake

Jean-Baptiste Kempf (@jbk) gitlab at videolan.org
Fri Oct 7 08:30:35 UTC 2022



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
319339db by Steve Lhomme at 2022-10-07T07:48:24+00:00
contrib: png: build with CMake

And don't depend on an outdated automake 1.11 version.

- - - - -
20bdf55c by Steve Lhomme at 2022-10-07T07:48:24+00:00
contrib: png: update to 1.6.38

* Added configurations and scripts for continuous integration.
* Fixed various errors in the handling of tRNS, hIST and eXIf.
* Implemented many stability improvements across all platforms.
* Updated the internal documentation.

- - - - -


5 changed files:

- contrib/src/png/SHA512SUMS
- − contrib/src/png/automake.patch
- − contrib/src/png/bins.patch
- contrib/src/png/rules.mak
- − contrib/src/png/winrt.patch


Changes:

=====================================
contrib/src/png/SHA512SUMS
=====================================
@@ -1 +1 @@
-59e8c1059013497ae616a14c3abbe239322d3873c6ded0912403fc62fb260561768230b6ab997e2cccc3b868c09f539fd13635616b9fa0dd6279a3f63ec7e074  libpng-1.6.37.tar.xz
+4e450636062fcc75ecc65715e0b23ddc1097b73b4c95ffd31bef627144c576f58660b2130105f5f5781212cf54f00c7b6dd3facefd7e9de70c76b981d499f81e  libpng-1.6.38.tar.xz


=====================================
contrib/src/png/automake.patch deleted
=====================================
@@ -1,11 +0,0 @@
---- libpng-1.6.8/configure.ac.orig	2014-02-08 15:42:46.399091835 +0100
-+++ libpng-1.6.8/configure.ac	2014-02-08 15:47:42.684534041 +0100
-@@ -27,7 +27,7 @@
- # dist-xz requires automake 1.11 or later
- # 1.12.2 fixes a security issue in 1.11.2 and 1.12.1
- # 1.13 is required for parallel tests
--AM_INIT_AUTOMAKE([1.13 foreign dist-xz color-tests silent-rules subdir-objects])
-+AM_INIT_AUTOMAKE([1.11 foreign dist-xz color-tests silent-rules subdir-objects])
- # The following line causes --disable-maintainer-mode to be the default to
- # configure, this is necessary because libpng distributions cannot rely on the
- # time stamps of the autotools generated files being correct


=====================================
contrib/src/png/bins.patch deleted
=====================================
@@ -1,18 +0,0 @@
---- libpng-1.6.29/Makefile.am.orig	2017-04-08 12:12:49.688261183 +0200
-+++ libpng-1.6.29/Makefile.am	2017-04-08 12:13:27.148259514 +0200
-@@ -12,13 +12,13 @@
- ACLOCAL_AMFLAGS = -I scripts
- 
- # test programs - run on make check, make distcheck
--check_PROGRAMS= pngtest pngunknown pngstest pngvalid pngimage pngcp
-+check_PROGRAMS=
- if HAVE_CLOCK_GETTIME
- check_PROGRAMS += timepng
- endif
- 
- # Utilities - installed
--bin_PROGRAMS= pngfix png-fix-itxt
-+bin_PROGRAMS=
- 
- # This ensures that pnglibconf.h gets built at the start of 'make all' or
- # 'make check', but it does not add dependencies to the individual programs,


=====================================
contrib/src/png/rules.mak
=====================================
@@ -1,5 +1,5 @@
 # PNG
-PNG_VERSION := 1.6.37
+PNG_VERSION := 1.6.38
 PNG_URL := $(SF)/libpng/libpng16/$(PNG_VERSION)/libpng-$(PNG_VERSION).tar.xz
 
 PKGS += png
@@ -14,18 +14,31 @@ $(TARBALLS)/libpng-$(PNG_VERSION).tar.xz:
 
 png: libpng-$(PNG_VERSION).tar.xz .sum-png
 	$(UNPACK)
-	$(APPLY) $(SRC)/png/winrt.patch
-	$(APPLY) $(SRC)/png/bins.patch
-	$(APPLY) $(SRC)/png/automake.patch
+	sed -i.orig 's,set(CMAKE_DEBUG_POSTFIX ,#set(CMAKE_DEBUG_POSTFIX ,' "$(UNPACK_DIR)/CMakeLists.txt"
 	$(call pkg_static,"libpng.pc.in")
 	$(MOVE)
 
 DEPS_png = zlib $(DEPS_zlib)
 
-.png: png
-	$(RECONF)
-	$(MAKEBUILDDIR)
-	$(MAKECONFIGURE)
-	+$(MAKEBUILD)
-	+$(MAKEBUILD) install
+PNG_CONF := -DPNG_SHARED=OFF -DPNG_TESTS=OFF -DPNG_EXECUTABLES=OFF
+
+ifdef HAVE_CLANG
+ifneq ($(filter arm aarch64, $(ARCH)),)
+# TODO this might be set globally and for all targets where intrinsincs are used
+PNG_CONF += -DCMAKE_ASM_FLAGS="$(CFLAGS)"
+endif
+endif
+
+ifdef HAVE_IOS
+ifeq ($(ARCH),arm)
+# otherwise detection fails
+PNG_CONF += -DPNG_ARM_NEON=on
+endif
+endif
+
+.png: png toolchain.cmake
+	$(CMAKECLEAN)
+	$(HOSTVARS_PIC) $(CMAKE) $(PNG_CONF)
+	+$(CMAKEBUILD)
+	+$(CMAKEBUILD) --target install
 	touch $@


=====================================
contrib/src/png/winrt.patch deleted
=====================================
@@ -1,14 +0,0 @@
---- png/pngpriv.h.orig	2013-05-09 15:17:34.933583625 +0200
-+++ png/pngpriv.h	2013-05-09 15:18:33.981581142 +0200
-@@ -360,11 +360,7 @@
- 
- /* Memory model/platform independent fns */
- #ifndef PNG_ABORT
--#  ifdef _WINDOWS_
--#    define PNG_ABORT() ExitProcess(0)
--#  else
- #    define PNG_ABORT() abort()
--#  endif
- #endif
- 
- #ifdef USE_FAR_KEYWORD



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/8f8891ed7f22ed061854c022bdb612853d9924e6...20bdf55cb5a5903b2c3bc032bf646e3f0b903a64

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/8f8891ed7f22ed061854c022bdb612853d9924e6...20bdf55cb5a5903b2c3bc032bf646e3f0b903a64
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list