Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Solstice245 committed Jan 30, 2025
2 parents 31c0a90 + 2f7bfd3 commit b868f29
Show file tree
Hide file tree
Showing 1,996 changed files with 348,764 additions and 664,864 deletions.
40 changes: 0 additions & 40 deletions .ci/azure/prepare_git_repo.cmake

This file was deleted.

236 changes: 0 additions & 236 deletions .ci/azure/templates/macos-build-pipeline-template.yml

This file was deleted.

14 changes: 0 additions & 14 deletions .ci/azure/templates/prepare-repo-steps.yml

This file was deleted.

14 changes: 14 additions & 0 deletions .ci/cmake/toolchains/aarch64-w64-mingw32.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
SET(CMAKE_SYSTEM_NAME "Windows")
SET(CMAKE_SYSTEM_PROCESSOR "ARM64")
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
set(CMAKE_CROSSCOMPILING OFF CACHE BOOL "")
endif()

set(_WZ_MINGW_TRIPLET_PREFIX "aarch64")

find_program(CMAKE_C_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-gcc")
find_program(CMAKE_CXX_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-g++")
find_program(CMAKE_RC_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-windres")
if(NOT CMAKE_RC_COMPILER)
find_program(CMAKE_RC_COMPILER "windres")
endif()
14 changes: 14 additions & 0 deletions .ci/cmake/toolchains/i686-w64-mingw32.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
SET(CMAKE_SYSTEM_NAME "Windows")
SET(CMAKE_SYSTEM_PROCESSOR "X86")
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
set(CMAKE_CROSSCOMPILING OFF CACHE BOOL "")
endif()

set(_WZ_MINGW_TRIPLET_PREFIX "i686")

find_program(CMAKE_C_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-gcc")
find_program(CMAKE_CXX_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-g++")
find_program(CMAKE_RC_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-windres")
if(NOT CMAKE_RC_COMPILER)
find_program(CMAKE_RC_COMPILER "windres")
endif()
File renamed without changes.
33 changes: 33 additions & 0 deletions .ci/cmake/toolchains/wasm32-emscripten.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Toolchain for compiling for Emscripten

# Note:
# This is a bit of a hack.
# We actually want to use the Emscripten.cmake toolchain provided by Emscripten...
# However we also want to override and enable pthreads for everything

if(NOT DEFINED ENV{EMSCRIPTEN_ROOT})
find_path(EMSCRIPTEN_ROOT "emcc")
else()
set(EMSCRIPTEN_ROOT "$ENV{EMSCRIPTEN_ROOT}")
endif()

if(NOT EMSCRIPTEN_ROOT)
if(NOT DEFINED ENV{EMSDK})
message(FATAL_ERROR "The emcc compiler not found in PATH")
endif()
set(EMSCRIPTEN_ROOT "$ENV{EMSDK}/upstream/emscripten")
endif()

if(NOT EXISTS "${EMSCRIPTEN_ROOT}/cmake/Modules/Platform/Emscripten.cmake")
message(FATAL_ERROR "Emscripten.cmake toolchain file not found")
endif()

include("${EMSCRIPTEN_ROOT}/cmake/Modules/Platform/Emscripten.cmake")

# Always enable PThreads
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -s USE_PTHREADS=1 -s USE_SDL=0")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -s USE_PTHREADS=1 -s USE_SDL=0")

# Enable optimizations for release builds
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O2")
set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -O2")
14 changes: 14 additions & 0 deletions .ci/cmake/toolchains/x86_64-w64-mingw32.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
SET(CMAKE_SYSTEM_NAME "Windows")
SET(CMAKE_SYSTEM_PROCESSOR "AMD64")
if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Windows")
set(CMAKE_CROSSCOMPILING OFF CACHE BOOL "")
endif()

set(_WZ_MINGW_TRIPLET_PREFIX "x86_64")

find_program(CMAKE_C_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-gcc")
find_program(CMAKE_CXX_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-g++")
find_program(CMAKE_RC_COMPILER "${_WZ_MINGW_TRIPLET_PREFIX}-w64-mingw32-windres")
if(NOT CMAKE_RC_COMPILER)
find_program(CMAKE_RC_COMPILER "windres")
endif()
24 changes: 24 additions & 0 deletions .ci/flatpak/Toolchain-cross-arch.cmake.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Toolchain for cross-compiling

set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR "@WZ_CROSS_COMPILE_TARGET_ARCH@")

# Specify the cross compiler
set(CMAKE_C_COMPILER "@WZ_CROSS_COMPILE_TARGET_ARCH@-unknown-linux-gnu-gcc")
set(CMAKE_CXX_COMPILER "@WZ_CROSS_COMPILE_TARGET_ARCH@-unknown-linux-gnu-g++")

# Target search paths
set(CMAKE_FIND_ROOT_PATH "/app;/usr/lib/@WZ_CROSS_COMPILE_TARGET_ARCH@-linux-gnu;/usr/include/@WZ_CROSS_COMPILE_TARGET_ARCH@-linux-gnu" CACHE STRING "Find root path" FORCE)

# Search for programs in the build host directories
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)

# Search for libraries and headers in the target directories
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE BOTH)
set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)

# Point pkgconfig at target arch .pc files first, falling back to regular system .pc files
if(EXISTS "/usr/lib/@WZ_CROSS_COMPILE_TARGET_ARCH@-linux-gnu/pkgconfig")
set(ENV{PKG_CONFIG_LIBDIR} "/usr/lib/@WZ_CROSS_COMPILE_TARGET_ARCH@-linux-gnu/pkgconfig")
endif()
Loading

0 comments on commit b868f29

Please sign in to comment.