mirror of
https://github.com/godotengine/godot-build-scripts.git
synced 2025-12-31 05:48:35 +03:00
Compare commits
266 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9d9b8f80f3 | ||
|
|
7126657c58 | ||
|
|
fd3bd4ad89 | ||
|
|
38f2a5e351 | ||
|
|
8f39b6a9cb | ||
|
|
9fbd2dbc44 | ||
|
|
d72076547a | ||
|
|
33d44ce966 | ||
|
|
f17aad663b | ||
|
|
4ffb22bfd7 | ||
|
|
a08918cf61 | ||
|
|
dd9cf6163a | ||
|
|
f1439e80e1 | ||
|
|
dbe21464e8 | ||
|
|
84d8bf774a | ||
|
|
6224c714c9 | ||
|
|
5b0684d8fb | ||
|
|
1012966dbb | ||
|
|
2c4962d347 | ||
|
|
fb6991e3c0 | ||
|
|
11046692e1 | ||
|
|
7cc22b8254 | ||
|
|
e7412b53cd | ||
|
|
f8e8e20da2 | ||
|
|
d95bc9b24c | ||
|
|
7b2ea29c50 | ||
|
|
3e4ab70d3c | ||
|
|
b1cf9b6095 | ||
|
|
74e21311a4 | ||
|
|
6d05bde764 | ||
|
|
05a4bfed90 | ||
|
|
38dbce0679 | ||
|
|
8c9fd0328b | ||
|
|
7a89e9087d | ||
|
|
6cc1418b6b | ||
|
|
3a34cfa1bc | ||
|
|
36d2cc32d6 | ||
|
|
95ed6d23db | ||
|
|
3348432f38 | ||
|
|
73402a1c9f | ||
|
|
d831be12a8 | ||
|
|
44992c6c76 | ||
|
|
d2e5eab17c | ||
|
|
fb34c3ff3e | ||
|
|
e2e01f05df | ||
|
|
c9f1d801ae | ||
|
|
7cfa88aaaf | ||
|
|
c9d351ab67 | ||
|
|
e7210ecc92 | ||
|
|
5e3a9b9cdc | ||
|
|
b4613cec24 | ||
|
|
bf0dd1992c | ||
|
|
1e4dc88253 | ||
|
|
8c176b460b | ||
|
|
e0891e9fde | ||
|
|
251cea182e | ||
|
|
9259edf571 | ||
|
|
cc7ca0f706 | ||
|
|
5f48331f5d | ||
|
|
fa404f8c17 | ||
|
|
d808ce84ce | ||
|
|
c3d199c4d4 | ||
|
|
629090d76e | ||
|
|
834f6223d8 | ||
|
|
1bf0772565 | ||
|
|
7131e406ae | ||
|
|
62a88ec262 | ||
|
|
0c96c1ea15 | ||
|
|
c3f202946a | ||
|
|
3cb13f27ea | ||
|
|
d99668ccaa | ||
|
|
a29f0a255d | ||
|
|
d36a865ff1 | ||
|
|
15810984ed | ||
|
|
a79a7d16ce | ||
|
|
b3ba0ae932 | ||
|
|
232be2e47f | ||
|
|
0f11496664 | ||
|
|
e321eca2bf | ||
|
|
ef6c745075 | ||
|
|
3fd3880077 | ||
|
|
0da7793d2d | ||
|
|
9bba647a8b | ||
|
|
ceadb16e22 | ||
|
|
ee35cb71ca | ||
|
|
f8a41bc69f | ||
|
|
2398d61b29 | ||
|
|
96b8f89a22 | ||
|
|
09b9dcf969 | ||
|
|
7b9e4271f4 | ||
|
|
93d253330f | ||
|
|
65cca8165a | ||
|
|
be182f1ed7 | ||
|
|
2c7419a7ed | ||
|
|
ad9e3b238a | ||
|
|
9d40b39c01 | ||
|
|
066ede3602 | ||
|
|
75877451f2 | ||
|
|
02e092ce76 | ||
|
|
4863750c00 | ||
|
|
37938758d8 | ||
|
|
79967d5bb9 | ||
|
|
37876d4d40 | ||
|
|
9f25ceccfb | ||
|
|
21af2c7666 | ||
|
|
360fa39095 | ||
|
|
80ea8aadde | ||
|
|
0780ea4a4f | ||
|
|
72cb40ffad | ||
|
|
e3827e123c | ||
|
|
1dcd8b7985 | ||
|
|
ef964dc2a3 | ||
|
|
9ad27f9f92 | ||
|
|
b5240cd977 | ||
|
|
631c5d216e | ||
|
|
6d25f64f31 | ||
|
|
eecf436ac7 | ||
|
|
f95a42611b | ||
|
|
872c9bfe0e | ||
|
|
4e9ee976b2 | ||
|
|
e244d6f9e3 | ||
|
|
9080ead63c | ||
|
|
c996282abe | ||
|
|
4a37b8e5cb | ||
|
|
46773439b7 | ||
|
|
41f2a836cf | ||
|
|
f37caa728a | ||
|
|
9aa0cb9d3b | ||
|
|
0bd0362372 | ||
|
|
12627036d2 | ||
|
|
23187596fb | ||
|
|
36fc7fca83 | ||
|
|
2c6469a904 | ||
|
|
ccb6b90e0b | ||
|
|
dd1128fea0 | ||
|
|
409efd043a | ||
|
|
0bcbc8fca2 | ||
|
|
d68cf1a26e | ||
|
|
83b71cbf8b | ||
|
|
9973556e65 | ||
|
|
e544bb91dc | ||
|
|
0dc9509c1f | ||
|
|
0fe855cc72 | ||
|
|
edd1194d3f | ||
|
|
6463e8b60a | ||
|
|
8405945b79 | ||
|
|
b2aef95606 | ||
|
|
4c9e58d98f | ||
|
|
135ad22e07 | ||
|
|
26bb927614 | ||
|
|
81c1fa10ef | ||
|
|
a0675bb238 | ||
|
|
6ebf52fda5 | ||
|
|
8adfdd068e | ||
|
|
720b0fe6c0 | ||
|
|
d5ba16cc46 | ||
|
|
59559971b5 | ||
|
|
45abfae75f | ||
|
|
7ac3b65e39 | ||
|
|
a679b94dfc | ||
|
|
0d2393cf02 | ||
|
|
eca85cfe19 | ||
|
|
c2c68da015 | ||
|
|
bcd0bd19bc | ||
|
|
a2e4b98977 | ||
|
|
b801e7174c | ||
|
|
0cf003077e | ||
|
|
e11c111d4a | ||
|
|
b41396bb1a | ||
|
|
c3bde1260d | ||
|
|
6824ba765b | ||
|
|
f2e9922e2d | ||
|
|
ed20196ea5 | ||
|
|
7bfa40e79e | ||
|
|
295431f722 | ||
|
|
51b552afc1 | ||
|
|
ad0d6918ec | ||
|
|
fbe75b39bc | ||
|
|
63133b65a4 | ||
|
|
a2649d96d0 | ||
|
|
f6ddb4e192 | ||
|
|
2bdb21c164 | ||
|
|
a94d978de6 | ||
|
|
faba7ebc50 | ||
|
|
9f2d00d177 | ||
|
|
ba0aa611d5 | ||
|
|
2e84f0b015 | ||
|
|
162cced016 | ||
|
|
01bf08cd9b | ||
|
|
2d656c918b | ||
|
|
39d2591051 | ||
|
|
9d80bcad67 | ||
|
|
78d64f285a | ||
|
|
e0d7b61e0e | ||
|
|
55373a69fb | ||
|
|
e4c94535c7 | ||
|
|
236efef7aa | ||
|
|
365596d3f0 | ||
|
|
38be71ef26 | ||
|
|
6e1556cf2b | ||
|
|
8d9ed90058 | ||
|
|
2e2fa65c67 | ||
|
|
f40716e53e | ||
|
|
33c8511a37 | ||
|
|
f3a5097159 | ||
|
|
c371cddcb5 | ||
|
|
a5d0f200b2 | ||
|
|
e0da42acd5 | ||
|
|
6499c248c1 | ||
|
|
abe22bbfcb | ||
|
|
5bc7435255 | ||
|
|
2190e23987 | ||
|
|
37ecf63e62 | ||
|
|
0a5547b12c | ||
|
|
02510df163 | ||
|
|
21da21455b | ||
|
|
1dddb1fb3a | ||
|
|
7024ac71f9 | ||
|
|
6bee8dec2e | ||
|
|
cab5d6f3c8 | ||
|
|
8eae1668f5 | ||
|
|
74cc8c712c | ||
|
|
0d85e09ebd | ||
|
|
1bd06975a9 | ||
|
|
37d7666b7b | ||
|
|
fe6e7b1e4e | ||
|
|
744b520910 | ||
|
|
463b957716 | ||
|
|
c44015dcec | ||
|
|
9ddda05e01 | ||
|
|
046ad85d00 | ||
|
|
279085ccce | ||
|
|
4797f217f0 | ||
|
|
964f9ca78f | ||
|
|
7a413ea5ec | ||
|
|
4b05de4339 | ||
|
|
3a3777b4db | ||
|
|
e365a856d3 | ||
|
|
5167633b6a | ||
|
|
5a7ffb3722 | ||
|
|
4d8e6dcb49 | ||
|
|
7b2cf596dc | ||
|
|
313cd37206 | ||
|
|
c53fb590aa | ||
|
|
9176967e98 | ||
|
|
d93b0785a8 | ||
|
|
4e6b7462b6 | ||
|
|
ee823e5177 | ||
|
|
0341022b36 | ||
|
|
1da72c73c3 | ||
|
|
bb7dfba9e7 | ||
|
|
651e5be851 | ||
|
|
751b30283e | ||
|
|
3319757d9d | ||
|
|
b4e081345c | ||
|
|
930cdb67c7 | ||
|
|
b2b7bea05f | ||
|
|
340eba3966 | ||
|
|
4d14345d37 | ||
|
|
1f7430025d | ||
|
|
0ef67e8796 | ||
|
|
067d3f3a49 | ||
|
|
7b376804d7 | ||
|
|
77091a9872 | ||
|
|
84f058dd24 | ||
|
|
0c2d825451 |
20
.gitignore
vendored
20
.gitignore
vendored
@@ -1,15 +1,25 @@
|
||||
# User-specific configuration and signing key
|
||||
# User-specific configuration and signing keys
|
||||
config.sh
|
||||
*.jks
|
||||
*.pfx
|
||||
*.pkcs12
|
||||
/*.json
|
||||
|
||||
# Generated by build scripts
|
||||
angle/
|
||||
deps/
|
||||
git/
|
||||
mono-glue/
|
||||
godot.tar.gz
|
||||
godot*.tar.gz
|
||||
angle.7z
|
||||
|
||||
# Output
|
||||
mono/
|
||||
out/
|
||||
release-*/
|
||||
templates/
|
||||
releases/
|
||||
sha512sums/
|
||||
steam/
|
||||
tmp/
|
||||
web/
|
||||
|
||||
# macOS
|
||||
.DS_Store
|
||||
|
||||
19
LICENSE.txt
Normal file
19
LICENSE.txt
Normal file
@@ -0,0 +1,19 @@
|
||||
Copyright (c) 2019-2020 Godot Engine contributors.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
34
README.md
Normal file
34
README.md
Normal file
@@ -0,0 +1,34 @@
|
||||
# Godot in-container build scripts
|
||||
|
||||
Build scripts used for official Godot Engine releases using containers
|
||||
built from https://github.com/godotengine/build-containers
|
||||
|
||||
## Disclaimer
|
||||
|
||||
This repository is **not** intended for end users, and thus not
|
||||
supported. It's only public as a way to document our build workflow,
|
||||
and for anyone to use as reference for their own buildsystems.
|
||||
|
||||
We will eventually release a public build script that integrates all
|
||||
this in a simple and user-friendly interface.
|
||||
|
||||
## Usage
|
||||
|
||||
- Build containers using https://github.com/godotengine/build-containers
|
||||
- Copy `config.sh.in` as `config.sh` and configure it as you want.
|
||||
- Edit `build.sh` to properly reference those containers if local, or
|
||||
use `config.sh` to point to your own registry if you uploaded
|
||||
containers.
|
||||
- Build with `build.sh` (check `--help` for usage).
|
||||
- Package binaries with `build-release.sh` (check `--help` for usage).
|
||||
|
||||
Example that builds Godot 3.2-stable Classical (not Mono):
|
||||
```
|
||||
./build.sh -v 3.2-stable -g 3.2-stable -b classical
|
||||
./build-release.sh -v 3.2-stable -t 3.2.stable -b classical
|
||||
```
|
||||
|
||||
Again, this is intended for release managers and usability is not the
|
||||
main focus. Tweak the build scripts to match your own requirements if
|
||||
you want to use this until we provide a better, user-friendly
|
||||
interface.
|
||||
@@ -2,28 +2,25 @@
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
# Config
|
||||
|
||||
# Debug symbols are enabled for the Android builds so we can generate a separate debug symbols file.
|
||||
# Gradle will strip them out of the final artifacts.
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
|
||||
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
|
||||
export TERM=xterm
|
||||
export ANDROID_HOME=/root/
|
||||
export ANDROID_NDK_ROOT=/root/ndk-bundle/
|
||||
export OPTIONS=""
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
echo "Starting classical build for Android..."
|
||||
$SCONS platform=android android_arch=armv7 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=android android_arch=armv7 $OPTIONS tools=no target=release
|
||||
|
||||
$SCONS platform=android android_arch=arm64v8 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=android android_arch=arm64v8 $OPTIONS tools=no target=release
|
||||
|
||||
$SCONS platform=android android_arch=x86 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=android android_arch=x86 $OPTIONS tools=no target=release
|
||||
|
||||
$SCONS platform=android android_arch=x86_64 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=android android_arch=x86_64 $OPTIONS tools=no target=release
|
||||
|
||||
@@ -31,4 +28,8 @@ pushd platform/android/java
|
||||
./gradlew build
|
||||
popd
|
||||
|
||||
cp bin/*.apk /root/out
|
||||
mkdir -p /root/out/templates
|
||||
cp bin/android_debug.apk /root/out/templates/
|
||||
cp bin/android_release.apk /root/out/templates/
|
||||
|
||||
echo "Android build successful"
|
||||
|
||||
109
build-android/playstore_upload_script.py
Normal file
109
build-android/playstore_upload_script.py
Normal file
@@ -0,0 +1,109 @@
|
||||
import sys, socket
|
||||
from google.oauth2 import service_account
|
||||
from googleapiclient.discovery import build
|
||||
|
||||
PACKAGE_NAME = "org.godotengine.editor.v4"
|
||||
|
||||
def main(aab_path, nds_path, key_path, version_name):
|
||||
version_base = version_name.split("-")[0]
|
||||
version_parts = version_base.split(".")
|
||||
major = version_parts[0]
|
||||
minor = version_parts[1]
|
||||
patch = int(version_parts[2]) if len(version_parts) > 2 else 0
|
||||
channel = version_name.split("-")[1]
|
||||
|
||||
release_note = f"Godot Engine {version_name} has arrived!\nNote: This is a pre-release piece of software so be sure to make backups."
|
||||
track = "alpha"
|
||||
|
||||
if "stable" in channel:
|
||||
if patch == 0:
|
||||
release_url = f"https://godotengine.org/releases/{major}.{minor}/"
|
||||
else:
|
||||
release_url = f"https://godotengine.org/article/maintenance-release-godot-{major}-{minor}-{patch}/"
|
||||
release_note = f"Godot Engine {version_name} has arrived!\nRelease page: {release_url}"
|
||||
track = "beta"
|
||||
elif "rc" in channel:
|
||||
channel_url = channel.replace("rc", "rc-")
|
||||
if patch == 0:
|
||||
release_url = f"https://godotengine.org/article/release-candidate-godot-{major}-{minor}-{channel_url}/"
|
||||
else:
|
||||
release_url = f"https://godotengine.org/article/release-candidate-godot-{major}-{minor}-{patch}-{channel_url}/"
|
||||
release_note += f"\nRelease page: {release_url}"
|
||||
else:
|
||||
# No need to handle patch versions here: maintenance releases go straight to RC and stable.
|
||||
# There are no 4.5.1-dev or 4.5.1-beta builds.
|
||||
if "beta" in channel:
|
||||
channel_url = channel.replace("beta", "beta-")
|
||||
else:
|
||||
channel_url = channel.replace("dev", "dev-")
|
||||
release_url = f"https://godotengine.org/article/dev-snapshot-godot-{major}-{minor}-{channel_url}/"
|
||||
release_note += f"\nRelease page: {release_url}"
|
||||
|
||||
scopes = ["https://www.googleapis.com/auth/androidpublisher"]
|
||||
credentials = service_account.Credentials.from_service_account_file(key_path, scopes=scopes)
|
||||
|
||||
initial_timeout = socket.getdefaulttimeout()
|
||||
socket.setdefaulttimeout(900)
|
||||
service = build("androidpublisher", "v3", credentials=credentials)
|
||||
|
||||
print("Creating a new edit")
|
||||
edit = service.edits().insert(body={}, packageName=PACKAGE_NAME).execute()
|
||||
edit_id = edit["id"]
|
||||
|
||||
print(f"Uploading {aab_path}")
|
||||
bundle_response = service.edits().bundles().upload(
|
||||
editId=edit_id,
|
||||
packageName=PACKAGE_NAME,
|
||||
media_body=aab_path,
|
||||
media_mime_type="application/octet-stream"
|
||||
).execute()
|
||||
|
||||
version_code = bundle_response["versionCode"]
|
||||
print(f"Uploaded AAB with versionCode: {version_code}")
|
||||
|
||||
print(f"Uploading native debug symbols {nds_path}")
|
||||
service.edits().deobfuscationfiles().upload(
|
||||
editId=edit_id,
|
||||
packageName=PACKAGE_NAME,
|
||||
apkVersionCode=version_code,
|
||||
deobfuscationFileType="nativeCode",
|
||||
media_body=nds_path,
|
||||
media_mime_type="application/octet-stream"
|
||||
).execute()
|
||||
|
||||
release_name = f"v{version_name} ({version_code})"
|
||||
print(f"Assigning {release_name} to {track} track")
|
||||
|
||||
service.edits().tracks().update(
|
||||
editId=edit_id,
|
||||
packageName=PACKAGE_NAME,
|
||||
track=track,
|
||||
body={
|
||||
"releases": [{
|
||||
"name": release_name,
|
||||
"versionCodes": [str(version_code)],
|
||||
"status": "completed",
|
||||
"releaseNotes": [{
|
||||
"language": "en-US",
|
||||
"text": release_note
|
||||
}]
|
||||
}]
|
||||
}
|
||||
).execute()
|
||||
|
||||
service.edits().commit(editId=edit_id, packageName=PACKAGE_NAME).execute()
|
||||
print("Release uploaded and published successfully!")
|
||||
socket.setdefaulttimeout(initial_timeout)
|
||||
|
||||
if __name__ == "__main__":
|
||||
if len(sys.argv) != 5:
|
||||
print("Usage: python3 upload_playstore.py <aab-path> <native-debug-symbols-path> <json-key-path> <version-name>")
|
||||
print("version-name format: <major>.<minor>[.<patch>]-<channel> (e.g. 4.4.1-stable, 4.5-stable, 4.6-dev1)")
|
||||
sys.exit(1)
|
||||
|
||||
aab_path = sys.argv[1]
|
||||
nds_path = sys.argv[2]
|
||||
key_path = sys.argv[3]
|
||||
version_name = sys.argv[4]
|
||||
|
||||
main(aab_path, nds_path, key_path, version_name)
|
||||
18
build-android/upload-mavencentral.sh
Executable file
18
build-android/upload-mavencentral.sh
Executable file
@@ -0,0 +1,18 @@
|
||||
#/bin/bash
|
||||
|
||||
basedir="$(pwd)"
|
||||
|
||||
if [ ! -d "${basedir}/deps/keystore" ]; then
|
||||
echo "Couldn't find ${basedir}/deps/keystore. Make sure to run this from the root folder of the Git repository."
|
||||
fi
|
||||
|
||||
source ${basedir}/deps/keystore/config.sh
|
||||
|
||||
# Release the Godot Android library to MavenCentral
|
||||
${PODMAN} run -it --rm \
|
||||
-v ${basedir}/out/android/source:/root/godot -v ${basedir}/deps/keystore:/root/keystore \
|
||||
localhost/godot-android:${IMAGE_VERSION} bash -c \
|
||||
"source /root/keystore/config.sh && \
|
||||
cp -r /root/godot/.gradle /root && \
|
||||
cd /root/godot/platform/android/java && \
|
||||
./gradlew publishAllPublicationToSonatypeRepository --max-workers 1 closeAndReleaseSonatypeStagingRepository"
|
||||
29
build-android/upload-playstore.sh
Executable file
29
build-android/upload-playstore.sh
Executable file
@@ -0,0 +1,29 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ "$#" -ne 1 ]; then
|
||||
echo "Usage: $0 <version-name>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
VERSION_NAME="$1"
|
||||
|
||||
BASEDIR="$(pwd)"
|
||||
|
||||
source ${BASEDIR}/config.sh
|
||||
|
||||
VENV_DIR="${BASEDIR}/venv"
|
||||
PYTHON_SCRIPT="${BASEDIR}/build-android/playstore_upload_script.py"
|
||||
AAB_FILE="${BASEDIR}/out/android/tools/android_editor.aab"
|
||||
NDS_FILE="${BASEDIR}/out/android/tools/android_editor_native_debug_symbols.zip"
|
||||
JSON_KEY_FILE="${BASEDIR}/${GODOT_ANDROID_UPLOAD_JSON_KEY}"
|
||||
|
||||
echo "Creating virtual environment"
|
||||
rm -rf "$VENV_DIR"
|
||||
python3 -m venv "$VENV_DIR"
|
||||
source "$VENV_DIR/bin/activate"
|
||||
|
||||
echo "Installing google-api-python-client"
|
||||
pip install --upgrade google-api-python-client
|
||||
|
||||
echo "Uploading editor to Google Play Store..."
|
||||
python3 "$PYTHON_SCRIPT" "$AAB_FILE" "$NDS_FILE" "$JSON_KEY_FILE" "$VERSION_NAME"
|
||||
@@ -2,36 +2,24 @@
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
# Config
|
||||
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export IOS_SDK="11.2"
|
||||
export OPTIONS="osxcross_sdk=darwin15 builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes"
|
||||
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
|
||||
export TERM=xterm
|
||||
export OSXCROSS_IOS=not_nothing
|
||||
export IOS_SDK="18.5"
|
||||
export IOS_OPTIONS_ARM64="SDKVERSION=${IOS_SDK} ios_triple=arm-apple-darwin11- IPHONEPATH=/root/ioscross/arm64/ IPHONESDK=/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk/"
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=arm tools=no target=release_debug IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
|
||||
echo "Starting classical build for iOS..."
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=arm tools=no target=release IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
|
||||
# arm64 device
|
||||
$SCONS platform=iphone $IOS_OPTIONS_ARM64 arch=arm64 tools=no target=release_debug
|
||||
$SCONS platform=iphone $IOS_OPTIONS_ARM64 arch=arm64 tools=no target=release
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=arm64 tools=no target=release_debug IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=arm64 tools=no target=release IPHONESDK="/root/ioscross/arm64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/arm64/" ios_triple="arm-apple-darwin11-"
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=x86 tools=no target=release_debug IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=x86 tools=no target=release IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=x86_64 tools=no target=release_debug IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
|
||||
|
||||
$SCONS platform=iphone $OPTIONS arch=x86_64 tools=no target=release IPHONESDK="/root/ioscross/x86_64/SDK/iPhoneOS${IOS_SDK}.sdk" IPHONEPATH="/root/ioscross/x86_64/" ios_triple="x86_64-apple-darwin11-"
|
||||
|
||||
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot.iphone.opt.arm.a bin/libgodot.iphone.opt.arm64.a bin/libgodot.iphone.opt.x86.a bin/libgodot.iphone.opt.x86_64.a -output /root/out/libgodot.iphone.opt.fat
|
||||
/root/ioscross/arm64/bin/arm-apple-darwin11-lipo -create bin/libgodot.iphone.opt.debug.arm.a bin/libgodot.iphone.opt.debug.arm64.a bin/libgodot.iphone.opt.debug.x86.a bin/libgodot.iphone.opt.debug.x86_64.a -output /root/out/libgodot.iphone.opt.debug.fat
|
||||
mkdir -p /root/out/templates
|
||||
cp bin/godot.iphone.*.arm64 /root/out/templates/
|
||||
|
||||
echo "iOS build successful"
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
|
||||
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
|
||||
export TERM=xterm
|
||||
|
||||
source /root/emsdk/emsdk_env.sh
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
$SCONS platform=javascript ${OPTIONS} target=release_debug tools=no
|
||||
$SCONS platform=javascript ${OPTIONS} target=release tools=no
|
||||
|
||||
cp -rvp bin/* /root/out/
|
||||
@@ -2,42 +2,56 @@
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
# Config
|
||||
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
|
||||
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
|
||||
export TERM=xterm
|
||||
export MONO32_PREFIX=/usr
|
||||
export MONO64_PREFIX=/usr
|
||||
export CC="gcc-8"
|
||||
export CXX="g++-8"
|
||||
export OPTIONS="use_static_cpp=yes"
|
||||
export STRIP="strip"
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
cp /root/mono-glue/*.cpp modules/mono/glue
|
||||
echo "Starting classical build for Linux..."
|
||||
|
||||
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=yes target=release_debug
|
||||
mkdir -p /root/out/tools
|
||||
cp -rvp bin/* /root/out/tools
|
||||
export PATH="${GODOT_SDK_LINUX_X86_64}/bin:${BASE_PATH}"
|
||||
|
||||
$SCONS platform=x11 bits=64 $OPTIONS tools=yes target=release_debug
|
||||
$STRIP bin/godot.x11.*
|
||||
mkdir -p /root/out/x86_64/tools
|
||||
cp -rvp bin/* /root/out/x86_64/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS tools=no target=release
|
||||
mkdir -p /root/out/templates
|
||||
cp -rvp bin/* /root/out/templates
|
||||
$SCONS platform=x11 bits=64 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=x11 bits=64 $OPTIONS tools=no target=release
|
||||
$STRIP bin/godot.x11.*
|
||||
mkdir -p /root/out/x86_64/templates
|
||||
cp -rvp bin/* /root/out/x86_64/templates
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
|
||||
mkdir -p /root/out/tools-mono
|
||||
cp -rvp bin/* /root/out/tools-mono
|
||||
export PATH="${GODOT_SDK_LINUX_X86_32}/bin:${BASE_PATH}"
|
||||
|
||||
$SCONS platform=x11 bits=32 $OPTIONS tools=yes target=release_debug
|
||||
$STRIP bin/godot.x11.*
|
||||
mkdir -p /root/out/x86_32/tools
|
||||
cp -rvp bin/* /root/out/x86_32/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=no target=release_debug
|
||||
$SCONS platform=x11 CC=$CC CXX=$CXX $OPTIONS $OPTIONS_MONO tools=no target=release
|
||||
mkdir -p /root/out/templates-mono
|
||||
cp -rvp bin/* /root/out/templates-mono
|
||||
$SCONS platform=x11 bits=32 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=x11 bits=32 $OPTIONS tools=no target=release
|
||||
$STRIP bin/godot.x11.*
|
||||
mkdir -p /root/out/x86_32/templates
|
||||
cp -rvp bin/* /root/out/x86_32/templates
|
||||
rm -rf bin
|
||||
|
||||
export PATH="${GODOT_SDK_LINUX_X86_64}/bin:${BASE_PATH}"
|
||||
|
||||
$SCONS platform=server bits=64 $OPTIONS tools=yes target=release_debug
|
||||
mkdir -p /root/out/x86_64/server
|
||||
cp -rvp bin/* /root/out/x86_64/server
|
||||
rm -rf bin
|
||||
|
||||
export PATH="${BASE_PATH}"
|
||||
|
||||
echo "Linux build successful"
|
||||
|
||||
31
build-macos/build.sh
Executable file
31
build-macos/build.sh
Executable file
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
# Config
|
||||
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="osxcross_sdk=darwin24.5"
|
||||
export STRIP="x86_64-apple-darwin24.5-strip"
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
echo "Starting classical build for macOS..."
|
||||
|
||||
$SCONS platform=osx $OPTIONS bits=64 tools=yes target=release_debug
|
||||
$STRIP bin/godot.osx.*
|
||||
mkdir -p /root/out/tools
|
||||
cp -rvp bin/* /root/out/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=osx $OPTIONS bits=64 tools=no target=release_debug
|
||||
$SCONS platform=osx $OPTIONS bits=64 tools=no target=release
|
||||
$STRIP bin/godot.osx.*
|
||||
mkdir -p /root/out/templates
|
||||
cp -rvp bin/* /root/out/templates
|
||||
rm -rf bin
|
||||
|
||||
echo "macOS build successful"
|
||||
@@ -1,49 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="osxcross_sdk=darwin17 builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
|
||||
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
|
||||
export TERM=xterm
|
||||
export MONO64_PREFIX=/root/dependencies/mono
|
||||
export PATH=/root/osxcross/target/bin:$PATH
|
||||
export OSXCROSS_ROOT=/root/osxcross
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
cp /root/mono-glue/*.cpp modules/mono/glue
|
||||
|
||||
$SCONS platform=osx $OPTIONS tools=yes target=release_debug
|
||||
|
||||
mkdir -p /root/out/tools
|
||||
cp -rvp bin/* /root/out/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=osx $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=osx $OPTIONS tools=no target=release
|
||||
|
||||
mkdir -p /root/out/templates
|
||||
cp -rvp bin/* /root/out/templates
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
|
||||
|
||||
mkdir -p /root/out/tools-mono
|
||||
cp -rvp bin/* /root/out/tools-mono
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=no target=release_debug
|
||||
$SCONS platform=osx $OPTIONS $OPTIONS_MONO tools=no target=release
|
||||
|
||||
mkdir -p /root/out/templates-mono
|
||||
cp -rvp bin/* /root/out/templates-mono
|
||||
rm -rf bin
|
||||
|
||||
find /root/out -name config -exec cp /root/dependencies/mono/etc/config {} \;
|
||||
|
||||
echo "MacOS build successful"
|
||||
@@ -1,24 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no"
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export TERM=xterm
|
||||
export MONO32_PREFIX=/usr
|
||||
export MONO64_PREFIX=/usr
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf ../godot.tar.gz --strip-components=1
|
||||
|
||||
${SCONS} platform=x11 bits=64 ${OPTIONS} target=release_debug tools=yes module_mono_enabled=yes mono_glue=no
|
||||
xvfb-run bin/godot.x11.opt.tools.64.mono --generate-mono-glue /root/mono-glue || /bin/true
|
||||
|
||||
xvfb-run bin/godot.x11.opt.tools.64.mono --generate-cs-api /tmp/build_GodotSharp || /bin/true
|
||||
xvfb-run msbuild /tmp/build_GodotSharp/GodotSharp.sln /p:Configuration=Release
|
||||
mkdir -p /root/mono-glue/Api
|
||||
cp -r /tmp/build_GodotSharp/GodotSharp/bin/Release/{GodotSharp.dll,GodotSharp.pdb,GodotSharp.xml} /root/mono-glue/Api
|
||||
cp -r /tmp/build_GodotSharp/GodotSharpEditor/bin/Release/{GodotSharpEditor.dll,GodotSharpEditor.pdb,GodotSharpEditor.xml} /root/mono-glue/Api
|
||||
553
build-release.sh
553
build-release.sh
@@ -1,327 +1,286 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
export basedir=$(pwd)
|
||||
|
||||
if [ -z $1 ]; then
|
||||
echo "Usage: $0 <version>"
|
||||
echo " For example: $0 3.0.3-rc3"
|
||||
echo ""
|
||||
exit 1
|
||||
fi
|
||||
# Log output to a file automatically.
|
||||
exec > >(tee -a "out/logs/build-release") 2>&1
|
||||
|
||||
# Config
|
||||
|
||||
# For signing keystore and password.
|
||||
source ./config.sh
|
||||
|
||||
can_sign=0
|
||||
if [ ! -z "${SIGN_KEYSTORE}" ] && [ ! -z "${SIGN_PASSWORD}" ]; then
|
||||
can_sign=1
|
||||
can_sign_windows=0
|
||||
if [ ! -z "${WINDOWS_SIGN_NAME}" ] && [ ! -z "${WINDOWS_SIGN_URL}" ] && [[ $(type -P "osslsigncode") ]]; then
|
||||
can_sign_windows=1
|
||||
else
|
||||
echo "Disabling binary signing as config.sh does not define the required data."
|
||||
echo "Disabling Windows binary signing as config.sh does not define the required data (WINDOWS_SIGN_NAME, WINDOWS_SIGN_URL), or osslsigncode can't be found in PATH."
|
||||
fi
|
||||
|
||||
function sign {
|
||||
if [ $can_sign == 0 ]; then
|
||||
sign_windows() {
|
||||
if [ $can_sign_windows == 0 ]; then
|
||||
return
|
||||
fi
|
||||
./osslsigncode -pkcs12 ${SIGN_KEYSTORE} -pass "${SIGN_PASSWORD}" -n "${SIGN_NAME}" -i "${SIGN_URL}" -t http://timestamp.comodoca.com -in $1 -out $1-signed
|
||||
P11_KIT_SERVER_ADDRESS=unix:path=/run/p11-kit/p11kit.sock osslsigncode sign -pkcs11module /usr/lib64/pkcs11/p11-kit-client.so -pkcs11cert 'pkcs11:model=SimplySign%20C' -key 'pkcs11:model=SimplySign%20C' -t http://time.certum.pl/ -n "${WINDOWS_SIGN_NAME}" -i "${WINDOWS_SIGN_URL}" -in $1 -out $1-signed
|
||||
mv $1-signed $1
|
||||
}
|
||||
|
||||
export GODOT_VERSION=$1
|
||||
sign_macos() {
|
||||
if [ -z "${OSX_HOST}" ]; then
|
||||
return
|
||||
fi
|
||||
_macos_tmpdir=$(ssh "${OSX_HOST}" "mktemp -d")
|
||||
_reldir="$1"
|
||||
_binname="$2"
|
||||
_appname="Godot.app"
|
||||
|
||||
scp "${_reldir}/${_binname}.zip" "${OSX_HOST}:${_macos_tmpdir}"
|
||||
ssh "${OSX_HOST}" "
|
||||
cd ${_macos_tmpdir} && \
|
||||
unzip ${_binname}.zip && \
|
||||
codesign --force --timestamp \
|
||||
--options=runtime \
|
||||
-s ${OSX_KEY_ID} -v ${_appname} && \
|
||||
zip -r ${_binname}_signed.zip ${_appname}"
|
||||
|
||||
_request_uuid=$(ssh "${OSX_HOST}" "xcrun notarytool submit ${_macos_tmpdir}/${_binname}_signed.zip --team-id \"${APPLE_TEAM}\" --apple-id \"${APPLE_ID}\" --password \"${APPLE_ID_PASSWORD}\" --no-progress --output-format json")
|
||||
_request_uuid=$(echo ${_request_uuid} | sed -e 's/.*"id":"\([^"]*\)".*/\1/')
|
||||
if ! ssh "${OSX_HOST}" "xcrun notarytool wait ${_request_uuid} --team-id \"${APPLE_TEAM}\" --apple-id \"${APPLE_ID}\" --password \"${APPLE_ID_PASSWORD}\" | grep -q status:\ Accepted"; then
|
||||
echo "Notarization failed."
|
||||
_notarization_log=$(ssh "${OSX_HOST}" "xcrun notarytool log ${_request_uuid} --team-id \"${APPLE_TEAM}\" --apple-id \"${APPLE_ID}\" --password \"${APPLE_ID_PASSWORD}\"")
|
||||
echo "${_notarization_log}"
|
||||
ssh "${OSX_HOST}" "rm -rf ${_macos_tmpdir}"
|
||||
exit 1
|
||||
else
|
||||
ssh "${OSX_HOST}" "
|
||||
cd ${_macos_tmpdir} && \
|
||||
xcrun stapler staple ${_appname} && \
|
||||
zip -r ${_binname}_stapled.zip ${_appname}"
|
||||
scp "${OSX_HOST}:${_macos_tmpdir}/${_binname}_stapled.zip" "${_reldir}/${_binname}.zip"
|
||||
ssh "${OSX_HOST}" "rm -rf ${_macos_tmpdir}"
|
||||
fi
|
||||
}
|
||||
|
||||
sign_macos_template() {
|
||||
if [ -z "${OSX_HOST}" ]; then
|
||||
return
|
||||
fi
|
||||
_macos_tmpdir=$(ssh "${OSX_HOST}" "mktemp -d")
|
||||
_reldir="$1"
|
||||
|
||||
scp "${_reldir}/osx.zip" "${OSX_HOST}:${_macos_tmpdir}"
|
||||
ssh "${OSX_HOST}" "
|
||||
cd ${_macos_tmpdir} && \
|
||||
unzip osx.zip && \
|
||||
codesign --force -s - \
|
||||
--options=linker-signed \
|
||||
-v osx_template.app/Contents/MacOS/* && \
|
||||
zip -r osx_signed.zip osx_template.app"
|
||||
|
||||
scp "${OSX_HOST}:${_macos_tmpdir}/osx_signed.zip" "${_reldir}/osx.zip"
|
||||
ssh "${OSX_HOST}" "rm -rf ${_macos_tmpdir}"
|
||||
}
|
||||
|
||||
godot_version=""
|
||||
templates_version=""
|
||||
do_cleanup=1
|
||||
make_tarball=1
|
||||
build_classical=1
|
||||
|
||||
while getopts "h?v:t:b:n-:" opt; do
|
||||
case "$opt" in
|
||||
h|\?)
|
||||
echo "Usage: $0 [OPTIONS...]"
|
||||
echo
|
||||
echo " -v godot version (e.g: 3.2-stable) [mandatory]"
|
||||
echo " -t templates version (e.g. 3.2.stable) [mandatory]"
|
||||
echo " -b build target: classical|none (default: classical)"
|
||||
echo " --no-cleanup disable deleting pre-existing output folders (default: false)"
|
||||
echo " --no-tarball disable generating source tarball (default: false)"
|
||||
echo
|
||||
exit 1
|
||||
;;
|
||||
v)
|
||||
godot_version=$OPTARG
|
||||
;;
|
||||
t)
|
||||
templates_version=$OPTARG
|
||||
;;
|
||||
b)
|
||||
if [ "$OPTARG" == "classical" ]; then
|
||||
build_classical=1
|
||||
elif [ "$OPTARG" == "none" ]; then
|
||||
build_classical=0
|
||||
fi
|
||||
;;
|
||||
-)
|
||||
case "${OPTARG}" in
|
||||
no-cleanup)
|
||||
do_cleanup=0
|
||||
;;
|
||||
no-tarball)
|
||||
make_tarball=0
|
||||
;;
|
||||
*)
|
||||
if [ "$OPTERR" == 1 ] && [ "${optspec:0:1}" != ":" ]; then
|
||||
echo "Unknown option --${OPTARG}."
|
||||
exit 1
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ -z "${godot_version}" -o -z "${templates_version}" ]; then
|
||||
echo "Mandatory argument -v or -t missing."
|
||||
exit 1
|
||||
elif [[ "{$templates_version}" == *"-"* ]]; then
|
||||
echo "Templates version (-t) shouldn't contain '-'. It should use a dot to separate version from status."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
export reldir="${basedir}/releases/${godot_version}"
|
||||
export tmpdir="${basedir}/tmp"
|
||||
export templatesdir="${tmpdir}/templates"
|
||||
|
||||
export godot_basename="Godot_v${godot_version}"
|
||||
|
||||
# Cleanup and setup
|
||||
|
||||
if [ "${do_cleanup}" == "1" ]; then
|
||||
|
||||
rm -rf ${reldir}
|
||||
rm -rf ${tmpdir}
|
||||
|
||||
mkdir -p ${reldir}
|
||||
mkdir -p ${templatesdir}
|
||||
|
||||
fi
|
||||
|
||||
# Tarball
|
||||
|
||||
mkdir -p release-${GODOT_VERSION}
|
||||
rm -rf release-${GODOT_VERSION}/*.xz release-${GODOT_VERSION}/*.sha256
|
||||
zcat godot.tar.gz | xz -c > release-${GODOT_VERSION}/godot-${GODOT_VERSION}.tar.xz
|
||||
sha256sum release-${GODOT_VERSION}/godot-${GODOT_VERSION}.tar.xz > release-${GODOT_VERSION}/godot-${GODOT_VERSION}.tar.xz.sha256
|
||||
if [ "${make_tarball}" == "1" ]; then
|
||||
|
||||
# Linux 64
|
||||
zcat godot-${godot_version}.tar.gz | xz -c > ${reldir}/godot-${godot_version}.tar.xz
|
||||
pushd ${reldir}
|
||||
sha256sum godot-${godot_version}.tar.xz > godot-${godot_version}.tar.xz.sha256
|
||||
popd
|
||||
|
||||
mkdir -p templates
|
||||
rm -f templates/linux_x11_64*
|
||||
|
||||
cp out/linux/x64/templates/godot.x11.opt.debug.64 templates/linux_x11_64_debug
|
||||
cp out/linux/x64/templates/godot.x11.opt.64 templates/linux_x11_64_release
|
||||
|
||||
mkdir -p release-${GODOT_VERSION}
|
||||
rm -f release-${GODOT_VERSION}/*linux*64*
|
||||
|
||||
cp out/linux/x64/tools/godot.x11.opt.tools.64 Godot_v${GODOT_VERSION}_x11.64
|
||||
zip -q -9 Godot_v${GODOT_VERSION}_x11.64.zip Godot_v${GODOT_VERSION}_x11.64
|
||||
mv Godot_v${GODOT_VERSION}_x11.64.zip release-${GODOT_VERSION}
|
||||
rm Godot_v${GODOT_VERSION}_x11.64
|
||||
|
||||
mkdir -p mono/release-${GODOT_VERSION}
|
||||
rm -rf mono/release-${GODOT_VERSION}/*linux*64*
|
||||
|
||||
mkdir -p Godot_v${GODOT_VERSION}_mono_x11_64
|
||||
cp out/linux/x64/tools-mono/godot.x11.opt.tools.64.mono Godot_v${GODOT_VERSION}_mono_x11_64/Godot_v${GODOT_VERSION}_mono_x11.64
|
||||
cp -rp out/linux/x64/tools-mono/GodotSharp Godot_v${GODOT_VERSION}_mono_x11_64
|
||||
cp -rp mono-glue/Api Godot_v${GODOT_VERSION}_mono_x11_64/GodotSharp/Api
|
||||
zip -r -q -9 Godot_v${GODOT_VERSION}_mono_x11_64.zip Godot_v${GODOT_VERSION}_mono_x11_64
|
||||
mv Godot_v${GODOT_VERSION}_mono_x11_64.zip mono/release-${GODOT_VERSION}
|
||||
rm -rf Godot_v${GODOT_VERSION}_mono_x11_64
|
||||
|
||||
mkdir -p mono/templates
|
||||
rm -rf mono/templates/*linux*64*
|
||||
|
||||
cp -rp out/linux/x64/templates-mono/data.mono.x11.64.* mono/templates/
|
||||
cp out/linux/x64/templates-mono/godot.x11.opt.debug.64.mono mono/templates/linux_x11_64_debug
|
||||
cp out/linux/x64/templates-mono/godot.x11.opt.64.mono mono/templates/linux_x11_64_release
|
||||
|
||||
# Linux 32
|
||||
|
||||
mkdir -p templates
|
||||
rm -f templates/linux_x11_32*
|
||||
|
||||
cp out/linux/x86/templates/godot.x11.opt.debug.32 templates/linux_x11_32_debug
|
||||
cp out/linux/x86/templates/godot.x11.opt.32 templates/linux_x11_32_release
|
||||
|
||||
mkdir -p release-${GODOT_VERSION}
|
||||
rm -f release-${GODOT_VERSION}/*linux*32*
|
||||
|
||||
cp out/linux/x86/tools/godot.x11.opt.tools.32 Godot_v${GODOT_VERSION}_x11.32
|
||||
zip -q -9 Godot_v${GODOT_VERSION}_x11.32.zip Godot_v${GODOT_VERSION}_x11.32
|
||||
mv Godot_v${GODOT_VERSION}_x11.32.zip release-${GODOT_VERSION}
|
||||
rm Godot_v${GODOT_VERSION}_x11.32
|
||||
|
||||
mkdir -p mono/release-${GODOT_VERSION}
|
||||
rm -rf mono/release-${GODOT_VERSION}/*linux*32*
|
||||
|
||||
mkdir -p Godot_v${GODOT_VERSION}_mono_x11_32
|
||||
cp out/linux/x86/tools-mono/godot.x11.opt.tools.32.mono Godot_v${GODOT_VERSION}_mono_x11_32/Godot_v${GODOT_VERSION}_mono_x11.32
|
||||
cp -rp out/linux/x86/tools-mono/GodotSharp/ Godot_v${GODOT_VERSION}_mono_x11_32
|
||||
cp -rp mono-glue/Api Godot_v${GODOT_VERSION}_mono_x11_32/GodotSharp/Api
|
||||
zip -r -q -9 Godot_v${GODOT_VERSION}_mono_x11_32.zip Godot_v${GODOT_VERSION}_mono_x11_32
|
||||
mv Godot_v${GODOT_VERSION}_mono_x11_32.zip mono/release-${GODOT_VERSION}
|
||||
rm -rf Godot_v${GODOT_VERSION}_mono_x11_32
|
||||
|
||||
mkdir -p mono/templates
|
||||
rm -rf mono/templates/*linux*32*
|
||||
|
||||
cp -rp out/linux/x86/templates-mono/data.mono.x11.32.* mono/templates/
|
||||
cp out/linux/x86/templates-mono/godot.x11.opt.debug.32.mono mono/templates/linux_x11_32_debug
|
||||
cp out/linux/x86/templates-mono/godot.x11.opt.32.mono mono/templates/linux_x11_32_release
|
||||
|
||||
# Windows
|
||||
|
||||
mkdir -p release-${GODOT_VERSION}
|
||||
rm -f release-${GODOT_VERSION}/*win*zip
|
||||
|
||||
cp out/windows/x64/tools/godot.windows.opt.tools.64.exe Godot_v${GODOT_VERSION}_win64.exe
|
||||
strip Godot_v${GODOT_VERSION}_win64.exe
|
||||
sign Godot_v${GODOT_VERSION}_win64.exe
|
||||
zip -q -9 Godot_v${GODOT_VERSION}_win64.exe.zip Godot_v${GODOT_VERSION}_win64.exe
|
||||
mv Godot_v${GODOT_VERSION}_win64.exe.zip release-${GODOT_VERSION}
|
||||
rm Godot_v${GODOT_VERSION}_win64.exe
|
||||
|
||||
cp out/windows/x86/tools/godot.windows.opt.tools.32.exe Godot_v${GODOT_VERSION}_win32.exe
|
||||
strip Godot_v${GODOT_VERSION}_win32.exe
|
||||
sign Godot_v${GODOT_VERSION}_win32.exe
|
||||
zip -q -9 Godot_v${GODOT_VERSION}_win32.exe.zip Godot_v${GODOT_VERSION}_win32.exe
|
||||
mv Godot_v${GODOT_VERSION}_win32.exe.zip release-${GODOT_VERSION}
|
||||
rm Godot_v${GODOT_VERSION}_win32.exe
|
||||
|
||||
mkdir -p templates
|
||||
rm -rf templates/*win*
|
||||
|
||||
cp out/windows/x64/templates/godot.windows.opt.64.exe templates/windows_64_release.exe
|
||||
cp out/windows/x64/templates/godot.windows.opt.debug.64.exe templates/windows_64_debug.exe
|
||||
cp out/windows/x86/templates/godot.windows.opt.32.exe templates/windows_32_release.exe
|
||||
cp out/windows/x86/templates/godot.windows.opt.debug.32.exe templates/windows_32_debug.exe
|
||||
|
||||
strip templates/windows*.exe
|
||||
|
||||
sign templates/windows_64_release.exe
|
||||
sign templates/windows_64_debug.exe
|
||||
sign templates/windows_32_release.exe
|
||||
sign templates/windows_32_debug.exe
|
||||
|
||||
mkdir -p mono/release-${GODOT_VERSION}
|
||||
rm -rf mono/release-${GODOT_VERSION}/*win*
|
||||
|
||||
mkdir -p mono/templates
|
||||
rm -rf mono/templates/*win*
|
||||
|
||||
mkdir -p Godot_v${GODOT_VERSION}_mono_win64
|
||||
cp out/windows/x64/tools-mono/godot.windows.opt.tools.64.mono.exe Godot_v${GODOT_VERSION}_mono_win64/Godot_v${GODOT_VERSION}_mono_win64.exe
|
||||
strip Godot_v${GODOT_VERSION}_mono_win64/Godot_v${GODOT_VERSION}_mono_win64.exe
|
||||
sign Godot_v${GODOT_VERSION}_mono_win64/Godot_v${GODOT_VERSION}_mono_win64.exe
|
||||
cp -rp out/windows/x64/tools-mono/GodotSharp Godot_v${GODOT_VERSION}_mono_win64
|
||||
cp -rp mono-glue/Api Godot_v${GODOT_VERSION}_mono_win64/GodotSharp/Api
|
||||
zip -r -q -9 Godot_v${GODOT_VERSION}_mono_win64.zip Godot_v${GODOT_VERSION}_mono_win64
|
||||
mv Godot_v${GODOT_VERSION}_mono_win64.zip mono/release-${GODOT_VERSION}
|
||||
rm -rf Godot_v${GODOT_VERSION}_mono_win64
|
||||
|
||||
cp -rp out/windows/x64/templates-mono/data.mono.windows.64.* mono/templates/
|
||||
cp out/windows/x64/templates-mono/godot.windows.opt.debug.64.mono.exe mono/templates/windows_64_debug.exe
|
||||
cp out/windows/x64/templates-mono/godot.windows.opt.64.mono.exe mono/templates/windows_64_release.exe
|
||||
|
||||
mkdir -p Godot_v${GODOT_VERSION}_mono_win32
|
||||
cp out/windows/x86/tools-mono/godot.windows.opt.tools.32.mono.exe Godot_v${GODOT_VERSION}_mono_win32/Godot_v${GODOT_VERSION}_mono_win32.exe
|
||||
strip Godot_v${GODOT_VERSION}_mono_win32/Godot_v${GODOT_VERSION}_mono_win32.exe
|
||||
sign Godot_v${GODOT_VERSION}_mono_win32/Godot_v${GODOT_VERSION}_mono_win32.exe
|
||||
cp -rp out/windows/x86/tools-mono/GodotSharp Godot_v${GODOT_VERSION}_mono_win32
|
||||
cp -rp mono-glue/Api Godot_v${GODOT_VERSION}_mono_win32/GodotSharp/Api
|
||||
zip -r -q -9 Godot_v${GODOT_VERSION}_mono_win32.zip Godot_v${GODOT_VERSION}_mono_win32
|
||||
mv Godot_v${GODOT_VERSION}_mono_win32.zip mono/release-${GODOT_VERSION}
|
||||
rm -rf Godot_v${GODOT_VERSION}_mono_win32
|
||||
|
||||
cp -rp out/windows/x86/templates-mono/data.mono.windows.32.* mono/templates/
|
||||
cp out/windows/x86/templates-mono/godot.windows.opt.debug.32.mono.exe mono/templates/windows_32_debug.exe
|
||||
cp out/windows/x86/templates-mono/godot.windows.opt.32.mono.exe mono/templates/windows_32_release.exe
|
||||
|
||||
strip mono/templates/windows*.exe
|
||||
|
||||
sign mono/templates/windows_64_debug.exe
|
||||
sign mono/templates/windows_64_release.exe
|
||||
sign mono/templates/windows_32_debug.exe
|
||||
sign mono/templates/windows_32_release.exe
|
||||
|
||||
# OSX
|
||||
|
||||
mkdir -p templates
|
||||
rm -f templates/osx*
|
||||
|
||||
rm -rf osx_template
|
||||
mkdir -p osx_template
|
||||
cd osx_template
|
||||
|
||||
cp -r ../git/misc/dist/osx_template.app .
|
||||
mkdir osx_template.app/Contents/MacOS
|
||||
|
||||
cp ../out/macosx/x64/templates/godot.osx.opt.64 osx_template.app/Contents/MacOS/godot_osx_release.64
|
||||
cp ../out/macosx/x64/templates/godot.osx.opt.debug.64 osx_template.app/Contents/MacOS/godot_osx_debug.64
|
||||
chmod +x osx_template.app/Contents/MacOS/godot_osx*
|
||||
zip -q -9 -r osx.zip osx_template.app
|
||||
cd ..
|
||||
|
||||
mv osx_template/osx.zip templates
|
||||
rm -rf osx_template
|
||||
|
||||
mkdir -p release-${GODOT_VERSION}
|
||||
rm -f release-${GODOT_VERSION}/*osx*
|
||||
|
||||
cp -r git/misc/dist/osx_tools.app Godot.app
|
||||
mkdir -p Godot.app/Contents/MacOS
|
||||
cp out/macosx/x64/tools/godot.osx.opt.tools.64 Godot.app/Contents/MacOS/Godot
|
||||
chmod +x Godot.app/Contents/MacOS/Godot
|
||||
zip -q -9 -r "release-${GODOT_VERSION}/Godot_v${GODOT_VERSION}_osx.64.zip" Godot.app
|
||||
rm -rf Godot.app
|
||||
|
||||
mkdir -p mono/templates
|
||||
rm -rf mono/templates/osx*
|
||||
|
||||
rm -rf osx_template
|
||||
mkdir -p osx_template
|
||||
cd osx_template
|
||||
|
||||
cp -r ../git/misc/dist/osx_template.app .
|
||||
mkdir osx_template.app/Contents/MacOS
|
||||
|
||||
cp ../out/macosx/x64/templates-mono/godot.osx.opt.64.mono osx_template.app/Contents/MacOS/godot_osx_release.64
|
||||
cp ../out/macosx/x64/templates-mono/godot.osx.opt.debug.64.mono osx_template.app/Contents/MacOS/godot_osx_debug.64
|
||||
cp -rp ../out/macosx/x64/templates-mono/data.mono.osx.64.* osx_template.app/Contents/MacOS/
|
||||
chmod +x osx_template.app/Contents/MacOS/godot_osx*
|
||||
zip -q -9 -r osx.zip osx_template.app
|
||||
cd ..
|
||||
|
||||
mv osx_template/osx.zip mono/templates
|
||||
rm -rf osx_template
|
||||
|
||||
mkdir -p mono/release-${GODOT_VERSION}
|
||||
rm -f mono/release-${GODOT_VERSION}/*osx*
|
||||
|
||||
cp -r git/misc/dist/osx_tools.app Godot_mono.app
|
||||
mkdir -p Godot_mono.app/Contents/MacOS
|
||||
cp out/macosx/x64/tools-mono/godot.osx.opt.tools.64.mono Godot_mono.app/Contents/MacOS/Godot
|
||||
mkdir -p Godot_mono.app/Contents/{Frameworks,Resources}
|
||||
mkdir -p Godot_mono.app/Contents/{Frameworks,Resources}/GodotSharp
|
||||
mkdir -p Godot_mono.app/Contents/{Frameworks,Resources}/GodotSharp/Mono
|
||||
cp -rp out/macosx/x64/tools-mono/GodotSharp/Mono/lib Godot_mono.app/Contents/Frameworks/GodotSharp/Mono
|
||||
cp -rp out/macosx/x64/tools-mono/GodotSharp/Tools Godot_mono.app/Contents/Frameworks/GodotSharp
|
||||
cp -rp mono-glue/Api Godot_mono.app/Contents/Frameworks/GodotSharp
|
||||
cp -rp out/macosx/x64/tools-mono/GodotSharp/Mono/etc Godot_mono.app/Contents/Resources/GodotSharp/Mono
|
||||
chmod +x Godot_mono.app/Contents/MacOS/Godot
|
||||
zip -q -9 -r "mono/release-${GODOT_VERSION}/Godot_v${GODOT_VERSION}_mono_osx.64.zip" Godot_mono.app
|
||||
rm -rf Godot_mono.app
|
||||
|
||||
# Server
|
||||
|
||||
cp out/server/x64/templates/godot_server.x11.opt.64 Godot_v${GODOT_VERSION}_linux_server.64
|
||||
zip -q -9 Godot_v${GODOT_VERSION}_linux_server.64.zip Godot_v${GODOT_VERSION}_linux_server.64
|
||||
mv Godot_v${GODOT_VERSION}_linux_server.64.zip release-${GODOT_VERSION}
|
||||
rm Godot_v${GODOT_VERSION}_linux_server.64
|
||||
|
||||
cp out/server/x64/tools/godot_server.x11.opt.tools.64 Godot_v${GODOT_VERSION}_linux_headless.64
|
||||
zip -q -9 Godot_v${GODOT_VERSION}_linux_headless.64.zip Godot_v${GODOT_VERSION}_linux_headless.64
|
||||
mv Godot_v${GODOT_VERSION}_linux_headless.64.zip release-${GODOT_VERSION}
|
||||
rm Godot_v${GODOT_VERSION}_linux_headless.64
|
||||
|
||||
# Javascript
|
||||
|
||||
cp out/javascript/godot.javascript.opt.zip templates/webassembly_release.zip
|
||||
cp out/javascript/godot.javascript.opt.debug.zip templates/webassembly_debug.zip
|
||||
|
||||
# Android
|
||||
|
||||
cp out/android/*.apk templates
|
||||
|
||||
# iOS
|
||||
|
||||
cp -r git/misc/dist/ios_xcode ios_xcode
|
||||
cp out/ios/libgodot.iphone.opt.fat ios_xcode/libgodot.iphone.release.fat.a
|
||||
cp out/ios/libgodot.iphone.opt.debug.fat ios_xcode/libgodot.iphone.debug.fat.a
|
||||
|
||||
chmod +x ios_xcode/libgodot.iphone.*
|
||||
cd ios_xcode
|
||||
zip -q -9 -r ../templates/iphone.zip *
|
||||
cd ..
|
||||
rm -rf ios_xcode
|
||||
|
||||
# UWP
|
||||
|
||||
if [ ! -d "angle" ]; then
|
||||
echo "Downloading ANGLE binaries from https://github.com/GodotBuilder/godot-builds/releases/tag/_tools"
|
||||
curl -LO https://github.com/GodotBuilder/godot-builds/releases/download/_tools/angle.7z
|
||||
7z x angle.7z && rm -f angle.7z
|
||||
fi
|
||||
|
||||
mkdir -p templates
|
||||
rm -f templates/uwp*
|
||||
rm -rf uwp_template_*
|
||||
# Classical
|
||||
|
||||
for arch in ARM Win32 x64; do
|
||||
cp -r git/misc/dist/uwp_template uwp_template_${arch}
|
||||
if [ "${build_classical}" == "1" ]; then
|
||||
|
||||
cp angle/winrt/10/src/Release_${arch}/libEGL.dll \
|
||||
angle/winrt/10/src/Release_${arch}/libGLESv2.dll \
|
||||
uwp_template_${arch}/
|
||||
cp -r uwp_template_${arch} uwp_template_${arch}_debug
|
||||
done
|
||||
## Linux (Classical) ##
|
||||
|
||||
cp out/uwp/arm/godot.uwp.opt.32.arm.exe uwp_template_ARM/godot.uwp.exe
|
||||
cp out/uwp/arm/godot.uwp.opt.debug.32.arm.exe uwp_template_ARM_debug/godot.uwp.exe
|
||||
sign uwp_template_ARM/godot.uwp.exe
|
||||
sign uwp_template_ARM_debug/godot.uwp.exe
|
||||
cd uwp_template_ARM && zip -q -9 -r ../templates/uwp_arm_release.zip * && cd ..
|
||||
cd uwp_template_ARM_debug && zip -q -9 -r ../templates/uwp_arm_debug.zip * && cd ..
|
||||
# Editor
|
||||
binname="${godot_basename}_x11.64"
|
||||
cp out/linux/x86_64/tools/godot.x11.opt.tools.64 ${binname}
|
||||
zip -q -9 "${reldir}/${binname}.zip" ${binname}
|
||||
rm ${binname}
|
||||
|
||||
cp out/uwp/x86/godot.uwp.opt.32.x86.exe uwp_template_Win32/godot.uwp.exe
|
||||
cp out/uwp/x86/godot.uwp.opt.debug.32.x86.exe uwp_template_Win32_debug/godot.uwp.exe
|
||||
sign uwp_template_Win32/godot.uwp.exe
|
||||
sign uwp_template_Win32_debug/godot.uwp.exe
|
||||
cd uwp_template_Win32 && zip -q -9 -r ../templates/uwp_x86_release.zip * && cd ..
|
||||
cd uwp_template_Win32_debug && zip -q -9 -r ../templates/uwp_x86_debug.zip * && cd ..
|
||||
binname="${godot_basename}_x11.32"
|
||||
cp out/linux/x86_32/tools/godot.x11.opt.tools.32 ${binname}
|
||||
zip -q -9 "${reldir}/${binname}.zip" ${binname}
|
||||
rm ${binname}
|
||||
|
||||
cp out/uwp/x64/godot.uwp.opt.64.x64.exe uwp_template_x64/godot.uwp.exe
|
||||
cp out/uwp/x64/godot.uwp.opt.debug.64.x64.exe uwp_template_x64_debug/godot.uwp.exe
|
||||
sign uwp_template_x64/godot.uwp.exe
|
||||
sign uwp_template_x64_debug/godot.uwp.exe
|
||||
cd uwp_template_x64 && zip -q -9 -r ../templates/uwp_x64_release.zip * && cd ..
|
||||
cd uwp_template_x64_debug && zip -q -9 -r ../templates/uwp_x64_debug.zip * && cd ..
|
||||
# Templates
|
||||
cp out/linux/x86_64/templates/godot.x11.opt.64 ${templatesdir}/linux_x11_64_release
|
||||
cp out/linux/x86_64/templates/godot.x11.opt.debug.64 ${templatesdir}/linux_x11_64_debug
|
||||
cp out/linux/x86_32/templates/godot.x11.opt.32 ${templatesdir}/linux_x11_32_release
|
||||
cp out/linux/x86_32/templates/godot.x11.opt.debug.32 ${templatesdir}/linux_x11_32_debug
|
||||
|
||||
rm -rf uwp_template_*
|
||||
## Windows (Classical) ##
|
||||
|
||||
exit 0
|
||||
# Editor
|
||||
binname="${godot_basename}_win64.exe"
|
||||
cp out/windows/x86_64/tools/godot.windows.opt.tools.64.exe ${binname}
|
||||
sign_windows ${binname}
|
||||
zip -q -9 "${reldir}/${binname}.zip" ${binname}
|
||||
rm ${binname}
|
||||
|
||||
binname="${godot_basename}_win32.exe"
|
||||
cp out/windows/x86_32/tools/godot.windows.opt.tools.32.exe ${binname}
|
||||
sign_windows ${binname}
|
||||
zip -q -9 "${reldir}/${binname}.zip" ${binname}
|
||||
rm ${binname}
|
||||
|
||||
# Templates
|
||||
cp out/windows/x86_64/templates/godot.windows.opt.64.exe ${templatesdir}/windows_64_release.exe
|
||||
cp out/windows/x86_64/templates/godot.windows.opt.debug.64.exe ${templatesdir}/windows_64_debug.exe
|
||||
cp out/windows/x86_32/templates/godot.windows.opt.32.exe ${templatesdir}/windows_32_release.exe
|
||||
cp out/windows/x86_32/templates/godot.windows.opt.debug.32.exe ${templatesdir}/windows_32_debug.exe
|
||||
|
||||
## macOS (Classical) ##
|
||||
|
||||
# Editor
|
||||
binname="${godot_basename}_osx.64"
|
||||
rm -rf Godot.app
|
||||
cp -r git/misc/dist/osx_tools.app Godot.app
|
||||
mkdir -p Godot.app/Contents/MacOS
|
||||
cp out/macos/tools/godot.osx.opt.tools.64 Godot.app/Contents/MacOS/Godot
|
||||
chmod +x Godot.app/Contents/MacOS/Godot
|
||||
zip -q -9 -r "${reldir}/${binname}.zip" Godot.app
|
||||
rm -rf Godot.app
|
||||
sign_macos ${reldir} ${binname}
|
||||
|
||||
# Templates
|
||||
rm -rf osx_template.app
|
||||
cp -r git/misc/dist/osx_template.app .
|
||||
mkdir -p osx_template.app/Contents/MacOS
|
||||
|
||||
cp out/macos/templates/godot.osx.opt.64 osx_template.app/Contents/MacOS/godot_osx_release.64
|
||||
cp out/macos/templates/godot.osx.opt.debug.64 osx_template.app/Contents/MacOS/godot_osx_debug.64
|
||||
chmod +x osx_template.app/Contents/MacOS/godot_osx*
|
||||
zip -q -9 -r "${templatesdir}/osx.zip" osx_template.app
|
||||
rm -rf osx_template.app
|
||||
sign_macos_template ${templatesdir}
|
||||
|
||||
## Web (Classical) ##
|
||||
|
||||
cp git/misc/dist/html/default.html godot.html
|
||||
cp out/web/templates/godot.javascript.opt.asm.js godot.asm.js
|
||||
cp out/web/templates/godot.javascript.opt.js godot.js
|
||||
cp out/web/templates/godot.javascript.opt.html.mem godot.mem
|
||||
zip -q -9 ${templatesdir}/javascript_release.zip godot.{html,asm.js,js,mem}
|
||||
cp out/web/templates/godot.javascript.opt.debug.asm.js godot.asm.js
|
||||
cp out/web/templates/godot.javascript.opt.debug.js godot.js
|
||||
cp out/web/templates/godot.javascript.opt.debug.html.mem godot.mem
|
||||
zip -q -9 ${templatesdir}/javascript_debug.zip godot.{html,asm.js,js,mem}
|
||||
rm -f godot.{html,asm.js,js,mem}
|
||||
|
||||
## Android (Classical) ##
|
||||
|
||||
cp out/android/templates/*.apk ${templatesdir}/
|
||||
|
||||
## iOS (Classical) ##
|
||||
|
||||
rm -rf ios_xcode
|
||||
cp -r git/misc/dist/ios_xcode ios_xcode
|
||||
cp out/ios/templates/godot.iphone.opt.arm64 ios_xcode/godot_opt.iphone
|
||||
cp out/ios/templates/godot.iphone.opt.debug.arm64 ios_xcode/godot_debug.iphone
|
||||
chmod +x ios_xcode/godot*.iphone
|
||||
zip -q -9 -r "${templatesdir}/GodotiOSXCode.zip" ios_xcode
|
||||
rm -rf ios_xcode
|
||||
|
||||
## Templates TPZ (Classical) ##
|
||||
|
||||
echo "${templates_version}" > ${templatesdir}/version.txt
|
||||
pushd ${templatesdir}/..
|
||||
zip -q -9 -r -D "${reldir}/${godot_basename}_export_templates.tpz" templates/*
|
||||
popd
|
||||
|
||||
## SHA-512 sums (Classical) ##
|
||||
|
||||
pushd ${reldir}
|
||||
sha512sum [Gg]* > SHA512-SUMS.txt
|
||||
mkdir -p ${basedir}/sha512sums/${godot_version}
|
||||
cp SHA512-SUMS.txt ${basedir}/sha512sums/${godot_version}/
|
||||
popd
|
||||
|
||||
fi
|
||||
|
||||
echo "All editor binaries and templates prepared successfully for release"
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
|
||||
export MONO_OPTIONS="module_mono_enabled=yes mono_static=yes copy_mono_root=yes"
|
||||
export TERM=xterm
|
||||
export MONO32_PREFIX=/usr
|
||||
export MONO64_PREFIX=/usr
|
||||
export CC="gcc-8"
|
||||
export CXX="g++-8"
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
$SCONS platform=server CC=$CC CXX=$CXX $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=server CC=$CC CXX=$CXX $OPTIONS tools=no target=release
|
||||
mkdir -p /root/out/templates
|
||||
cp -rvp bin/* /root/out/templates
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=server CC=$CC CXX=$CXX $OPTIONS tools=yes target=release_debug
|
||||
mkdir -p /root/out/tools
|
||||
cp -rvp bin/* /root/out/tools
|
||||
rm -rf bin
|
||||
|
||||
@@ -1,26 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
if [ -z "$1" ] || [ -z "$2" ]; then
|
||||
echo "usage: $0 <version> <file version>"
|
||||
echo " like : $0 3.0.3.rc1 3.0.3-rc1"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
VERSION=$1
|
||||
FILE_VERSION=$2
|
||||
MONO_VERSION=$3
|
||||
|
||||
echo "$VERSION" > templates/version.txt
|
||||
|
||||
mkdir -p release-${FILE_VERSION}
|
||||
rm -f release-${FILE_VERSION}/*templates.tpz
|
||||
zip -q -9 -r -D release-${FILE_VERSION}/Godot_v${FILE_VERSION}_export_templates.tpz templates
|
||||
|
||||
mkdir -p mono/release-${FILE_VERSION}
|
||||
rm -f mono/release-${FILE_VERSION}/*templates.tpz
|
||||
cd mono
|
||||
echo "$VERSION".mono > templates/version.txt
|
||||
zip -q -9 -r -D release-${FILE_VERSION}/Godot_v${FILE_VERSION}_mono_export_templates.tpz templates
|
||||
cd ..
|
||||
@@ -1,3 +0,0 @@
|
||||
call z:\root\build\env-%1.bat
|
||||
|
||||
%SCONS% platform=uwp %OPTIONS% tools=no target=%2 LINK="\"C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\bin\HostX64\%1\link.exe\""
|
||||
@@ -1,26 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
export ANGLE_SRC_PATH='c:\angle'
|
||||
export BUILD_NAME=official
|
||||
export SCONS="call scons -j4 verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no"
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
for arch in x86 x64 arm; do
|
||||
for release in release release_debug; do
|
||||
wine cmd /c /root/build/build.bat $arch $release
|
||||
|
||||
sync
|
||||
wineserver -kw
|
||||
|
||||
mkdir -p /root/out/$arch
|
||||
mv bin/* /root/out/$arch
|
||||
done
|
||||
done
|
||||
|
||||
@@ -1,36 +0,0 @@
|
||||
set ALLUSERSPROFILE=C:\ProgramData
|
||||
set CommandPromptType=Native
|
||||
set CommonProgramFiles=C:\Program Files\Common Files
|
||||
set CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
|
||||
set CommonProgramW6432=C:\Program Files\Common Files
|
||||
set DevEnvDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\
|
||||
set ExtensionSdkDir=C:\Program Files (x86)\Microsoft SDKs\Windows Kits\10\ExtensionSDKs
|
||||
set Framework40Version=v4.0
|
||||
set FrameworkDir=C:\Windows\Microsoft.NET\Framework64\
|
||||
set FrameworkDir64=C:\Windows\Microsoft.NET\Framework64\
|
||||
set FrameworkVersion=v4.0.30319
|
||||
set FrameworkVersion64=v4.0.30319
|
||||
set VCIDEInstallDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\
|
||||
set VCINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\
|
||||
set VCToolsInstallDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\
|
||||
set VCToolsRedistDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Redist\MSVC\14.16.27012\
|
||||
set VCToolsVersion=14.16.27023
|
||||
set VisualStudioVersion=15.0
|
||||
set VS150COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\
|
||||
set VSCMD_ARG_app_plat=UWP
|
||||
set Platform=arm
|
||||
set VSCMD_ARG_HOST_ARCH=x86
|
||||
set VSCMD_ARG_TGT_ARCH=arm
|
||||
set VSCMD_ARG_winsdk=10.0.16299.0
|
||||
set VSCMD_VER=15.0
|
||||
set VSINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\
|
||||
set Path=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\bin\HostX86\arm;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2017\Build Tools\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\bin\Roslyn;C:\Program Files (x86)\Windows Kits\10\bin\10.0.16299.0\arm;C:\Program Files (x86)\Windows Kits\10\bin\arm;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\\MSBuild\15.0\bin;C:\Windows\Microsoft.NET\Framework\ v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\;C:\Program Files\Python37\Scripts\;C:\Program Files\Python37\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\ProgramData\chocolatey\bin;C:\Program Files\OpenSSH-Win64;C:\Program Files\Git\cmd;C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\WindowsApps;C:\Users\user\AppData\Local\Microsoft\WindowsApps;
|
||||
set INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\ucrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\shared;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\um;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\winrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\cppwinrt
|
||||
set LIB=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\lib\arm\store\;C:\Program Files (x86)\Windows Kits\10\lib\10.0.16299.0\ucrt\arm;C:\Program Files (x86)\Windows Kits\10\lib\10.0.16299.0\um\arm;
|
||||
set LIBPATH=C:\Program Files (x86)\Microsoft SDKs\Windows Kits\10\ExtensionSDKs\Microsoft.VCLibs\14.0\References\CommonConfiguration\neutral;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\lib\arm\store\references;C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.16299.0;C:\Program Files (x86)\Windows Kits\10\References\10.0.16299.0;C:\Windows\Microsoft.NET\Framework\v4.0.30319;
|
||||
set WindowsLibPath=C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.16299.0;C:\Program Files (x86)\Windows Kits\10\References\10.0.16299.0
|
||||
set WindowsSdkBinPath=C:\Program Files (x86)\Windows Kits\10\bin\
|
||||
set WindowsSdkDir=C:\Program Files (x86)\Windows Kits\10\
|
||||
set WindowsSDKLibVersion=10.0.16299.0\
|
||||
set WindowsSdkVerBinPath=C:\Program Files (x86)\Windows Kits\10\bin\10.0.16299.0\
|
||||
set WindowsSDKVersion=10.0.16299.0\
|
||||
@@ -1,35 +0,0 @@
|
||||
set ALLUSERSPROFILE=C:\ProgramData
|
||||
set CommandPromptType=Native
|
||||
set CommonProgramFiles=C:\Program Files\Common Files
|
||||
set CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
|
||||
set CommonProgramW6432=C:\Program Files\Common Files
|
||||
set DevEnvDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\
|
||||
set ExtensionSdkDir=C:\Program Files (x86)\Microsoft SDKs\Windows Kits\10\ExtensionSDKs
|
||||
set Framework40Version=v4.0
|
||||
set FrameworkDir=C:\Windows\Microsoft.NET\Framework64\
|
||||
set FrameworkDir64=C:\Windows\Microsoft.NET\Framework64\
|
||||
set FrameworkVersion=v4.0.30319
|
||||
set FrameworkVersion64=v4.0.30319
|
||||
set VCIDEInstallDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\
|
||||
set VCINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\
|
||||
set VCToolsInstallDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\
|
||||
set VCToolsRedistDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Redist\MSVC\14.16.27012\
|
||||
set VCToolsVersion=14.16.27023
|
||||
set VisualStudioVersion=15.0
|
||||
set VS150COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\
|
||||
set VSCMD_ARG_app_plat=UWP
|
||||
set VSCMD_ARG_HOST_ARCH=x86
|
||||
set VSCMD_ARG_TGT_ARCH=x64
|
||||
set VSCMD_ARG_winsdk=10.0.16299.0
|
||||
set VSCMD_VER=15.0
|
||||
set VSINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\
|
||||
set Path=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\bin\HostX86\x64;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2017\Build Tools\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\bin\Roslyn;C:\Program Files (x86)\Windows Kits\10\bin\10.0.16299.0\x64;C:\Program Files (x86)\Windows Kits\10\bin\x64;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\\MSBuild\15.0\bin;C:\Windows\Microsoft.NET\Framework\ v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\;C:\Program Files\Python37\Scripts\;C:\Program Files\Python37\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\ProgramData\chocolatey\bin;C:\Program Files\OpenSSH-Win64;C:\Program Files\Git\cmd;C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\WindowsApps;C:\Users\user\AppData\Local\Microsoft\WindowsApps;
|
||||
set INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\ucrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\shared;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\um;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\winrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\cppwinrt
|
||||
set LIB=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\lib\x64\store\;C:\Program Files (x86)\Windows Kits\10\lib\10.0.16299.0\ucrt\x64;C:\Program Files (x86)\Windows Kits\10\lib\10.0.16299.0\um\x64;
|
||||
set LIBPATH=C:\Program Files (x86)\Microsoft SDKs\Windows Kits\10\ExtensionSDKs\Microsoft.VCLibs\14.0\References\CommonConfiguration\neutral;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\lib\x64\store\references;C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.16299.0;C:\Program Files (x86)\Windows Kits\10\References\10.0.16299.0;C:\Windows\Microsoft.NET\Framework\v4.0.30319;
|
||||
set WindowsLibPath=C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.16299.0;C:\Program Files (x86)\Windows Kits\10\References\10.0.16299.0
|
||||
set WindowsSdkBinPath=C:\Program Files (x86)\Windows Kits\10\bin\
|
||||
set WindowsSdkDir=C:\Program Files (x86)\Windows Kits\10\
|
||||
set WindowsSDKLibVersion=10.0.16299.0\
|
||||
set WindowsSdkVerBinPath=C:\Program Files (x86)\Windows Kits\10\bin\10.0.16299.0\
|
||||
set WindowsSDKVersion=10.0.16299.0\
|
||||
@@ -1,36 +0,0 @@
|
||||
set ALLUSERSPROFILE=C:\ProgramData
|
||||
set CommandPromptType=Native
|
||||
set CommonProgramFiles=C:\Program Files\Common Files
|
||||
set CommonProgramFiles(x86)=C:\Program Files (x86)\Common Files
|
||||
set CommonProgramW6432=C:\Program Files\Common Files
|
||||
set DevEnvDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\
|
||||
set ExtensionSdkDir=C:\Program Files (x86)\Microsoft SDKs\Windows Kits\10\ExtensionSDKs
|
||||
set Framework40Version=v4.0
|
||||
set FrameworkDir=C:\Windows\Microsoft.NET\Framework64\
|
||||
set FrameworkDir64=C:\Windows\Microsoft.NET\Framework64\
|
||||
set FrameworkVersion=v4.0.30319
|
||||
set FrameworkVersion64=v4.0.30319
|
||||
set VCIDEInstallDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\
|
||||
set VCINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\
|
||||
set VCToolsInstallDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\
|
||||
set VCToolsRedistDir=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Redist\MSVC\14.16.27012\
|
||||
set VCToolsVersion=14.16.27023
|
||||
set VisualStudioVersion=15.0
|
||||
set VS150COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\
|
||||
set VSCMD_ARG_app_plat=UWP
|
||||
set VSCMD_ARG_HOST_ARCH=x86
|
||||
set VSCMD_ARG_TGT_ARCH=x86
|
||||
set VSCMD_ARG_winsdk=10.0.16299.0
|
||||
set VSCMD_VER=15.0
|
||||
set VSINSTALLDIR=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\
|
||||
set Path=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\bin\HostX86\x86;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\VC\VCPackages;C:\Program Files (x86)\Microsoft Visual Studio\2017\Build Tools\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\bin\Roslyn;C:\Program Files (x86)\Windows Kits\10\bin\10.0.16299.0\x86;C:\Program Files (x86)\Windows Kits\10\bin\x86;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\\MSBuild\15.0\bin;C:\Windows\Microsoft.NET\Framework\ v4.0.30319;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\IDE\;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\Common7\Tools\;C:\Program Files\Python37\Scripts\;C:\Program Files\Python37\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\ProgramData\chocolatey\bin;C:\Program Files\OpenSSH-Win64;C:\Program Files\Git\cmd;C:\Windows\system32\config\systemprofile\AppData\Local\Microsoft\WindowsApps;C:\Users\user\AppData\Local\Microsoft\WindowsApps;
|
||||
set INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\include;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\ucrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\shared;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\um;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\winrt;C:\Program Files (x86)\Windows Kits\10\include\10.0.16299.0\cppwinrt
|
||||
set LIB=C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\lib\x86\store\;C:\Program Files (x86)\Windows Kits\10\lib\10.0.16299.0\ucrt\x86;C:\Program Files (x86)\Windows Kits\10\lib\10.0.16299.0\um\x86;
|
||||
set LIBPATH=C:\Program Files (x86)\Microsoft SDKs\Windows Kits\10\ExtensionSDKs\Microsoft.VCLibs\14.0\References\CommonConfiguration\neutral;C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.16.27023\lib\x86\store\references;C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.16299.0;C:\Program Files (x86)\Windows Kits\10\References\10.0.16299.0;C:\Windows\Microsoft.NET\Framework\v4.0.30319;
|
||||
set WindowsLibPath=C:\Program Files (x86)\Windows Kits\10\UnionMetadata\10.0.16299.0;C:\Program Files (x86)\Windows Kits\10\References\10.0.16299.0
|
||||
set WindowsSdkBinPath=C:\Program Files (x86)\Windows Kits\10\bin\
|
||||
set WindowsSdkDir=C:\Program Files (x86)\Windows Kits\10\
|
||||
set WindowsSDKLibVersion=10.0.16299.0\
|
||||
set WindowsSdkVerBinPath=C:\Program Files (x86)\Windows Kits\10\bin\10.0.16299.0\
|
||||
set WindowsSDKVersion=10.0.16299.0\
|
||||
|
||||
26
build-web/build.sh
Executable file
26
build-web/build.sh
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
# Config
|
||||
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS=""
|
||||
|
||||
source /root/emsdk/emsdk_env.sh
|
||||
export EMSCRIPTEN_ROOT=/root/emsdk/fastcomp/emscripten
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
echo "Starting classical build for Web..."
|
||||
|
||||
$SCONS platform=javascript ${OPTIONS} tools=no target=release_debug
|
||||
$SCONS platform=javascript ${OPTIONS} tools=no target=release
|
||||
|
||||
mkdir -p /root/out/templates
|
||||
cp -rvp bin/* /root/out/templates
|
||||
|
||||
echo "Web build successful"
|
||||
@@ -2,61 +2,43 @@
|
||||
|
||||
set -e
|
||||
|
||||
export BUILD_NAME=official
|
||||
# Config
|
||||
|
||||
export SCONS="scons -j${NUM_CORES} verbose=yes warnings=no progress=no"
|
||||
export OPTIONS="builtin_libpng=yes builtin_openssl=yes builtin_zlib=yes debug_symbols=no use_static_cpp=yes use_lto=yes"
|
||||
export OPTIONS_MONO="module_mono_enabled=yes mono_static=yes"
|
||||
export TERM=xterm
|
||||
export MONO32_PREFIX=/root/dependencies/mono-32
|
||||
export MONO64_PREFIX=/root/dependencies/mono-64
|
||||
export OPTIONS=""
|
||||
export STRIP="x86_64-w64-mingw32-strip"
|
||||
|
||||
rm -rf godot
|
||||
mkdir godot
|
||||
cd godot
|
||||
tar xf /root/godot.tar.gz --strip-components=1
|
||||
|
||||
cp /root/mono-glue/*.cpp modules/mono/glue
|
||||
|
||||
$SCONS platform=windows bits=32 $OPTIONS tools=yes target=release_debug
|
||||
mkdir -p /root/out/x86/tools
|
||||
cp -rvp bin/* /root/out/x86/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=windows bits=32 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=windows bits=32 $OPTIONS tools=no target=release
|
||||
mkdir -p /root/out/x86/templates
|
||||
cp -rvp bin/* /root/out/x86/templates
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=windows bits=32 $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
|
||||
mkdir -p /root/out/x86/tools-mono
|
||||
cp -rvp bin/* /root/out/x86/tools-mono
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=windows bits=32 $OPTIONS $OPTIONS_MONO tools=no target=release_debug
|
||||
$SCONS platform=windows bits=32 $OPTIONS $OPTIONS_MONO tools=no target=release
|
||||
mkdir -p /root/out/x86/templates-mono
|
||||
cp -rvp bin/* /root/out/x86/templates-mono
|
||||
rm -rf bin
|
||||
echo "Starting classical build for Windows..."
|
||||
|
||||
$SCONS platform=windows bits=64 $OPTIONS tools=yes target=release_debug
|
||||
mkdir -p /root/out/x64/tools
|
||||
cp -rvp bin/* /root/out/x64/tools
|
||||
$STRIP bin/godot.windows.*
|
||||
mkdir -p /root/out/x86_64/tools
|
||||
cp -rvp bin/* /root/out/x86_64/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=windows bits=64 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=windows bits=64 $OPTIONS tools=no target=release
|
||||
mkdir -p /root/out/x64/templates
|
||||
cp -rvp bin/* /root/out/x64/templates
|
||||
$STRIP bin/godot.windows.*
|
||||
mkdir -p /root/out/x86_64/templates
|
||||
cp -rvp bin/* /root/out/x86_64/templates
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=windows bits=64 $OPTIONS $OPTIONS_MONO tools=yes target=release_debug copy_mono_root=yes
|
||||
mkdir -p /root/out/x64/tools-mono
|
||||
cp -rvp bin/* /root/out/x64/tools-mono
|
||||
$SCONS platform=windows bits=32 $OPTIONS tools=yes target=release_debug
|
||||
$STRIP bin/godot.windows.*
|
||||
mkdir -p /root/out/x86_32/tools
|
||||
cp -rvp bin/* /root/out/x86_32/tools
|
||||
rm -rf bin
|
||||
|
||||
$SCONS platform=windows bits=64 $OPTIONS $OPTIONS_MONO tools=no target=release_debug
|
||||
$SCONS platform=windows bits=64 $OPTIONS $OPTIONS_MONO tools=no target=release
|
||||
mkdir -p /root/out/x64/templates-mono
|
||||
cp -rvp bin/* /root/out/x64/templates-mono
|
||||
$SCONS platform=windows bits=32 $OPTIONS tools=no target=release_debug
|
||||
$SCONS platform=windows bits=32 $OPTIONS tools=no target=release
|
||||
$STRIP bin/godot.windows.*
|
||||
mkdir -p /root/out/x86_32/templates
|
||||
cp -rvp bin/* /root/out/x86_32/templates
|
||||
rm -rf bin
|
||||
|
||||
echo "Windows build successful"
|
||||
|
||||
194
build.sh
194
build.sh
@@ -4,112 +4,78 @@ set -e
|
||||
|
||||
OPTIND=1
|
||||
|
||||
# For default registry and number of cores.
|
||||
export basedir="$(pwd)"
|
||||
mkdir -p ${basedir}/out
|
||||
mkdir -p ${basedir}/out/logs
|
||||
|
||||
# Log output to a file automatically.
|
||||
exec > >(tee -a "out/logs/build") 2>&1
|
||||
|
||||
# Config
|
||||
|
||||
if [ ! -e config.sh ]; then
|
||||
echo "No config.sh, copying default values from config.sh.in."
|
||||
cp config.sh.in config.sh
|
||||
fi
|
||||
source ./config.sh
|
||||
|
||||
if [ -z "${BUILD_NAME}" ]; then
|
||||
export BUILD_NAME="custom_build"
|
||||
fi
|
||||
|
||||
if [ -z "${NUM_CORES}" ]; then
|
||||
export NUM_CORES=16
|
||||
fi
|
||||
|
||||
registry="${REGISTRY}"
|
||||
username=""
|
||||
password=""
|
||||
godot_version=""
|
||||
git_treeish="master"
|
||||
build_classical=1
|
||||
force_download=0
|
||||
skip_download=0
|
||||
skip_git_checkout=0
|
||||
|
||||
while getopts "h?r:u:p:v:g:fsc" opt; do
|
||||
case "$opt" in
|
||||
h|\?)
|
||||
echo "Usage: $0 [OPTIONS...]"
|
||||
echo
|
||||
echo " -r registry"
|
||||
echo " -u username"
|
||||
echo " -p password"
|
||||
echo " -v godot version (e.g: 3.1-alpha5) [mandatory]"
|
||||
echo " -g git treeish (e.g: master)"
|
||||
echo " -f force redownload of all images"
|
||||
echo " -s skip downloading"
|
||||
echo " -c skip checkout"
|
||||
echo
|
||||
exit 1
|
||||
;;
|
||||
r) registry=$OPTARG
|
||||
;;
|
||||
u) username=$OPTARG
|
||||
;;
|
||||
p) password=$OPTARG
|
||||
;;
|
||||
v) godot_version=$OPTARG
|
||||
;;
|
||||
g) git_treeish=$OPTARG
|
||||
;;
|
||||
f) force_download=1
|
||||
;;
|
||||
s) skip_download=1
|
||||
;;
|
||||
c) skip_git_checkout=1
|
||||
;;
|
||||
esac
|
||||
while getopts "h?v:g:fc" opt; do
|
||||
case "$opt" in
|
||||
h|\?)
|
||||
echo "Usage: $0 [OPTIONS...]"
|
||||
echo
|
||||
echo " -v godot version (e.g. 2.1.7-stable) [mandatory]"
|
||||
echo " -g git treeish (e.g. master)"
|
||||
echo " -f force redownload of all images"
|
||||
echo " -c skip checkout"
|
||||
echo
|
||||
exit 1
|
||||
;;
|
||||
v)
|
||||
godot_version=$OPTARG
|
||||
;;
|
||||
g)
|
||||
git_treeish=$OPTARG
|
||||
;;
|
||||
f)
|
||||
force_download=1
|
||||
;;
|
||||
c)
|
||||
skip_git_checkout=1
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
export podman=none
|
||||
if which podman > /dev/null; then
|
||||
export podman=podman
|
||||
elif which docker > /dev/null; then
|
||||
export podman=docker
|
||||
fi
|
||||
|
||||
if [ "${podman}" == "none" ]; then
|
||||
echo "Either podman or docker needs to be installed"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ $UID != 0 ]; then
|
||||
echo "WARNING: Running as non-root may cause problems for the uwp build"
|
||||
fi
|
||||
export podman=${PODMAN}
|
||||
|
||||
if [ -z "${godot_version}" ]; then
|
||||
echo "-v <version> is mandatory!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -z "${username}" ] && [ ! -z "${password}" ]; then
|
||||
if ${podman} login ${registry} -u "${username}" -p "${password}"; then
|
||||
export logged_in=true
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ $skip_download == 0 ]; then
|
||||
echo "Fetching images"
|
||||
for image in mono-glue windows ubuntu-64 ubuntu-32 javascript; do
|
||||
if [ ${force_download} == 1 ] || ! ${podman} image exists godot/$image; then
|
||||
if ! ${podman} pull ${registry}/godot/${image}; then
|
||||
echo "ERROR: image $image does not exist and can't be downloaded"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
if [ ! -z "${logged_in}" ]; then
|
||||
echo "Fetching private images"
|
||||
|
||||
for image in macosx android ios uwp; do
|
||||
if [ ${force_download} == 1 ] || ! ${podman} image exists godot-private/$image; then
|
||||
if ! ${podman} pull ${registry}/godot-private/${image}; then
|
||||
echo "ERROR: image $image does not exist and can't be downloaded"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
done
|
||||
fi
|
||||
fi
|
||||
IFS=- read version status <<< "$godot_version"
|
||||
echo "Building Godot ${version} ${status} from commit or branch ${git_treeish}."
|
||||
read -p "Is this correct (y/n)? " choice
|
||||
case "$choice" in
|
||||
y|Y ) echo "yes";;
|
||||
n|N ) echo "No, aborting."; exit 0;;
|
||||
* ) echo "Invalid choice, aborting."; exit 1;;
|
||||
esac
|
||||
export GODOT_VERSION_STATUS="${status}"
|
||||
|
||||
if [ "${skip_git_checkout}" == 0 ]; then
|
||||
git clone https://github.com/godotengine/godot git || /bin/true
|
||||
@@ -119,46 +85,52 @@ if [ "${skip_git_checkout}" == 0 ]; then
|
||||
git clean -fdx
|
||||
git pull origin ${git_treeish} || /bin/true
|
||||
|
||||
git archive --format=tar $git_treeish --prefix=godot-${godot_version}/ | gzip > ../godot.tar.gz
|
||||
# Validate version
|
||||
correct_version=$(python3 << EOF
|
||||
import version;
|
||||
if hasattr(version, "patch") and version.patch != 0:
|
||||
git_version = f"{version.major}.{version.minor}.{version.patch}"
|
||||
else:
|
||||
git_version = f"{version.major}.{version.minor}"
|
||||
print(git_version == "${version}")
|
||||
EOF
|
||||
)
|
||||
if [[ "$correct_version" != "True" ]]; then
|
||||
echo "Version in version.py doesn't match the passed ${version}."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
sh ../make_tarball.sh -v ${godot_version} -g ${git_treeish}
|
||||
popd
|
||||
fi
|
||||
|
||||
export basedir="$(pwd)"
|
||||
mkdir -p ${basedir}/out
|
||||
mkdir -p ${basedir}/out/logs
|
||||
|
||||
export podman_run="${podman} run -it --rm --env NUM_CORES -v ${basedir}/godot.tar.gz:/root/godot.tar.gz -v ${basedir}/mono-glue:/root/mono-glue -w /root/"
|
||||
|
||||
mkdir -p ${basedir}/mono-glue
|
||||
${podman_run} -v ${basedir}/build-mono-glue:/root/build ${registry}/godot/mono-glue:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/mono-glue
|
||||
export podman_run="${podman} run -it --rm --env BUILD_NAME=${BUILD_NAME} --env GODOT_VERSION_STATUS=${GODOT_VERSION_STATUS} --env NUM_CORES=${NUM_CORES} --env CLASSICAL=${build_classical} -v ${basedir}/godot-${godot_version}.tar.gz:/root/godot.tar.gz -w /root/"
|
||||
export img_version=$IMAGE_VERSION
|
||||
|
||||
mkdir -p ${basedir}/out/windows
|
||||
${podman_run} -v ${basedir}/build-windows:/root/build -v ${basedir}/out/windows:/root/out ${registry}/godot/windows:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/windows
|
||||
${podman_run} -v ${basedir}/build-windows:/root/build -v ${basedir}/out/windows:/root/out --env STEAM=${build_steam} localhost/godot-windows:${img_version} bash build/build.sh 2>&1 | tee ${basedir}/out/logs/windows
|
||||
|
||||
mkdir -p ${basedir}/out/linux/x64
|
||||
${podman_run} -v ${basedir}/build-linux:/root/build -v ${basedir}/out/linux/x64:/root/out ${registry}/godot/ubuntu-64:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/linux64
|
||||
mkdir -p ${basedir}/out/linux
|
||||
${podman_run} -v ${basedir}/build-linux:/root/build -v ${basedir}/out/linux:/root/out localhost/godot-linux:${img_version} bash build/build.sh 2>&1 | tee ${basedir}/out/logs/linux
|
||||
|
||||
mkdir -p ${basedir}/out/linux/x86
|
||||
${podman_run} -v ${basedir}/build-linux:/root/build -v ${basedir}/out/linux/x86:/root/out ${registry}/godot/ubuntu-32:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/linux32
|
||||
mkdir -p ${basedir}/out/web
|
||||
${podman_run} -v ${basedir}/build-web:/root/build -v ${basedir}/out/web:/root/out localhost/godot-web:${img_version} bash build/build.sh 2>&1 | tee ${basedir}/out/logs/web
|
||||
|
||||
mkdir -p ${basedir}/out/server/x64
|
||||
${podman_run} -v ${basedir}/build-server:/root/build -v ${basedir}/out/server/x64:/root/out ${registry}/godot/ubuntu-64:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/server
|
||||
|
||||
mkdir -p ${basedir}/out/javascript
|
||||
${podman_run} -v ${basedir}/build-javascript:/root/build -v ${basedir}/out/javascript:/root/out ${registry}/godot/javascript:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/javascript
|
||||
|
||||
mkdir -p ${basedir}/out/macosx/x64
|
||||
${podman_run} -v ${basedir}/build-macosx:/root/build -v ${basedir}/out/macosx/x64:/root/out ${registry}/godot-private/macosx:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/macosx
|
||||
mkdir -p ${basedir}/out/macos
|
||||
${podman_run} -v ${basedir}/build-macos:/root/build -v ${basedir}/out/macos:/root/out localhost/godot-osx:${img_version} bash build/build.sh 2>&1 | tee ${basedir}/out/logs/macos
|
||||
|
||||
mkdir -p ${basedir}/out/android
|
||||
${podman_run} -v ${basedir}/build-android:/root/build -v ${basedir}/out/android:/root/out ${registry}/godot-private/android:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/android
|
||||
${podman_run} -v ${basedir}/build-android:/root/build -v ${basedir}/out/android:/root/out localhost/godot-android:${img_version} bash build/build.sh 2>&1 | tee ${basedir}/out/logs/android
|
||||
|
||||
mkdir -p ${basedir}/out/ios
|
||||
${podman_run} -v ${basedir}/build-ios:/root/build -v ${basedir}/out/ios:/root/out ${registry}/godot-private/ios:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/ios
|
||||
|
||||
mkdir -p ${basedir}/out/uwp
|
||||
${podman_run} --ulimit nofile=32768:32768 -v ${basedir}/build-uwp:/root/build -v ${basedir}/out/uwp:/root/out ${registry}/godot-private/uwp:latest bash build/build.sh 2>&1 | tee ${basedir}/out/logs/uwp
|
||||
${podman_run} -v ${basedir}/build-ios:/root/build -v ${basedir}/out/ios:/root/out localhost/godot-ios:${img_version} bash build/build.sh 2>&1 | tee ${basedir}/out/logs/ios
|
||||
|
||||
uid=$(id -un)
|
||||
gid=$(id -gn)
|
||||
if [ ! -z "$SUDO_UID" ]; then
|
||||
chown -R "${SUDO_UID}":"${SUDO_GID}" ${basedir}/out
|
||||
uid="${SUDO_UID}"
|
||||
gid="${SUDO_GID}"
|
||||
fi
|
||||
chown -R -f $uid:$gid ${basedir}/git ${basedir}/out ${basedir}/godot*.tar.gz
|
||||
|
||||
echo "All builds completed. Check `out/logs/` to validate that they all succeeded (e.g. `tail -n 1 out/logs/*`)."
|
||||
|
||||
3
clean-release.sh
Executable file
3
clean-release.sh
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/bin/bash
|
||||
|
||||
rm -rf releases steam tmp web
|
||||
4
clean.sh
Executable file
4
clean.sh
Executable file
@@ -0,0 +1,4 @@
|
||||
#!/bin/bash
|
||||
|
||||
rm -rf godot*.tar.gz mono-glue out releases steam tmp web
|
||||
git status
|
||||
45
config.sh.in
45
config.sh.in
@@ -3,27 +3,40 @@
|
||||
# Configuration file for user-specific details.
|
||||
# This file is gitignore'd and will be sourced by build scripts.
|
||||
|
||||
# Registry for build containers.
|
||||
# The default registry is the one used for official Godot builds.
|
||||
# Note that some of its images are private and only accessible to selected
|
||||
# contributors.
|
||||
# You can build your own registry with scripts at
|
||||
# https://github.com/godotengine/build-containers
|
||||
export REGISTRY="registry.prehensile-tales.com"
|
||||
# Note: For passwords or GPG keys, make sure that special characters such
|
||||
# as $ won't be expanded, by using single quotes to enclose the string,
|
||||
# or escaping with \$.
|
||||
|
||||
# These scripts are designed and tested against podman. They may also work
|
||||
# with docker, but it's not guaranteed. You can set this variable to the
|
||||
# relevant tool in your PATH or an absolute path to run it from.
|
||||
export PODMAN='podman'
|
||||
|
||||
# Version string of the images to use in build.sh.
|
||||
export IMAGE_VERSION='2.1-f43'
|
||||
|
||||
# Default build name used to distinguish between official and custom builds.
|
||||
export BUILD_REVISION='custom_build'
|
||||
|
||||
# Default number of parallel cores for each build.
|
||||
export NUM_CORES=16
|
||||
|
||||
# Set up your own signing keystore and relevant details below.
|
||||
# Set up your own Windows signing details below.
|
||||
# If you do not fill all SIGN_* fields, signing will be skipped.
|
||||
|
||||
# Path to pkcs12 archive.
|
||||
export SIGN_KEYSTORE=""
|
||||
|
||||
# Password for the private key.
|
||||
export SIGN_PASSWORD=""
|
||||
|
||||
# Name and URL of the signed application.
|
||||
# Use your own when making a thirdparty build.
|
||||
export SIGN_NAME=""
|
||||
export SIGN_URL=""
|
||||
export WINDOWS_SIGN_NAME=''
|
||||
export WINDOWS_SIGN_URL=''
|
||||
|
||||
# Hostname or IP address of an OSX host (Needed for signing)
|
||||
# eg 'user@10.1.0.10'
|
||||
export OSX_HOST=''
|
||||
# ID of the Apple certificate used to sign
|
||||
export OSX_KEY_ID=''
|
||||
# Bundle id for the signed app
|
||||
export OSX_BUNDLE_ID=''
|
||||
# Username/password for Apple's signing APIs (used for notarytool)
|
||||
export APPLE_TEAM=''
|
||||
export APPLE_ID=''
|
||||
export APPLE_ID_PASSWORD=''
|
||||
|
||||
66
make_tarball.sh
Executable file
66
make_tarball.sh
Executable file
@@ -0,0 +1,66 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ ! -e "version.py" ]; then
|
||||
echo "This script should be ran from the root folder of the Godot repository."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
while getopts "h?sv:g:" opt; do
|
||||
case "$opt" in
|
||||
h|\?)
|
||||
echo "Usage: $0 [OPTIONS...]"
|
||||
echo
|
||||
echo " -s script friendly file name (godot.tar.gz)"
|
||||
echo " -v godot version for file name (e.g. 4.0-stable)"
|
||||
echo " -g git treeish to archive (e.g. master)"
|
||||
echo
|
||||
exit 1
|
||||
;;
|
||||
s)
|
||||
script_friendly_name=1
|
||||
;;
|
||||
v)
|
||||
godot_version=$OPTARG
|
||||
;;
|
||||
g)
|
||||
git_treeish=$OPTARG
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ ! -z "$git_treeish" ]; then
|
||||
HEAD=$(git rev-parse $git_treeish)
|
||||
else
|
||||
HEAD=$(git rev-parse HEAD)
|
||||
fi
|
||||
|
||||
if [ ! -z "$script_friendly_name" ]; then
|
||||
NAME=godot
|
||||
else
|
||||
if [ ! -z "$godot_version" ]; then
|
||||
NAME=godot-$godot_version
|
||||
else
|
||||
NAME=godot-$HEAD
|
||||
fi
|
||||
fi
|
||||
|
||||
CURDIR=$(pwd)
|
||||
TMPDIR=$(mktemp -d -t godot-XXXXXX)
|
||||
|
||||
echo "Generating tarball for revision $HEAD with folder name '$NAME'."
|
||||
echo
|
||||
echo "The tarball will be written to the parent folder:"
|
||||
echo " $(dirname $CURDIR)/$NAME.tar.gz"
|
||||
|
||||
git archive $HEAD --prefix=$NAME/ -o $TMPDIR/$NAME.tar
|
||||
|
||||
# Adding custom .git/HEAD to tarball so that we can generate VERSION_HASH.
|
||||
cd $TMPDIR
|
||||
mkdir -p $NAME/.git
|
||||
echo $HEAD > $NAME/.git/HEAD
|
||||
tar -uf $NAME.tar $NAME
|
||||
|
||||
cd $CURDIR
|
||||
gzip -c $TMPDIR/$NAME.tar > ../$NAME.tar.gz
|
||||
|
||||
rm -rf $TMPDIR
|
||||
BIN
osslsigncode
BIN
osslsigncode
Binary file not shown.
114
publish-release.sh
Executable file
114
publish-release.sh
Executable file
@@ -0,0 +1,114 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
# Log output to a file automatically.
|
||||
exec > >(tee -a "out/logs/publish-release") 2>&1
|
||||
|
||||
# Config
|
||||
|
||||
# For upload tools and signing/release keys.
|
||||
source ./config.sh
|
||||
|
||||
godot_version=""
|
||||
skip_stable=0
|
||||
draft_arg=""
|
||||
|
||||
while getopts "h?v:sd" opt; do
|
||||
case "$opt" in
|
||||
h|\?)
|
||||
echo "Usage: $0 [OPTIONS...]"
|
||||
echo
|
||||
echo " -v godot version (e.g: 3.2-stable) [mandatory]"
|
||||
echo " -s don't run stable specific steps"
|
||||
echo " -d publish as draft release on GitHub"
|
||||
echo
|
||||
exit 1
|
||||
;;
|
||||
v)
|
||||
godot_version=$OPTARG
|
||||
;;
|
||||
s)
|
||||
skip_stable=1
|
||||
;;
|
||||
d)
|
||||
draft_arg="-d"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
if [ -z "${godot_version}" ]; then
|
||||
echo "Mandatory argument -v missing."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
basedir=$(pwd)
|
||||
reldir=${basedir}/releases/${godot_version}
|
||||
|
||||
# Confirm
|
||||
|
||||
IFS=- read version status <<< "${godot_version}"
|
||||
echo "Publishing Godot ${version} ${status}."
|
||||
read -p "Is this correct (y/n)? " choice
|
||||
case "$choice" in
|
||||
y|Y ) echo "yes";;
|
||||
n|N ) echo "No, aborting."; exit 0;;
|
||||
* ) echo "Invalid choice, aborting."; exit 1;;
|
||||
esac
|
||||
template_version=${version}.${status}
|
||||
|
||||
# Config checks for stable releases.
|
||||
|
||||
if [ "${status}" == "stable" -a "${skip_stable}" == "0" ]; then
|
||||
echo "Publishing a stable release. Checking that configuration is valid to perform stable release specific steps."
|
||||
|
||||
read -p "Enter personal access token (GH_TOKEN) for godotengine/godot: " personal_gh_token
|
||||
if [[ "${personal_gh_token}" != "github_pat_"* ]]; then
|
||||
echo "Provided personal access token should start with 'github_pat', aborting."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if ! gh api repos/godotengine/godot/git/refs/tags | grep -q ${godot_version}; then
|
||||
echo "The tag '${godot_version}' does not exist in godotengine/godot, aborting."
|
||||
echo "Push commits and create it manually before running this script."
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
# Upload to GitHub godot-builds
|
||||
|
||||
echo "Uploading release to to godotengine/godot-builds repository."
|
||||
|
||||
if [ -z "${GODOT_BUILDS_PATH}" ]; then
|
||||
echo "Missing path to godotengine/godot-builds clone in config.sh, necessary to upload releases. Aborting."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
${GODOT_BUILDS_PATH}/tools/upload-github.sh -v ${version} -f ${status} ${draft_arg}
|
||||
|
||||
# Stable release only
|
||||
|
||||
if [ "${status}" == "stable" -a "${skip_stable}" == "0" ]; then
|
||||
namever=Godot_v${godot_version}
|
||||
|
||||
echo "Uploading stable release to main GitHub repository."
|
||||
|
||||
export GH_TOKEN=${personal_gh_token}
|
||||
pushd git
|
||||
# Get release details from existing godot-builds release.
|
||||
release_info=$(gh release view ${godot_version} --repo godotengine/godot-builds --json name,body)
|
||||
release_title=$(echo "$release_info" | jq -r '.name')
|
||||
release_desc=$(echo "$release_info" | jq -r '.body')
|
||||
|
||||
gh release create ${godot_version} --repo godotengine/godot --title "$release_title" --notes "$release_desc" ${draft_arg}
|
||||
gh release upload ${godot_version} ${reldir}/[Gg]*
|
||||
# Concatenate SHA sums.
|
||||
cp ${reldir}/SHA512-SUMS.txt .
|
||||
gh release upload ${godot_version} SHA512-SUMS.txt
|
||||
rm SHA512-SUMS.txt
|
||||
popd
|
||||
|
||||
echo "All stable release upload steps done."
|
||||
fi
|
||||
|
||||
echo "All publishing steps done. Check out/logs/publish-release to double check that all steps succeeded."
|
||||
Reference in New Issue
Block a user