Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
a5809c29 by Steve Lhomme at 2022-09-22T10:21:22+02:00
contrib: flac: remove uneeded Android patch

USE_OBSOLETE_SIGCONTEXT_FLAVOR is not used since 1.3.1

https://github.com/xiph/flac/commit/6a28facd7cd70f7ad0c6bc37e3a661dbfd850b45

- - - - -
71bc0ae5 by Steve Lhomme at 2022-09-22T10:21:51+02:00
contrib: flac: build with CMake

It doesn't require forcing a CFLAG manually or using AUTORECONF.

- - - - -


2 changed files:

- − contrib/src/flac/dont-force-msvcrt-version.patch
- contrib/src/flac/rules.mak


Changes:

=====================================
contrib/src/flac/dont-force-msvcrt-version.patch deleted
=====================================
@@ -1,10 +0,0 @@
---- flac-orig/configure.ac     2019-08-26 11:13:17.604801738 -0400
-+++ flac/configure.ac  2019-08-26 11:13:46.624689160 -0400
-@@ -208,7 +208,6 @@
- os_is_windows=no
- case "$host" in
-       *mingw*)
--              CPPFLAGS="-D__MSVCRT_VERSION__=0x0601 $CPPFLAGS"
-               os_is_windows=yes
-               ;;
- esac


=====================================
contrib/src/flac/rules.mak
=====================================
@@ -20,48 +20,28 @@ ifdef HAVE_WINSTORE
        $(APPLY) $(SRC)/flac/remove_blocking_code_useless_flaclib.patch
        $(APPLY) $(SRC)/flac/no-createfilew.patch
 endif
-ifdef HAVE_DARWIN_OS
-       cd $(UNPACK_DIR) && sed -e 's,-dynamiclib,-dynamiclib -arch $(ARCH),' 
-i.orig configure
-endif
-ifdef HAVE_ANDROID
-ifeq ($(ANDROID_ABI), x86)
-       # cpu.c:130:29: error: sys/ucontext.h: No such file or directory
-       # defining USE_OBSOLETE_SIGCONTEXT_FLAVOR allows us to bypass that
-       cd $(UNPACK_DIR) && sed -i.orig -e s/"#  undef 
USE_OBSOLETE_SIGCONTEXT_FLAVOR"/"#define USE_OBSOLETE_SIGCONTEXT_FLAVOR"/g 
src/libFLAC/cpu.c
-endif
-endif
-       $(APPLY) $(SRC)/flac/dont-force-msvcrt-version.patch
+       # disable building a tool we don't use
+       cd $(UNPACK_DIR) && sed -e 
's,add_subdirectory("microbench"),#add_subdirectory("microbench"),' -i.orig 
CMakeLists.txt
        $(call pkg_static,"src/libFLAC/flac.pc.in")
-       $(UPDATE_AUTOCONFIG)
        $(MOVE)
 
-FLACCONF := \
-       --disable-examples \
-       --disable-thorough-tests \
-       --disable-doxygen-docs \
-       --disable-xmms-plugin \
-       --disable-cpplibs \
-       --disable-oggtest
-# TODO? --enable-sse
-ifdef HAVE_DARWIN_OS
-ifneq ($(findstring $(ARCH),i386 x86_64),)
-FLACCONF += --disable-asm-optimizations
-endif
-endif
+FLAC_CONF = \
+       -DBUILD_TESTING=OFF \
+       -DINSTALL_MANPAGES=OFF \
+       -DBUILD_CXXLIBS=OFF \
+       -DBUILD_EXAMPLES=OFF \
+       -DBUILD_PROGRAMS=OFF
 
-FLAC_CFLAGS := $(CFLAGS)
-ifdef HAVE_WIN32
-FLAC_CFLAGS += -mstackrealign
-FLAC_CFLAGS +="-DFLAC__NO_DLL"
+ifeq ($(ARCH),i386)
+# nasm doesn't like the -fstack-protector-strong that's added to its flags
+# let's prioritize the use of nasm over stack protection
+FLAC_CONF += -DWITH_STACK_PROTECTOR=OFF
 endif
 
 DEPS_flac = ogg $(DEPS_ogg)
 
-.flac: flac
-       cd $< && $(AUTORECONF)
-       $(MAKEBUILDDIR)
-       $(MAKECONFIGURE) CFLAGS="$(FLAC_CFLAGS)" $(FLACCONF)
-       $(MAKEBUILD) -C include install
-       $(MAKEBUILD) -C src/libFLAC install
-       $(MAKEBUILD) -C src/share install
+.flac: flac toolchain.cmake
+       $(CMAKECLEAN)
+       $(HOSTVARS_PIC) $(CMAKE) $(FLAC_CONF)
+       +$(CMAKEBUILD) --target install
        touch $@



View it on GitLab: 
https://code.videolan.org/videolan/vlc/-/compare/23c152d4705a8cec654df7100fcdf77bfacb6c24...71bc0ae5f7866dfacdd6b16b6c08a1321811a571

-- 
View it on GitLab: 
https://code.videolan.org/videolan/vlc/-/compare/23c152d4705a8cec654df7100fcdf77bfacb6c24...71bc0ae5f7866dfacdd6b16b6c08a1321811a571
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance
_______________________________________________
vlc-commits mailing list
vlc-commits@videolan.org
https://mailman.videolan.org/listinfo/vlc-commits

Reply via email to