From c2b6fdf6d199faf00d33a0a4f3a0369e0b28a65d Mon Sep 17 00:00:00 2001 From: Relintai Date: Sat, 11 Jun 2022 00:42:37 +0200 Subject: [PATCH] Removed some of the helper scripts, as I added them to the engine directly. --- Makefile | 20 ---- build_ios.sh | 19 --- build_ios_release.sh | 21 ---- build_osx.sh | 15 --- build_pi.sh | 12 -- build_uwp.bat | 14 --- export_all.sh | 53 --------- make_release.sh | 55 --------- tools/copy_repos.py | 111 ------------------ .../pre_release_check_files_present.sh | 48 -------- tools/vscode-setup/launch.json | 67 ----------- tools/vscode-setup/settings.json | 6 - tools/vscode-setup/tasks.json | 26 ---- 13 files changed, 467 deletions(-) delete mode 100644 Makefile delete mode 100755 build_ios.sh delete mode 100755 build_ios_release.sh delete mode 100755 build_osx.sh delete mode 100755 build_pi.sh delete mode 100644 build_uwp.bat delete mode 100755 export_all.sh delete mode 100755 make_release.sh delete mode 100644 tools/copy_repos.py delete mode 100755 tools/release/pre_release_check_files_present.sh delete mode 100644 tools/vscode-setup/launch.json delete mode 100644 tools/vscode-setup/settings.json delete mode 100644 tools/vscode-setup/tasks.json diff --git a/Makefile b/Makefile deleted file mode 100644 index f1b47578..00000000 --- a/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -all: - scons bels -j5 - -e: - scons belsE -j5 - -t: - scons belsT -j5 - -v: - scons belsV -j5 - -W: - scons belsW -j5 - -p: - scons belsP -j5 - -m: - scons belsM -j5 diff --git a/build_ios.sh b/build_ios.sh deleted file mode 100755 index 8b038511..00000000 --- a/build_ios.sh +++ /dev/null @@ -1,19 +0,0 @@ - -export SCONS_CACHE=~/.scons_cache -export SCONS_CACHE_LIMIT=5000 - -cd ./pandemonium_engine - -scons -j6 p=iphone tools=no target=release_debug arch=arm module_arkit_enabled=no game_center=no -scons -j6 p=iphone tools=no target=release_debug arch=arm64 module_arkit_enabled=no game_center=no -lipo -create bin/libpandemonium.iphone.opt.debug.arm.a bin/libpandemonium.iphone.opt.debug.arm64.a -output bin/libpandemonium.iphone.debug.fat.a -rm bin/ios_xcode/libpandemonium.iphone.debug.fat.a -cp bin/libpandemonium.iphone.debug.fat.a bin/ios_xcode/libpandemonium.iphone.debug.fat.a - -rm bin/iphone.zip -cd bin/ios_xcode -zip -r -X ../iphone.zip . - -cd .. -cd .. -cd .. diff --git a/build_ios_release.sh b/build_ios_release.sh deleted file mode 100755 index afcb7414..00000000 --- a/build_ios_release.sh +++ /dev/null @@ -1,21 +0,0 @@ - -export SCONS_CACHE=~/.scons_cache -export SCONS_CACHE_LIMIT=5000 - -cd ./pandemonium_engine - -scons -j6 p=iphone tools=no target=release arch=arm module_arkit_enabled=no game_center=no -scons -j6 p=iphone tools=no target=release arch=arm64 module_arkit_enabled=no game_center=no -lipo -create bin/libpandemonium.iphone.opt.arm.a bin/libpandemonium.iphone.opt.arm64.a -output bin/libpandemonium.iphone.release.fat.a -rm bin/ios_xcode/libpandemonium.iphone.release.fat.a -cp bin/libpandemonium.iphone.release.fat.a bin/ios_xcode/libpandemonium.iphone.release.fat.a - -rm bin/iphone.zip -cd bin/ios_xcode -zip -r -X ../iphone.zip . - -cd .. -cd .. - - -cd .. diff --git a/build_osx.sh b/build_osx.sh deleted file mode 100755 index c5bbfa8d..00000000 --- a/build_osx.sh +++ /dev/null @@ -1,15 +0,0 @@ - -export SCONS_CACHE=~/.scons_cache -export SCONS_CACHE_LIMIT=5000 - -cd ./pandemonium_engine - -scons -j6 platform=osx target=release_debug - -rm -Rf bin/Godot.app -cp -r misc/dist/osx_tools.app ./bin/Godot.app -mkdir -p ./bin/Godot.app/Contents/MacOS -cp bin/pandemonium.osx.opt.tools.64 bin/Godot.app/Contents/MacOS/Godot -chmod +x bin/Godot.app/Contents/MacOS/Godot - -cd .. diff --git a/build_pi.sh b/build_pi.sh deleted file mode 100755 index cf083225..00000000 --- a/build_pi.sh +++ /dev/null @@ -1,12 +0,0 @@ - -scons bel_latomic_strip_slim -j4 -scons bl_latomic_strip_slim -j4 -scons blr_latomic_strip_slim -j4 - -rm -f ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.32 -rm -f ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.debug.32 -rm -f ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.tools.32 - -mv ./pandemonium_engine/bin/pandemonium.x11.opt.32 ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.32 -mv ./pandemonium_engine/bin/pandemonium.x11.opt.debug.32 ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.debug.32 -mv ./pandemonium_engine/bin/pandemonium.x11.opt.tools.32 ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.tools.32 diff --git a/build_uwp.bat b/build_uwp.bat deleted file mode 100644 index d27e52a8..00000000 --- a/build_uwp.bat +++ /dev/null @@ -1,14 +0,0 @@ - -cd ./pandemonium_engine - -if not defined DevEnvDir ( - rem call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" x86 - call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x64 -) - -call scons -j6 platform=uwp target=release -rem call scons -j6 platform=uwp target=release_debug -rem call scons -j6 platform=uwp target=release - -cd .. - diff --git a/export_all.sh b/export_all.sh deleted file mode 100755 index e7763c95..00000000 --- a/export_all.sh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/bash -set -e - -version="" -version_snake_cased="" - -if [ ! -z $1 ]; then - version="." - version+=$1 - - version_snake_cased=${version//./_} -fi - -project_root=$(pwd) - -rm -Rf ./export - -mkdir export -mkdir export/broken_seals${version_snake_cased}_android_release -mkdir export/broken_seals${version_snake_cased}_android_debug -mkdir export/broken_seals${version_snake_cased}_linux -mkdir export/broken_seals${version_snake_cased}_windows -mkdir export/broken_seals${version_snake_cased}_javascript -mkdir export/broken_seals${version_snake_cased}_pi4 -mkdir export/broken_seals${version_snake_cased}_osx -mkdir export/export_templates_bs${version_snake_cased} - -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export-debug Android-Release ${project_root}/export/broken_seals${version_snake_cased}_android_release/broken_seals${version_snake_cased}.apk -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export-debug Android ${project_root}/export/broken_seals${version_snake_cased}_android_debug/broken_seals_debug${version_snake_cased}.apk -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export Linux/X11 ${project_root}/export/broken_seals${version_snake_cased}_linux/broken_seals${version_snake_cased}_x11 -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export "Windows Desktop" ${project_root}/export/broken_seals${version_snake_cased}_windows/broken_seals${version_snake_cased}.exe -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export HTML5 ${project_root}/export/broken_seals${version_snake_cased}_javascript/broken_seals.html -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export PI4/X11 ${project_root}/export/broken_seals${version_snake_cased}_pi4/broken_seals${version_snake_cased}_pi4 -./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 --path ./game/ --export "Mac OSX" ${project_root}/export/broken_seals${version_snake_cased}_osx/broken_seals${version_snake_cased}.app - -cp ./pandemonium_engine/bin/pandemonium.windows.opt.tools.64.exe ${project_root}/export/pandemonium.bs${version}.windows.opt.tools.64.exe -cp ./pandemonium_engine/bin/pandemonium.x11.opt.tools.64 ${project_root}/export/pandemonium.bs${version}.x11.opt.tools.64 -cp ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.tools.32 ${project_root}/export/pandemonium.bs${version}.x11.pi4.opt.tools.32 -cp ./pandemonium_engine/bin/pandemonium.javascript.opt.tools.threads.zip ${project_root}/export/pandemonium.bs${version}.javascript.opt.tools.zip -cp ./pandemonium_engine/bin/android_editor.apk ${project_root}/export/pandemonium.bs${version}.android_editor.apk -cp ./pandemonium_engine/bin/Pandemonium.app.zip ${project_root}/export/pandemonium.bs${version}.osx.opt.tools.zip - -cp ./pandemonium_engine/bin/android_debug.apk ${project_root}/export/export_templates_bs${version_snake_cased}/android_debug.apk -cp ./pandemonium_engine/bin/android_release.apk ${project_root}/export/export_templates_bs${version_snake_cased}/android_release.apk -cp ./pandemonium_engine/bin/pandemonium.javascript.opt.debug.zip ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.javascript.opt.debug.zip -cp ./pandemonium_engine/bin/pandemonium.javascript.opt.zip ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.javascript.opt.zip -cp ./pandemonium_engine/bin/pandemonium.windows.opt.64.exe ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.windows.opt.64.exe -cp ./pandemonium_engine/bin/pandemonium.windows.opt.debug.64.exe ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.windows.opt.debug.64.exe -cp ./pandemonium_engine/bin/pandemonium.x11.opt.64 ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.x11.opt.64 -cp ./pandemonium_engine/bin/pandemonium.x11.opt.debug.64 ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.x11.opt.debug.64 -cp ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.32 ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.x11.pi4.opt.32 -cp ./pandemonium_engine/bin/pandemonium.x11.pi4.opt.debug.32 ${project_root}/export/export_templates_bs${version_snake_cased}/pandemonium.x11.pi4.opt.debug.32 -cp ./pandemonium_engine/bin/osx.zip ${project_root}/export/export_templates_bs${version_snake_cased}/osx.zip diff --git a/make_release.sh b/make_release.sh deleted file mode 100755 index b6cc0e7b..00000000 --- a/make_release.sh +++ /dev/null @@ -1,55 +0,0 @@ -#!/bin/bash -set -e - -version="" -version_snake_cased="" - -if [ ! -z $1 ]; then - version="." - version+=$1 - - version_snake_cased=${version//./_} -fi - -project_root=$(pwd) - -rm -Rf ./release - -mkdir release - -cd export - -rm -Rf broken_seals${version_snake_cased}_full_source -rm -Rf broken_seals${version_snake_cased}_game_source - -mkdir broken_seals${version_snake_cased}_full_source -mkdir broken_seals${version_snake_cased}_game_source - -# Warn if a file is over a megabyte. Used to catch big temporary files that would slip through outherwise -python ../tools/copy_repos.py ../ ./broken_seals${version_snake_cased}_full_source 1048576 -python ../tools/copy_repos.py ../game/ ./broken_seals${version_snake_cased}_game_source - -zip -q ../release/broken_seals${version_snake_cased}_android_debug.zip ./broken_seals${version_snake_cased}_android_debug/* -zip -q ../release/broken_seals${version_snake_cased}_android_release.zip ./broken_seals${version_snake_cased}_android_release/* -zip -q ../release/broken_seals${version_snake_cased}_javascript.zip ./broken_seals${version_snake_cased}_javascript/* -zip -q ../release/broken_seals${version_snake_cased}_linux.zip ./broken_seals${version_snake_cased}_linux/* -zip -q ../release/broken_seals${version_snake_cased}_windows.zip ./broken_seals${version_snake_cased}_windows/* -zip -q ../release/broken_seals${version_snake_cased}_pi4.zip ./broken_seals${version_snake_cased}_pi4/* -zip -r -q ../release/broken_seals${version_snake_cased}_osx.zip ./broken_seals${version_snake_cased}_osx/* - -# Editor -zip -q ../release/editor_windows_bs${version_snake_cased}.zip ./pandemonium.bs${version}.windows.opt.tools.64.exe -zip -q ../release/editor_linux_bs${version_snake_cased}.zip ./pandemonium.bs${version}.x11.opt.tools.64 -zip -q ../release/editor_pi4_bs${version_snake_cased}.zip ./pandemonium.bs${version}.x11.pi4.opt.tools.32 -cp ./pandemonium.bs${version}.javascript.opt.tools.zip ../release/editor_javascript_bs${version_snake_cased}.zip -zip -q ../release/editor_osx_bs${version_snake_cased}.zip ./pandemonium.bs${version}.osx.opt.tools.zip -zip -q ../release/pandemonium.bs${version}.android_editor.zip ./pandemonium.bs${version}.android_editor.apk - -zip -q ../release/export_templates_bs${version_snake_cased}.zip ./export_templates_bs${version_snake_cased}/* -#mv ../release/export_templates_bs${version_snake_cased}.zip ../release/export_templates_bs${version_snake_cased}.tpz - -zip -q -r ../release/broken_seals${version_snake_cased}_full_source.zip ./broken_seals${version_snake_cased}_full_source/* -zip -q -r ../release/broken_seals${version_snake_cased}_game_source.zip ./broken_seals${version_snake_cased}_game_source/* - -cd .. - diff --git a/tools/copy_repos.py b/tools/copy_repos.py deleted file mode 100644 index 5b228fe7..00000000 --- a/tools/copy_repos.py +++ /dev/null @@ -1,111 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- - -# Copyright (c) 2019-2021 Péter Magyar -# -# 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. - -import sys -import os -import subprocess -import json -import shutil -import traceback - -def onerror(func, path, exc_info): - """ - https://stackoverflow.com/questions/2656322/shutil-rmtree-fails-on-windows-with-access-is-denied - - Because Windows. - - Error handler for ``shutil.rmtree``. - - If the error is due to an access error (read only file) - it attempts to add write permission and then retries. - - If the error is for another reason it re-raises the error. - - Usage : ``shutil.rmtree(path, onerror=onerror)`` - """ - import stat - if not os.access(path, os.W_OK): - # Is the error an access error ? - os.chmod(path, stat.S_IWUSR) - func(path) - else: - raise - -def copytree(src, dst, warn = 0): - for item in os.listdir(src): - - sp = os.path.join(src, item) - dp = os.path.join(dst, item) - - if os.path.isdir(sp): - if item == ".git" or item == ".gradle" or item == "bin" or item == "__pycache__" or item == ".import" or item == "logs" or item == "release" or item == "export" or item == "build" or item == "libs": - continue - - #print(item) - - if os.path.isdir(dp): - shutil.rmtree(dp, onerror=onerror) - - copytree(sp, dp, warn) - else: - if item.endswith(".a") or item.endswith(".class") or item.endswith(".dex") or item.endswith(".pyc") or item.endswith(".o") or item.endswith(".bc") or item.endswith(".so") or item == "export_presets.cfg" or item.endswith(".gen.h") or item.endswith(".os") or item.endswith(".dblite") or item == ".scons_node_count" or item == ".scons_env.json" or item == "compile_commands.json" or item == "config.log" or item.endswith(".gen.inc") or item.endswith(".gen.cpp") : - continue - - #print(item) - - if not os.path.isdir(dst): - os.makedirs(dst) - - file_size_bytes = os.path.getsize(sp) - - if warn > 0 and file_size_bytes >= warn: - # Ignore assets, this is meant to catch temp / generated files - if not (item.endswith(".po") or item.endswith(".tres") or item.endswith(".ttf") or item.endswith(".tza") or item.endswith(".blend") or item.endswith(".blend1") or item.endswith(".pot")): - print("WARNING! File '", sp, "' (", file_size_bytes, "bytes) is over the warn threshold!") - - shutil.copy2(sp, dp) - -def copy_repository(data, target_folder, clone_path): - copytree(os.path.abspath(clone_path + data[1] + '/' + data[2]), os.path.abspath(target_folder + data[1])) - - -#copy_repository(rep, './game/addons/', '.' + module_clone_path) - -#print(sys.argv) - -if len(sys.argv) == 3 or len(sys.argv) == 4: - src_dir = sys.argv[1] - dst_dir = sys.argv[2] - warn = 0 - - if len(sys.argv) == 4: - warn = int(sys.argv[3]) - - src_dir = os.path.abspath(src_dir) - dst_dir = os.path.abspath(dst_dir) - - copytree(src_dir, dst_dir, warn) - - -else: - print("Usange: python copy_repos.py source_dir target_dir") diff --git a/tools/release/pre_release_check_files_present.sh b/tools/release/pre_release_check_files_present.sh deleted file mode 100755 index 41ce94b1..00000000 --- a/tools/release/pre_release_check_files_present.sh +++ /dev/null @@ -1,48 +0,0 @@ -cd ../../pandemonium_engine/bin/ - -files=( - # Windows - "pandemonium.windows.opt.64.exe" - "pandemonium.windows.opt.debug.64.exe" - "pandemonium.windows.opt.tools.64.exe" - - # Linux - "pandemonium.x11.opt.64" - "pandemonium.x11.opt.debug.64" - "pandemonium.x11.opt.tools.64" - - # JS - "pandemonium.javascript.opt.tools.threads.zip" - "pandemonium.javascript.opt.zip" - # Android - - "android_debug.apk" - "android_release.apk" - - # OSX - Editor - "Pandemonium.app.zip" - - # OSX - export templates - "osx.zip" - - # Pi4 - "pandemonium.x11.pi4.opt.32" - "pandemonium.x11.pi4.opt.debug.32" - "pandemonium.x11.pi4.opt.tools.32" -) - -error=0 - -for f in ${files[*]} -do -if [ ! -e $f ]; then - error=1 - echo "$f is not present!" -fi -done - -if [ $error -eq 0 ]; then - echo "All files are present!" -fi - -cd ../.. diff --git a/tools/vscode-setup/launch.json b/tools/vscode-setup/launch.json deleted file mode 100644 index 985eb3e4..00000000 --- a/tools/vscode-setup/launch.json +++ /dev/null @@ -1,67 +0,0 @@ -{ - // Use IntelliSense to learn about possible attributes. - // Hover to view descriptions of existing attributes. - // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 - "version": "0.2.0", - "configurations": [ - { - "name": "build and debug", - "type": "cppdbg", - "request": "launch", - "program": "${workspaceFolder}/bin/godot.x11.opt.tools.64", - "args": [ - "--path", - "${workspaceFolder}/../game/" - ], - "stopAtEntry": false, - "cwd": "${workspaceFolder}", - "environment": [ - { - "name": "LD_LIBRARY_PATH", - "value": "${workspaceFolder}/bin/" - } - ], - "externalConsole": false, - "MIMode": "gdb", - "setupCommands": [ - { - "description": "Enable pretty-printing for gdb", - "text": "-enable-pretty-printing", - "ignoreFailures": true - } - ], - "preLaunchTask": "build", - //"miDebuggerPath": "/usr/bin/gdb" - }, - { - "name": "debug", - "type": "cppdbg", - "request": "launch", - "program": "${workspaceFolder}/bin/godot.x11.opt.tools.64", - //"args": ["-e"], - "args": [ - "--path", - "${workspaceFolder}/../game/", - ], - "stopAtEntry": false, - "cwd": "${workspaceFolder}", - "environment": [ - { - "name": "LD_LIBRARY_PATH", - "value": "${workspaceFolder}/bin/" - } - ], - "externalConsole": false, - "MIMode": "gdb", - "setupCommands": [ - { - "description": "Enable pretty-printing for gdb", - "text": "-enable-pretty-printing", - "ignoreFailures": true - } - ], - //"preLaunchTask": "build", - //"miDebuggerPath": "/usr/bin/gdb" - } - ] -} \ No newline at end of file diff --git a/tools/vscode-setup/settings.json b/tools/vscode-setup/settings.json deleted file mode 100644 index 9ce7b68f..00000000 --- a/tools/vscode-setup/settings.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "files.associations": { - "functional": "cpp", - }, - "editor.formatOnSave": true -} \ No newline at end of file diff --git a/tools/vscode-setup/tasks.json b/tools/vscode-setup/tasks.json deleted file mode 100644 index e53957c6..00000000 --- a/tools/vscode-setup/tasks.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - // See https://go.microsoft.com/fwlink/?LinkId=733558 - // for the documentation about the tasks.json format - "version": "2.0.0", - "tasks": [ - { - "label": "build", - "type": "shell", - "command": "scons", - "group": "build", - "args": [ - "platform=x11", - "custom_modules_shared=yes", - "target=release_debug", - //"bin/libess.x11.opt.tools.64.so", - //"bin/libtexture_packer.x11.opt.tools.64.so", - "bin/libvoxelman.x11.opt.tools.64.so", - //"bin/libworld_generator.x11.opt.tools.64.so", - //"bin/libprocedural_animations.x11.opt.tools.64.so", - //"bin/libfqms.x11.opt.tools.64.so", - "-j3" - ], - "problemMatcher": "$msCompile" - } - ] -} \ No newline at end of file