mirror of
https://github.com/SFML/CSFML.git
synced 2026-10-26 13:06:13 +01:00
Update to SFML 3.1.0
- Require CMake 3.28 to match SFML - Install HarfBuzz, MbedTLS and libssh2 for Linux CI builds - Bump CSFML and NuGet package version to 3.1.0
This commit is contained in:
10 files changed
+24
-25
No files matched your search
@@ -9,7 +9,7 @@ concurrency:
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
SFML_VERSION: 3.0.2
|
||||
SFML_VERSION: 3.1.0
|
||||
|
||||
defaults:
|
||||
run:
|
||||
@@ -26,8 +26,7 @@ jobs:
|
||||
platform:
|
||||
- { name: Windows VS2026 x86, os: windows-2025-vs2026, flags: -AWin32 }
|
||||
- { name: Windows VS2026 x64, os: windows-2025-vs2026, flags: -Ax64 }
|
||||
# ClangCL is disabled until we build against SFML 3.1, the FLAC version bundled with SFML 3.0 fails to compile with VS2026's ClangCL
|
||||
# - { name: Windows ClangCL, os: windows-2025-vs2026, flags: -T ClangCL }
|
||||
- { name: Windows ClangCL, os: windows-2025-vs2026, flags: -T ClangCL }
|
||||
- { name: Windows Clang, os: windows-2025-vs2026, flags: -GNinja -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ }
|
||||
- { name: Linux GCC, os: ubuntu-24.04, flags: -GNinja }
|
||||
- { name: Linux Clang, os: ubuntu-24.04, flags: -GNinja -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ }
|
||||
@@ -43,12 +42,12 @@ jobs:
|
||||
- name: Get CMake and Ninja
|
||||
uses: lukka/get-cmake@latest
|
||||
with:
|
||||
cmakeVersion: ${{ runner.os == 'Windows' && '4.2' || '3.22' }} # Visual Studio 2026 generator requires CMake 4.2 or later
|
||||
cmakeVersion: ${{ runner.os == 'Windows' && '4.2' || '3.28' }} # Visual Studio 2026 generator requires CMake 4.2 or later
|
||||
ninjaVersion: latest
|
||||
|
||||
- name: Install Linux Dependencies
|
||||
if: runner.os == 'Linux'
|
||||
run: sudo apt-get update && sudo apt-get install libxrandr-dev libxcursor-dev libxi-dev libudev-dev libflac-dev libvorbis-dev libgl1-mesa-dev libegl1-mesa-dev libfreetype-dev
|
||||
run: sudo apt-get update && sudo apt-get install libxrandr-dev libxcursor-dev libxi-dev libudev-dev libflac-dev libvorbis-dev libgl1-mesa-dev libegl1-mesa-dev libfreetype-dev libharfbuzz-dev libmbedtls-dev libssh2-1-dev
|
||||
|
||||
- name: Checkout SFML
|
||||
uses: actions/checkout@v7
|
||||
@@ -128,7 +127,7 @@ jobs:
|
||||
- name: Get CMake and Ninja
|
||||
uses: lukka/get-cmake@latest
|
||||
with:
|
||||
cmakeVersion: ${{ runner.os == 'Windows' && '4.2' || '3.22' }} # Visual Studio 2026 generator requires CMake 4.2 or later
|
||||
cmakeVersion: ${{ runner.os == 'Windows' && '4.2' || '3.28' }} # Visual Studio 2026 generator requires CMake 4.2 or later
|
||||
ninjaVersion: latest
|
||||
|
||||
- name: Install Dependencies
|
||||
@@ -171,7 +170,7 @@ jobs:
|
||||
- name: Get CMake and Ninja
|
||||
uses: lukka/get-cmake@latest
|
||||
with:
|
||||
cmakeVersion: ${{ runner.os == 'Windows' && '4.2' || '3.22' }} # Visual Studio 2026 generator requires CMake 4.2 or later
|
||||
cmakeVersion: ${{ runner.os == 'Windows' && '4.2' || '3.28' }} # Visual Studio 2026 generator requires CMake 4.2 or later
|
||||
ninjaVersion: latest
|
||||
|
||||
- name: Install Doxygen
|
||||
|
||||
@@ -16,7 +16,7 @@ concurrency:
|
||||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
SFML_VERSION: 3.0.2
|
||||
SFML_VERSION: 3.1.0
|
||||
|
||||
defaults:
|
||||
run:
|
||||
|
||||
+3
-3
@@ -1,4 +1,4 @@
|
||||
cmake_minimum_required(VERSION 3.22)
|
||||
cmake_minimum_required(VERSION 3.28)
|
||||
|
||||
# define a macro that helps defining an option
|
||||
macro(csfml_set_option var default type docstring)
|
||||
@@ -13,7 +13,7 @@ endmacro()
|
||||
csfml_set_option(CMAKE_BUILD_TYPE Release STRING "Choose the type of build (Debug or Release)")
|
||||
|
||||
# project name
|
||||
project(CSFML VERSION 3.0.0)
|
||||
project(CSFML VERSION 3.1.0)
|
||||
|
||||
# we use the paths from the cmake GNUInstallDirs module as defaults
|
||||
# you can override these if you like
|
||||
@@ -66,7 +66,7 @@ endif()
|
||||
if(CSFML_BUILD_NETWORK)
|
||||
list(PREPEND SFML_MODULES "Network")
|
||||
endif()
|
||||
find_package(SFML 3.0 COMPONENTS ${SFML_MODULES} REQUIRED)
|
||||
find_package(SFML 3.1 COMPONENTS ${SFML_MODULES} REQUIRED)
|
||||
|
||||
# add the subdirectories
|
||||
add_subdirectory(src/CSFML)
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
// Define the CSFML version
|
||||
////////////////////////////////////////////////////////////
|
||||
#define CSFML_VERSION_MAJOR 3
|
||||
#define CSFML_VERSION_MINOR 0
|
||||
#define CSFML_VERSION_MINOR 1
|
||||
#define CSFML_VERSION_PATCH 0
|
||||
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ Here's how to get started.
|
||||
|
||||
1. Install SFML.
|
||||
This may be done in a variety of ways including using a system package manager or building and installing SFML from source.
|
||||
The major version of SFML must match the major version of CSFML.
|
||||
The major version of SFML must match the major version of CSFML and the minor version of SFML must be the same or newer than the one of CSFML.
|
||||
2. Configure CSFML.
|
||||
If you are building CSFML for the purpose of contributing, we recommend using the `dev` CMake preset.
|
||||
This will enable a number of useful settings related to developing the library.
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
#!/bin/sh
|
||||
|
||||
VERSION="3.0.2"
|
||||
VERSION_C="3.0.0"
|
||||
VERSION="3.1.0"
|
||||
VERSION_C="3.1.0"
|
||||
# BUILD_CSFML=FALSE
|
||||
BUILD_CSFML=TRUE
|
||||
BUILD_SFML=FALSE
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<TargetFramework>netstandard2.0</TargetFramework>
|
||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||
|
||||
<Version>3.0.0</Version>
|
||||
<Version>3.1.0</Version>
|
||||
<Authors>Laurent Gomila</Authors>
|
||||
<PackageTags>sfml csfml</PackageTags>
|
||||
<Copyright>Copyright © Laurent Gomila</Copyright>
|
||||
|
||||
@@ -58,7 +58,7 @@ if [[ -n "$CXX_COMPILER" ]]; then
|
||||
echo "Using custom compilers: CXX=$CXX_COMPILER, CC=$C_COMPILER"
|
||||
fi
|
||||
|
||||
SFMLBranch="3.0.2" # The branch or tag of the SFML repository to be cloned
|
||||
SFMLBranch="3.1.0" # The branch or tag of the SFML repository to be cloned
|
||||
CSFMLDir="$(realpath ../../)" # The directory of the source code of CSFML
|
||||
|
||||
OutDir="./CSFML/runtimes/$RID/native" # The base directory of all CSFML modules, used to copy the final libraries
|
||||
@@ -145,8 +145,8 @@ cmake --build . --config Release
|
||||
# STEP 5: Copy result to the NuGet folders #
|
||||
# ======================================== #
|
||||
|
||||
SFMLMajorMinor="3.0"
|
||||
CSFMLMajorMinor="3.0"
|
||||
SFMLMajorMinor="3.1"
|
||||
CSFMLMajorMinor="3.1"
|
||||
|
||||
# Copies one SFML and CSFML module into the NuGet package
|
||||
# The module name must be passed to this function as an argument, in lowercase
|
||||
@@ -161,7 +161,7 @@ copymodule()
|
||||
# SFML.Net only searches for the name with common pre- and suffixes
|
||||
# As such we need to ship e.g. libcsfml-graphics.so
|
||||
# But the CSFML libs will look for the major.minor version
|
||||
# As such we also need to ship e.g. libcsfml-graphics.so.3.0
|
||||
# As such we also need to ship e.g. libcsfml-graphics.so.3.1
|
||||
# Unfortunately NuGet package don't support symlinks: https://github.com/NuGet/Home/issues/10734
|
||||
# For SFML, we can just ship one version that CSFML will be looking for
|
||||
cp "$SFMLLibDir/libsfml-$MODULE.so.$SFMLMajorMinor" "$OutDir"
|
||||
|
||||
@@ -46,7 +46,7 @@ echo "Please note that all SFML dependencies must be installed and available to
|
||||
|
||||
RID="$1"
|
||||
|
||||
SFMLBranch="3.0.2" # The branch or tag of the SFML repository to be cloned
|
||||
SFMLBranch="3.1.0" # The branch or tag of the SFML repository to be cloned
|
||||
CSFMLDir="$(grealpath "$(git rev-parse --show-toplevel)")" # The directory of the source code of CSFML
|
||||
|
||||
OutDir="./CSFML/runtimes/$RID/native" # The base directory of all CSFML modules, used to copy the final libraries
|
||||
@@ -150,9 +150,9 @@ cmake --build . --config Release --target install
|
||||
# STEP 5: Copy result to the NuGet folders #
|
||||
# ======================================== #
|
||||
|
||||
SFMLMajorMinor="3.0"
|
||||
SFMLMajorMinor="3.1"
|
||||
SFMLMajorMinorPatch="$SFMLMajorMinor.0"
|
||||
CSFMLMajorMinor="3.0"
|
||||
CSFMLMajorMinor="3.1"
|
||||
CSFMLMajorMinorPatch="$CSFMLMajorMinor.0"
|
||||
|
||||
# Copies one SFML and CSFML module into the NuGet package
|
||||
@@ -168,7 +168,7 @@ copymodule()
|
||||
# SFML.Net only searches for the name with common pre- and suffixes
|
||||
# As such we need to ship e.g. libcsfml-graphics.dylib
|
||||
# But the CSFML libs will look for the major.minor version
|
||||
# As such we also need to ship e.g. libcsfml-graphics.3.0.dylib
|
||||
# As such we also need to ship e.g. libcsfml-graphics.3.1.dylib
|
||||
# Unfortunately NuGet package don't support symlinks: https://github.com/NuGet/Home/issues/10734
|
||||
# For SFML, we can just ship one version that CSFML will be looking for
|
||||
cp "$SFMLLibDir/libsfml-$MODULE.$SFMLMajorMinor.dylib" "$OutDir"
|
||||
|
||||
@@ -43,7 +43,7 @@ Write-Output "Building $RID"
|
||||
Write-Output "Using $Generator as the cmake generator"
|
||||
Write-Output "Using architecture $ArchitectureCMake"
|
||||
|
||||
$SFMLBranch = "3.0.2" # The branch or tag of the SFML repository to be cloned
|
||||
$SFMLBranch = "3.1.0" # The branch or tag of the SFML repository to be cloned
|
||||
$CSFMLDir = (Get-Item (git rev-parse --show-toplevel)).FullName # The directory of the source code of CSFML
|
||||
|
||||
$OutDir = "./CSFML/runtimes/$RID/native" # The directory of all CSFML modules, used to copy the final dlls
|
||||
|
||||
Reference in new issue
Block a user