Skip to content

Commit ced8cc8

Browse files
committed
Update to Fedora 39, update all toolchains
- Base image: Fedora 39 - SCons: 4.5.2 - Linux: GCC 10.2.0 built against glibc 2.19, binutils 2.35.1 - Windows: MinGW 11.0.0, GCC 13.2.1, binutils 2.40 - Web: Emscripten 3.1.39 - Android: Android NDK 23.2.8568313, build-tools 33.0.2, platform android-33, CMake 3.22.1, JDK 17 CMake 3.22.1, JDK 17 - macOS: Xcode 15.0 with Apple Clang (LLVM 16.0.0), MacOSX SDK 14.0 - iOS: Xcode 15.0 with Apple Clang (LLVM 16.0.0), iPhoneOS SDK 17.0 Switches macOS/iOS builds to use Apple Clang, to maximize compatibility with upstream Xcode. Also add gettext which is needed by Godot build scripts to compile PO files to MO.
1 parent 913ae1e commit ced8cc8

File tree

8 files changed

+61
-68
lines changed

8 files changed

+61
-68
lines changed

Dockerfile.android

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ ENV ANDROID_NDK_VERSION=23.2.8568313
66
ENV ANDROID_NDK_ROOT=${ANDROID_SDK_ROOT}/ndk/${ANDROID_NDK_VERSION}
77

88
RUN dnf -y install --setopt=install_weak_deps=False \
9-
java-11-openjdk-devel ncurses-compat-libs && \
9+
java-17-openjdk-devel ncurses-compat-libs && \
1010
mkdir -p sdk && cd sdk && \
11-
export CMDLINETOOLS=commandlinetools-linux-8512546_latest.zip && \
11+
export CMDLINETOOLS=commandlinetools-linux-10406996_latest.zip && \
1212
curl -LO https://dl.google.com/android/repository/${CMDLINETOOLS} && \
1313
unzip ${CMDLINETOOLS} && \
1414
rm ${CMDLINETOOLS} && \
1515
yes | cmdline-tools/bin/sdkmanager --sdk_root="${ANDROID_SDK_ROOT}" --licenses && \
16-
cmdline-tools/bin/sdkmanager --sdk_root="${ANDROID_SDK_ROOT}" "ndk;${ANDROID_NDK_VERSION}" 'cmdline-tools;latest' 'build-tools;32.0.0' 'platforms;android-32' 'cmake;3.18.1'
16+
cmdline-tools/bin/sdkmanager --sdk_root="${ANDROID_SDK_ROOT}" "ndk;${ANDROID_NDK_VERSION}" 'cmdline-tools;latest' 'build-tools;33.0.2' 'platforms;android-33' 'cmake;3.22.1'
1717

1818
CMD /bin/bash

Dockerfile.base

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
FROM fedora:36
1+
FROM fedora:39
22

33
WORKDIR /root
44

55
ENV DOTNET_NOLOGO=1
66
ENV DOTNET_CLI_TELEMETRY_OPTOUT=1
77

88
RUN dnf -y install --setopt=install_weak_deps=False \
9-
bash bzip2 curl file findutils git make nano patch pkgconfig python3-pip unzip which xz \
9+
bash bzip2 curl file findutils gettext git make nano patch pkgconfig python3-pip unzip which xz \
1010
dotnet-sdk-6.0 && \
11-
pip install scons==4.4.0
11+
pip install scons==4.5.2
1212

1313
CMD /bin/bash

Dockerfile.ios

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,31 @@
11
ARG img_version
22
FROM godot-osx:${img_version}
33

4-
ENV IOS_SDK=16.1
4+
ENV IOS_SDK=17.0
55

66
RUN dnf -y install --setopt=install_weak_deps=False \
77
automake autoconf gcc gcc-c++ gcc-objc gcc-objc++ cmake libicu-devel libtool libxml2-devel openssl-devel perl python yasm && \
8-
git clone --progress https://github.com/tpoechtrager/cctools-port.git && \
8+
git clone --progress https://github.com/tpoechtrager/cctools-port && \
99
cd /root/cctools-port && \
10-
git checkout 11c93763d7e7ce7305163341d08052374e4712de && \
10+
git checkout 437ced391dbf14dce86f977ca050a750d5682f39 && \
11+
curl -LO https://github.com/tpoechtrager/cctools-port/pull/136.patch && \
12+
git apply 136.patch && \
1113
# arm64 device
1214
usage_examples/ios_toolchain/build.sh /root/files/iPhoneOS${IOS_SDK}.sdk.tar.xz arm64 && \
1315
mkdir -p /root/ioscross/arm64 && \
1416
mv usage_examples/ios_toolchain/target/* /root/ioscross/arm64 && \
1517
mkdir /root/ioscross/arm64/usr && \
1618
ln -s /root/ioscross/arm64/bin /root/ioscross/arm64/usr/bin && \
19+
# Prepare for simulator builds
20+
sed -i '/WRAPPER_SDKDIR/s/iPhoneOS/iPhoneSimulator/' usage_examples/ios_toolchain/build.sh && \
1721
# arm64 simulator
18-
# Disabled for now as it doesn't work with cctools-port and current LLVM:
19-
# Cf. https://github.com/tpoechtrager/cctools-port/issues/102
20-
#sed -i 's/miphoneos-version-min/mios-simulator-version-min/g' usage_examples/ios_toolchain/wrapper.c && \
21-
#usage_examples/ios_toolchain/build.sh /root/files/iPhoneSimulator${IOS_SDK}.sdk.tar.xz arm64 && \
22-
#mkdir -p /root/ioscross/arm64_sim && \
23-
#mv usage_examples/ios_toolchain/target/* /root/ioscross/arm64_sim && \
24-
#mkdir /root/ioscross/arm64_sim/usr && \
25-
#ln -s /root/ioscross/arm64_sim/bin /root/ioscross/arm64_sim/usr/bin && \
22+
usage_examples/ios_toolchain/build.sh /root/files/iPhoneSimulator${IOS_SDK}.sdk.tar.xz arm64 && \
23+
mkdir -p /root/ioscross/arm64_sim && \
24+
mv usage_examples/ios_toolchain/target/* /root/ioscross/arm64_sim && \
25+
mkdir /root/ioscross/arm64_sim/usr && \
26+
ln -s /root/ioscross/arm64_sim/bin /root/ioscross/arm64_sim/usr/bin && \
2627
# x86_64 simulator
27-
sed -i 's#^TRIPLE=.*#TRIPLE="x86_64-apple-darwin11"#' usage_examples/ios_toolchain/build.sh && \
28+
sed -i 's/^TRIPLE=.*/TRIPLE="x86_64-apple-darwin11"/' usage_examples/ios_toolchain/build.sh && \
2829
usage_examples/ios_toolchain/build.sh /root/files/iPhoneSimulator${IOS_SDK}.sdk.tar.xz x86_64 && \
2930
mkdir -p /root/ioscross/x86_64_sim && \
3031
mv usage_examples/ios_toolchain/target/* /root/ioscross/x86_64_sim && \

Dockerfile.osx

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,17 @@ ARG img_version
22
FROM godot-fedora:${img_version}
33

44
RUN dnf -y install --setopt=install_weak_deps=False \
5-
automake autoconf bzip2-devel cmake gcc gcc-c++ libicu-devel libtool libxml2-devel openssl-devel yasm \
6-
clang llvm-devel && \
7-
git clone --progress https://github.com/tpoechtrager/osxcross.git && \
5+
automake autoconf bzip2-devel cmake gcc gcc-c++ libdispatch libicu-devel libtool \
6+
libxml2-devel openssl-devel uuid-devel yasm && \
7+
git clone --progress https://github.com/tpoechtrager/osxcross && \
88
cd /root/osxcross && \
9-
git checkout 50e86ebca7d14372febd0af8cd098705049161b9 && \
10-
ln -s /root/files/MacOSX13.0.sdk.tar.xz /root/osxcross/tarballs && \
9+
git checkout 5e1b71fcceb23952f3229995edca1b6231525b5b && \
10+
ln -s /root/files/MacOSX14.0.sdk.tar.xz /root/osxcross/tarballs && \
1111
export UNATTENDED=1 && \
12-
# Custom build Clang if the Fedora version doesn't match the Xcode SDK.
13-
#CLANG_VERSION=14.0.6 ENABLE_CLANG_INSTALL=1 INSTALLPREFIX=/usr ./build_clang.sh && \
12+
# Custom build Apple Clang to ensure compatibility.
13+
# Find the equivalent LLVM version for the SDK from:
14+
# https://en.wikipedia.org/wiki/Xcode#Toolchain_versions
15+
CLANG_VERSION=16.0.0 ENABLE_CLANG_INSTALL=1 INSTALLPREFIX=/usr ./build_apple_clang.sh && \
1416
./build.sh && \
1517
./build_compiler_rt.sh && \
1618
rm -rf /root/osxcross/build

Dockerfile.web

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
ARG img_version
22
FROM godot-fedora:${img_version}
33

4-
ENV EMSCRIPTEN_VERSION=3.1.18
4+
ENV EMSCRIPTEN_VERSION=3.1.39
55

66
RUN git clone --branch ${EMSCRIPTEN_VERSION} --progress https://github.com/emscripten-core/emsdk && \
77
emsdk/emsdk install ${EMSCRIPTEN_VERSION} && \

Dockerfile.xcode

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ RUN dnf -y install --setopt=install_weak_deps=False \
55
clang xar xar-devel xz-devel cpio && \
66
git clone --progress https://github.com/nrosenstein-stuff/pbzx && \
77
cd pbzx && \
8-
git checkout 2a4d7c3300c826d918def713a24d25c237c8ed53 && \
8+
git checkout bf536e167f2e514866f91d7baa0df1dff5a13711 && \
99
clang -O3 -llzma -lxar -I /usr/local/include pbzx.c -o pbzx
1010

1111
ENV XCODE_SDKV=
@@ -18,28 +18,18 @@ CMD mkdir -p /root/xcode && \
1818
/root/pbzx/pbzx -n Content | cpio -i && \
1919
export OSX_SDK=MacOSX${OSX_SDKV}.sdk && \
2020
cp -r Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk /tmp/${OSX_SDK} && \
21-
mkdir -p /tmp/${OSX_SDK}/usr/include/c++ && \
22-
cp -r Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 /tmp/${OSX_SDK}/usr/include/c++/ && \
23-
mkdir -p mkdir -p /tmp/${OSX_SDK}/usr/share/man && \
24-
cp -rf Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/share/man/man1 \
25-
Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/share/man/man3 \
26-
Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/share/man/man5 /tmp/${OSX_SDK}/usr/share/man/ && \
2721
cd /tmp && \
2822
tar -cJf /root/files/${OSX_SDK}.tar.xz ${OSX_SDK} && \
2923
rm -rf ${OSX_SDK} && \
3024
cd /root/xcode && \
3125
export IOS_SDK=iPhoneOS${IOS_SDKV}.sdk && \
3226
export IOS_SIMULATOR_SDK=iPhoneSimulator${IOS_SDKV}.sdk && \
3327
cp -r Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk /tmp/${IOS_SDK} && \
34-
mkdir -p /tmp/${IOS_SDK}/usr/include/c++ && \
35-
cp -r Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 /tmp/${IOS_SDK}/usr/include/c++/ && \
3628
cd /tmp && \
3729
tar -cJf /root/files/${IOS_SDK}.tar.xz ${IOS_SDK} && \
3830
rm -rf ${IOS_SDK} && \
3931
cd /root/xcode && \
40-
cp -r Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk /tmp/${IOS_SDK} && \
41-
mkdir -p /tmp/${IOS_SDK}/usr/include/c++ && \
42-
cp -r Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 /tmp/${IOS_SDK}/usr/include/c++/ && \
32+
cp -r Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk /tmp/${IOS_SIMULATOR_SDK} && \
4333
cd /tmp && \
44-
tar -cJf /root/files/${IOS_SIMULATOR_SDK}.tar.xz ${IOS_SDK} && \
45-
rm -rf ${IOS_SDK}
34+
tar -cJf /root/files/${IOS_SIMULATOR_SDK}.tar.xz ${IOS_SIMULATOR_SDK} && \
35+
rm -rf ${IOS_SIMULATOR_SDK}

README.md

Lines changed: 24 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,13 @@ The `build.sh` script included is used to build the containers themselves.
3737

3838
The two arguments can take any value and are meant to convey what Godot branch
3939
you are building for (e.g. `4.x`) and what Linux distribution the `Dockerfile.base`
40-
is based on (e.g. `f36` for Fedora 36).
40+
is based on (e.g. `f39` for Fedora 39).
4141

4242
Run the command using:
4343

44-
./build.sh 4.x f36
44+
./build.sh 4.x f39
4545

46-
The above will generate images using the tag '4.x-f36'.
46+
The above will generate images using the tag '4.x-f39'.
4747
You can then specify it in the `build.sh` of
4848
[godot-build-scripts](https://github.com/godotengine/godot-build-scripts).
4949

@@ -53,39 +53,39 @@ You can then specify it in the `build.sh` of
5353
If you don't need to build all versions or you want to try with a single target OS first,
5454
you can comment out the corresponding lines from the script:
5555

56-
$podman_build -t godot-linux:${img_version} -f Dockerfile.linux . 2>&1 | tee logs/linux.log
57-
$podman_build -t godot-windows:${img_version} -f Dockerfile.windows . 2>&1 | tee logs/windows.log
58-
$podman_build -t godot-web:${img_version} -f Dockerfile.web . 2>&1 | tee logs/web.log
59-
$podman_build -t godot-android:${img_version} -f Dockerfile.android . 2>&1 | tee logs/android.log
56+
podman_build linux
57+
podman_build windows
58+
podman_build web
59+
podman_build android
6060
...
6161

6262

6363
## Image sizes
6464

6565
These are the expected container image sizes, so you can plan your disk usage in advance:
6666

67-
REPOSITORY TAG SIZE
68-
localhost/godot-fedora 4.x-f36 1.06 GB
69-
localhost/godot-linux 4.x-f36 2.07 GB
70-
localhost/godot-windows 4.x-f36 1.81 GB
71-
localhost/godot-web 4.x-f36 2.2 GB
72-
localhost/godot-android 4.x-f36 4.24 GB
73-
localhost/godot-osx 4.x-f36 4.56 GB
74-
localhost/godot-ios 4.x-f36 5.01 GB
67+
REPOSITORY TAG SIZE
68+
localhost/godot-fedora 4.x-f39 1.08 GB
69+
localhost/godot-linux 4.x-f39 2.10 GB
70+
localhost/godot-windows 4.x-f39 1.89 GB
71+
localhost/godot-web 4.x-f39 2.24 GB
72+
localhost/godot-android 4.x-f39 3.67 GB
73+
localhost/godot-osx 4.x-f39 4.70 GB
74+
localhost/godot-ios 4.x-f39 5.30 GB
7575

7676
In addition to this, generating containers will also require some host disk space
77-
(around 10 GB) for the dependencies (Xcode).
77+
(up to 10 GB) for the dependencies (Xcode).
7878

7979

8080
## Toolchains
8181

82-
These are the toolchains currently in use for Godot 4.0 and later:
82+
These are the toolchains currently in use for Godot 4.2 and later:
8383

84-
- Base image: Fedora 36
85-
- SCons: 4.4.0
84+
- Base image: Fedora 39
85+
- SCons: 4.5.2
8686
- Linux: GCC 10.2.0 built against glibc 2.19, binutils 2.35.1, from our own [Linux SDK](https://github.com/godotengine/buildroot)
87-
- Windows: MinGW 9.0.0, GCC 11.2.0, binutils 2.37
88-
- Web: Emscripten 3.1.18
89-
- Android: Android NDK 23.2.8568313, build-tools 32.0.0, platform android-32, CMake 3.18.1
90-
- macOS: Xcode 13.3.1 with LLVM Clang 13.0.1, MacOSX SDK 12.3
91-
- iOS: Xcode 13.3.1 with LLVM Clang 13.0.1, iPhoneOS SDK 15.4
87+
- Windows: MinGW 11.0.0, GCC 13.2.1, binutils 2.40
88+
- Web: Emscripten 3.1.39
89+
- Android: Android NDK 23.2.8568313, build-tools 33.0.2, platform android-33, CMake 3.22.1, JDK 17
90+
- macOS: Xcode 15.0 with Apple Clang (LLVM 16.0.0), MacOSX SDK 14.0
91+
- iOS: Xcode 15.0 with Apple Clang (LLVM 16.0.0), iPhoneOS SDK 17.0

build.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ source $basedir/setup.sh
77
if [ -z "$1" -o -z "$2" ]; then
88
echo "Usage: $0 <godot branch> <base distro>"
99
echo
10-
echo "Example: $0 3.x f35"
10+
echo "Example: $0 4.x f39"
1111
echo
1212
echo "godot branch:"
1313
echo " Informational, tracks the Godot branch these containers are intended for."
@@ -58,9 +58,9 @@ podman_build windows
5858
podman_build web
5959
podman_build android
6060

61-
XCODE_SDK=14.1
62-
OSX_SDK=13.0
63-
IOS_SDK=16.1
61+
XCODE_SDK=15
62+
OSX_SDK=14.0
63+
IOS_SDK=17.0
6464
if [ ! -e "${files_root}"/MacOSX${OSX_SDK}.sdk.tar.xz ] || [ ! -e "${files_root}"/iPhoneOS${IOS_SDK}.sdk.tar.xz ] || [ ! -e "${files_root}"/iPhoneSimulator${IOS_SDK}.sdk.tar.xz ]; then
6565
if [ ! -e "${files_root}"/Xcode_${XCODE_SDK}.xip ]; then
6666
echo "files/Xcode_${XCODE_SDK}.xip is required. It can be downloaded from https://developer.apple.com/download/more/ with a valid apple ID."

0 commit comments

Comments
 (0)