diff options
Diffstat (limited to 'contrib')
27 files changed, 344 insertions, 10 deletions
diff --git a/contrib/ffmpeg/module.defs b/contrib/ffmpeg/module.defs index b63fb512a..ebddcf19a 100644 --- a/contrib/ffmpeg/module.defs +++ b/contrib/ffmpeg/module.defs @@ -97,6 +97,10 @@ ifeq (darwin,$(HOST.system)) else ifeq (arm64,$(HOST.arch)) FFMPEG.CONFIGURE.extra += --arch=arm64 endif + + ifeq (1,$(HOST.cross)) + FFMPEG.CONFIGURE.extra += --enable-cross-compile + endif endif ## check against tuple: B-SYSTEM where B is { 0 | 1 } for cross-compiling flag diff --git a/contrib/freetype/P02-darwin-applesi-cross.patch b/contrib/freetype/P02-darwin-applesi-cross.patch new file mode 100644 index 000000000..127a3aefa --- /dev/null +++ b/contrib/freetype/P02-darwin-applesi-cross.patch @@ -0,0 +1,13 @@ +diff --git a/builds/unix/config.sub b/builds/unix/config.sub +index 5b158ac..99917b9 100755 +--- a/builds/unix/config.sub ++++ b/builds/unix/config.sub +@@ -1159,7 +1159,7 @@ case $cpu-$vendor in + case $cpu in + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | abacus \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] \ diff --git a/contrib/fribidi/module.defs b/contrib/fribidi/module.defs index 49e8c4298..63316a689 100644 --- a/contrib/fribidi/module.defs +++ b/contrib/fribidi/module.defs @@ -8,3 +8,10 @@ FRIBIDI.FETCH.basename = fribidi-1.0.7.tar.gz FRIBIDI.CONFIGURE.bootstrap = rm -fr aclocal.m4 autom4te.cache configure; autoreconf -I m4 -fiv; +ifeq ($(HOST.system),darwin) + FRIBIDI.CONFIGURE.extra = CFLAGS_FOR_BUILD="-arch $(BUILD.machine)" + ifneq ($(HOST.machine),$(BUILD.machine)) + FRIBIDI.CONFIGURE.args.host = --host=$(HOST.machine:arm64=aarch64)-$(HOST.vendor)-$(HOST.system) + FRIBIDI.CONFIGURE.args.build = --build=$(BUILD.machine:arm64=aarch64)-$(BUILD.vendor)-$(BUILD.system) + endif +endif diff --git a/contrib/harfbuzz/P00-darwin-applesi-cross.patch b/contrib/harfbuzz/P00-darwin-applesi-cross.patch new file mode 100644 index 000000000..2656bab05 --- /dev/null +++ b/contrib/harfbuzz/P00-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index 20f7cf2..9c52d5b 100755 +--- a/config.sub ++++ b/config.sub +@@ -264,7 +264,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -393,7 +393,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/harfbuzz/module.defs b/contrib/harfbuzz/module.defs index 5d5778a3e..c94353cf2 100644 --- a/contrib/harfbuzz/module.defs +++ b/contrib/harfbuzz/module.defs @@ -36,6 +36,8 @@ ifeq (1,$(HOST.cross)) -DHB_HAVE_GRAPHITE2=OFF \ -DHB_HAVE_ICU=OFF \ -DHB_HAVE_UNISCRIBE=OFF + else ifeq ($(HOST.system),darwin) + HARFBUZZ.CONFIGURE.args.host = -DCMAKE_HOST_SYSTEM="$(HARFBUZZ.CONFIGURE.host)" else HARFBUZZ.CONFIGURE.args.host = -DCMAKE_SYSTEM_NAME="$(HARFBUZZ.CONFIGURE.host)" endif diff --git a/contrib/jansson/module.defs b/contrib/jansson/module.defs index 6661c6081..0db9d4524 100644 --- a/contrib/jansson/module.defs +++ b/contrib/jansson/module.defs @@ -6,3 +6,10 @@ JANSSON.FETCH.url += http://www.digip.org/jansson/releases/jansson-2.12.tar.b JANSSON.FETCH.sha256 = 645d72cc5dbebd4df608d33988e55aa42a7661039e19a379fcbe5c79d1aee1d2 JANSSON.CONFIGURE.bootstrap = rm -fr aclocal.m4 autom4te.cache; mkdir m4; autoreconf -fiv; + +ifeq (darwin,$(HOST.system)) + ifneq ($(HOST.machine),$(BUILD.machine)) + JANSSON.CONFIGURE.args.host = --host=$(HOST.machine:arm64=aarch64)-$(HOST.vendor)-$(HOST.system) + JANSSON.CONFIGURE.args.build = --build=$(BUILD.machine:arm64=aarch64)-$(BUILD.vendor)-$(BUILD.system) + endif +endif diff --git a/contrib/lame/P00-darwin-applesi-cross.patch b/contrib/lame/P00-darwin-applesi-cross.patch new file mode 100644 index 000000000..d227c4166 --- /dev/null +++ b/contrib/lame/P00-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index 3580aaf..4a81e12 100755 +--- a/config.sub ++++ b/config.sub +@@ -248,7 +248,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -370,7 +370,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | amd64-* | arc-* | arceb-* \ diff --git a/contrib/libass/P01-darwin-applesi-cross.patch b/contrib/libass/P01-darwin-applesi-cross.patch new file mode 100644 index 000000000..238105196 --- /dev/null +++ b/contrib/libass/P01-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index 7ffe373..49e3909 100755 +--- a/config.sub ++++ b/config.sub +@@ -248,7 +248,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -370,7 +370,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/libbluray/P04-darwin-applesi-cross.patch b/contrib/libbluray/P04-darwin-applesi-cross.patch new file mode 100644 index 000000000..05523293d --- /dev/null +++ b/contrib/libbluray/P04-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/build-aux/config.sub b/build-aux/config.sub +index 1d8e98b..7adaaee 100755 +--- a/build-aux/config.sub ++++ b/build-aux/config.sub +@@ -244,7 +244,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -368,7 +368,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/libdav1d/P02-darwin-cross-file.patch b/contrib/libdav1d/P02-darwin-cross-file.patch new file mode 100644 index 000000000..00c3f6dc2 --- /dev/null +++ b/contrib/libdav1d/P02-darwin-cross-file.patch @@ -0,0 +1,17 @@ +diff --git a/x86_64-darwin-gcc.meson b/x86_64-darwin-gcc.meson +new file mode 100644 +index 0000000..2ddbe93 +--- /dev/null ++++ b/x86_64-darwin-gcc.meson +@@ -0,0 +1,9 @@ ++[binaries] ++c = 'clang' ++cpp = 'clang++' ++[host_machine] ++system = 'darwin' ++cpu_family = 'x86_64' ++cpu = 'x86_64' ++endian = 'little' ++ +-- +2.24.2 (Apple Git-127) diff --git a/contrib/libdav1d/module.defs b/contrib/libdav1d/module.defs index c296c836c..8f5a435f8 100644 --- a/contrib/libdav1d/module.defs +++ b/contrib/libdav1d/module.defs @@ -33,6 +33,10 @@ ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) LIBDAV1D.CONFIGURE.extra += --cross-file=$(call fn.ABSOLUTE,$(LIBDAV1D.EXTRACT.dir/))/arm64-darwin-gcc.meson -Dc_args="-arch arm64" endif +ifeq (x86_64-darwin,$(HOST.machine)-$(HOST.system)) + LIBDAV1D.CONFIGURE.extra += --cross-file=$(call fn.ABSOLUTE,$(LIBDAV1D.EXTRACT.dir/))/x86_64-darwin-gcc.meson -Dc_args="-arch x86_64" +endif + ifeq (1-mingw,$(HOST.cross)-$(HOST.system)) LIBDAV1D.CONFIGURE.extra += --cross-file=$(call fn.ABSOLUTE,$(LIBDAV1D.EXTRACT.dir/))$(HOST.machine)-w64-mingw32.meson endif diff --git a/contrib/libdvdnav/P01-darwin-applesi-cross.patch b/contrib/libdvdnav/P01-darwin-applesi-cross.patch new file mode 100644 index 000000000..5b1295c1f --- /dev/null +++ b/contrib/libdvdnav/P01-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index 1d8e98b..7adaaee 100755 +--- a/config.sub ++++ b/config.sub +@@ -244,7 +244,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -368,7 +368,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/libdvdread/P01-darwin-applesi-cross.patch b/contrib/libdvdread/P01-darwin-applesi-cross.patch new file mode 100644 index 000000000..5b1295c1f --- /dev/null +++ b/contrib/libdvdread/P01-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index 1d8e98b..7adaaee 100755 +--- a/config.sub ++++ b/config.sub +@@ -244,7 +244,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -368,7 +368,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/libjpeg-turbo/P00-darwin-applesi-cross.patch b/contrib/libjpeg-turbo/P00-darwin-applesi-cross.patch new file mode 100644 index 000000000..229d264e4 --- /dev/null +++ b/contrib/libjpeg-turbo/P00-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 4e2d5bd..fecd54a 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -4,6 +4,9 @@ if(CMAKE_EXECUTABLE_SUFFIX) + set(CMAKE_EXECUTABLE_SUFFIX_TMP ${CMAKE_EXECUTABLE_SUFFIX}) + endif() + ++# Something overwrite CMAKE_SYSTEM_PROCESSOR is we try to read it later ++string(TOLOWER ${CMAKE_SYSTEM_PROCESSOR} CMAKE_SYSTEM_PROCESSOR_LC) ++ + project(libjpeg-turbo C) + set(VERSION 2.0.4) + string(REPLACE "." ";" VERSION_TRIPLET ${VERSION}) +@@ -40,7 +43,6 @@ message(STATUS "VERSION = ${VERSION}, BUILD = ${BUILD}") + + # Detect CPU type and whether we're building 64-bit or 32-bit code + math(EXPR BITS "${CMAKE_SIZEOF_VOID_P} * 8") +-string(TOLOWER ${CMAKE_SYSTEM_PROCESSOR} CMAKE_SYSTEM_PROCESSOR_LC) + if(CMAKE_SYSTEM_PROCESSOR_LC MATCHES "x86_64" OR + CMAKE_SYSTEM_PROCESSOR_LC MATCHES "amd64" OR + CMAKE_SYSTEM_PROCESSOR_LC MATCHES "i[0-9]86" OR diff --git a/contrib/libjpeg-turbo/module.defs b/contrib/libjpeg-turbo/module.defs index dddfec5de..1518514c4 100644 --- a/contrib/libjpeg-turbo/module.defs +++ b/contrib/libjpeg-turbo/module.defs @@ -26,6 +26,13 @@ else endif endif +ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) + LIBJPEGTURBO.CONFIGURE.extra += -DCMAKE_SYSTEM_PROCESSOR=arm64 +endif +ifeq (x86_64-darwin,$(HOST.machine)-$(HOST.system)) + LIBJPEGTURBO.CONFIGURE.extra += -DCMAKE_SYSTEM_PROCESSOR=x86_64 +endif + ifeq (1,$(HOST.cross)) ifeq (mingw,$(HOST.system)) LIBJPEGTURBO.CONFIGURE.extra += -DWIN32=ON -DMINGW=ON @@ -37,6 +44,8 @@ ifeq (1,$(HOST.cross)) LIBJPEGTURBO.CONFIGURE.extra += -DCMAKE_CXX_COMPILER=$(LIBJPEGTURBO.GCC.gxx) LIBJPEGTURBO.CONFIGURE.extra += -DCMAKE_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" LIBJPEGTURBO.CONFIGURE.extra += -DCMAKE_RC_COMPILER=$(HOST.cross.prefix)windres + else ifeq ($(HOST.system),darwin) + LIBJPEGTURBO.CONFIGURE.args.host = -DCMAKE_HOST_SYSTEM="$(LIBJPEGTURBO.CONFIGURE.host)" else LIBJPEGTURBO.CONFIGURE.args.host = -DCMAKE_SYSTEM_NAME="$(LIBJPEGTURBO.CONFIGURE.host)" endif diff --git a/contrib/libogg/module.defs b/contrib/libogg/module.defs index f585465c5..849538a70 100644 --- a/contrib/libogg/module.defs +++ b/contrib/libogg/module.defs @@ -6,3 +6,10 @@ LIBOGG.FETCH.url += https://downloads.xiph.org/releases/ogg/libogg-1.3.4.tar. LIBOGG.FETCH.sha256 = fe5670640bd49e828d64d2879c31cb4dde9758681bb664f9bdbf159a01b0c76e LIBOGG.CONFIGURE.bootstrap = rm -fr aclocal.m4 autom4te.cache configure; autoreconf -fiv; + +ifeq (darwin,$(HOST.system)) + ifneq ($(HOST.machine),$(BUILD.machine)) + LIBOGG.CONFIGURE.args.host = --host=$(HOST.machine:arm64=aarch64)-$(HOST.vendor)-$(HOST.system) + LIBOGG.CONFIGURE.args.build = --build=$(BUILD.machine:arm64=aarch64)-$(BUILD.vendor)-$(BUILD.system) + endif +endif diff --git a/contrib/libopus/module.defs b/contrib/libopus/module.defs index 3f767c32f..da684b99e 100644 --- a/contrib/libopus/module.defs +++ b/contrib/libopus/module.defs @@ -12,4 +12,11 @@ LIBOPUS.CONFIGURE.extra = --disable-doc --disable-extra-programs # optimizations are turned off. LIBOPUS.GCC.args.extra += -DOPUS_WILL_BE_SLOW -LIBOPUS.CONFIGURE.bootstrap = rm -fr aclocal.m4 autom4te.cache configure; autoreconf -fiv; +ifeq (darwin,$(HOST.system)) + ifneq ($(HOST.machine),$(BUILD.machine)) + LIBOPUS.CONFIGURE.extra += --host=$(HOST.machine:arm64=aarch64)-$(HOST.vendor)-$(HOST.system) + LIBOPUS.CONFIGURE.args.build = --build=$(BUILD.machine:arm64=aarch64)-$(BUILD.vendor)-$(BUILD.system) + endif +endif + +LIBOPUS.CONFIGURE.bootstrap = rm -fr aclocal.m4 autom4te.cache configure; autoreconf -fiv;
\ No newline at end of file diff --git a/contrib/libspeex/P00-darwin-applesi-cross.patch b/contrib/libspeex/P00-darwin-applesi-cross.patch new file mode 100644 index 000000000..7993624ca --- /dev/null +++ b/contrib/libspeex/P00-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index 1acc966..7b7db42 100755 +--- a/config.sub ++++ b/config.sub +@@ -248,7 +248,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -371,7 +371,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/libtheora/module.defs b/contrib/libtheora/module.defs index da5a14535..c5ca895cb 100644 --- a/contrib/libtheora/module.defs +++ b/contrib/libtheora/module.defs @@ -20,3 +20,10 @@ LIBTHEORA.CONFIGURE.extra = \ ifeq (1-msys,$(HOST.cross)-$(BUILD.system)) LIBTHEORA.CONFIGURE.args.build = --build=$(BUILD.machine)-unknown-linux-gnu endif + +ifeq (darwin,$(HOST.system)) + ifneq ($(HOST.machine),$(BUILD.machine)) + LIBTHEORA.CONFIGURE.args.host = --host=$(HOST.machine:arm64=aarch64)-$(HOST.vendor)-$(HOST.system) + LIBTHEORA.CONFIGURE.args.build = --build=$(BUILD.machine:arm64=aarch64)-$(BUILD.vendor)-$(BUILD.system) + endif +endif
\ No newline at end of file diff --git a/contrib/libvorbis/module.defs b/contrib/libvorbis/module.defs index 30bf82d55..2cfbb5246 100644 --- a/contrib/libvorbis/module.defs +++ b/contrib/libvorbis/module.defs @@ -8,3 +8,10 @@ LIBVORBIS.FETCH.sha256 = 6ed40e0241089a42c48604dc00e362beee00036af2d8b3f4633803 LIBVORBIS.CONFIGURE.extra = --with-ogg=$(call fn.ABSOLUTE,$(CONTRIB.build/)) HAVE_PKG_CONFIG="no" LIBVORBIS.CONFIGURE.bootstrap = rm -fr aclocal.m4 autom4te.cache configure; autoreconf -I m4 -fiv; + +ifeq (darwin,$(HOST.system)) + ifneq ($(HOST.machine),$(BUILD.machine)) + LIBVORBIS.CONFIGURE.args.host = --host=$(HOST.machine:arm64=aarch64)-$(HOST.vendor)-$(HOST.system) + LIBVORBIS.CONFIGURE.args.build = --build=$(BUILD.machine:arm64=aarch64)-$(BUILD.vendor)-$(BUILD.system) + endif +endif
\ No newline at end of file diff --git a/contrib/libvpx/module.defs b/contrib/libvpx/module.defs index 003a9aae6..b1add498b 100644 --- a/contrib/libvpx/module.defs +++ b/contrib/libvpx/module.defs @@ -18,15 +18,17 @@ LIBVPX.CONFIGURE.extra = \ --disable-unit-tests ifeq (1,$(HOST.cross)) - LIBVPX.CONFIGURE.env.CROSS = CROSS="$(HOST.spec)-" LIBVPX.CONFIGURE.args.build = - LIBVPX.CONFIGURE.extra += --enable-static-msvcrt - ifeq (i686,$(HOST.machine)) - LIBVPX.CONFIGURE.extra += --target=x86-win32-gcc - else ifeq (x86_64,$(HOST.machine)) - LIBVPX.CONFIGURE.extra += --target=x86_64-win64-gcc - else ifeq (aarch64,$(HOST.machine)) - LIBVPX.CONFIGURE.extra += --target=arm64-win64-gcc + ifneq ($(HOST.system),darwin) + LIBVPX.CONFIGURE.env.CROSS = CROSS="$(HOST.spec)-" + LIBVPX.CONFIGURE.extra += --enable-static-msvcrt + ifeq (i686,$(HOST.machine)) + LIBVPX.CONFIGURE.extra += --target=x86-win32-gcc + else ifeq (x86_64,$(HOST.machine)) + LIBVPX.CONFIGURE.extra += --target=x86_64-win64-gcc + else ifeq (aarch64,$(HOST.machine)) + LIBVPX.CONFIGURE.extra += --target=arm64-win64-gcc + endif endif endif diff --git a/contrib/libxml2/P00-darwin-applesi-cross.patch b/contrib/libxml2/P00-darwin-applesi-cross.patch new file mode 100644 index 000000000..f0fd5c1a6 --- /dev/null +++ b/contrib/libxml2/P00-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/config.sub b/config.sub +index f4bafc1..cc30ca6 100755 +--- a/config.sub ++++ b/config.sub +@@ -247,7 +247,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -372,7 +372,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ diff --git a/contrib/x264/module.defs b/contrib/x264/module.defs index f5d8b9e1a..b2f349225 100644 --- a/contrib/x264/module.defs +++ b/contrib/x264/module.defs @@ -14,9 +14,14 @@ X264.CONFIGURE.extra += --disable-lavf --disable-ffms --disable-avs --disable-sw ifeq (1,$(HOST.cross)) X264.CONFIGURE.build = - X264.CONFIGURE.extra += --cross-prefix=$(HOST.spec)- + ifneq ($(HOST.system),darwin) + X264.CONFIGURE.extra += --cross-prefix=$(HOST.spec)- + endif X264.CONFIGURE.env.CFLAGS = CFLAGS="-I$(call fn.ABSOLUTE,$(CONTRIB.build/)include) $(call fn.ARGS,X264.GCC,*archs *sysroot *minver ?extra)" X264.CONFIGURE.env.LDFLAGS = LDFLAGS="-L$(call fn.ABSOLUTE,$(CONTRIB.build/)lib) $(call fn.ARGS,X264.GCC,*archs *sysroot *minver)" + ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) + X264.CONFIGURE.extra += --extra-asflags="-arch $(HOST.arch)" + endif endif ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) diff --git a/contrib/x265_10bit/module.defs b/contrib/x265_10bit/module.defs index b6fba9c3d..5a08029b7 100644 --- a/contrib/x265_10bit/module.defs +++ b/contrib/x265_10bit/module.defs @@ -29,6 +29,9 @@ endif ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) X265_10.CONFIGURE.extra += -DCMAKE_OSX_ARCHITECTURES=arm64 endif +ifeq (x86_64-darwin,$(HOST.machine)-$(HOST.system)) + X265_10.CONFIGURE.extra += -DCMAKE_OSX_ARCHITECTURES=x86_64 +endif ifeq ($(GCC.O),$(filter $(GCC.O),size size-aggressive)) X265_10.CONFIGURE.extra += -DCMAKE_BUILD_TYPE=MinSizeRel @@ -51,6 +54,8 @@ ifeq (1,$(HOST.cross)) X265_10.CONFIGURE.extra += -DCMAKE_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" X265_10.CONFIGURE.extra += -DCMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" X265_10.CONFIGURE.extra += -DCMAKE_RC_COMPILER=$(HOST.cross.prefix)windres + else ifeq ($(HOST.system),darwin) + X265_10.CONFIGURE.args.host = -DCMAKE_HOST_SYSTEM="$(X265_10.CONFIGURE.host)" else X265_10.CONFIGURE.args.host = -DCMAKE_SYSTEM_NAME="$(X265_10.CONFIGURE.host)" endif diff --git a/contrib/x265_12bit/module.defs b/contrib/x265_12bit/module.defs index 20fcb390f..f21238a58 100644 --- a/contrib/x265_12bit/module.defs +++ b/contrib/x265_12bit/module.defs @@ -29,6 +29,9 @@ endif ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) X265_12.CONFIGURE.extra += -DCMAKE_OSX_ARCHITECTURES=arm64 endif +ifeq (x86_64-darwin,$(HOST.machine)-$(HOST.system)) + X265_12.CONFIGURE.extra += -DCMAKE_OSX_ARCHITECTURES=x86_64 +endif ifeq ($(GCC.O),$(filter $(GCC.O),size size-aggressive)) X265_12.CONFIGURE.extra += -DCMAKE_BUILD_TYPE=MinSizeRel @@ -51,6 +54,8 @@ ifeq (1,$(HOST.cross)) X265_12.CONFIGURE.extra += -DCMAKE_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" X265_12.CONFIGURE.extra += -DCMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" X265_12.CONFIGURE.extra += -DCMAKE_RC_COMPILER=$(HOST.cross.prefix)windres + else ifeq ($(HOST.system),darwin) + X265_12.CONFIGURE.args.host = -DCMAKE_HOST_SYSTEM="$(X265_12.CONFIGURE.host)" else X265_12.CONFIGURE.args.host = -DCMAKE_SYSTEM_NAME="$(X265_12.CONFIGURE.host)" endif diff --git a/contrib/x265_8bit/module.defs b/contrib/x265_8bit/module.defs index be7268a06..7f28dcd5b 100644 --- a/contrib/x265_8bit/module.defs +++ b/contrib/x265_8bit/module.defs @@ -27,6 +27,10 @@ ifeq (arm64-darwin,$(HOST.machine)-$(HOST.system)) X265_8.CONFIGURE.extra += -DCMAKE_OSX_ARCHITECTURES=arm64 endif +ifeq (x86_64-darwin,$(HOST.machine)-$(HOST.system)) + X265_8.CONFIGURE.extra += -DCMAKE_OSX_ARCHITECTURES=x86_64 +endif + ifeq ($(GCC.O),$(filter $(GCC.O),size size-aggressive)) X265_8.CONFIGURE.extra += -DCMAKE_BUILD_TYPE=MinSizeRel else @@ -48,6 +52,8 @@ ifeq (1,$(HOST.cross)) X265_8.CONFIGURE.extra += -DCMAKE_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" X265_8.CONFIGURE.extra += -DCMAKE_SHARED_LIBRARY_LINK_CXX_FLAGS="-static-libgcc -static-libstdc++ -static" X265_8.CONFIGURE.extra += -DCMAKE_RC_COMPILER=$(HOST.cross.prefix)windres + else ifeq ($(HOST.system),darwin) + X265_8.CONFIGURE.args.host = -DCMAKE_HOST_SYSTEM="$(X265_8.CONFIGURE.host)" else X265_8.CONFIGURE.args.host = -DCMAKE_SYSTEM_NAME="$(X265_8.CONFIGURE.host)" endif diff --git a/contrib/xz/P00-darwin-applesi-cross.patch b/contrib/xz/P00-darwin-applesi-cross.patch new file mode 100644 index 000000000..4f8fb67bb --- /dev/null +++ b/contrib/xz/P00-darwin-applesi-cross.patch @@ -0,0 +1,22 @@ +diff --git a/build-aux/config.sub b/build-aux/config.sub +index 40ea5df..f7174c9 100755 +--- a/build-aux/config.sub ++++ b/build-aux/config.sub +@@ -247,7 +247,7 @@ case $basic_machine in + # Some are omitted here because they have special meanings below. + 1750a | 580 \ + | a29k \ +- | aarch64 | aarch64_be \ ++ | aarch64 | aarch64_be | arm64 \ + | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ + | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ + | am33_2.0 \ +@@ -372,7 +372,7 @@ case $basic_machine in + # Recognize the basic CPU types with company name. + 580-* \ + | a29k-* \ +- | aarch64-* | aarch64_be-* \ ++ | aarch64-* | aarch64_be-* | arm64*-* \ + | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ + | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ + | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ |