Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/build-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ jobs:
matrix:
# make arm64 deps and x86_64 deps
include:
- { macarch: arm64, os: macos-14 }
- { macarch: x86_64, os: macos-13 }
- { macarch: arm64, os: macos-15 }
- { macarch: x86_64, os: macos-15 }

steps:
- uses: actions/[email protected]
Expand Down Expand Up @@ -64,8 +64,8 @@ jobs:
fail-fast: false # if a particular matrix build fails, don't skip the rest
matrix:
include:
- { macarch: arm64, os: macos-14 }
- { macarch: x86_64, os: macos-13 }
- { macarch: arm64, os: macos-15 }
- { macarch: x86_64, os: macos-15 }

env:
MAC_ARCH: ${{ matrix.macarch }}
Expand Down
15 changes: 12 additions & 3 deletions buildconfig/macdependencies/build_mac_deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,21 @@ else
# install NASM to generate optimised x86_64 libjpegturbo builds
brew install nasm

# for scripts using ./configure to make x86_64 binaries
export CC="clang -target x86_64-apple-macos10.11"
export CXX="clang++ -target x86_64-apple-macos10.11"

export PG_BASE_CONFIGURE_FLAGS="$PG_BASE_CONFIGURE_FLAGS --host=x86_64-apple-darwin"

# configure cmake to cross-compile
export PG_BASE_CMAKE_FLAGS="$PG_BASE_CMAKE_FLAGS -DCMAKE_OSX_ARCHITECTURES=x86_64"

# SDL 2.26.5 new minimum macos is 10.11, so we build our x86 mac deps
# for 10.11 as well.
export MACOSX_DEPLOYMENT_TARGET=10.11

# needs native-file that has correct macosx deployment target
export PG_BASE_MESON_FLAGS="$PG_BASE_MESON_FLAGS --native-file $(pwd)/macos_x86_64.ini"
# configure meson to cross-compile with correct target
export PG_BASE_MESON_FLAGS="$PG_BASE_MESON_FLAGS --cross-file $(pwd)/macos_x86_64.ini"
fi

cd ../manylinux-build/docker_base
Expand Down Expand Up @@ -90,7 +99,7 @@ bash wavpack/build-wavpack.sh

# fluidsynth (for sdl_mixer)
# bash gettext/build-gettext.sh
bash glib/build-glib.sh
# bash glib/build-glib.sh
bash sndfile/build-sndfile.sh
bash fluidsynth/build-fluidsynth.sh

Expand Down
3 changes: 2 additions & 1 deletion buildconfig/macdependencies/clean_usr_local.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ln -s /usr/bin/git /usr/local/bin/git
ln -s /usr/bin/git /opt/homebrew/bin/git

rm -rf /usr/local/lib/libtiff*
rm -rf /usr/local/lib/libzstd*
rm -rf /usr/local/lib/libzstd* /opt/homebrew/lib/libzstd*
rm -rf /usr/local/lib/libwebp*
rm -rf /usr/local/lib/libdeflate*
rm -rf /usr/local/lib/libsndfile*
Expand All @@ -25,6 +25,7 @@ rm -rf /usr/local/lib/libbrotlidec*
rm -rf /usr/local/lib/libopus*
rm -rf /usr/local/lib/freetype*
rm -rf /usr/local/opt/freetype*
rm -rf /opt/homebrew/lib/libgif*

rm -rf /usr/local/Cellar/libtiff /opt/homebrew/Cellar/libtiff
rm -rf /usr/local/Cellar/libsndfile /opt/homebrew/Cellar/libsndfile
Expand Down
8 changes: 7 additions & 1 deletion buildconfig/macdependencies/macos_x86_64.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
[constants]
macos_ver = ['-mmacosx-version-min=10.11']
macos_ver = ['-target', 'x86_64-apple-macos10.11']

[host_machine]
system = 'darwin'
cpu_family = 'x86_64'
cpu = 'x86_64'
endian = 'little'

[binaries]
c = ['clang']
Expand Down
12 changes: 6 additions & 6 deletions buildconfig/manylinux-build/docker_base/Dockerfile-aarch64
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# pin version on image for CI stability
FROM quay.io/pypa/manylinux2014_aarch64:2025.07.25-1
FROM quay.io/pypa/manylinux2014_aarch64:2025.10.10-1
ENV MAKEFLAGS="-j 4"
ENV PG_DEP_PREFIX="/usr/local"

Expand Down Expand Up @@ -94,12 +94,12 @@ RUN ["bash", "/libjpegturbo_build/build-jpeg-turbo.sh"]
ADD libpng /libpng_build/
RUN ["bash", "/libpng_build/build-png.sh"]

ADD libwebp /webp_build/
RUN ["bash", "/webp_build/build-webp.sh"]

ADD libtiff /libtiff_build/
RUN ["bash", "/libtiff_build/build-tiff.sh"]

ADD libwebp /webp_build/
RUN ["bash", "/webp_build/build-webp.sh"]

ADD brotli /brotli_build/
RUN ["bash", "/brotli_build/build-brotli.sh"]

Expand Down Expand Up @@ -142,8 +142,8 @@ RUN ["bash", "/libxmp_build/build-libxmp.sh"]
# ADD gettext /gettext_build/
# RUN ["bash", "/gettext_build/build-gettext.sh"]

ADD glib /glib_build/
RUN ["bash", "/glib_build/build-glib.sh"]
# ADD glib /glib_build/
# RUN ["bash", "/glib_build/build-glib.sh"]

ADD fluidsynth /fluidsynth_build/
RUN ["bash", "/fluidsynth_build/build-fluidsynth.sh"]
Expand Down
12 changes: 6 additions & 6 deletions buildconfig/manylinux-build/docker_base/Dockerfile-i686
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# pin version on image for CI stability
FROM quay.io/pypa/manylinux2014_i686:2025.07.25-1
FROM quay.io/pypa/manylinux2014_i686:2025.10.10-1

Check warning on line 2 in buildconfig/manylinux-build/docker_base/Dockerfile-i686

View workflow job for this annotation

GitHub Actions / i686

Base image platform does not match expected target platform

InvalidBaseImagePlatform: Base image quay.io/pypa/manylinux2014_i686:2025.10.10-1 was pulled with platform "linux/386", expected "linux/amd64" for current build
ENV MAKEFLAGS="-j 4"
ENV PG_DEP_PREFIX="/usr/local"

Expand Down Expand Up @@ -94,12 +94,12 @@
ADD libpng /libpng_build/
RUN ["linux32", "bash", "/libpng_build/build-png.sh"]

ADD libwebp /webp_build/
RUN ["linux32", "bash", "/webp_build/build-webp.sh"]

ADD libtiff /libtiff_build/
RUN ["linux32", "bash", "/libtiff_build/build-tiff.sh"]

ADD libwebp /webp_build/
RUN ["linux32", "bash", "/webp_build/build-webp.sh"]

ADD brotli /brotli_build/
RUN ["linux32", "bash", "/brotli_build/build-brotli.sh"]

Expand Down Expand Up @@ -142,8 +142,8 @@
# ADD gettext /gettext_build/
# RUN ["bash", "/gettext_build/build-gettext.sh"]

ADD glib /glib_build/
RUN ["linux32", "bash", "/glib_build/build-glib.sh"]
# ADD glib /glib_build/
# RUN ["linux32", "bash", "/glib_build/build-glib.sh"]

ADD fluidsynth /fluidsynth_build/
RUN ["linux32", "bash", "/fluidsynth_build/build-fluidsynth.sh"]
Expand Down
12 changes: 6 additions & 6 deletions buildconfig/manylinux-build/docker_base/Dockerfile-x86_64
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# pin version on image for CI stability
FROM quay.io/pypa/manylinux2014_x86_64:2025.07.25-1
FROM quay.io/pypa/manylinux2014_x86_64:2025.10.10-1
ENV MAKEFLAGS="-j 4"
ENV PG_DEP_PREFIX="/usr/local"

Expand Down Expand Up @@ -94,12 +94,12 @@ RUN ["bash", "/libjpegturbo_build/build-jpeg-turbo.sh"]
ADD libpng /libpng_build/
RUN ["bash", "/libpng_build/build-png.sh"]

ADD libwebp /webp_build/
RUN ["bash", "/webp_build/build-webp.sh"]

ADD libtiff /libtiff_build/
RUN ["bash", "/libtiff_build/build-tiff.sh"]

ADD libwebp /webp_build/
RUN ["bash", "/webp_build/build-webp.sh"]

ADD brotli /brotli_build/
RUN ["bash", "/brotli_build/build-brotli.sh"]

Expand Down Expand Up @@ -142,8 +142,8 @@ RUN ["bash", "/libxmp_build/build-libxmp.sh"]
# ADD gettext /gettext_build/
# RUN ["bash", "/gettext_build/build-gettext.sh"]

ADD glib /glib_build/
RUN ["bash", "/glib_build/build-glib.sh"]
# ADD glib /glib_build/
# RUN ["bash", "/glib_build/build-glib.sh"]

ADD fluidsynth /fluidsynth_build/
RUN ["bash", "/fluidsynth_build/build-fluidsynth.sh"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ fi

# pin versions for stability (remember to keep updated)
python3 -m pip install $PG_PIP_EXTRA_FLAGS \
setuptools==80.9.0 meson==1.8.2 ninja==1.11.1.4
setuptools==80.9.0 meson==1.9.1 ninja==1.13.0

if [[ "$OSTYPE" == "linux-gnu"* ]]; then
cp /root/.local/bin/* /usr/bin
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,17 @@ set -e -x

cd $(dirname `readlink -f "$0"`)

FSYNTH_VER="2.4.7"
FSYNTH_VER="2.5.0"
FSYNTH="fluidsynth-$FSYNTH_VER"

curl -sL --retry 10 https://github.com/FluidSynth/fluidsynth/archive/v${FSYNTH_VER}.tar.gz > ${FSYNTH}.tar.gz
sha512sum -c fluidsynth.sha512
tar xzf ${FSYNTH}.tar.gz

cd $FSYNTH
# Vendor in the fix from https://github.com/FluidSynth/fluidsynth/pull/1687
# this can be removed when we bump fluidsynth next
patch -p1 < ../pr-1687.patch
mkdir build
cd build

Expand All @@ -22,6 +25,7 @@ elif [[ "$OSTYPE" == "darwin"* ]]; then
fi

cmake .. $PG_BASE_CMAKE_FLAGS -Denable-readline=OFF $FLUIDSYNTH_EXTRA_PLAT_FLAGS \
-Denable-openmp=OFF -Dosal=cpp11 -Denable-libinstpatch=0 \
-Denable-pulseaudio=NO \
-Denable-pipewire=NO

Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
8f5d9e20ab5a50b966ae9abee349913611a3e4ebb6c4a39c8b0f56aaba06483e82a761e3d38a37af689e45a0940957c9db9d324ff77352b0841da40be1ff3899 fluidsynth-2.4.7.tar.gz
8f326db4049b3241c7a0472aa5db8c715dcfc0a1ce9c5fda492bf84e6c17e27a2298131a58a51e275797259a434e59bfe3f53d85358f903652dca8de753a3376 fluidsynth-2.5.0.tar.gz
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
From 2dc377b4e7b59d01b71d6389a12e787231a792c5 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pedro=20L=C3=B3pez-Cabanillas?= <[email protected]>
Date: Sat, 18 Oct 2025 20:45:46 +0200
Subject: [PATCH 1/2] alternate std::filesystem CMake check for mac

---
CMakeLists.txt | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 350a1dcef..0344240fa 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -567,7 +567,9 @@ unset ( HAVE_CXX_FILESYSTEM CACHE )
if ( osal STREQUAL "cpp11" )
# Will silently fall back to a lower standard version if not available
set( CMAKE_CXX_STANDARD 17 )
- check_include_file_cxx ( filesystem HAVE_CXX_FILESYSTEM )
+ include( CheckCXXSourceCompiles )
+ check_cxx_source_compiles( "#include <filesystem>
+ int main() { std::filesystem::path path = std::filesystem::current_path(); }" HAVE_CXX_FILESYSTEM )
if ( NOT HAVE_CXX_FILESYSTEM )
message ( WARNING "C++ filesystem support not found, some file operations will be stubs" )
endif ( NOT HAVE_CXX_FILESYSTEM )

From 5ae4455c409fb0eb01112880bed7cb1262e3668b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Pedro=20L=C3=B3pez-Cabanillas?= <[email protected]>
Date: Sat, 18 Oct 2025 22:56:59 +0200
Subject: [PATCH 2/2] additional check for feature-test macro

---
CMakeLists.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0344240fa..400855416 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -569,7 +569,7 @@ if ( osal STREQUAL "cpp11" )
set( CMAKE_CXX_STANDARD 17 )
include( CheckCXXSourceCompiles )
check_cxx_source_compiles( "#include <filesystem>
- int main() { std::filesystem::path path = std::filesystem::current_path(); }" HAVE_CXX_FILESYSTEM )
+ int main() { static_assert(__cpp_lib_filesystem == 201703L); std::filesystem::path p = std::filesystem::current_path(); }" HAVE_CXX_FILESYSTEM )
if ( NOT HAVE_CXX_FILESYSTEM )
message ( WARNING "C++ filesystem support not found, some file operations will be stubs" )
endif ( NOT HAVE_CXX_FILESYSTEM )
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,8 @@ set -e -x

cd $(dirname `readlink -f "$0"`)

# TODO: when freetype is updated, we can look into resolving the circular
# dependency between freetype and harfbuzz by using the upcoming freetype
# dynamic harfbuzz loading feature.
FREETYPE="freetype-2.13.3"
HARFBUZZ_VER=11.3.3
FREETYPE="freetype-2.14.1"
HARFBUZZ_VER=12.1.0
HARFBUZZ_NAME="harfbuzz-$HARFBUZZ_VER"

curl -sL --retry 10 https://savannah.nongnu.org/download/freetype/${FREETYPE}.tar.gz > ${FREETYPE}.tar.gz
Expand All @@ -19,19 +16,24 @@ tar xzf ${FREETYPE}.tar.gz
unxz ${HARFBUZZ_NAME}.tar.xz
tar xf ${HARFBUZZ_NAME}.tar

# freetype and harfbuzz have an infamous circular dependency, which is why
# this file is not like the rest of docker_base files

# 1. First compile freetype without harfbuzz support
cd $FREETYPE

./configure $PG_BASE_CONFIGURE_FLAGS --with-harfbuzz=no
make
make install # this freetype is not installed to mac cache dir
# For now bzip2 is only used on macOS, on other platforms there are issues with
# it.
if [[ "$OSTYPE" == "darwin"* ]]; then
export PG_FT_BZ2="-Dbzip2=enabled"
else
export PG_FT_BZ2="-Dbzip2=disabled"
fi

meson setup _build $PG_BASE_MESON_FLAGS -Dbrotli=enabled -Dharfbuzz=dynamic \
-Dpng=enabled -Dzlib=system $PG_FT_BZ2

meson compile -C _build
meson install -C _build

cd ..

# 2. Compile harfbuzz with freetype support
cd ${HARFBUZZ_NAME}

# harfbuzz has a load of optional dependencies but only freetype is important
Expand All @@ -46,28 +48,4 @@ meson setup _build $PG_BASE_MESON_FLAGS -Dfreetype=enabled \
meson compile -C _build
meson install -C _build

if [[ "$OSTYPE" == "darwin"* ]]; then
# We do a little hack...
# When freetype finds harfbuzz with pkg-config, we tell freetype a little
# lie that harfbuzz doesn't depend on freetype (even though it does).
# This ensures no direct circular dylib link happen.
# This is a bit of a brittle hack: This command removes the entire line that
# contains "freetype". This is fine for now when the harfbuzz we are
# building has no other dependencies
sed -i '' '/freetype/d' $PG_DEP_PREFIX/lib/pkgconfig/harfbuzz.pc
fi

cd ..

# 3. Recompile freetype, and this time with harfbuzz support
cd $FREETYPE

# fully clean previous install
make clean
if [[ "$OSTYPE" == "darwin"* ]]; then
make uninstall
fi

./configure $PG_BASE_CONFIGURE_FLAGS --with-harfbuzz=yes
make
make install
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
b7e7e67baed421dbe08c48dcde5d5891c0f7e3c1253be8dc27826c60eaa17ca89f888c3d5a6faf5141b02c154e1cf42d4ed6133b9959ddc359fe6bd41615ae89 freetype-2.13.3.tar.gz
56a971c939522bc5edad5f8a578444844b9101321c6bacfb3d96eadf3b13238144d465dd22171b61ef7b3873af88e43297989c289a5fc37e4d390b64c435cff6 harfbuzz-11.3.3.tar.xz
1a1db7baa9979b55e663e210433ea53818d39ca25793242a6b3a7edbdd68ea1c386a72aeaa30cea9a9bee5dd0ffd42e8f2785e58bcc543c3452ac5c5c0dc7e2d freetype-2.14.1.tar.gz
94cbc3fe8fad30f4f7871bdddc8b129c486ab55329f9b48c6336fdf15d05f09c3c96cac51f68a0218db113b4783c07ce5d6bb455ccc875b31fd2261e3e8dc559 harfbuzz-12.1.0.tar.xz
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set -e -x

cd $(dirname `readlink -f "$0"`)

JPEG_VERSION=3.1.1
JPEG_VERSION=3.1.2
JPEG="libjpeg-turbo-${JPEG_VERSION}"

curl -sL --retry 10 https://github.com/libjpeg-turbo/libjpeg-turbo/releases/download/${JPEG_VERSION}/${JPEG}.tar.gz > ${JPEG}.tar.gz
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
d08c8eb77281c1eee2c93ef9f2eefaf79a4b9adff5172ebcb20c845ccad8896a28fc3d622002cc8b28964ff860dca0a491d6b1b921aaa7aedccd21b909aad4cb libjpeg-turbo-3.1.1.tar.gz
79271ae4ddc12e3753cc7323dc15617f1d82b2d554ef27b555712f6ab5de603323dd33747620815e3b55663a20e07b292a55172aee9f401f9fd3557145967abe libjpeg-turbo-3.1.2.tar.gz
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ sha512sum -c png.sha512
tar xzf ${PNG}.tar.gz
cd $PNG

./configure --with-zlib-prefix=$PG_DEP_PREFIX $PG_BASE_CONFIGURE_FLAGS
cmake . $PG_BASE_CMAKE_FLAGS -DPNG_TESTS=0 -DPNG_TOOLS=0 -DPNG_STATIC=0 -DPNG_FRAMEWORK=0
make
make install
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set -e -x

cd $(dirname `readlink -f "$0"`)

TIFF=tiff-4.7.0
TIFF=tiff-4.7.1

curl -sL --retry 10 https://download.osgeo.org/libtiff/${TIFF}.tar.gz > ${TIFF}.tar.gz
sha512sum -c tiff.sha512
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
a77a050d1d8777c6d86077c3c26e8d35f98717fe14bb3c049e2b82fbfbb374e96f83a0c1ff67ffb21591a9a7abf0d3e18c3d7695c96939326cc19a9712dd2492 tiff-4.7.0.tar.gz
89c5af880626888451caf8b78a2f57b2973719db837dce6530c1fb30318fc6fba7ef9f9d8e46c547821eae29322607cb5146bf3de39b3d7b70bcf5b68c4ee3b1 tiff-4.7.1.tar.gz
Loading
Loading