Migrating to using Toolchains compilers.
This commit is contained in:
parent
642742a1c8
commit
6802761e49
5 changed files with 27 additions and 124 deletions
29
build-all.sh
29
build-all.sh
|
@ -33,6 +33,7 @@ function buildAll() {
|
|||
local TOOLCHAIN=
|
||||
local COMMON=
|
||||
local CROSS_OS=
|
||||
local OSXCROSS_LOCATION=
|
||||
|
||||
|
||||
case "${OS}" in
|
||||
|
@ -49,6 +50,27 @@ function buildAll() {
|
|||
CROSS_OS="linux"
|
||||
;;
|
||||
|
||||
macos)
|
||||
case "${ARCH}" in
|
||||
aarch64)
|
||||
TRIPLE="aarch64-apple-darwin22.4"
|
||||
OSXCROSS_LOCATION=${G_BUILDROOT}/../toolchains/x-tools/aarch64-macos-apple
|
||||
;;
|
||||
x86)
|
||||
TRIPLE="i386-apple-darwin17"
|
||||
OSXCROSS_LOCATION=${G_BUILDROOT}/../toolchains/x-tools/x86_64-macos-apple
|
||||
;;
|
||||
x86_64)
|
||||
TRIPLE="x86_64-apple-darwin17"
|
||||
OSXCROSS_LOCATION=${G_BUILDROOT}/../toolchains/x-tools/x86_64-macos-apple
|
||||
;;
|
||||
esac
|
||||
CROSS_OS="darwin"
|
||||
source <("${OSXCROSS_LOCATION}/bin/osxcross-conf" 2>/dev/null)
|
||||
export OSXCROSS_LOCATION
|
||||
;;
|
||||
|
||||
|
||||
windows)
|
||||
case "${ARCH}" in
|
||||
x86)
|
||||
|
@ -66,7 +88,7 @@ function buildAll() {
|
|||
|
||||
G_TARGET=${G_BUILDROOT}/build/${OS}/${ARCH}
|
||||
G_GENERATED=${G_TARGET}/generated
|
||||
TOOLCHAIN=${G_BUILDROOT}/cmake/${TRIPLE}.cmake
|
||||
TOOLCHAIN=${G_BUILDROOT}/../toolchains/cmake/${TRIPLE}.cmake
|
||||
COMMON="-DCMAKE_INSTALL_PREFIX=${G_TARGET} -DCMAKE_TOOLCHAIN_FILE=${TOOLCHAIN}"
|
||||
# Add CMAKE_BUILD_TYPE to COMMON
|
||||
|
||||
|
@ -387,6 +409,9 @@ function outputLicense() {
|
|||
|
||||
|
||||
#buildAll linux x86
|
||||
buildAll linux x86_64
|
||||
#buildAll linux x86_64
|
||||
buildAll macos aarch64
|
||||
#buildAll macos x86 #***TODO*** Needs older SDL2
|
||||
#buildAll macos x86_64 #***TODO*** Needs older SDL2
|
||||
#buildAll windows x86
|
||||
#buildAll windows x86_64
|
||||
|
|
|
@ -1,30 +0,0 @@
|
|||
#
|
||||
# Singe 2
|
||||
# Copyright (C) 2006-2024 Scott Duensing <scott@kangaroopunch.com>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public Licens
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_PROCESSOR i686)
|
||||
|
||||
set(CMAKE_C_COMPILER i686-linux-gnu-gcc)
|
||||
set(CMAKE_C_FLAGS -m32)
|
||||
set(CMAKE_CXX_COMPILER i686-linux-gnu-g++)
|
||||
set(CMAKE_CXX_FLAGS -m32)
|
||||
|
||||
set(KANGAROO_OS linux)
|
||||
set(KANGAROO_ARCH x86)
|
|
@ -1,35 +0,0 @@
|
|||
#
|
||||
# Singe 2
|
||||
# Copyright (C) 2006-2024 Scott Duensing <scott@kangaroopunch.com>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public Licens
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Windows)
|
||||
set(CMAKE_SYSTEM_PROCESSOR i686)
|
||||
|
||||
set(triple i686-w64-mingw32)
|
||||
|
||||
set(CMAKE_C_COMPILER i686-w64-mingw32-gcc-10-posix)
|
||||
set(CMAKE_C_COMPILER_TARGET ${triple})
|
||||
set(CMAKE_CXX_COMPILER i686-w64-mingw32-c++-posix)
|
||||
set(CMAKE_CXX_COMPILER_TARGET ${triple})
|
||||
|
||||
set(CMAKE_C_FLAGS -m32)
|
||||
set(CMAKE_CXX_FLAGS -m32)
|
||||
|
||||
set(KANGAROO_OS windows)
|
||||
set(KANGAROO_ARCH x86)
|
|
@ -1,25 +0,0 @@
|
|||
#
|
||||
# Singe 2
|
||||
# Copyright (C) 2006-2024 Scott Duensing <scott@kangaroopunch.com>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public Licens
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_SYSTEM_PROCESSOR x86_64)
|
||||
|
||||
set(KANGAROO_OS linux)
|
||||
set(KANGAROO_ARCH x86_64)
|
|
@ -1,32 +0,0 @@
|
|||
#
|
||||
# Singe 2
|
||||
# Copyright (C) 2006-2024 Scott Duensing <scott@kangaroopunch.com>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or
|
||||
# modify it under the terms of the GNU General Public Licens
|
||||
# as published by the Free Software Foundation; either version 2
|
||||
# of the License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
#
|
||||
|
||||
|
||||
set(CMAKE_SYSTEM_NAME Windows)
|
||||
set(CMAKE_SYSTEM_PROCESSOR x86_64)
|
||||
|
||||
set(triple x86_64-w64-mingw32)
|
||||
|
||||
set(CMAKE_C_COMPILER x86_64-w64-mingw32-gcc-10-posix)
|
||||
set(CMAKE_C_COMPILER_TARGET ${triple})
|
||||
set(CMAKE_CXX_COMPILER x86_64-w64-mingw32-c++-posix)
|
||||
set(CMAKE_CXX_COMPILER_TARGET ${triple})
|
||||
|
||||
set(KANGAROO_OS windows)
|
||||
set(KANGAROO_ARCH x86_64)
|
Loading…
Add table
Reference in a new issue