mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-09-06 03:18:13 +00:00
Compare commits
245 Commits
main
...
release-3.
Author | SHA1 | Date | |
---|---|---|---|
![]() |
8d604353a5 | ||
![]() |
8410e11ecb | ||
![]() |
9f8161bf4a | ||
![]() |
c038d6f7f8 | ||
![]() |
2fff37fffc | ||
![]() |
6feb86be71 | ||
![]() |
ed22220bc6 | ||
![]() |
219cb1a59d | ||
![]() |
71bd25a893 | ||
![]() |
01ef4c46a1 | ||
![]() |
64f728ec48 | ||
![]() |
ba10adf1fb | ||
![]() |
c18aa99358 | ||
![]() |
3498412611 | ||
![]() |
8c1b3ff210 | ||
![]() |
1870052af6 | ||
![]() |
3b1e3d5176 | ||
![]() |
cdf26c6e97 | ||
![]() |
9f1a1405a6 | ||
![]() |
6e97d8d1b3 | ||
![]() |
9d9a24d325 | ||
![]() |
0897f4a7d1 | ||
![]() |
5aec645191 | ||
![]() |
07c33068f3 | ||
![]() |
d684e5d57e | ||
![]() |
219500d95c | ||
![]() |
810addf7ae | ||
![]() |
4ef077ca52 | ||
![]() |
7d2275c4dc | ||
![]() |
cbd8917047 | ||
![]() |
c98a19401c | ||
![]() |
434836c480 | ||
![]() |
50d02ad732 | ||
![]() |
5ac37a8ffc | ||
![]() |
7dd2915475 | ||
![]() |
0ae1ddee17 | ||
![]() |
db4c7e47f1 | ||
![]() |
362445460e | ||
![]() |
de5cb9db23 | ||
![]() |
418eab29eb | ||
![]() |
2f3d242183 | ||
![]() |
4ad6d18203 | ||
![]() |
cd4a4f8a9f | ||
![]() |
a96e72da02 | ||
![]() |
337f012de2 | ||
![]() |
3c29b620e4 | ||
![]() |
579fc161f0 | ||
![]() |
22e968af4e | ||
![]() |
e37e96cfff | ||
![]() |
56c76c20a0 | ||
![]() |
efd812c399 | ||
![]() |
b2b92bbe25 | ||
![]() |
a29c67ac94 | ||
![]() |
f88e0aaac0 | ||
![]() |
29a4a4a5d1 | ||
![]() |
01000c73b0 | ||
![]() |
1a5d1dfef0 | ||
![]() |
2c38143834 | ||
![]() |
c56a1c664c | ||
![]() |
41cae64580 | ||
![]() |
c6dd2662c3 | ||
![]() |
f48027cf12 | ||
![]() |
fabbc8d183 | ||
![]() |
a142e5ef7d | ||
![]() |
825c0c7691 | ||
![]() |
dc30a00a26 | ||
![]() |
5a05ef01ad | ||
![]() |
0237997e4d | ||
![]() |
4f90432a49 | ||
![]() |
0cd6942bfc | ||
![]() |
1beb6fdedf | ||
![]() |
3b4472ecf7 | ||
![]() |
faed8b620c | ||
![]() |
982b778e45 | ||
![]() |
3a8f1cb7c5 | ||
![]() |
3c2d7ecdd6 | ||
![]() |
0834f1d6ce | ||
![]() |
6ce446b768 | ||
![]() |
e045edb567 | ||
![]() |
6cd14660cf | ||
![]() |
f5ac58c9f4 | ||
![]() |
c1779ca4a5 | ||
![]() |
6d8309f72e | ||
![]() |
cf95db46a7 | ||
![]() |
b8abfeb7f3 | ||
![]() |
014e24e1a8 | ||
![]() |
e42071a47c | ||
![]() |
1543f523b7 | ||
![]() |
f2d0e965fc | ||
![]() |
f782278d20 | ||
![]() |
3b17d08eb2 | ||
![]() |
18d367afd2 | ||
![]() |
9a4faf9ab9 | ||
![]() |
cb0ba020d4 | ||
![]() |
f705e2f9f7 | ||
![]() |
e76bffa183 | ||
![]() |
a4e19dc567 | ||
![]() |
4e1282617a | ||
![]() |
f102ff16a2 | ||
![]() |
50935a9d41 | ||
![]() |
a1dde664d1 | ||
![]() |
ba5325fba1 | ||
![]() |
e225a10ea8 | ||
![]() |
c4fba75a12 | ||
![]() |
5b052e6f8c | ||
![]() |
d89c3489f8 | ||
![]() |
a447863e4f | ||
![]() |
34db21cea8 | ||
![]() |
943226edc1 | ||
![]() |
281494676a | ||
![]() |
413b55deb7 | ||
![]() |
8222513f63 | ||
![]() |
2dd20ce8e7 | ||
![]() |
d308df6d62 | ||
![]() |
f51b88e6b5 | ||
![]() |
7cb0fa5c56 | ||
![]() |
976c92a2fb | ||
![]() |
15db51d7ff | ||
![]() |
4aa4e6a18e | ||
![]() |
0759f22a91 | ||
![]() |
02036ee643 | ||
![]() |
9109e05f3f | ||
![]() |
2103451d00 | ||
![]() |
b6db091d60 | ||
![]() |
9827653c38 | ||
![]() |
877399b2b2 | ||
![]() |
3f059376ac | ||
![]() |
30a6d01cc5 | ||
![]() |
b6fb47aa70 | ||
![]() |
7ecae856e5 | ||
![]() |
5db7694f22 | ||
![]() |
366294e1c5 | ||
![]() |
4d966ff546 | ||
![]() |
6b665066f0 | ||
![]() |
519011f271 | ||
![]() |
5c224a3221 | ||
![]() |
4b8c38e7ba | ||
![]() |
16f6c1058c | ||
![]() |
7939309520 | ||
![]() |
cec6073085 | ||
![]() |
a9f121f3f7 | ||
![]() |
361218ce15 | ||
![]() |
04dcfada00 | ||
![]() |
d73ad0ef18 | ||
![]() |
a1b888f622 | ||
![]() |
d6267afcb9 | ||
![]() |
b8325be9cf | ||
![]() |
e77ef86f09 | ||
![]() |
951ba597ed | ||
![]() |
ab5e178dab | ||
![]() |
04dace6c75 | ||
![]() |
013918cd83 | ||
![]() |
996466e855 | ||
![]() |
61e7878ac0 | ||
![]() |
c067cb4e7d | ||
![]() |
38697dd812 | ||
![]() |
f03572335a | ||
![]() |
d8837edfa2 | ||
![]() |
e5f8043037 | ||
![]() |
134b57f6f5 | ||
![]() |
072e760197 | ||
![]() |
d37a3e2a71 | ||
![]() |
ed8e7e85f0 | ||
![]() |
eb9faad124 | ||
![]() |
3ed80843fe | ||
![]() |
4029521a63 | ||
![]() |
f971a59746 | ||
![]() |
5836266bfb | ||
![]() |
ed893bde04 | ||
![]() |
a934a36a18 | ||
![]() |
59857acd08 | ||
![]() |
8129b637f3 | ||
![]() |
9e1675671d | ||
![]() |
d39d951f89 | ||
![]() |
10ed6f49a9 | ||
![]() |
c2c848a752 | ||
![]() |
8b191c3ca6 | ||
![]() |
06a412cd68 | ||
![]() |
b74609d5f3 | ||
![]() |
d8756582f9 | ||
![]() |
ff90984dc3 | ||
![]() |
81952f9f96 | ||
![]() |
d0122ff624 | ||
![]() |
7a36aa37aa | ||
![]() |
464cb0ab6e | ||
![]() |
ac21e3ef3f | ||
![]() |
a5b51669fb | ||
![]() |
0ac030549b | ||
![]() |
6f1afe7084 | ||
![]() |
6302589829 | ||
![]() |
3225d31679 | ||
![]() |
ae05ab280d | ||
![]() |
51a6cb2cf5 | ||
![]() |
daf468e141 | ||
![]() |
cd673c8254 | ||
![]() |
3f13c0b36d | ||
![]() |
3e34720851 | ||
![]() |
0799237d74 | ||
![]() |
53f64e40c4 | ||
![]() |
a530df20b2 | ||
![]() |
b958189c92 | ||
![]() |
341f910835 | ||
![]() |
84dff407d4 | ||
![]() |
21e6c5814c | ||
![]() |
776f0a685c | ||
![]() |
9f32fafe21 | ||
![]() |
74b3b8e9e3 | ||
![]() |
fa4a9ba74e | ||
![]() |
9a6f8a2512 | ||
![]() |
1173bc2dde | ||
![]() |
ada55bd887 | ||
![]() |
fe97cff7d1 | ||
![]() |
8cdeb1a35a | ||
![]() |
7c82171a85 | ||
![]() |
2d2085c80b | ||
![]() |
03a4eea0ef | ||
![]() |
fec3e2cd45 | ||
![]() |
2aec1c2ef6 | ||
![]() |
b32cd4f84b | ||
![]() |
550bdc658a | ||
![]() |
d75ba9c2d2 | ||
![]() |
2477f7f982 | ||
![]() |
e454d7d4be | ||
![]() |
cd8bffb2dd | ||
![]() |
9646e3cc1b | ||
![]() |
1a2362ebf1 | ||
![]() |
f6864924f7 | ||
![]() |
6b3dafa4d3 | ||
![]() |
5c0c5d2816 | ||
![]() |
de11dd3d60 | ||
![]() |
ac09af2600 | ||
![]() |
26d1afa29c | ||
![]() |
6aab3b9da8 | ||
![]() |
d959719a3d | ||
![]() |
5a7b17fec5 | ||
![]() |
1d6bb62870 | ||
![]() |
0c3603d893 | ||
![]() |
38a5bca892 | ||
![]() |
70a289076a | ||
![]() |
1d0ecf982f | ||
![]() |
18d93d11e1 | ||
![]() |
110a832f5c | ||
![]() |
6a9e970880 | ||
![]() |
4e3058ce82 | ||
![]() |
bc6307a872 |
102
.github/actions/setup-ngage-sdk/action.yml
vendored
102
.github/actions/setup-ngage-sdk/action.yml
vendored
@@ -1,102 +0,0 @@
|
||||
name: 'Setup Nonka N-Gage SDK'
|
||||
description: 'Download and setup Nokia N-Gage SDK'
|
||||
inputs:
|
||||
path:
|
||||
description: 'Installation path'
|
||||
default: 'default'
|
||||
runs:
|
||||
using: 'composite'
|
||||
steps:
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.x'
|
||||
- name: 'Verify platform'
|
||||
id: calc
|
||||
shell: sh
|
||||
run: |
|
||||
case "${{ runner.os }}-${{ runner.arch }}" in
|
||||
"Windows-X86" | "Windows-X64")
|
||||
echo "ok!"
|
||||
echo "cache-key=ngage-sdk-windows" >> ${GITHUB_OUTPUT}
|
||||
default_install_path="C:/ngagesdk"
|
||||
;;
|
||||
*)
|
||||
echo "Unsupported ${{ runner.os }}-${{ runner.arch }}"
|
||||
exit 1;
|
||||
;;
|
||||
esac
|
||||
install_path="${{ inputs.path }}"
|
||||
if [ "x$install_path" = "xdefault" ]; then
|
||||
install_path="$default_install_path"
|
||||
fi
|
||||
echo "install-path=$install_path" >> ${GITHUB_OUTPUT}
|
||||
|
||||
toolchain_repo="https://github.com/ngagesdk/ngage-toolchain"
|
||||
toolchain_branch="main"
|
||||
echo "toolchain-repo=${toolchain_repo}" >> ${GITHUB_OUTPUT}
|
||||
echo "toolchain-branch=${toolchain_branch}" >> ${GITHUB_OUTPUT}
|
||||
|
||||
sdk_repo="https://github.com/ngagesdk/sdk"
|
||||
sdk_branch="main"
|
||||
echo "sdk-repo=${sdk_repo}" >> ${GITHUB_OUTPUT}
|
||||
echo "sdk-branch=${sdk_branch}" >> ${GITHUB_OUTPUT}
|
||||
|
||||
tools_repo="https://github.com/ngagesdk/tools"
|
||||
tools_branch="main"
|
||||
echo "tools-repo=${tools_repo}" >> ${GITHUB_OUTPUT}
|
||||
echo "tools-branch=${tools_branch}" >> ${GITHUB_OUTPUT}
|
||||
|
||||
extras_repo="https://github.com/ngagesdk/extras"
|
||||
extras_branch="main"
|
||||
echo "extras-repo=${extras_repo}" >> ${GITHUB_OUTPUT}
|
||||
echo "extras-branch=${extras_branch}" >> ${GITHUB_OUTPUT}
|
||||
# - name: 'Restore cached ${{ steps.calc.outputs.archive }}'
|
||||
# id: cache-restore
|
||||
# uses: actions/cache/restore@v4
|
||||
# with:
|
||||
# path: '${{ runner.temp }}'
|
||||
# key: ${{ steps.calc.outputs.cache-key }}
|
||||
- name: 'Download N-Gage SDK'
|
||||
# if: ${{ !steps.cache-restore.outputs.cache-hit || steps.cache-restore.outputs.cache-hit == 'false' }}
|
||||
shell: pwsh
|
||||
run: |
|
||||
|
||||
Invoke-WebRequest "${{ steps.calc.outputs.toolchain-repo }}/archive/refs/heads/${{ steps.calc.outputs.toolchain-branch }}.zip" -OutFile "${{ runner.temp }}/ngage-toolchain.zip"
|
||||
Invoke-WebRequest "${{ steps.calc.outputs.sdk-repo }}/archive/refs/heads/${{ steps.calc.outputs.sdk-branch }}.zip" -OutFile "${{ runner.temp }}/sdk.zip"
|
||||
Invoke-WebRequest "${{ steps.calc.outputs.tools-repo }}/archive/refs/heads/${{ steps.calc.outputs.tools-branch }}.zip" -OutFile "${{ runner.temp }}/tools.zip"
|
||||
Invoke-WebRequest "${{ steps.calc.outputs.extras-repo }}/archive/refs/heads/${{ steps.calc.outputs.extras-branch }}.zip" -OutFile "${{ runner.temp }}/extras.zip"
|
||||
|
||||
# - name: 'Cache ${{ steps.calc.outputs.archive }}'
|
||||
# if: ${{ !steps.cache-restore.outputs.cache-hit || steps.cache-restore.outputs.cache-hit == 'false' }}
|
||||
# uses: actions/cache/save@v4
|
||||
# with:
|
||||
# path: |
|
||||
# ${{ runner.temp }}/apps.zip
|
||||
# ${{ runner.temp }}/sdk.zip
|
||||
# ${{ runner.temp }}/tools.zip
|
||||
# key: ${{ steps.calc.outputs.cache-key }}
|
||||
- name: 'Extract N-Gage SDK'
|
||||
shell: pwsh
|
||||
run: |
|
||||
New-Item -ItemType Directory -Path "${{ steps.calc.outputs.install-path }}" -Force
|
||||
|
||||
New-Item -ItemType Directory -Path "${{ runner.temp }}/ngage-toolchain-temp" -Force
|
||||
7z "-o${{ runner.temp }}/ngage-toolchain-temp" x "${{ runner.temp }}/ngage-toolchain.zip"
|
||||
Move-Item -Path "${{ runner.temp }}/ngage-toolchain-temp/ngage-toolchain-${{ steps.calc.outputs.toolchain-branch }}/*" -Destination "${{ steps.calc.outputs.install-path }}"
|
||||
|
||||
7z "-o${{ steps.calc.outputs.install-path }}/sdk" x "${{ runner.temp }}/sdk.zip"
|
||||
Move-Item -Path "${{ steps.calc.outputs.install-path }}/sdk/sdk-${{ steps.calc.outputs.sdk-branch }}" -Destination "${{ steps.calc.outputs.install-path }}/sdk/sdk"
|
||||
|
||||
7z "-o${{ steps.calc.outputs.install-path }}/sdk" x "${{ runner.temp }}/tools.zip"
|
||||
Move-Item -Path "${{ steps.calc.outputs.install-path }}/sdk/tools-${{ steps.calc.outputs.tools-branch }}" -Destination "${{ steps.calc.outputs.install-path }}/sdk/tools"
|
||||
|
||||
7z "-o${{ steps.calc.outputs.install-path }}/sdk" x "${{ runner.temp }}/extras.zip"
|
||||
Move-Item -Path "${{ steps.calc.outputs.install-path }}/sdk/extras-${{ steps.calc.outputs.extras-branch }}" -Destination "${{ steps.calc.outputs.install-path }}/sdk/extras"
|
||||
- name: 'Set output variables'
|
||||
id: final
|
||||
shell: sh
|
||||
run: |
|
||||
echo "${{ steps.calc.outputs.install-path }}/sdk/sdk/6.1/Shared/EPOC32/gcc/bin" >> $GITHUB_PATH
|
||||
echo "${{ steps.calc.outputs.install-path }}/sdk/sdk/6.1/Shared/EPOC32/ngagesdk/bin" >> $GITHUB_PATH
|
||||
echo "NGAGESDK=${{ steps.calc.outputs.install-path }}" >> $GITHUB_ENV
|
||||
echo "CMAKE_TOOLCHAIN_FILE=${{ steps.calc.outputs.install-path }}/cmake/ngage-toolchain.cmake" >> $GITHUB_ENV
|
53
.github/workflows/create-test-plan.py
vendored
53
.github/workflows/create-test-plan.py
vendored
@@ -54,8 +54,6 @@ class SdlPlatform(Enum):
|
||||
Riscos = "riscos"
|
||||
FreeBSD = "freebsd"
|
||||
NetBSD = "netbsd"
|
||||
OpenBSD = "openbsd"
|
||||
NGage = "ngage"
|
||||
|
||||
|
||||
class Msys2Platform(Enum):
|
||||
@@ -115,8 +113,7 @@ JOB_SPECS = {
|
||||
"msvc-gdk-x64": JobSpec(name="GDK (MSVC, x64)", os=JobOs.WindowsLatest, platform=SdlPlatform.Msvc, artifact="SDL-VC-GDK", msvc_arch=MsvcArch.X64, msvc_project="VisualC-GDK/SDL.sln", gdk=True, no_cmake=True, ),
|
||||
"ubuntu-22.04": JobSpec(name="Ubuntu 22.04", os=JobOs.Ubuntu22_04, platform=SdlPlatform.Linux, artifact="SDL-ubuntu22.04", ),
|
||||
"ubuntu-24.04-arm64": JobSpec(name="Ubuntu 24.04 (ARM64)", os=JobOs.Ubuntu24_04_arm, platform=SdlPlatform.Linux, artifact="SDL-ubuntu24.04-arm64", ),
|
||||
"steamrt3": JobSpec(name="Steam Linux Runtime 3.0 (x86_64)", os=JobOs.UbuntuLatest, platform=SdlPlatform.Linux, artifact="SDL-steamrt3", container="registry.gitlab.steamos.cloud/steamrt/sniper/sdk:latest", ),
|
||||
"steamrt3-arm64": JobSpec(name="Steam Linux Runtime 3.0 (arm64)", os=JobOs.Ubuntu24_04_arm, platform=SdlPlatform.Linux, artifact="SDL-steamrt3-arm64", container="registry.gitlab.steamos.cloud/steamrt/sniper/sdk/arm64:latest", ),
|
||||
"steamrt-sniper": JobSpec(name="Steam Linux Runtime (Sniper)", os=JobOs.UbuntuLatest, platform=SdlPlatform.Linux, artifact="SDL-slrsniper", container="registry.gitlab.steamos.cloud/steamrt/sniper/sdk:beta", ),
|
||||
"ubuntu-intel-icx": JobSpec(name="Ubuntu 22.04 (Intel oneAPI)", os=JobOs.Ubuntu22_04, platform=SdlPlatform.Linux, artifact="SDL-ubuntu22.04-oneapi", intel=IntelCompiler.Icx, ),
|
||||
"ubuntu-intel-icc": JobSpec(name="Ubuntu 22.04 (Intel Compiler)", os=JobOs.Ubuntu22_04, platform=SdlPlatform.Linux, artifact="SDL-ubuntu22.04-icc", intel=IntelCompiler.Icc, ),
|
||||
"macos-framework-x64": JobSpec(name="MacOS (Framework) (x64)", os=JobOs.Macos13, platform=SdlPlatform.MacOS, artifact="SDL-macos-framework", apple_framework=True, apple_archs={AppleArch.Aarch64, AppleArch.X86_64, }, xcode=True, ),
|
||||
@@ -140,14 +137,12 @@ JOB_SPECS = {
|
||||
"vita-pvr": JobSpec(name="Sony PlayStation Vita (GLES w/ PVR_PSP2)", os=JobOs.UbuntuLatest, platform=SdlPlatform.Vita, artifact="SDL-vita-pvr", container="vitasdk/vitasdk:latest", vita_gles=VitaGLES.Pvr, ),
|
||||
"riscos": JobSpec(name="RISC OS", os=JobOs.UbuntuLatest, platform=SdlPlatform.Riscos, artifact="SDL-riscos", container="riscosdotinfo/riscos-gccsdk-4.7:latest", ),
|
||||
"netbsd": JobSpec(name="NetBSD", os=JobOs.UbuntuLatest, platform=SdlPlatform.NetBSD, artifact="SDL-netbsd-x64", ),
|
||||
"openbsd": JobSpec(name="OpenBSD", os=JobOs.UbuntuLatest, platform=SdlPlatform.OpenBSD, artifact="SDL-openbsd-x64", ),
|
||||
"freebsd": JobSpec(name="FreeBSD", os=JobOs.UbuntuLatest, platform=SdlPlatform.FreeBSD, artifact="SDL-freebsd-x64", ),
|
||||
"ngage": JobSpec(name="N-Gage", os=JobOs.WindowsLatest, platform=SdlPlatform.NGage, artifact="SDL-ngage", ),
|
||||
}
|
||||
|
||||
|
||||
class StaticLibType(Enum):
|
||||
STATIC_LIB = "SDL3-static.lib"
|
||||
MSVC = "SDL3-static.lib"
|
||||
A = "libSDL3.a"
|
||||
|
||||
|
||||
@@ -179,7 +174,6 @@ class JobDetails:
|
||||
brew_packages: list[str] = dataclasses.field(default_factory=list)
|
||||
cmake_toolchain_file: str = ""
|
||||
cmake_arguments: list[str] = dataclasses.field(default_factory=list)
|
||||
cmake_generator: str = "Ninja"
|
||||
cmake_build_arguments: list[str] = dataclasses.field(default_factory=list)
|
||||
clang_tidy: bool = True
|
||||
cppflags: list[str] = dataclasses.field(default_factory=list)
|
||||
@@ -228,8 +222,6 @@ class JobDetails:
|
||||
check_sources: bool = False
|
||||
setup_python: bool = False
|
||||
pypi_packages: list[str] = dataclasses.field(default_factory=list)
|
||||
setup_gage_sdk_path: str = ""
|
||||
binutils_strings: str = "strings"
|
||||
|
||||
def to_workflow(self, enable_artifacts: bool) -> dict[str, str|bool]:
|
||||
data = {
|
||||
@@ -263,7 +255,6 @@ class JobDetails:
|
||||
"cflags": my_shlex_join(self.cppflags + self.cflags),
|
||||
"cxxflags": my_shlex_join(self.cppflags + self.cxxflags),
|
||||
"ldflags": my_shlex_join(self.ldflags),
|
||||
"cmake-generator": self.cmake_generator,
|
||||
"cmake-toolchain-file": self.cmake_toolchain_file,
|
||||
"clang-tidy": self.clang_tidy,
|
||||
"cmake-arguments": my_shlex_join(self.cmake_arguments),
|
||||
@@ -298,8 +289,6 @@ class JobDetails:
|
||||
"check-sources": self.check_sources,
|
||||
"setup-python": self.setup_python,
|
||||
"pypi-packages": my_shlex_join(self.pypi_packages),
|
||||
"setup-ngage-sdk-path": self.setup_gage_sdk_path,
|
||||
"binutils-strings": self.binutils_strings,
|
||||
}
|
||||
return {k: v for k, v in data.items() if v != ""}
|
||||
|
||||
@@ -375,7 +364,7 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
job.msvc_project_flags.append("-p:TreatWarningsAsError=true")
|
||||
job.test_pkg_config = False
|
||||
job.shared_lib = SharedLibType.WIN32
|
||||
job.static_lib = StaticLibType.STATIC_LIB
|
||||
job.static_lib = StaticLibType.MSVC
|
||||
job.cmake_arguments.extend((
|
||||
"-DCMAKE_MSVC_DEBUG_INFORMATION_FORMAT=ProgramDatabase",
|
||||
"-DCMAKE_EXE_LINKER_FLAGS=-DEBUG",
|
||||
@@ -392,11 +381,9 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
match spec.msvc_arch:
|
||||
case MsvcArch.X86:
|
||||
job.cflags.append("/clang:-m32")
|
||||
job.cxxflags.append("/clang:-m32")
|
||||
job.ldflags.append("/MACHINE:X86")
|
||||
case MsvcArch.X64:
|
||||
job.cflags.append("/clang:-m64")
|
||||
job.cxxflags.append("/clang:-m64")
|
||||
job.ldflags.append("/MACHINE:X64")
|
||||
case _:
|
||||
raise ValueError(f"Unsupported clang-cl architecture (arch={spec.msvc_arch})")
|
||||
@@ -563,10 +550,6 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
"testmultiaudio-apk",
|
||||
"testsprite-apk",
|
||||
]
|
||||
|
||||
# -fPIC is required after updating NDK from 21 to 28
|
||||
job.cflags.append("-fPIC")
|
||||
job.cxxflags.append("-fPIC")
|
||||
case SdlPlatform.Emscripten:
|
||||
job.clang_tidy = False # clang-tidy does not understand -gsource-map
|
||||
job.shared = False
|
||||
@@ -659,7 +642,7 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
job.cmake_arguments.extend((
|
||||
f"-DCMAKE_C_COMPILER={job.cc}",
|
||||
f"-DCMAKE_CXX_COMPILER={job.cxx}",
|
||||
"-DCMAKE_SYSTEM_NAME=Haiku",
|
||||
"-DSDL_UNIX_CONSOLE_BUILD=ON",
|
||||
))
|
||||
job.shared_lib = SharedLibType.SO_0
|
||||
job.static_lib = StaticLibType.A
|
||||
@@ -692,16 +675,13 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
job.shared_lib = SharedLibType.SO_0
|
||||
job.static_lib = StaticLibType.A
|
||||
case SdlPlatform.N3ds:
|
||||
job.cmake_generator = "Unix Makefiles"
|
||||
job.cmake_build_arguments.append("-j$(nproc)")
|
||||
job.ccache = False
|
||||
job.ccache = True
|
||||
job.shared = False
|
||||
job.apt_packages = []
|
||||
job.apt_packages = ["ccache", "ninja-build", "binutils"]
|
||||
job.clang_tidy = False
|
||||
job.run_tests = False
|
||||
job.cc_from_cmake = True
|
||||
job.cmake_toolchain_file = "${DEVKITPRO}/cmake/3DS.cmake"
|
||||
job.binutils_strings = "/opt/devkitpro/devkitARM/bin/arm-none-eabi-strings"
|
||||
job.static_lib = StaticLibType.A
|
||||
case SdlPlatform.Msys2:
|
||||
job.ccache = True
|
||||
@@ -733,7 +713,7 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
))
|
||||
job.cmake_toolchain_file = "/home/riscos/env/toolchain-riscos.cmake"
|
||||
job.static_lib = StaticLibType.A
|
||||
case SdlPlatform.FreeBSD | SdlPlatform.NetBSD | SdlPlatform.OpenBSD:
|
||||
case SdlPlatform.FreeBSD | SdlPlatform.NetBSD:
|
||||
job.cpactions = True
|
||||
job.no_cmake = True
|
||||
job.run_tests = False
|
||||
@@ -757,25 +737,6 @@ def spec_to_job(spec: JobSpec, key: str, trackmem_symbol_names: bool) -> JobDeta
|
||||
job.cpactions_arch = "x86-64"
|
||||
job.cpactions_setup_cmd = "export PATH=\"/usr/pkg/sbin:/usr/pkg/bin:/sbin:$PATH\"; export PKG_CONFIG_PATH=\"/usr/pkg/lib/pkgconfig\";export PKG_PATH=\"https://cdn.netBSD.org/pub/pkgsrc/packages/NetBSD/$(uname -p)/$(uname -r|cut -f \"1 2\" -d.)/All/\";echo \"PKG_PATH=$PKG_PATH\";echo \"uname -a -> \"$(uname -a)\"\";sudo -E sysctl -w security.pax.aslr.enabled=0;sudo -E sysctl -w security.pax.aslr.global=0;sudo -E pkgin clean;sudo -E pkgin update"
|
||||
job.cpactions_install_cmd = "sudo -E pkgin -y install cmake dbus pkgconf ninja-build pulseaudio libxkbcommon wayland wayland-protocols libinotify libusb1"
|
||||
case SdlPlatform.OpenBSD:
|
||||
job.cpactions_os = "openbsd"
|
||||
job.cpactions_version = "7.4"
|
||||
job.cpactions_arch = "x86-64"
|
||||
job.cpactions_setup_cmd = "sudo pkg_add -u"
|
||||
job.cpactions_install_cmd = "sudo pkg_add cmake ninja pkgconf wayland wayland-protocols xwayland libxkbcommon libinotify pulseaudio dbus ibus"
|
||||
case SdlPlatform.NGage:
|
||||
build_parallel = False
|
||||
job.cmake_build_type = "Release"
|
||||
job.setup_ninja = True
|
||||
job.static_lib = StaticLibType.STATIC_LIB
|
||||
job.shared_lib = None
|
||||
job.clang_tidy = False
|
||||
job.werror = False # FIXME: enable SDL_WERROR
|
||||
job.shared = False
|
||||
job.run_tests = False
|
||||
job.setup_gage_sdk_path = "C:/ngagesdk"
|
||||
job.cmake_toolchain_file = "C:/ngagesdk/cmake/ngage-toolchain.cmake"
|
||||
job.test_pkg_config = False
|
||||
case _:
|
||||
raise ValueError(f"Unsupported platform={spec.platform}")
|
||||
|
||||
|
21
.github/workflows/generic.yml
vendored
21
.github/workflows/generic.yml
vendored
@@ -76,7 +76,7 @@ jobs:
|
||||
id: setup-ndk
|
||||
with:
|
||||
local-cache: true
|
||||
ndk-version: r28c
|
||||
ndk-version: r21e
|
||||
- name: 'Configure Android NDK variables'
|
||||
if: ${{ matrix.platform.android-ndk }}
|
||||
shell: sh
|
||||
@@ -93,11 +93,6 @@ jobs:
|
||||
with:
|
||||
arch: ${{ matrix.platform.msvc-vcvars-arch }}
|
||||
sdk: ${{ matrix.platform.msvc-vcvars-sdk }}
|
||||
- name: 'Set up Nokia N-Gage SDK'
|
||||
uses: ./.github/actions/setup-ngage-sdk
|
||||
if: ${{ matrix.platform.setup-ngage-sdk-path != '' }}
|
||||
with:
|
||||
path: '${{ matrix.platform.setup-ngage-sdk-path }}'
|
||||
- name: 'Set up Windows GDK Desktop'
|
||||
uses: ./.github/actions/setup-gdk-desktop
|
||||
if: ${{ matrix.platform.setup-gdk-folder != '' }}
|
||||
@@ -206,7 +201,7 @@ jobs:
|
||||
#shell: ${{ matrix.platform.shell }}
|
||||
run: |
|
||||
${{ matrix.platform.source-cmd }}
|
||||
${{ matrix.platform.cmake-config-emulator }} cmake -S . -B build -G "${{ matrix.platform.cmake-generator }}" \
|
||||
${{ matrix.platform.cmake-config-emulator }} cmake -S . -B build -GNinja \
|
||||
-Wdeprecated -Wdev -Werror \
|
||||
${{ matrix.platform.cmake-toolchain-file != '' && format('-DCMAKE_TOOLCHAIN_FILE={0}', matrix.platform.cmake-toolchain-file) || '' }} \
|
||||
-DSDL_WERROR=${{ matrix.platform.werror }} \
|
||||
@@ -237,9 +232,9 @@ jobs:
|
||||
run: |
|
||||
echo "This should show us the SDL_REVISION"
|
||||
echo "Shared library:"
|
||||
${{ (matrix.platform.shared-lib && format('{0} build/{1} | grep "Github Workflow"', matrix.platform.binutils-strings, matrix.platform.shared-lib)) || 'echo "<Shared library not supported by platform>"' }}
|
||||
${{ (matrix.platform.shared-lib && format('strings build/{0} | grep "Github Workflow"', matrix.platform.shared-lib)) || 'echo "<Shared library not supported by platform>"' }}
|
||||
echo "Static library:"
|
||||
${{ (matrix.platform.static-lib && format('{0} build/{1} | grep "Github Workflow"', matrix.platform.binutils-strings, matrix.platform.static-lib)) || 'echo "<Static library not supported by platform>"' }}
|
||||
${{ (matrix.platform.static-lib && format('strings build/{0} | grep "Github Workflow"', matrix.platform.static-lib)) || 'echo "<Static library not supported by platform>"' }}
|
||||
- name: 'Run build-time tests (CMake)'
|
||||
id: tests
|
||||
if: ${{ !matrix.platform.no-cmake && matrix.platform.run-tests }}
|
||||
@@ -411,14 +406,6 @@ jobs:
|
||||
build-scripts/test-versioning.sh
|
||||
python build-scripts/check_android_jni.py
|
||||
python build-scripts/check_stdlib_usage.py
|
||||
- name: 'Verify alignment of Android test apks'
|
||||
if: ${{ matrix.platform.android-ndk && !matrix.platform.no-cmake }}
|
||||
run: |
|
||||
find ./ -iname '*.apk' | xargs -L1 ./build-scripts/check_elf_alignment.sh
|
||||
- name: 'Verify alignment of Android .so files'
|
||||
if: ${{ matrix.platform.android-ndk && !matrix.platform.no-cmake }}
|
||||
run: |
|
||||
find ./ -iname '*.so' | xargs -L1 ./build-scripts/check_elf_alignment.sh
|
||||
- name: 'Upload binary package'
|
||||
uses: actions/upload-artifact@v4
|
||||
if: ${{ always() && matrix.platform.artifact != '' && (steps.package.outcome == 'success' || steps.cpactions.outcome == 'success') && (matrix.platform.enable-artifacts || steps.tests.outcome == 'failure') }}
|
||||
|
7
.github/workflows/release.yml
vendored
7
.github/workflows/release.yml
vendored
@@ -256,7 +256,7 @@ jobs:
|
||||
|
||||
msvc:
|
||||
needs: [src]
|
||||
runs-on: windows-2025
|
||||
runs-on: windows-2019
|
||||
outputs:
|
||||
VC-x86: ${{ steps.releaser.outputs.VC-x86 }}
|
||||
VC-x64: ${{ steps.releaser.outputs.VC-x64 }}
|
||||
@@ -532,11 +532,10 @@ jobs:
|
||||
with:
|
||||
sparse-checkout: 'build-scripts/build-release.py'
|
||||
- name: 'Setup Android NDK'
|
||||
id: setup-ndk
|
||||
uses: nttld/setup-ndk@v1
|
||||
with:
|
||||
local-cache: true
|
||||
ndk-version: r28c
|
||||
ndk-version: r21e
|
||||
- name: 'Setup Java JDK'
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
@@ -562,8 +561,6 @@ jobs:
|
||||
run: |
|
||||
python build-scripts/build-release.py \
|
||||
--actions android \
|
||||
--android-api 21 \
|
||||
--android-ndk-home "${{ steps.setup-ndk.outputs.ndk-path }}" \
|
||||
--commit ${{ inputs.commit }} \
|
||||
--root "${{ steps.tar.outputs.path }}" \
|
||||
--github \
|
||||
|
@@ -9,7 +9,6 @@ versionfname = include/SDL3/SDL_version.h
|
||||
versionmajorregex = \A\#define\s+SDL_MAJOR_VERSION\s+(\d+)\Z
|
||||
versionminorregex = \A\#define\s+SDL_MINOR_VERSION\s+(\d+)\Z
|
||||
versionmicroregex = \A\#define\s+SDL_MICRO_VERSION\s+(\d+)\Z
|
||||
apipropertyregex = \A\s*\#\s*define\s+SDL_PROP_
|
||||
selectheaderregex = \ASDL.*?\.h\Z
|
||||
projecturl = https://libsdl.org/
|
||||
wikiurl = https://wiki.libsdl.org
|
||||
@@ -26,16 +25,8 @@ manpagesymbolfilterregex = \A[US]int\d+\Z
|
||||
headercategoryeval = s/\ASDL_test_?.*?\.h\Z//; s/\ASDL_?(.*?)\.h\Z/$1/; ucfirst();
|
||||
|
||||
quickrefenabled = 1
|
||||
quickrefcategoryorder = Init,Hints,Error,Version,Properties,Log,Video,Events,Keyboard,Mouse,Touch,Gamepad,Joystick,Haptic,Audio,Time,Timer,Render,SharedObject,Thread,Mutex,Atomic,Filesystem,IOStream,AsyncIO,Storage,Pixels,Surface,Blendmode,Rect,Camera,Clipboard,Dialog,Tray,Messagebox,GPU,Vulkan,Metal,Platform,Power,Sensor,Process,Bits,Endian,Assert,CPUInfo,Intrinsics,Locale,System,Misc,GUID,Main,Stdinc
|
||||
quickrefcategoryorder = Init,Hints,Error,Version,Properties,Log,Video,Events,Keyboard,Mouse,Touch,Gamepad,Joystick,Haptic,Audio,Time,Timer,Render,SharedObject,Thread,Mutex,Atomic,Filesystem,IOStream,AsyncIO,Storage,Pixels,Surface,Blendmode,Rect,Camera,Clipboard,Dialog,GPU,Messagebox,Vulkan,Metal,Platform,Power,Sensor,Process,Bits,Endian,Assert,CPUInfo,Intrinsics,Locale,System,Misc,GUID,Main,Stdinc
|
||||
quickreftitle = SDL3 API Quick Reference
|
||||
quickrefurl = https://libsdl.org/
|
||||
quickrefdesc = The latest version of this document can be found at https://wiki.libsdl.org/SDL3/QuickReference
|
||||
quickrefmacroregex = \A(SDL_PLATFORM_.*|SDL_.*_INTRINSICS|SDL_Atomic...Ref|SDL_assert.*?|SDL_COMPILE_TIME_ASSERT|SDL_arraysize|SDL_Swap[BL]E\d\d|SDL_[a-z]+_cast)\Z
|
||||
|
||||
envvarenabled = 1
|
||||
envvartitle = SDL3 Environment Variables
|
||||
envvardesc = SDL3 can be controlled by the user, externally, with environment variables. They are all operate exactly like the [hints you can get and set programmatically](CategoryHints), but named without the `_HINT` part (so `"SDL_HINT_A"` would be environment variable `"SDL_A"`).\n\nThis list matches the latest in SDL3's revision control.
|
||||
envvarsymregex = \ASDL_HINT_(.*)\Z
|
||||
envvarsymreplace = SDL_$1
|
||||
|
||||
|
||||
|
@@ -42,7 +42,6 @@ LOCAL_SRC_FILES := \
|
||||
$(wildcard $(LOCAL_PATH)/src/haptic/*.c) \
|
||||
$(wildcard $(LOCAL_PATH)/src/haptic/android/*.c) \
|
||||
$(wildcard $(LOCAL_PATH)/src/haptic/dummy/*.c) \
|
||||
$(wildcard $(LOCAL_PATH)/src/haptic/hidapi/*.c) \
|
||||
$(wildcard $(LOCAL_PATH)/src/hidapi/*.c) \
|
||||
$(wildcard $(LOCAL_PATH)/src/hidapi/android/*.cpp) \
|
||||
$(wildcard $(LOCAL_PATH)/src/joystick/*.c) \
|
||||
|
824
CMakeLists.txt
824
CMakeLists.txt
File diff suppressed because it is too large
Load Diff
@@ -326,6 +326,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
@@ -453,10 +454,8 @@
|
||||
<ClInclude Include="..\..\src\io\SDL_sysasyncio.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_haptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_syshaptic.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_hidapihaptic.h" />
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_dinputhaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_windowshaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\hidapi\hidapi\hidapi.h" />
|
||||
<ClInclude Include="..\..\src\hidapi\SDL_hidapi_c.h" />
|
||||
<ClInclude Include="..\..\src\joystick\controller_type.h" />
|
||||
@@ -644,7 +643,7 @@
|
||||
<ClCompile Include="..\..\src\audio\SDL_wave.c" />
|
||||
<ClCompile Include="..\..\src\audio\wasapi\SDL_wasapi.c" />
|
||||
<ClCompile Include="..\..\src\core\SDL_core_unsupported.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.cpp"/>
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.c"/>
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_hid.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_immdevice.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_windows.c" />
|
||||
@@ -704,36 +703,28 @@
|
||||
<LanguageStandard Condition="'$(Configuration)|$(Platform)'=='Release|Gaming.Xbox.Scarlett.x64'">stdcpp17</LanguageStandard>
|
||||
<LanguageStandard Condition="'$(Configuration)|$(Platform)'=='Release|Gaming.Xbox.XboxOne.x64'">stdcpp17</LanguageStandard>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_lg4ff.c" />
|
||||
<ClCompile Include="..\..\src\hidapi\SDL_hidapi.c" />
|
||||
<ClCompile Include="..\..\src\joystick\controller_type.c" />
|
||||
<ClCompile Include="..\..\src\joystick\dummy\SDL_sysjoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.cpp" />
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapijoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_8bitdo.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_flydigi.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_combined.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gamecube.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gip.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_luna.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps3.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps4.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps5.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_rumble.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_shield.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_sinput.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_stadia.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steam.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steam_hori.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steamdeck.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch2.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_wii.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xbox360.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xbox360w.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xboxone.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_lg4ff.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_gamepad.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_joystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_steam_virtual_gamepad.c" />
|
||||
@@ -765,7 +756,6 @@
|
||||
<ClCompile Include="..\..\src\loadso\windows\SDL_sysloadso.c" />
|
||||
<ClCompile Include="..\..\src\locale\SDL_locale.c" />
|
||||
<ClCompile Include="..\..\src\locale\windows\SDL_syslocale.c" />
|
||||
<ClCompile Include="..\..\src\misc\SDL_libusb.c" />
|
||||
<ClCompile Include="..\..\src\misc\SDL_url.c" />
|
||||
<ClCompile Include="..\..\src\misc\windows\SDL_sysurl.c" />
|
||||
<ClCompile Include="..\..\src\power\SDL_power.c" />
|
||||
@@ -890,11 +880,12 @@
|
||||
<ClCompile Include="..\..\src\video\SDL_video_unsupported.c" />
|
||||
<ClCompile Include="..\..\src\video\SDL_vulkan_utils.c" />
|
||||
<ClCompile Include="..\..\src\video\SDL_yuv.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_surface_utils.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsclipboard.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsevents.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsframebuffer.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowskeyboard.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.cpp" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmessagebox.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmodes.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmouse.c" />
|
||||
|
@@ -27,7 +27,7 @@
|
||||
<ClCompile Include="..\..\src\audio\SDL_wave.c" />
|
||||
<ClCompile Include="..\..\src\audio\wasapi\SDL_wasapi.c" />
|
||||
<ClCompile Include="..\..\src\core\SDL_core_unsupported.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.cpp" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_hid.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_immdevice.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_windows.c" />
|
||||
@@ -56,36 +56,28 @@
|
||||
<ClCompile Include="..\..\src\haptic\SDL_haptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\windows\SDL_dinputhaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\windows\SDL_windowshaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_lg4ff.c" />
|
||||
<ClCompile Include="..\..\src\hidapi\SDL_hidapi.c" />
|
||||
<ClCompile Include="..\..\src\joystick\controller_type.c" />
|
||||
<ClCompile Include="..\..\src\joystick\dummy\SDL_sysjoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.cpp" />
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapijoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_8bitdo.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_flydigi.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_combined.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gamecube.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gip.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_luna.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps3.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps4.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps5.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_rumble.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_shield.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_sinput.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_stadia.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steam.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steam_hori.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steamdeck.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch2.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_wii.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xbox360.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xbox360w.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xboxone.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_lg4ff.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_gamepad.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_joystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_steam_virtual_gamepad.c" />
|
||||
@@ -99,7 +91,6 @@
|
||||
<ClCompile Include="..\..\src\loadso\windows\SDL_sysloadso.c" />
|
||||
<ClCompile Include="..\..\src\locale\SDL_locale.c" />
|
||||
<ClCompile Include="..\..\src\locale\windows\SDL_syslocale.c" />
|
||||
<ClCompile Include="..\..\src\misc\SDL_libusb.c" />
|
||||
<ClCompile Include="..\..\src\misc\SDL_url.c" />
|
||||
<ClCompile Include="..\..\src\misc\windows\SDL_sysurl.c" />
|
||||
<ClCompile Include="..\..\src\power\SDL_power.c" />
|
||||
@@ -193,11 +184,12 @@
|
||||
<ClCompile Include="..\..\src\video\SDL_video_unsupported.c" />
|
||||
<ClCompile Include="..\..\src\video\SDL_vulkan_utils.c" />
|
||||
<ClCompile Include="..\..\src\video\SDL_yuv.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_surface_utils.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsclipboard.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsevents.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsframebuffer.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowskeyboard.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.cpp" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmessagebox.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmodes.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmouse.c" />
|
||||
@@ -351,10 +343,8 @@
|
||||
<ClInclude Include="..\..\src\gpu\SDL_sysgpu.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_haptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_syshaptic.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_hidapihaptic.h" />
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_dinputhaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_windowshaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\hidapi\hidapi\hidapi.h" />
|
||||
<ClInclude Include="..\..\src\hidapi\SDL_hidapi_c.h" />
|
||||
<ClInclude Include="..\..\src\joystick\controller_type.h" />
|
||||
|
@@ -192,6 +192,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -268,6 +268,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -56,7 +56,8 @@ static struct
|
||||
static SDL_AudioStream *stream;
|
||||
|
||||
/* Call this instead of exit(), so we can clean up SDL: atexit() is evil. */
|
||||
static void quit(int rc)
|
||||
static void
|
||||
quit(int rc)
|
||||
{
|
||||
SDL_free(sprites);
|
||||
SDL_DestroyAudioStream(stream);
|
||||
@@ -79,7 +80,8 @@ static int fillerup(void)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void UserLoggedIn(XUserHandle user)
|
||||
void
|
||||
UserLoggedIn(XUserHandle user)
|
||||
{
|
||||
HRESULT hr;
|
||||
char gamertag[128];
|
||||
@@ -94,7 +96,8 @@ static void UserLoggedIn(XUserHandle user)
|
||||
XUserCloseHandle(user);
|
||||
}
|
||||
|
||||
static void AddUserUICallback(XAsyncBlock *asyncBlock)
|
||||
void
|
||||
AddUserUICallback(XAsyncBlock *asyncBlock)
|
||||
{
|
||||
HRESULT hr;
|
||||
XUserHandle user = NULL;
|
||||
@@ -120,7 +123,8 @@ static void AddUserUICallback(XAsyncBlock *asyncBlock)
|
||||
delete asyncBlock;
|
||||
}
|
||||
|
||||
static void AddUserUI()
|
||||
void
|
||||
AddUserUI()
|
||||
{
|
||||
HRESULT hr;
|
||||
XAsyncBlock *asyncBlock = new XAsyncBlock;
|
||||
@@ -137,7 +141,8 @@ static void AddUserUI()
|
||||
}
|
||||
}
|
||||
|
||||
static void AddUserSilentCallback(XAsyncBlock *asyncBlock)
|
||||
void
|
||||
AddUserSilentCallback(XAsyncBlock *asyncBlock)
|
||||
{
|
||||
HRESULT hr;
|
||||
XUserHandle user = NULL;
|
||||
@@ -163,7 +168,8 @@ static void AddUserSilentCallback(XAsyncBlock *asyncBlock)
|
||||
delete asyncBlock;
|
||||
}
|
||||
|
||||
static void AddUserSilent()
|
||||
void
|
||||
AddUserSilent()
|
||||
{
|
||||
HRESULT hr;
|
||||
XAsyncBlock *asyncBlock = new XAsyncBlock;
|
||||
@@ -180,27 +186,30 @@ static void AddUserSilent()
|
||||
}
|
||||
}
|
||||
|
||||
static bool LoadSprite(const char *file)
|
||||
int
|
||||
LoadSprite(const char *file)
|
||||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i < state->num_windows; ++i) {
|
||||
/* This does the SDL_LoadBMP step repeatedly, but that's OK for test code. */
|
||||
sprites[i] = LoadTexture(state->renderers[i], file, true);
|
||||
sprites[i] = LoadTexture(state->renderers[i], file, true, &sprite_w, &sprite_h);
|
||||
if (!sprites[i]) {
|
||||
return false;
|
||||
return -1;
|
||||
}
|
||||
if (!SDL_SetTextureBlendMode(sprites[i], blendMode)) {
|
||||
SDL_LogError(SDL_LOG_CATEGORY_APPLICATION, "Couldn't set blend mode: %s", SDL_GetError());
|
||||
SDL_DestroyTexture(sprites[i]);
|
||||
return -1;
|
||||
}
|
||||
sprite_w = sprites[i]->w;
|
||||
sprite_h = sprites[i]->h;
|
||||
|
||||
SDL_SetTextureBlendMode(sprites[i], blendMode);
|
||||
}
|
||||
|
||||
/* We're ready to roll. :) */
|
||||
return true;
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void DrawSprites(SDL_Renderer * renderer, SDL_Texture * sprite)
|
||||
void
|
||||
DrawSprites(SDL_Renderer * renderer, SDL_Texture * sprite)
|
||||
{
|
||||
SDL_Rect viewport;
|
||||
SDL_FRect temp;
|
||||
@@ -291,7 +300,8 @@ static void DrawSprites(SDL_Renderer * renderer, SDL_Texture * sprite)
|
||||
SDL_RenderPresent(renderer);
|
||||
}
|
||||
|
||||
static void loop()
|
||||
void
|
||||
loop()
|
||||
{
|
||||
int i;
|
||||
SDL_Event event;
|
||||
@@ -319,7 +329,8 @@ static void loop()
|
||||
fillerup();
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
int i;
|
||||
const char *icon = "icon.bmp";
|
||||
@@ -402,7 +413,7 @@ int main(int argc, char *argv[])
|
||||
SDL_SetRenderDrawColor(renderer, 0xA0, 0xA0, 0xA0, 0xFF);
|
||||
SDL_RenderClear(renderer);
|
||||
}
|
||||
if (!LoadSprite(icon)) {
|
||||
if (LoadSprite(icon) < 0) {
|
||||
quit(2);
|
||||
}
|
||||
|
||||
|
@@ -292,6 +292,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -292,6 +292,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -69,7 +69,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "camera", "camera", "{AAEC83
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "01-read-and-draw", "examples\camera\01-read-and-draw\01-read-and-draw.vcxproj", "{510ACF0C-4012-4216-98EF-E4F155DE33CE}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "demo", "demo", "{D1BF59F6-22DC-493B-BDEB-451A50DA793D}"
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "game", "game", "{D1BF59F6-22DC-493B-BDEB-451A50DA793D}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "01-snake", "examples\demo\01-snake\01-snake.vcxproj", "{7820969A-5B7B-4046-BB0A-82905D457FC5}"
|
||||
EndProject
|
||||
@@ -115,24 +115,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "02-woodeneye-008", "example
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "03-infinite-monkeys", "examples\demo\03-infinite-monkeys\03-infinite-monkeys.vcxproj", "{75AEE75A-C016-4497-960B-D767B822237D}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "19-affine-textures", "examples\renderer\19-affine-textures\19-affine-textures.vcxproj", "{E21C50BF-54B4-434C-AA24-9A6469553987}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "04-multiple-streams", "examples\audio\04-multiple-streams\04-multiple-streams.vcxproj", "{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "asyncio", "asyncio", "{02EA681E-C7D8-13C7-8484-4AC65E1B71E8}"
|
||||
EndProject
|
||||
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "input", "input", "{8DEAE483-FDE7-463F-9FD5-F597BBAED1F9}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "01-load-bitmaps", "examples\asyncio\01-load-bitmaps\01-load-bitmaps.vcxproj", "{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "04-bytepusher", "examples\demo\04-bytepusher\04-bytepusher.vcxproj", "{3DB9B219-769E-43AC-8B8B-319DB6045DCF}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "01-joystick-polling", "examples\input\01-joystick-polling\01-joystick-polling.vcxproj", "{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "02-joystick-events", "examples\input\02-joystick-events\02-joystick-events.vcxproj", "{FCBDF2B2-1129-49AE-9406-3F219E65CA89}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "testsoftwaretransparent", "tests\testsoftwaretransparent\testsoftwaretransparent.vcxproj", "{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Win32 = Debug|Win32
|
||||
@@ -533,62 +515,6 @@ Global
|
||||
{75AEE75A-C016-4497-960B-D767B822237D}.Release|Win32.Build.0 = Release|Win32
|
||||
{75AEE75A-C016-4497-960B-D767B822237D}.Release|x64.ActiveCfg = Release|x64
|
||||
{75AEE75A-C016-4497-960B-D767B822237D}.Release|x64.Build.0 = Release|x64
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Debug|x64.Build.0 = Debug|x64
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Release|Win32.Build.0 = Release|Win32
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Release|x64.ActiveCfg = Release|x64
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987}.Release|x64.Build.0 = Release|x64
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Debug|x64.Build.0 = Debug|x64
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Release|Win32.Build.0 = Release|Win32
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Release|x64.ActiveCfg = Release|x64
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}.Release|x64.Build.0 = Release|x64
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Debug|x64.Build.0 = Debug|x64
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Release|Win32.Build.0 = Release|Win32
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Release|x64.ActiveCfg = Release|x64
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}.Release|x64.Build.0 = Release|x64
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Debug|x64.Build.0 = Debug|x64
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Release|Win32.Build.0 = Release|Win32
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Release|x64.ActiveCfg = Release|x64
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF}.Release|x64.Build.0 = Release|x64
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Debug|x64.Build.0 = Debug|x64
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Release|Win32.Build.0 = Release|Win32
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Release|x64.ActiveCfg = Release|x64
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}.Release|x64.Build.0 = Release|x64
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Debug|x64.Build.0 = Debug|x64
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Release|Win32.Build.0 = Release|Win32
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Release|x64.ActiveCfg = Release|x64
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89}.Release|x64.Build.0 = Release|x64
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Debug|Win32.ActiveCfg = Debug|Win32
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Debug|Win32.Build.0 = Debug|Win32
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Debug|x64.ActiveCfg = Debug|x64
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Debug|x64.Build.0 = Debug|x64
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Release|Win32.ActiveCfg = Release|Win32
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Release|Win32.Build.0 = Release|Win32
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Release|x64.ActiveCfg = Release|x64
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}.Release|x64.Build.0 = Release|x64
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
@@ -646,15 +572,6 @@ Global
|
||||
{608C6C67-7766-471F-BBFF-8B00086039AF} = {1B61A1B7-92DE-4C37-9151-D2928D6449AB}
|
||||
{A3F601E0-B54C-4DD8-8A97-FDEF7624EE60} = {D1BF59F6-22DC-493B-BDEB-451A50DA793D}
|
||||
{75AEE75A-C016-4497-960B-D767B822237D} = {D1BF59F6-22DC-493B-BDEB-451A50DA793D}
|
||||
{E21C50BF-54B4-434C-AA24-9A6469553987} = {F91DDAF0-B74F-4516-A1A9-42ED8DFCBF6A}
|
||||
{7117A55C-BE4E-41DB-A4FC-4070E35A8B28} = {1B61A1B7-92DE-4C37-9151-D2928D6449AB}
|
||||
{02EA681E-C7D8-13C7-8484-4AC65E1B71E8} = {1498F0CD-F4DA-4847-9CB2-FB18D48061D5}
|
||||
{8DEAE483-FDE7-463F-9FD5-F597BBAED1F9} = {1498F0CD-F4DA-4847-9CB2-FB18D48061D5}
|
||||
{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0} = {02EA681E-C7D8-13C7-8484-4AC65E1B71E8}
|
||||
{3DB9B219-769E-43AC-8B8B-319DB6045DCF} = {D1BF59F6-22DC-493B-BDEB-451A50DA793D}
|
||||
{B3852DB7-E925-4026-8B9D-D2272EFEFF3C} = {8DEAE483-FDE7-463F-9FD5-F597BBAED1F9}
|
||||
{FCBDF2B2-1129-49AE-9406-3F219E65CA89} = {8DEAE483-FDE7-463F-9FD5-F597BBAED1F9}
|
||||
{D91C45E2-274E-4C0F-89C7-9986F9A7E85A} = {D69D5741-611F-4E14-8541-1FEE94F50B5A}
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {C320C9F2-1A8F-41D7-B02B-6338F872BCAD}
|
||||
|
@@ -239,6 +239,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
@@ -366,10 +367,8 @@
|
||||
<ClInclude Include="..\..\src\io\SDL_sysasyncio.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_haptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_syshaptic.h" />
|
||||
<ClInclude Include="..\..\src\haptic\SDL_hidapihaptic.h" />
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_dinputhaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_windowshaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_c.h" />
|
||||
<ClInclude Include="..\..\src\hidapi\hidapi\hidapi.h" />
|
||||
<ClInclude Include="..\..\src\hidapi\SDL_hidapi_c.h" />
|
||||
<ClInclude Include="..\..\src\joystick\controller_type.h" />
|
||||
@@ -423,16 +422,6 @@
|
||||
<ClCompile Include="..\..\src\camera\dummy\SDL_camera_dummy.c" />
|
||||
<ClCompile Include="..\..\src\camera\mediafoundation\SDL_camera_mediafoundation.c" />
|
||||
<ClCompile Include="..\..\src\camera\SDL_camera.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\pch_cpp.cpp">
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\dialog\SDL_dialog.c" />
|
||||
<ClCompile Include="..\..\src\dialog\SDL_dialog_utils.c" />
|
||||
<ClCompile Include="..\..\src\filesystem\SDL_filesystem.c" />
|
||||
@@ -552,12 +541,7 @@
|
||||
<ClCompile Include="..\..\src\audio\SDL_wave.c" />
|
||||
<ClCompile Include="..\..\src\audio\wasapi\SDL_wasapi.c" />
|
||||
<ClCompile Include="..\..\src\core\SDL_core_unsupported.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.cpp">
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_hid.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_immdevice.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_windows.c" />
|
||||
@@ -589,41 +573,28 @@
|
||||
<ClCompile Include="..\..\src\haptic\SDL_haptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\windows\SDL_dinputhaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\windows\SDL_windowshaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic.c" />
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_lg4ff.c" />
|
||||
<ClCompile Include="..\..\src\hidapi\SDL_hidapi.c" />
|
||||
<ClCompile Include="..\..\src\joystick\controller_type.c" />
|
||||
<ClCompile Include="..\..\src\joystick\dummy\SDL_sysjoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.cpp">
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapijoystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_8bitdo.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_flydigi.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_combined.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gamecube.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gip.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_luna.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps3.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps4.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_ps5.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_rumble.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_shield.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_sinput.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_stadia.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steam.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steam_hori.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_steamdeck.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch2.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_wii.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xbox360.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xbox360w.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xboxone.c" />
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_lg4ff.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_gamepad.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_joystick.c" />
|
||||
<ClCompile Include="..\..\src\joystick\SDL_steam_virtual_gamepad.c" />
|
||||
@@ -637,7 +608,6 @@
|
||||
<ClCompile Include="..\..\src\loadso\windows\SDL_sysloadso.c" />
|
||||
<ClCompile Include="..\..\src\locale\SDL_locale.c" />
|
||||
<ClCompile Include="..\..\src\locale\windows\SDL_syslocale.c" />
|
||||
<ClCompile Include="..\..\src\misc\SDL_libusb.c" />
|
||||
<ClCompile Include="..\..\src\misc\SDL_url.c" />
|
||||
<ClCompile Include="..\..\src\misc\windows\SDL_sysurl.c" />
|
||||
<ClCompile Include="..\..\src\power\SDL_power.c" />
|
||||
@@ -745,16 +715,12 @@
|
||||
<ClCompile Include="..\..\src\video\SDL_video_unsupported.c" />
|
||||
<ClCompile Include="..\..\src\video\SDL_vulkan_utils.c" />
|
||||
<ClCompile Include="..\..\src\video\SDL_yuv.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_surface_utils.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsclipboard.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsevents.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsframebuffer.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowskeyboard.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.cpp">
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
<PrecompiledHeaderOutputFile Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(IntDir)$(TargetName)_cpp.pch</PrecompiledHeaderOutputFile>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmessagebox.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmodes.c" />
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmouse.c" />
|
||||
|
@@ -82,9 +82,6 @@
|
||||
<Filter Include="haptic\windows">
|
||||
<UniqueIdentifier>{ebc2fca3-3c26-45e3-815e-3e0581d5e226}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="haptic\hidapi">
|
||||
<UniqueIdentifier>{06DB01C0-65B5-4DE7-8ADC-C0B0CA3A1E69}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="haptic\dummy">
|
||||
<UniqueIdentifier>{47c445a2-7014-4e15-9660-7c89a27dddcf}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -537,6 +534,9 @@
|
||||
<ClInclude Include="..\..\src\events\SDL_events_c.h">
|
||||
<Filter>events</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\events\SDL_eventfilter_c.h">
|
||||
<Filter>events</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\events\SDL_keyboard_c.h">
|
||||
<Filter>events</Filter>
|
||||
</ClInclude>
|
||||
@@ -564,9 +564,6 @@
|
||||
<ClInclude Include="..\..\src\haptic\SDL_syshaptic.h">
|
||||
<Filter>haptic</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\haptic\SDL_hidapihaptic.h">
|
||||
<Filter>haptic</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\haptic\SDL_haptic_c.h">
|
||||
<Filter>haptic</Filter>
|
||||
</ClInclude>
|
||||
@@ -624,9 +621,6 @@
|
||||
<ClInclude Include="..\..\src\haptic\windows\SDL_windowshaptic_c.h">
|
||||
<Filter>haptic\windows</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_c.h">
|
||||
<Filter>haptic\hidapi</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\joystick\hidapi\SDL_hidapijoystick_c.h">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClInclude>
|
||||
@@ -959,7 +953,6 @@
|
||||
<ClInclude Include="..\..\include\SDL3\SDL_storage.h" />
|
||||
<ClInclude Include="..\..\include\SDL3\SDL_time.h" />
|
||||
<ClInclude Include="..\..\src\events\SDL_categories_c.h" />
|
||||
<ClInclude Include="..\..\src\events\SDL_eventwatch_c.h" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\src\audio\wasapi\SDL_wasapi.c" />
|
||||
@@ -1047,7 +1040,7 @@
|
||||
<ClCompile Include="..\..\src\core\SDL_core_unsupported.c">
|
||||
<Filter>core</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.cpp">
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_gameinput.c">
|
||||
<Filter>core\windows</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\core\windows\SDL_hid.c">
|
||||
@@ -1086,6 +1079,9 @@
|
||||
<ClCompile Include="..\..\src\events\SDL_events.c">
|
||||
<Filter>events</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\events\SDL_eventfilter.c">
|
||||
<Filter>events</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\events\SDL_keyboard.c">
|
||||
<Filter>events</Filter>
|
||||
</ClCompile>
|
||||
@@ -1137,9 +1133,6 @@
|
||||
<ClCompile Include="..\..\src\loadso\windows\SDL_sysloadso.c">
|
||||
<Filter>loadso\windows</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\misc\SDL_libusb.c">
|
||||
<Filter>misc</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\misc\SDL_url.c">
|
||||
<Filter>misc</Filter>
|
||||
</ClCompile>
|
||||
@@ -1170,36 +1163,21 @@
|
||||
<ClCompile Include="..\..\src\haptic\windows\SDL_windowshaptic.c">
|
||||
<Filter>haptic\windows</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic.c">
|
||||
<Filter>haptic\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\haptic\hidapi\SDL_hidapihaptic_lg4ff.c">
|
||||
<Filter>haptic\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\haptic\dummy\SDL_syshaptic.c">
|
||||
<Filter>haptic\dummy</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\dummy\SDL_sysjoystick.c">
|
||||
<Filter>joystick\dummy</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.cpp">
|
||||
<ClCompile Include="..\..\src\joystick\gdk\SDL_gameinputjoystick.c">
|
||||
<Filter>joystick\gdk</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_8bitdo.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_flydigi.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_combined.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gamecube.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_gip.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_luna.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
@@ -1218,9 +1196,6 @@
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_shield.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_sinput.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_stadia.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
@@ -1236,9 +1211,6 @@
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_switch2.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_wii.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
@@ -1251,9 +1223,6 @@
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_xboxone.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapi_lg4ff.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\joystick\hidapi\SDL_hidapijoystick.c">
|
||||
<Filter>joystick\hidapi</Filter>
|
||||
</ClCompile>
|
||||
@@ -1362,6 +1331,9 @@
|
||||
<ClCompile Include="..\..\src\video\dummy\SDL_nullvideo.c">
|
||||
<Filter>video\dummy</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_surface_utils.c">
|
||||
<Filter>video\windows</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsclipboard.c">
|
||||
<Filter>video\windows</Filter>
|
||||
</ClCompile>
|
||||
@@ -1374,7 +1346,7 @@
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowskeyboard.c">
|
||||
<Filter>video\windows</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.cpp">
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsgameinput.c">
|
||||
<Filter>video\windows</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\video\windows\SDL_windowsmessagebox.c">
|
||||
@@ -1613,12 +1585,11 @@
|
||||
<ClCompile Include="..\..\src\storage\generic\SDL_genericstorage.c" />
|
||||
<ClCompile Include="..\..\src\storage\steam\SDL_steamstorage.c" />
|
||||
<ClCompile Include="..\..\src\storage\SDL_storage.c" />
|
||||
<ClCompile Include="..\..\src\events\SDL_eventwatch.c" />
|
||||
<ClCompile Include="..\..\src\core\windows\pch_cpp.cpp">
|
||||
<Filter>core\windows</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="..\..\src\core\windows\version.rc" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<MASM Include="..\..\src\stdlib\SDL_mslibc_x64.masm" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
@@ -158,6 +158,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{6A2BFA8B-C027-400D-A18B-3E9E1CC4DDD0}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ItemGroup>
|
||||
<None Include="$(SolutionDir)\..\examples\asyncio\01-load-bitmaps\README.txt" />
|
||||
<ClCompile Include="$(SolutionDir)\..\examples\asyncio\01-load-bitmaps\load-bitmaps.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
</Project>
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{7117A55C-BE4E-41DB-A4FC-4070E35A8B28}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ItemGroup>
|
||||
<None Include="$(SolutionDir)\..\examples\audio\04-multiple-streams\README.txt" />
|
||||
<ClCompile Include="$(SolutionDir)\..\examples\audio\04-multiple-streams\multiple-streams.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
</Project>
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{3DB9B219-769E-43AC-8B8B-319DB6045DCF}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ItemGroup>
|
||||
<None Include="$(SolutionDir)\..\examples\demo\04-bytepusher\README.txt" />
|
||||
<ClCompile Include="$(SolutionDir)\..\examples\demo\04-bytepusher\bytepusher.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
</Project>
|
@@ -47,7 +47,6 @@ def main():
|
||||
for category in path.iterdir():
|
||||
if category.is_dir():
|
||||
for example in category.iterdir():
|
||||
if example.is_dir():
|
||||
generate(category.name, example.name, get_c_source_filename(example))
|
||||
|
||||
|
||||
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{B3852DB7-E925-4026-8B9D-D2272EFEFF3C}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ItemGroup>
|
||||
<None Include="$(SolutionDir)\..\examples\input\01-joystick-polling\README.txt" />
|
||||
<ClCompile Include="$(SolutionDir)\..\examples\input\01-joystick-polling\joystick-polling.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
</Project>
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{FCBDF2B2-1129-49AE-9406-3F219E65CA89}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ItemGroup>
|
||||
<None Include="$(SolutionDir)\..\examples\input\02-joystick-events\README.txt" />
|
||||
<ClCompile Include="$(SolutionDir)\..\examples\input\02-joystick-events\joystick-events.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
</Project>
|
@@ -1,13 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{E21C50BF-54B4-434C-AA24-9A6469553987}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ItemGroup>
|
||||
<None Include="$(SolutionDir)\..\examples\renderer\19-affine-textures\README.txt" />
|
||||
<ClCompile Include="$(SolutionDir)\..\examples\renderer\19-affine-textures\affine-textures.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
</Project>
|
@@ -189,6 +189,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -189,6 +189,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -187,6 +187,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -195,6 +195,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -1,209 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{D91C45E2-274E-4C0F-89C7-9986F9A7E85A}</ProjectGuid>
|
||||
<RootNamespace>testsoftwaretransparent</RootNamespace>
|
||||
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<PlatformToolset Condition="'$(VisualStudioVersion)' != '10.0'">$(DefaultPlatformToolset)</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<PlatformToolset Condition="'$(VisualStudioVersion)' != '10.0'">$(DefaultPlatformToolset)</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<PlatformToolset Condition="'$(VisualStudioVersion)' != '10.0'">$(DefaultPlatformToolset)</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
<PlatformToolset Condition="'$(VisualStudioVersion)' != '10.0'">$(DefaultPlatformToolset)</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Platform)\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(Platform)\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Platform)\$(Configuration)\</IntDir>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(Platform)\$(Configuration)\</IntDir>
|
||||
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
|
||||
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
|
||||
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" />
|
||||
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" />
|
||||
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
|
||||
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
|
||||
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|x64'">AllRules.ruleset</CodeAnalysisRuleSet>
|
||||
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|x64'" />
|
||||
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|x64'" />
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TargetEnvironment>Win32</TargetEnvironment>
|
||||
<TypeLibraryName>.\Release/testsoftwaretransparent.tlb</TypeLibraryName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<AdditionalIncludeDirectories>$(SolutionDir)/../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalUsingDirectories>%(AdditionalUsingDirectories)</AdditionalUsingDirectories>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TargetEnvironment>X64</TargetEnvironment>
|
||||
<TypeLibraryName>.\Release/testsoftwaretransparent.tlb</TypeLibraryName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<AdditionalIncludeDirectories>$(SolutionDir)/../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalUsingDirectories>%(AdditionalUsingDirectories)</AdditionalUsingDirectories>
|
||||
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TargetEnvironment>Win32</TargetEnvironment>
|
||||
<TypeLibraryName>.\Debug/testsoftwaretransparent.tlb</TypeLibraryName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>$(SolutionDir)/../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalUsingDirectories>%(AdditionalUsingDirectories)</AdditionalUsingDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>OldStyle</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TargetEnvironment>X64</TargetEnvironment>
|
||||
<TypeLibraryName>.\Debug/testsoftwaretransparent.tlb</TypeLibraryName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>$(SolutionDir)/../include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<AdditionalUsingDirectories>%(AdditionalUsingDirectories)</AdditionalUsingDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<DebugInformationFormat>OldStyle</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\SDL\SDL.vcxproj">
|
||||
<Project>{81ce8daf-ebb2-4761-8e45-b71abcca8c68}</Project>
|
||||
<Private>false</Private>
|
||||
<CopyLocalSatelliteAssemblies>false</CopyLocalSatelliteAssemblies>
|
||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\..\SDL_test\SDL_test.vcxproj">
|
||||
<Project>{da956fd3-e143-46f2-9fe5-c77bebc56b1a}</Project>
|
||||
<Private>false</Private>
|
||||
<CopyLocalSatelliteAssemblies>false</CopyLocalSatelliteAssemblies>
|
||||
<ReferenceOutputAssembly>true</ReferenceOutputAssembly>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\..\test\testsoftwaretransparent.c" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -189,6 +189,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -183,6 +183,7 @@
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(TreatWarningsAsError)'!=''">
|
||||
<ClCompile>
|
||||
<AdditionalOptions>%(AdditionalOptions) /utf-8</AdditionalOptions>
|
||||
<TreatWarningAsError>$(TreatWarningsAsError)</TreatWarningAsError>
|
||||
</ClCompile>
|
||||
</ItemDefinitionGroup>
|
||||
|
@@ -19,10 +19,10 @@
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>FMWK</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>3.3.0</string>
|
||||
<string>3.2.14</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>SDLX</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>3.3.0</string>
|
||||
<string>3.2.14</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
@@ -71,12 +71,7 @@
|
||||
63134A262A7902FD0021E9A6 /* SDL_pen.c in Sources */ = {isa = PBXBuildFile; fileRef = 63134A242A7902FD0021E9A6 /* SDL_pen.c */; };
|
||||
75E0915A241EA924004729E1 /* SDL_virtualjoystick.c in Sources */ = {isa = PBXBuildFile; fileRef = 75E09158241EA924004729E1 /* SDL_virtualjoystick.c */; };
|
||||
75E09163241EA924004729E1 /* SDL_virtualjoystick_c.h in Headers */ = {isa = PBXBuildFile; fileRef = 75E09159241EA924004729E1 /* SDL_virtualjoystick_c.h */; };
|
||||
89E5801E2D03602200DAF6D3 /* SDL_hidapi_lg4ff.c in Sources */ = {isa = PBXBuildFile; fileRef = 89E5801D2D03602200DAF6D3 /* SDL_hidapi_lg4ff.c */; };
|
||||
89E580232D03606400DAF6D3 /* SDL_hidapihaptic.c in Sources */ = {isa = PBXBuildFile; fileRef = 89E5801F2D03606400DAF6D3 /* SDL_hidapihaptic.c */; };
|
||||
89E580242D03606400DAF6D3 /* SDL_hidapihaptic_lg4ff.c in Sources */ = {isa = PBXBuildFile; fileRef = 89E580212D03606400DAF6D3 /* SDL_hidapihaptic_lg4ff.c */; };
|
||||
89E580252D03606400DAF6D3 /* SDL_hidapihaptic_c.h in Headers */ = {isa = PBXBuildFile; fileRef = 89E580202D03606400DAF6D3 /* SDL_hidapihaptic_c.h */; };
|
||||
9846B07C287A9020000C35C8 /* SDL_hidapi_shield.c in Sources */ = {isa = PBXBuildFile; fileRef = 9846B07B287A9020000C35C8 /* SDL_hidapi_shield.c */; };
|
||||
02D6A1C228A84B8F00A7F002 /* SDL_hidapi_sinput.c in Sources */ = {isa = PBXBuildFile; fileRef = 02D6A1C128A84B8F00A7F001 /* SDL_hidapi_sinput.c */; };
|
||||
A1626A3E2617006A003F1973 /* SDL_triangle.c in Sources */ = {isa = PBXBuildFile; fileRef = A1626A3D2617006A003F1973 /* SDL_triangle.c */; };
|
||||
A1626A522617008D003F1973 /* SDL_triangle.h in Headers */ = {isa = PBXBuildFile; fileRef = A1626A512617008C003F1973 /* SDL_triangle.h */; };
|
||||
A1BB8B6327F6CF330057CFA8 /* SDL_list.c in Sources */ = {isa = PBXBuildFile; fileRef = A1BB8B6127F6CF320057CFA8 /* SDL_list.c */; };
|
||||
@@ -229,7 +224,6 @@
|
||||
A7D8B54523E2514300DCD162 /* SDL_hidapijoystick.c in Sources */ = {isa = PBXBuildFile; fileRef = A7D8A7C423E2513E00DCD162 /* SDL_hidapijoystick.c */; };
|
||||
A7D8B54B23E2514300DCD162 /* SDL_hidapi_xboxone.c in Sources */ = {isa = PBXBuildFile; fileRef = A7D8A7C523E2513E00DCD162 /* SDL_hidapi_xboxone.c */; };
|
||||
A7D8B55123E2514300DCD162 /* SDL_hidapi_switch.c in Sources */ = {isa = PBXBuildFile; fileRef = A7D8A7C623E2513E00DCD162 /* SDL_hidapi_switch.c */; };
|
||||
A7D8B55123E2514300DCD163 /* SDL_hidapi_switch2.c in Sources */ = {isa = PBXBuildFile; fileRef = A7D8A7C623E2513E00DCD163 /* SDL_hidapi_switch2.c */; };
|
||||
A7D8B55723E2514300DCD162 /* SDL_hidapijoystick_c.h in Headers */ = {isa = PBXBuildFile; fileRef = A7D8A7C723E2513E00DCD162 /* SDL_hidapijoystick_c.h */; };
|
||||
A7D8B55D23E2514300DCD162 /* SDL_hidapi_xbox360w.c in Sources */ = {isa = PBXBuildFile; fileRef = A7D8A7C823E2513E00DCD162 /* SDL_hidapi_xbox360w.c */; };
|
||||
A7D8B56323E2514300DCD162 /* SDL_hidapi_gamecube.c in Sources */ = {isa = PBXBuildFile; fileRef = A7D8A7C923E2513E00DCD162 /* SDL_hidapi_gamecube.c */; };
|
||||
@@ -390,7 +384,6 @@
|
||||
F32DDAD42AB795A30041EAA5 /* SDL_audioresample.c in Sources */ = {isa = PBXBuildFile; fileRef = F32DDACE2AB795A30041EAA5 /* SDL_audioresample.c */; };
|
||||
F338A1182D1B37D8007CDFDF /* SDL_tray.m in Sources */ = {isa = PBXBuildFile; fileRef = F338A1172D1B37D8007CDFDF /* SDL_tray.m */; };
|
||||
F338A11A2D1B37E4007CDFDF /* SDL_tray.c in Sources */ = {isa = PBXBuildFile; fileRef = F338A1192D1B37E4007CDFDF /* SDL_tray.c */; };
|
||||
F3395BA82D9A5971007246C8 /* SDL_hidapi_8bitdo.c in Sources */ = {isa = PBXBuildFile; fileRef = F3395BA72D9A5971007246C8 /* SDL_hidapi_8bitdo.c */; };
|
||||
F34400342D40217A003F26D7 /* LICENSE.txt in Resources */ = {isa = PBXBuildFile; fileRef = F373DA182D388A1E002158FA /* LICENSE.txt */; };
|
||||
F34400362D40217A003F26D7 /* README.md in Resources */ = {isa = PBXBuildFile; fileRef = F373DA192D388A1E002158FA /* README.md */; };
|
||||
F344003D2D4022E1003F26D7 /* INSTALL.md in Resources */ = {isa = PBXBuildFile; fileRef = F344003C2D4022E1003F26D7 /* INSTALL.md */; };
|
||||
@@ -440,7 +433,6 @@
|
||||
F3B439532C935C2C00792030 /* SDL_posixprocess.c in Sources */ = {isa = PBXBuildFile; fileRef = F3B439522C935C2C00792030 /* SDL_posixprocess.c */; };
|
||||
F3B439562C937DAB00792030 /* SDL_process.c in Sources */ = {isa = PBXBuildFile; fileRef = F3B439542C937DAB00792030 /* SDL_process.c */; };
|
||||
F3B439572C937DAB00792030 /* SDL_sysprocess.h in Headers */ = {isa = PBXBuildFile; fileRef = F3B439552C937DAB00792030 /* SDL_sysprocess.h */; };
|
||||
F3B6B80A2DC3EA54004954FD /* SDL_hidapi_gip.c in Sources */ = {isa = PBXBuildFile; fileRef = F3B6B8092DC3EA54004954FD /* SDL_hidapi_gip.c */; };
|
||||
F3C1BD752D1F1A3000846529 /* SDL_tray_utils.c in Sources */ = {isa = PBXBuildFile; fileRef = F3C1BD742D1F1A3000846529 /* SDL_tray_utils.c */; };
|
||||
F3C1BD762D1F1A3000846529 /* SDL_tray_utils.h in Headers */ = {isa = PBXBuildFile; fileRef = F3C1BD732D1F1A3000846529 /* SDL_tray_utils.h */; };
|
||||
F3C2CB222C5DDDB2004D7998 /* SDL_categories_c.h in Headers */ = {isa = PBXBuildFile; fileRef = F3C2CB202C5DDDB2004D7998 /* SDL_categories_c.h */; };
|
||||
@@ -522,8 +514,6 @@
|
||||
F3D60A8328C16A1900788A3A /* SDL_hidapi_wii.c in Sources */ = {isa = PBXBuildFile; fileRef = F3D60A8228C16A1800788A3A /* SDL_hidapi_wii.c */; };
|
||||
F3D8BDFC2D6D2C7000B22FA1 /* SDL_eventwatch_c.h in Headers */ = {isa = PBXBuildFile; fileRef = F3D8BDFB2D6D2C7000B22FA1 /* SDL_eventwatch_c.h */; };
|
||||
F3D8BDFD2D6D2C7000B22FA1 /* SDL_eventwatch.c in Sources */ = {isa = PBXBuildFile; fileRef = F3D8BDFA2D6D2C7000B22FA1 /* SDL_eventwatch.c */; };
|
||||
F3DC38C92E5FC60300CD73DE /* SDL_libusb.h in Headers */ = {isa = PBXBuildFile; fileRef = F3DC38C72E5FC60300CD73DE /* SDL_libusb.h */; };
|
||||
F3DC38CA2E5FC60300CD73DE /* SDL_libusb.c in Sources */ = {isa = PBXBuildFile; fileRef = F3DC38C82E5FC60300CD73DE /* SDL_libusb.c */; };
|
||||
F3DDCC562AFD42B600B0842B /* SDL_clipboard_c.h in Headers */ = {isa = PBXBuildFile; fileRef = F3DDCC4D2AFD42B500B0842B /* SDL_clipboard_c.h */; };
|
||||
F3DDCC5B2AFD42B600B0842B /* SDL_video_c.h in Headers */ = {isa = PBXBuildFile; fileRef = F3DDCC522AFD42B600B0842B /* SDL_video_c.h */; };
|
||||
F3DDCC5D2AFD42B600B0842B /* SDL_rect_impl.h in Headers */ = {isa = PBXBuildFile; fileRef = F3DDCC542AFD42B600B0842B /* SDL_rect_impl.h */; };
|
||||
@@ -545,7 +535,6 @@
|
||||
F3FA5A232B59ACE000FEAD97 /* yuv_rgb_lsx.c in Sources */ = {isa = PBXBuildFile; fileRef = F3FA5A1A2B59ACE000FEAD97 /* yuv_rgb_lsx.c */; };
|
||||
F3FA5A242B59ACE000FEAD97 /* yuv_rgb_lsx.h in Headers */ = {isa = PBXBuildFile; fileRef = F3FA5A1B2B59ACE000FEAD97 /* yuv_rgb_lsx.h */; };
|
||||
F3FA5A252B59ACE000FEAD97 /* yuv_rgb_common.h in Headers */ = {isa = PBXBuildFile; fileRef = F3FA5A1C2B59ACE000FEAD97 /* yuv_rgb_common.h */; };
|
||||
F3FBB1082DDF93AB0000F99F /* SDL_hidapi_flydigi.c in Sources */ = {isa = PBXBuildFile; fileRef = F3395BA72D9A5971007246C9 /* SDL_hidapi_flydigi.c */; };
|
||||
F3FD042E2C9B755700824C4C /* SDL_hidapi_nintendo.h in Headers */ = {isa = PBXBuildFile; fileRef = F3FD042C2C9B755700824C4C /* SDL_hidapi_nintendo.h */; };
|
||||
F3FD042F2C9B755700824C4C /* SDL_hidapi_steam_hori.c in Sources */ = {isa = PBXBuildFile; fileRef = F3FD042D2C9B755700824C4C /* SDL_hidapi_steam_hori.c */; };
|
||||
FA73671D19A540EF004122E4 /* CoreVideo.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = FA73671C19A540EF004122E4 /* CoreVideo.framework */; platformFilters = (ios, maccatalyst, macos, tvos, ); settings = {ATTRIBUTES = (Required, ); }; };
|
||||
@@ -619,12 +608,7 @@
|
||||
63134A242A7902FD0021E9A6 /* SDL_pen.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_pen.c; sourceTree = "<group>"; };
|
||||
75E09158241EA924004729E1 /* SDL_virtualjoystick.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_virtualjoystick.c; sourceTree = "<group>"; };
|
||||
75E09159241EA924004729E1 /* SDL_virtualjoystick_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_virtualjoystick_c.h; sourceTree = "<group>"; };
|
||||
89E5801D2D03602200DAF6D3 /* SDL_hidapi_lg4ff.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_lg4ff.c; sourceTree = "<group>"; };
|
||||
89E5801F2D03606400DAF6D3 /* SDL_hidapihaptic.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_hidapihaptic.c; sourceTree = "<group>"; };
|
||||
89E580202D03606400DAF6D3 /* SDL_hidapihaptic_c.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SDL_hidapihaptic_c.h; sourceTree = "<group>"; };
|
||||
89E580212D03606400DAF6D3 /* SDL_hidapihaptic_lg4ff.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_hidapihaptic_lg4ff.c; sourceTree = "<group>"; };
|
||||
9846B07B287A9020000C35C8 /* SDL_hidapi_shield.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_shield.c; sourceTree = "<group>"; };
|
||||
02D6A1C128A84B8F00A7F001 /* SDL_hidapi_sinput.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_sinput.c; sourceTree = "<group>"; };
|
||||
A1626A3D2617006A003F1973 /* SDL_triangle.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_triangle.c; sourceTree = "<group>"; };
|
||||
A1626A512617008C003F1973 /* SDL_triangle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_triangle.h; sourceTree = "<group>"; };
|
||||
A1BB8B6127F6CF320057CFA8 /* SDL_list.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_list.c; sourceTree = "<group>"; };
|
||||
@@ -816,7 +800,6 @@
|
||||
A7D8A7C423E2513E00DCD162 /* SDL_hidapijoystick.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapijoystick.c; sourceTree = "<group>"; };
|
||||
A7D8A7C523E2513E00DCD162 /* SDL_hidapi_xboxone.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_xboxone.c; sourceTree = "<group>"; };
|
||||
A7D8A7C623E2513E00DCD162 /* SDL_hidapi_switch.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_switch.c; sourceTree = "<group>"; };
|
||||
A7D8A7C623E2513E00DCD163 /* SDL_hidapi_switch2.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_switch2.c; sourceTree = "<group>"; };
|
||||
A7D8A7C723E2513E00DCD162 /* SDL_hidapijoystick_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_hidapijoystick_c.h; sourceTree = "<group>"; };
|
||||
A7D8A7C823E2513E00DCD162 /* SDL_hidapi_xbox360w.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_xbox360w.c; sourceTree = "<group>"; };
|
||||
A7D8A7C923E2513E00DCD162 /* SDL_hidapi_gamecube.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_gamecube.c; sourceTree = "<group>"; };
|
||||
@@ -955,8 +938,6 @@
|
||||
F32DDACE2AB795A30041EAA5 /* SDL_audioresample.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_audioresample.c; sourceTree = "<group>"; };
|
||||
F338A1172D1B37D8007CDFDF /* SDL_tray.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDL_tray.m; sourceTree = "<group>"; };
|
||||
F338A1192D1B37E4007CDFDF /* SDL_tray.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_tray.c; sourceTree = "<group>"; };
|
||||
F3395BA72D9A5971007246C8 /* SDL_hidapi_8bitdo.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_8bitdo.c; sourceTree = "<group>"; };
|
||||
F3395BA72D9A5971007246C9 /* SDL_hidapi_flydigi.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_flydigi.c; sourceTree = "<group>"; };
|
||||
F344003C2D4022E1003F26D7 /* INSTALL.md */ = {isa = PBXFileReference; lastKnownFileType = net.daringfireball.markdown; path = INSTALL.md; sourceTree = "<group>"; };
|
||||
F362B9152B3349E200D30B94 /* controller_list.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = controller_list.h; sourceTree = "<group>"; };
|
||||
F362B9162B3349E200D30B94 /* SDL_gamepad_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_gamepad_c.h; sourceTree = "<group>"; };
|
||||
@@ -1021,7 +1002,6 @@
|
||||
F3B439522C935C2C00792030 /* SDL_posixprocess.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_posixprocess.c; sourceTree = "<group>"; };
|
||||
F3B439542C937DAB00792030 /* SDL_process.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_process.c; sourceTree = "<group>"; };
|
||||
F3B439552C937DAB00792030 /* SDL_sysprocess.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_sysprocess.h; sourceTree = "<group>"; };
|
||||
F3B6B8092DC3EA54004954FD /* SDL_hidapi_gip.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_gip.c; sourceTree = "<group>"; };
|
||||
F3C1BD732D1F1A3000846529 /* SDL_tray_utils.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SDL_tray_utils.h; sourceTree = "<group>"; };
|
||||
F3C1BD742D1F1A3000846529 /* SDL_tray_utils.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_tray_utils.c; sourceTree = "<group>"; };
|
||||
F3C2CB202C5DDDB2004D7998 /* SDL_categories_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_categories_c.h; sourceTree = "<group>"; };
|
||||
@@ -1103,8 +1083,6 @@
|
||||
F3D60A8228C16A1800788A3A /* SDL_hidapi_wii.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_hidapi_wii.c; sourceTree = "<group>"; };
|
||||
F3D8BDFA2D6D2C7000B22FA1 /* SDL_eventwatch.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_eventwatch.c; sourceTree = "<group>"; };
|
||||
F3D8BDFB2D6D2C7000B22FA1 /* SDL_eventwatch_c.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SDL_eventwatch_c.h; sourceTree = "<group>"; };
|
||||
F3DC38C72E5FC60300CD73DE /* SDL_libusb.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SDL_libusb.h; sourceTree = "<group>"; };
|
||||
F3DC38C82E5FC60300CD73DE /* SDL_libusb.c */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.c; path = SDL_libusb.c; sourceTree = "<group>"; };
|
||||
F3DDCC4D2AFD42B500B0842B /* SDL_clipboard_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_clipboard_c.h; sourceTree = "<group>"; };
|
||||
F3DDCC522AFD42B600B0842B /* SDL_video_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_video_c.h; sourceTree = "<group>"; };
|
||||
F3DDCC542AFD42B600B0842B /* SDL_rect_impl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_rect_impl.h; sourceTree = "<group>"; };
|
||||
@@ -1418,8 +1396,6 @@
|
||||
children = (
|
||||
F3ADAB8C2576F08500A6B1D9 /* ios */,
|
||||
5616CA48252BB285005D5928 /* macos */,
|
||||
F3DC38C72E5FC60300CD73DE /* SDL_libusb.h */,
|
||||
F3DC38C82E5FC60300CD73DE /* SDL_libusb.c */,
|
||||
5616CA4A252BB2A6005D5928 /* SDL_sysurl.h */,
|
||||
5616CA49252BB2A5005D5928 /* SDL_url.c */,
|
||||
);
|
||||
@@ -1501,16 +1477,6 @@
|
||||
path = virtual;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
89E580222D03606400DAF6D3 /* hidapi */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
89E5801F2D03606400DAF6D3 /* SDL_hidapihaptic.c */,
|
||||
89E580202D03606400DAF6D3 /* SDL_hidapihaptic_c.h */,
|
||||
89E580212D03606400DAF6D3 /* SDL_hidapihaptic_lg4ff.c */,
|
||||
);
|
||||
path = hidapi;
|
||||
sourceTree = "<group>";
|
||||
};
|
||||
A75FDAA423E2790500529352 /* ios */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
@@ -1569,7 +1535,6 @@
|
||||
A7D8A5C223E2513D00DCD162 /* haptic */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
89E580222D03606400DAF6D3 /* hidapi */,
|
||||
A7D8A5CD23E2513D00DCD162 /* darwin */,
|
||||
A7D8A5C323E2513D00DCD162 /* dummy */,
|
||||
A7D8A5C623E2513D00DCD162 /* SDL_haptic_c.h */,
|
||||
@@ -1939,12 +1904,8 @@
|
||||
A7D8A7BE23E2513E00DCD162 /* hidapi */ = {
|
||||
isa = PBXGroup;
|
||||
children = (
|
||||
F3395BA72D9A5971007246C8 /* SDL_hidapi_8bitdo.c */,
|
||||
F32305FE28939F6400E66D30 /* SDL_hidapi_combined.c */,
|
||||
F3395BA72D9A5971007246C9 /* SDL_hidapi_flydigi.c */,
|
||||
A7D8A7C923E2513E00DCD162 /* SDL_hidapi_gamecube.c */,
|
||||
F3B6B8092DC3EA54004954FD /* SDL_hidapi_gip.c */,
|
||||
89E5801D2D03602200DAF6D3 /* SDL_hidapi_lg4ff.c */,
|
||||
F3F07D59269640160074468B /* SDL_hidapi_luna.c */,
|
||||
F3FD042C2C9B755700824C4C /* SDL_hidapi_nintendo.h */,
|
||||
F388C95428B5F6F600661ECF /* SDL_hidapi_ps3.c */,
|
||||
@@ -1953,13 +1914,11 @@
|
||||
A75FDBC323EA380300529352 /* SDL_hidapi_rumble.h */,
|
||||
A75FDBC423EA380300529352 /* SDL_hidapi_rumble.c */,
|
||||
9846B07B287A9020000C35C8 /* SDL_hidapi_shield.c */,
|
||||
02D6A1C128A84B8F00A7F001 /* SDL_hidapi_sinput.c */,
|
||||
F3984CCF25BCC92800374F43 /* SDL_hidapi_stadia.c */,
|
||||
A75FDAAC23E2795C00529352 /* SDL_hidapi_steam.c */,
|
||||
F3FD042D2C9B755700824C4C /* SDL_hidapi_steam_hori.c */,
|
||||
A797456F2B2E9D39009D224A /* SDL_hidapi_steamdeck.c */,
|
||||
A7D8A7C623E2513E00DCD162 /* SDL_hidapi_switch.c */,
|
||||
A7D8A7C623E2513E00DCD163 /* SDL_hidapi_switch2.c */,
|
||||
F3D60A8228C16A1800788A3A /* SDL_hidapi_wii.c */,
|
||||
A7D8A7C223E2513E00DCD162 /* SDL_hidapi_xbox360.c */,
|
||||
A7D8A7C823E2513E00DCD162 /* SDL_hidapi_xbox360w.c */,
|
||||
@@ -2658,7 +2617,6 @@
|
||||
F37E18642BAA40670098C111 /* SDL_time_c.h in Headers */,
|
||||
F31013C82C24E98200FBE946 /* SDL_keymap_c.h in Headers */,
|
||||
63134A252A7902FD0021E9A6 /* SDL_pen_c.h in Headers */,
|
||||
89E580252D03606400DAF6D3 /* SDL_hidapihaptic_c.h in Headers */,
|
||||
F36C34312C0F876500991150 /* SDL_offscreenvulkan.h in Headers */,
|
||||
A7D8B2C023E2514200DCD162 /* SDL_pixels_c.h in Headers */,
|
||||
F37E18622BAA40090098C111 /* SDL_sysfilesystem.h in Headers */,
|
||||
@@ -2756,7 +2714,6 @@
|
||||
F3FA5A252B59ACE000FEAD97 /* yuv_rgb_common.h in Headers */,
|
||||
F3FA5A1D2B59ACE000FEAD97 /* yuv_rgb_internal.h in Headers */,
|
||||
F3D8BDFC2D6D2C7000B22FA1 /* SDL_eventwatch_c.h in Headers */,
|
||||
F3DC38C92E5FC60300CD73DE /* SDL_libusb.h in Headers */,
|
||||
F3FA5A242B59ACE000FEAD97 /* yuv_rgb_lsx.h in Headers */,
|
||||
F3FA5A1E2B59ACE000FEAD97 /* yuv_rgb_lsx_func.h in Headers */,
|
||||
F3FA5A1F2B59ACE000FEAD97 /* yuv_rgb_sse.h in Headers */,
|
||||
@@ -2876,7 +2833,7 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
shellPath = /bin/sh;
|
||||
shellScript = "# Build an xcframework with both device and simulator files for all platforms.\n# Adapted from an answer in\n# https://developer.apple.com/forums/thread/666335?answerId=685927022#685927022\n\nif [ \"$XCODE_VERSION_ACTUAL\" -lt 1100 ]\nthen\n echo \"error: Building an xcframework requires Xcode 11 minimum.\"\n exit 1\nfi\n\nFRAMEWORK_NAME=\"SDL3\"\nPROJECT_NAME=\"SDL\"\nSCHEME=\"SDL3\"\n\nMACOS_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-macosx.xcarchive\"\nIOS_SIMULATOR_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-iphonesimulator.xcarchive\"\nIOS_DEVICE_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-iphoneos.xcarchive\"\nTVOS_SIMULATOR_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-appletvsimulator.xcarchive\"\nTVOS_DEVICE_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-appletvos.xcarchive\"\n\nOUTPUT_DIR=\"./build/\"\n\n# macOS\nxcodebuild archive \\\n ONLY_ACTIVE_ARCH=NO \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${MACOS_ARCHIVE_PATH} \\\n -destination 'generic/platform=macOS,name=Any Mac' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n \n# iOS simulator\nxcodebuild archive \\\n ONLY_ACTIVE_ARCH=NO \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${IOS_SIMULATOR_ARCHIVE_PATH} \\\n -destination 'generic/platform=iOS Simulator' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# iOS device\nxcodebuild archive \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${IOS_DEVICE_ARCHIVE_PATH} \\\n -destination 'generic/platform=iOS' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# tvOS simulator\nxcodebuild archive \\\n ONLY_ACTIVE_ARCH=NO \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${TVOS_SIMULATOR_ARCHIVE_PATH} \\\n -destination 'generic/platform=tvOS Simulator' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# tvOS device\nxcodebuild archive \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${TVOS_DEVICE_ARCHIVE_PATH} \\\n -destination 'generic/platform=tvOS' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# Clean-up any existing instance of this xcframework from the Products directory\nrm -rf \"${OUTPUT_DIR}${FRAMEWORK_NAME}.xcframework\"\n\n# Create final xcframework\nxcodebuild -create-xcframework \\\n -framework \"${MACOS_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -debug-symbols \"${MACOS_ARCHIVE_PATH}\"/dSYMs/$FRAMEWORK_NAME.framework.dSYM \\\n -framework \"${IOS_DEVICE_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -debug-symbols \"${IOS_DEVICE_ARCHIVE_PATH}\"/dSYMs/$FRAMEWORK_NAME.framework.dSYM \\\n -framework \"${IOS_SIMULATOR_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -framework \"${TVOS_DEVICE_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -debug-symbols \"${TVOS_DEVICE_ARCHIVE_PATH}\"/dSYMs/$FRAMEWORK_NAME.framework.dSYM \\\n -framework \"${TVOS_SIMULATOR_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -output ${OUTPUT_DIR}/${FRAMEWORK_NAME}.xcframework\n\n# Ensure git doesn't pick up on our Products folder. \nrm -rf ${OUTPUT_DIR}/.gitignore\necho \"*\" >> ${OUTPUT_DIR}/.gitignore\n";
|
||||
shellScript = "# Build an xcframework with both device and simulator files for all platforms.\n# Adapted from an answer in\n# https://developer.apple.com/forums/thread/666335?answerId=685927022#685927022\n\nif [ \"$XCODE_VERSION_ACTUAL\" -lt 1100 ]\nthen\n echo \"error: Building an xcframework requires Xcode 11 minimum.\"\n exit 1\nfi\n\nFRAMEWORK_NAME=\"SDL3\"\nPROJECT_NAME=\"SDL\"\nSCHEME=\"SDL3\"\n\nMACOS_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-macosx.xcarchive\"\nIOS_SIMULATOR_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-iphonesimulator.xcarchive\"\nIOS_DEVICE_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-iphoneos.xcarchive\"\nTVOS_SIMULATOR_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-appletvsimulator.xcarchive\"\nTVOS_DEVICE_ARCHIVE_PATH=\"${BUILD_DIR}/${CONFIGURATION}/${FRAMEWORK_NAME}-appletvos.xcarchive\"\n\nOUTPUT_DIR=\"./build/\"\n\n# macOS\nxcodebuild archive \\\n ONLY_ACTIVE_ARCH=NO \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${MACOS_ARCHIVE_PATH} \\\n -destination 'generic/platform=macOS,name=Any Mac' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n \n# iOS simulator\nxcodebuild archive \\\n ONLY_ACTIVE_ARCH=NO \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${IOS_SIMULATOR_ARCHIVE_PATH} \\\n -destination 'generic/platform=iOS Simulator' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# iOS device\nxcodebuild archive \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${IOS_DEVICE_ARCHIVE_PATH} \\\n -destination 'generic/platform=iOS' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# tvOS simulator\nxcodebuild archive \\\n ONLY_ACTIVE_ARCH=NO \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${TVOS_SIMULATOR_ARCHIVE_PATH} \\\n -destination 'generic/platform=tvOS Simulator' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# tvOS device\nxcodebuild archive \\\n -scheme \"${SCHEME}\" \\\n -project \"${PROJECT_NAME}.xcodeproj\" \\\n -archivePath ${TVOS_DEVICE_ARCHIVE_PATH} \\\n -destination 'generic/platform=tvOS' \\\n BUILD_LIBRARY_FOR_DISTRIBUTION=YES \\\n SKIP_INSTALL=NO || exit $?\n\n# Clean-up any existing instance of this xcframework from the Products directory\nrm -rf \"${OUTPUT_DIR}${FRAMEWORK_NAME}.xcframework\"\n\n# Create final xcframework\nxcodebuild -create-xcframework \\\n -framework \"${MACOS_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -framework \"${IOS_DEVICE_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -framework \"${IOS_SIMULATOR_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -framework \"${TVOS_DEVICE_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -framework \"${TVOS_SIMULATOR_ARCHIVE_PATH}\"/Products/Library/Frameworks/${FRAMEWORK_NAME}.framework \\\n -output ${OUTPUT_DIR}/${FRAMEWORK_NAME}.xcframework\n\n# Ensure git doesn't pick up on our Products folder. \nrm -rf ${OUTPUT_DIR}/.gitignore\necho \"*\" >> ${OUTPUT_DIR}/.gitignore\n";
|
||||
};
|
||||
/* End PBXShellScriptBuildPhase section */
|
||||
|
||||
@@ -2890,7 +2847,6 @@
|
||||
A7D8B62F23E2514300DCD162 /* SDL_sysfilesystem.m in Sources */,
|
||||
A7D8B41C23E2514300DCD162 /* SDL_systls.c in Sources */,
|
||||
9846B07C287A9020000C35C8 /* SDL_hidapi_shield.c in Sources */,
|
||||
02D6A1C228A84B8F00A7F002 /* SDL_hidapi_sinput.c in Sources */,
|
||||
F31013C72C24E98200FBE946 /* SDL_keymap.c in Sources */,
|
||||
F3A9AE992C8A13C100AAC390 /* SDL_render_gpu.c in Sources */,
|
||||
A7D8BBD923E2574800DCD162 /* SDL_uikitmessagebox.m in Sources */,
|
||||
@@ -2949,8 +2905,6 @@
|
||||
A7D8BBDD23E2574800DCD162 /* SDL_uikitmodes.m in Sources */,
|
||||
A7D8BA3723E2514400DCD162 /* SDL_d3dmath.c in Sources */,
|
||||
F3A9AE9C2C8A13C100AAC390 /* SDL_pipeline_gpu.c in Sources */,
|
||||
89E580232D03606400DAF6D3 /* SDL_hidapihaptic.c in Sources */,
|
||||
89E580242D03606400DAF6D3 /* SDL_hidapihaptic_lg4ff.c in Sources */,
|
||||
75E0915A241EA924004729E1 /* SDL_virtualjoystick.c in Sources */,
|
||||
F338A11A2D1B37E4007CDFDF /* SDL_tray.c in Sources */,
|
||||
A7D8ABEB23E2514100DCD162 /* SDL_nullvideo.c in Sources */,
|
||||
@@ -3012,7 +2966,6 @@
|
||||
A7D8B76423E2514300DCD162 /* SDL_mixer.c in Sources */,
|
||||
A7D8BB5723E2514500DCD162 /* SDL_events.c in Sources */,
|
||||
A7D8ADE623E2514100DCD162 /* SDL_blit_0.c in Sources */,
|
||||
89E5801E2D03602200DAF6D3 /* SDL_hidapi_lg4ff.c in Sources */,
|
||||
A7D8B8A823E2514400DCD162 /* SDL_diskaudio.c in Sources */,
|
||||
56A2373329F9C113003CCA5F /* SDL_sysrwlock.c in Sources */,
|
||||
F3A9AE9A2C8A13C100AAC390 /* SDL_shaders_gpu.c in Sources */,
|
||||
@@ -3049,7 +3002,6 @@
|
||||
F3FA5A222B59ACE000FEAD97 /* yuv_rgb_sse.c in Sources */,
|
||||
F3C2CB232C5DDDB2004D7998 /* SDL_categories.c in Sources */,
|
||||
A7D8B55123E2514300DCD162 /* SDL_hidapi_switch.c in Sources */,
|
||||
A7D8B55123E2514300DCD163 /* SDL_hidapi_switch2.c in Sources */,
|
||||
A7D8B96223E2514400DCD162 /* SDL_strtokr.c in Sources */,
|
||||
A7D8BB7523E2514500DCD162 /* SDL_clipboardevents.c in Sources */,
|
||||
E4F798202AD8D87F00669F54 /* SDL_video_unsupported.c in Sources */,
|
||||
@@ -3077,7 +3029,6 @@
|
||||
A7D8BA5B23E2514400DCD162 /* SDL_shaders_gles2.c in Sources */,
|
||||
A7D8B14023E2514200DCD162 /* SDL_blit_1.c in Sources */,
|
||||
A7D8BBDB23E2574800DCD162 /* SDL_uikitmetalview.m in Sources */,
|
||||
F3B6B80A2DC3EA54004954FD /* SDL_hidapi_gip.c in Sources */,
|
||||
A7D8BB1523E2514500DCD162 /* SDL_mouse.c in Sources */,
|
||||
F395C19C2569C68F00942BFF /* SDL_iokitjoystick.c in Sources */,
|
||||
A7D8B4B223E2514300DCD162 /* SDL_sysjoystick.c in Sources */,
|
||||
@@ -3100,15 +3051,12 @@
|
||||
000028F8113A53F4333E0000 /* SDL_main_callbacks.c in Sources */,
|
||||
000098E9DAA43EF6FF7F0000 /* SDL_camera.c in Sources */,
|
||||
F310138E2C1F2CB700FBE946 /* SDL_random.c in Sources */,
|
||||
F3395BA82D9A5971007246C8 /* SDL_hidapi_8bitdo.c in Sources */,
|
||||
00001B2471F503DD3C1B0000 /* SDL_camera_dummy.c in Sources */,
|
||||
00002B20A48E055EB0350000 /* SDL_camera_coremedia.m in Sources */,
|
||||
000080903BC03006F24E0000 /* SDL_filesystem.c in Sources */,
|
||||
F3FBB1082DDF93AB0000F99F /* SDL_hidapi_flydigi.c in Sources */,
|
||||
0000481D255AF155B42C0000 /* SDL_sysfsops.c in Sources */,
|
||||
0000494CC93F3E624D3C0000 /* SDL_systime.c in Sources */,
|
||||
000095FA1BDE436CF3AF0000 /* SDL_time.c in Sources */,
|
||||
F3DC38CA2E5FC60300CD73DE /* SDL_libusb.c in Sources */,
|
||||
0000140640E77F73F1DF0000 /* SDL_dialog_utils.c in Sources */,
|
||||
0000D5B526B85DE7AB1C0000 /* SDL_cocoapen.m in Sources */,
|
||||
6312C66D2B42341400A7BB00 /* SDL_murmur3.c in Sources */,
|
||||
@@ -3137,8 +3085,8 @@
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CLANG_ENABLE_OBJC_ARC = YES;
|
||||
DEPLOYMENT_POSTPROCESSING = YES;
|
||||
DYLIB_COMPATIBILITY_VERSION = 301.0.0;
|
||||
DYLIB_CURRENT_VERSION = 301.0.0;
|
||||
DYLIB_COMPATIBILITY_VERSION = 201.0.0;
|
||||
DYLIB_CURRENT_VERSION = 201.14.0;
|
||||
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||
GCC_ALTIVEC_EXTENSIONS = YES;
|
||||
@@ -3173,7 +3121,7 @@
|
||||
"@loader_path/Frameworks",
|
||||
);
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.13;
|
||||
MARKETING_VERSION = 3.3.0;
|
||||
MARKETING_VERSION = 3.2.14;
|
||||
OTHER_LDFLAGS = "$(CONFIG_FRAMEWORK_LDFLAGS)";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = org.libsdl.SDL3;
|
||||
PRODUCT_NAME = SDL3;
|
||||
@@ -3190,8 +3138,6 @@
|
||||
baseConfigurationReference = F3F7BE3B2CBD79D200C984AF /* config.xcconfig */;
|
||||
buildSettings = {
|
||||
CLANG_LINK_OBJC_RUNTIME = NO;
|
||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||
GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
|
||||
OTHER_LDFLAGS = "-liconv";
|
||||
SUPPORTS_MACCATALYST = YES;
|
||||
};
|
||||
@@ -3203,8 +3149,8 @@
|
||||
ALLOW_TARGET_PLATFORM_SPECIALIZATION = YES;
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CLANG_ENABLE_OBJC_ARC = YES;
|
||||
DYLIB_COMPATIBILITY_VERSION = 301.0.0;
|
||||
DYLIB_CURRENT_VERSION = 301.0.0;
|
||||
DYLIB_COMPATIBILITY_VERSION = 201.0.0;
|
||||
DYLIB_CURRENT_VERSION = 201.14.0;
|
||||
DYLIB_INSTALL_NAME_BASE = "@rpath";
|
||||
ENABLE_STRICT_OBJC_MSGSEND = YES;
|
||||
ENABLE_TESTABILITY = YES;
|
||||
@@ -3236,7 +3182,7 @@
|
||||
"@loader_path/Frameworks",
|
||||
);
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.13;
|
||||
MARKETING_VERSION = 3.3.0;
|
||||
MARKETING_VERSION = 3.2.14;
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
OTHER_LDFLAGS = "$(CONFIG_FRAMEWORK_LDFLAGS)";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = org.libsdl.SDL3;
|
||||
@@ -3254,8 +3200,6 @@
|
||||
baseConfigurationReference = F3F7BE3B2CBD79D200C984AF /* config.xcconfig */;
|
||||
buildSettings = {
|
||||
CLANG_LINK_OBJC_RUNTIME = NO;
|
||||
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
|
||||
GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
|
||||
OTHER_LDFLAGS = "-liconv";
|
||||
SUPPORTS_MACCATALYST = YES;
|
||||
};
|
||||
|
@@ -1,4 +1,4 @@
|
||||
Title SDL 3.3.0
|
||||
Title SDL 3.2.14
|
||||
Version 1
|
||||
Description SDL Library for macOS (http://www.libsdl.org)
|
||||
DefaultLocation /Library/Frameworks
|
||||
|
@@ -92,7 +92,7 @@ if(NOT TARGET SDL3::Headers)
|
||||
add_library(SDL3::Headers INTERFACE IMPORTED)
|
||||
set_target_properties(SDL3::Headers
|
||||
PROPERTIES
|
||||
INTERFACE_COMPILE_OPTIONS "-F${_sdl3_framework_parent_path}"
|
||||
INTERFACE_COMPILE_OPTIONS "SHELL:-F \"${_sdl3_framework_parent_path}\""
|
||||
)
|
||||
endif()
|
||||
set(SDL3_Headers_FOUND TRUE)
|
||||
|
@@ -7,4 +7,4 @@
|
||||
APP_ABI := armeabi-v7a arm64-v8a x86 x86_64
|
||||
|
||||
# Min runtime API level
|
||||
APP_PLATFORM=android-21
|
||||
APP_PLATFORM=android-16
|
||||
|
3
android-project/app/proguard-rules.pro
vendored
3
android-project/app/proguard-rules.pro
vendored
@@ -36,6 +36,7 @@
|
||||
int messageboxShowMessageBox(int, java.lang.String, java.lang.String, int[], int[], java.lang.String[], int[]);
|
||||
void minimizeWindow();
|
||||
boolean openURL(java.lang.String);
|
||||
void onNativePen(int, int, int , float , float , float);
|
||||
void requestPermission(java.lang.String, int);
|
||||
boolean showToast(java.lang.String, int, int, int, int);
|
||||
boolean sendMessage(int, int);
|
||||
@@ -50,8 +51,6 @@
|
||||
boolean supportsRelativeMouse();
|
||||
int openFileDescriptor(java.lang.String, java.lang.String);
|
||||
boolean showFileDialog(java.lang.String[], boolean, boolean, int);
|
||||
java.lang.String getPreferredLocales();
|
||||
java.lang.String formatLocale(java.util.Locale);
|
||||
}
|
||||
|
||||
-keep,includedescriptorclasses,allowoptimization class org.libsdl.app.HIDDeviceManager {
|
||||
|
@@ -71,7 +71,6 @@
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:allowBackup="true"
|
||||
android:theme="@style/AppTheme"
|
||||
android:enableOnBackInvokedCallback="false"
|
||||
android:hardwareAccelerated="true" >
|
||||
|
||||
<!-- Example of setting SDL hints from AndroidManifest.xml:
|
||||
|
@@ -44,9 +44,9 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
|
||||
private static final int CHROMEBOOK_CONNECTION_CHECK_INTERVAL = 10000;
|
||||
|
||||
static final UUID steamControllerService = UUID.fromString("100F6C32-1735-4313-B402-38567131E5F3");
|
||||
static final UUID inputCharacteristic = UUID.fromString("100F6C33-1735-4313-B402-38567131E5F3");
|
||||
static final UUID reportCharacteristic = UUID.fromString("100F6C34-1735-4313-B402-38567131E5F3");
|
||||
static public final UUID steamControllerService = UUID.fromString("100F6C32-1735-4313-B402-38567131E5F3");
|
||||
static public final UUID inputCharacteristic = UUID.fromString("100F6C33-1735-4313-B402-38567131E5F3");
|
||||
static public final UUID reportCharacteristic = UUID.fromString("100F6C34-1735-4313-B402-38567131E5F3");
|
||||
static private final byte[] enterValveMode = new byte[] { (byte)0xC0, (byte)0x87, 0x03, 0x08, 0x07, 0x00 };
|
||||
|
||||
static class GattOperation {
|
||||
@@ -156,12 +156,12 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
}
|
||||
}
|
||||
|
||||
HIDDeviceBLESteamController(HIDDeviceManager manager, BluetoothDevice device) {
|
||||
public HIDDeviceBLESteamController(HIDDeviceManager manager, BluetoothDevice device) {
|
||||
mManager = manager;
|
||||
mDevice = device;
|
||||
mDeviceId = mManager.getDeviceIDForIdentifier(getIdentifier());
|
||||
mIsRegistered = false;
|
||||
mIsChromebook = SDLActivity.isChromebook();
|
||||
mIsChromebook = mManager.getContext().getPackageManager().hasSystemFeature("org.chromium.arc.device_management");
|
||||
mOperations = new LinkedList<GattOperation>();
|
||||
mHandler = new Handler(Looper.getMainLooper());
|
||||
|
||||
@@ -169,17 +169,17 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
// final HIDDeviceBLESteamController finalThis = this;
|
||||
// mHandler.postDelayed(new Runnable() {
|
||||
// @Override
|
||||
// void run() {
|
||||
// public void run() {
|
||||
// finalThis.checkConnectionForChromebookIssue();
|
||||
// }
|
||||
// }, CHROMEBOOK_CONNECTION_CHECK_INTERVAL);
|
||||
}
|
||||
|
||||
String getIdentifier() {
|
||||
public String getIdentifier() {
|
||||
return String.format("SteamController.%s", mDevice.getAddress());
|
||||
}
|
||||
|
||||
BluetoothGatt getGatt() {
|
||||
public BluetoothGatt getGatt() {
|
||||
return mGatt;
|
||||
}
|
||||
|
||||
@@ -219,7 +219,7 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
return btManager.getConnectionState(mDevice, BluetoothProfile.GATT);
|
||||
}
|
||||
|
||||
void reconnect() {
|
||||
public void reconnect() {
|
||||
|
||||
if (getConnectionState() != BluetoothProfile.STATE_CONNECTED) {
|
||||
mGatt.disconnect();
|
||||
@@ -401,12 +401,12 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
queueGattOperation(op);
|
||||
}
|
||||
|
||||
void writeCharacteristic(UUID uuid, byte[] value) {
|
||||
public void writeCharacteristic(UUID uuid, byte[] value) {
|
||||
GattOperation op = HIDDeviceBLESteamController.GattOperation.writeCharacteristic(mGatt, uuid, value);
|
||||
queueGattOperation(op);
|
||||
}
|
||||
|
||||
void readCharacteristic(UUID uuid) {
|
||||
public void readCharacteristic(UUID uuid) {
|
||||
GattOperation op = HIDDeviceBLESteamController.GattOperation.readCharacteristic(mGatt, uuid);
|
||||
queueGattOperation(op);
|
||||
}
|
||||
@@ -415,7 +415,6 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
////////////// BluetoothGattCallback overridden methods
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@Override
|
||||
public void onConnectionStateChange(BluetoothGatt g, int status, int newState) {
|
||||
//Log.v(TAG, "onConnectionStateChange status=" + status + " newState=" + newState);
|
||||
mIsReconnecting = false;
|
||||
@@ -438,7 +437,6 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
// Disconnection is handled in SteamLink using the ACTION_ACL_DISCONNECTED Intent.
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onServicesDiscovered(BluetoothGatt gatt, int status) {
|
||||
//Log.v(TAG, "onServicesDiscovered status=" + status);
|
||||
if (status == 0) {
|
||||
@@ -455,7 +453,6 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCharacteristicRead(BluetoothGatt gatt, BluetoothGattCharacteristic characteristic, int status) {
|
||||
//Log.v(TAG, "onCharacteristicRead status=" + status + " uuid=" + characteristic.getUuid());
|
||||
|
||||
@@ -466,7 +463,6 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
finishCurrentGattOperation();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCharacteristicWrite(BluetoothGatt gatt, BluetoothGattCharacteristic characteristic, int status) {
|
||||
//Log.v(TAG, "onCharacteristicWrite status=" + status + " uuid=" + characteristic.getUuid());
|
||||
|
||||
@@ -482,7 +478,6 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
finishCurrentGattOperation();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCharacteristicChanged(BluetoothGatt gatt, BluetoothGattCharacteristic characteristic) {
|
||||
// Enable this for verbose logging of controller input reports
|
||||
//Log.v(TAG, "onCharacteristicChanged uuid=" + characteristic.getUuid() + " data=" + HexDump.dumpHexString(characteristic.getValue()));
|
||||
@@ -492,12 +487,10 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDescriptorRead(BluetoothGatt gatt, BluetoothGattDescriptor descriptor, int status) {
|
||||
//Log.v(TAG, "onDescriptorRead status=" + status);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDescriptorWrite(BluetoothGatt gatt, BluetoothGattDescriptor descriptor, int status) {
|
||||
BluetoothGattCharacteristic chr = descriptor.getCharacteristic();
|
||||
//Log.v(TAG, "onDescriptorWrite status=" + status + " uuid=" + chr.getUuid() + " descriptor=" + descriptor.getUuid());
|
||||
@@ -515,17 +508,14 @@ class HIDDeviceBLESteamController extends BluetoothGattCallback implements HIDDe
|
||||
finishCurrentGattOperation();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onReliableWriteCompleted(BluetoothGatt gatt, int status) {
|
||||
//Log.v(TAG, "onReliableWriteCompleted status=" + status);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onReadRemoteRssi(BluetoothGatt gatt, int rssi, int status) {
|
||||
//Log.v(TAG, "onReadRemoteRssi status=" + status);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMtuChanged(BluetoothGatt gatt, int mtu, int status) {
|
||||
//Log.v(TAG, "onMtuChanged status=" + status);
|
||||
}
|
||||
|
@@ -32,7 +32,7 @@ public class HIDDeviceManager {
|
||||
private static HIDDeviceManager sManager;
|
||||
private static int sManagerRefCount = 0;
|
||||
|
||||
static public HIDDeviceManager acquire(Context context) {
|
||||
public static HIDDeviceManager acquire(Context context) {
|
||||
if (sManagerRefCount == 0) {
|
||||
sManager = new HIDDeviceManager(context);
|
||||
}
|
||||
@@ -40,7 +40,7 @@ public class HIDDeviceManager {
|
||||
return sManager;
|
||||
}
|
||||
|
||||
static public void release(HIDDeviceManager manager) {
|
||||
public static void release(HIDDeviceManager manager) {
|
||||
if (manager == sManager) {
|
||||
--sManagerRefCount;
|
||||
if (sManagerRefCount == 0) {
|
||||
@@ -108,7 +108,7 @@ public class HIDDeviceManager {
|
||||
HIDDeviceRegisterCallback();
|
||||
|
||||
mSharedPreferences = mContext.getSharedPreferences("hidapi", Context.MODE_PRIVATE);
|
||||
mIsChromebook = SDLActivity.isChromebook();
|
||||
mIsChromebook = mContext.getPackageManager().hasSystemFeature("org.chromium.arc.device_management");
|
||||
|
||||
// if (shouldClear) {
|
||||
// SharedPreferences.Editor spedit = mSharedPreferences.edit();
|
||||
@@ -121,11 +121,11 @@ public class HIDDeviceManager {
|
||||
}
|
||||
}
|
||||
|
||||
Context getContext() {
|
||||
public Context getContext() {
|
||||
return mContext;
|
||||
}
|
||||
|
||||
int getDeviceIDForIdentifier(String identifier) {
|
||||
public int getDeviceIDForIdentifier(String identifier) {
|
||||
SharedPreferences.Editor spedit = mSharedPreferences.edit();
|
||||
|
||||
int result = mSharedPreferences.getInt(identifier, 0);
|
||||
@@ -193,7 +193,7 @@ public class HIDDeviceManager {
|
||||
filter.addAction(UsbManager.ACTION_USB_DEVICE_ATTACHED);
|
||||
filter.addAction(UsbManager.ACTION_USB_DEVICE_DETACHED);
|
||||
filter.addAction(HIDDeviceManager.ACTION_USB_PERMISSION);
|
||||
if (Build.VERSION.SDK_INT >= 33) { /* Android 13.0 (TIRAMISU) */
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
|
||||
mContext.registerReceiver(mUsbBroadcast, filter, Context.RECEIVER_EXPORTED);
|
||||
} else {
|
||||
mContext.registerReceiver(mUsbBroadcast, filter);
|
||||
@@ -288,13 +288,9 @@ public class HIDDeviceManager {
|
||||
0x1532, // Razer Wildcat
|
||||
0x20d6, // PowerA
|
||||
0x24c6, // PowerA
|
||||
0x294b, // Snakebyte
|
||||
0x2dc8, // 8BitDo
|
||||
0x2e24, // Hyperkin
|
||||
0x2e95, // SCUF
|
||||
0x3285, // Nacon
|
||||
0x3537, // GameSir
|
||||
0x366c, // ByoWave
|
||||
};
|
||||
|
||||
if (usbInterface.getId() == 0 &&
|
||||
@@ -380,7 +376,7 @@ public class HIDDeviceManager {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!mContext.getPackageManager().hasSystemFeature(PackageManager.FEATURE_BLUETOOTH_LE)) {
|
||||
if (!mContext.getPackageManager().hasSystemFeature(PackageManager.FEATURE_BLUETOOTH_LE) || (Build.VERSION.SDK_INT < 18 /* Android 4.3 (JELLY_BEAN_MR2) */)) {
|
||||
Log.d(TAG, "Couldn't initialize Bluetooth, this version of Android does not support Bluetooth LE");
|
||||
return;
|
||||
}
|
||||
@@ -412,7 +408,7 @@ public class HIDDeviceManager {
|
||||
IntentFilter filter = new IntentFilter();
|
||||
filter.addAction(BluetoothDevice.ACTION_ACL_CONNECTED);
|
||||
filter.addAction(BluetoothDevice.ACTION_ACL_DISCONNECTED);
|
||||
if (Build.VERSION.SDK_INT >= 33) { /* Android 13.0 (TIRAMISU) */
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) {
|
||||
mContext.registerReceiver(mBluetoothBroadcast, filter, Context.RECEIVER_EXPORTED);
|
||||
} else {
|
||||
mContext.registerReceiver(mBluetoothBroadcast, filter);
|
||||
@@ -443,7 +439,7 @@ public class HIDDeviceManager {
|
||||
// Chromebooks do not pass along ACTION_ACL_CONNECTED / ACTION_ACL_DISCONNECTED properly.
|
||||
// This function provides a sort of dummy version of that, watching for changes in the
|
||||
// connected devices and attempting to add controllers as things change.
|
||||
void chromebookConnectionHandler() {
|
||||
public void chromebookConnectionHandler() {
|
||||
if (!mIsChromebook) {
|
||||
return;
|
||||
}
|
||||
@@ -482,7 +478,7 @@ public class HIDDeviceManager {
|
||||
}, 10000);
|
||||
}
|
||||
|
||||
boolean connectBluetoothDevice(BluetoothDevice bluetoothDevice) {
|
||||
public boolean connectBluetoothDevice(BluetoothDevice bluetoothDevice) {
|
||||
Log.v(TAG, "connectBluetoothDevice device=" + bluetoothDevice);
|
||||
synchronized (this) {
|
||||
if (mBluetoothDevices.containsKey(bluetoothDevice)) {
|
||||
@@ -503,7 +499,7 @@ public class HIDDeviceManager {
|
||||
return true;
|
||||
}
|
||||
|
||||
void disconnectBluetoothDevice(BluetoothDevice bluetoothDevice) {
|
||||
public void disconnectBluetoothDevice(BluetoothDevice bluetoothDevice) {
|
||||
synchronized (this) {
|
||||
HIDDeviceBLESteamController device = mBluetoothDevices.get(bluetoothDevice);
|
||||
if (device == null)
|
||||
@@ -517,7 +513,7 @@ public class HIDDeviceManager {
|
||||
}
|
||||
}
|
||||
|
||||
boolean isSteamController(BluetoothDevice bluetoothDevice) {
|
||||
public boolean isSteamController(BluetoothDevice bluetoothDevice) {
|
||||
// Sanity check. If you pass in a null device, by definition it is never a Steam Controller.
|
||||
if (bluetoothDevice == null) {
|
||||
return false;
|
||||
@@ -571,7 +567,7 @@ public class HIDDeviceManager {
|
||||
////////// JNI interface functions
|
||||
//////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
boolean initialize(boolean usb, boolean bluetooth) {
|
||||
public boolean initialize(boolean usb, boolean bluetooth) {
|
||||
Log.v(TAG, "initialize(" + usb + ", " + bluetooth + ")");
|
||||
|
||||
if (usb) {
|
||||
@@ -583,7 +579,7 @@ public class HIDDeviceManager {
|
||||
return true;
|
||||
}
|
||||
|
||||
boolean openDevice(int deviceID) {
|
||||
public boolean openDevice(int deviceID) {
|
||||
Log.v(TAG, "openDevice deviceID=" + deviceID);
|
||||
HIDDevice device = getDevice(deviceID);
|
||||
if (device == null) {
|
||||
@@ -603,10 +599,13 @@ public class HIDDeviceManager {
|
||||
} else {
|
||||
flags = 0;
|
||||
}
|
||||
|
||||
if (Build.VERSION.SDK_INT >= 33 /* Android 14.0 (U) */) {
|
||||
Intent intent = new Intent(HIDDeviceManager.ACTION_USB_PERMISSION);
|
||||
intent.setPackage(mContext.getPackageName());
|
||||
mUsbManager.requestPermission(usbDevice, PendingIntent.getBroadcast(mContext, 0, intent, flags));
|
||||
} else {
|
||||
mUsbManager.requestPermission(usbDevice, PendingIntent.getBroadcast(mContext, 0, new Intent(HIDDeviceManager.ACTION_USB_PERMISSION), flags));
|
||||
}
|
||||
} catch (Exception e) {
|
||||
Log.v(TAG, "Couldn't request permission for USB device " + usbDevice);
|
||||
HIDDeviceOpenResult(deviceID, false);
|
||||
@@ -622,7 +621,7 @@ public class HIDDeviceManager {
|
||||
return false;
|
||||
}
|
||||
|
||||
int writeReport(int deviceID, byte[] report, boolean feature) {
|
||||
public int writeReport(int deviceID, byte[] report, boolean feature) {
|
||||
try {
|
||||
//Log.v(TAG, "writeReport deviceID=" + deviceID + " length=" + report.length);
|
||||
HIDDevice device;
|
||||
@@ -639,7 +638,7 @@ public class HIDDeviceManager {
|
||||
return -1;
|
||||
}
|
||||
|
||||
boolean readReport(int deviceID, byte[] report, boolean feature) {
|
||||
public boolean readReport(int deviceID, byte[] report, boolean feature) {
|
||||
try {
|
||||
//Log.v(TAG, "readReport deviceID=" + deviceID);
|
||||
HIDDevice device;
|
||||
@@ -656,7 +655,7 @@ public class HIDDeviceManager {
|
||||
return false;
|
||||
}
|
||||
|
||||
void closeDevice(int deviceID) {
|
||||
public void closeDevice(int deviceID) {
|
||||
try {
|
||||
Log.v(TAG, "closeDevice deviceID=" + deviceID);
|
||||
HIDDevice device;
|
||||
|
@@ -30,7 +30,7 @@ class HIDDeviceUSB implements HIDDevice {
|
||||
mRunning = false;
|
||||
}
|
||||
|
||||
String getIdentifier() {
|
||||
public String getIdentifier() {
|
||||
return String.format("%s/%x/%x/%d", mDevice.getDeviceName(), mDevice.getVendorId(), mDevice.getProductId(), mInterfaceIndex);
|
||||
}
|
||||
|
||||
@@ -52,12 +52,14 @@ class HIDDeviceUSB implements HIDDevice {
|
||||
@Override
|
||||
public String getSerialNumber() {
|
||||
String result = null;
|
||||
if (Build.VERSION.SDK_INT >= 21 /* Android 5.0 (LOLLIPOP) */) {
|
||||
try {
|
||||
result = mDevice.getSerialNumber();
|
||||
}
|
||||
catch (SecurityException exception) {
|
||||
//Log.w(TAG, "App permissions mean we cannot get serial number for device " + getDeviceName() + " message: " + exception.getMessage());
|
||||
}
|
||||
}
|
||||
if (result == null) {
|
||||
result = "";
|
||||
}
|
||||
@@ -71,8 +73,10 @@ class HIDDeviceUSB implements HIDDevice {
|
||||
|
||||
@Override
|
||||
public String getManufacturerName() {
|
||||
String result;
|
||||
String result = null;
|
||||
if (Build.VERSION.SDK_INT >= 21 /* Android 5.0 (LOLLIPOP) */) {
|
||||
result = mDevice.getManufacturerName();
|
||||
}
|
||||
if (result == null) {
|
||||
result = String.format("%x", getVendorId());
|
||||
}
|
||||
@@ -81,8 +85,10 @@ class HIDDeviceUSB implements HIDDevice {
|
||||
|
||||
@Override
|
||||
public String getProductName() {
|
||||
String result;
|
||||
String result = null;
|
||||
if (Build.VERSION.SDK_INT >= 21 /* Android 5.0 (LOLLIPOP) */) {
|
||||
result = mDevice.getProductName();
|
||||
}
|
||||
if (result == null) {
|
||||
result = String.format("%x", getProductId());
|
||||
}
|
||||
@@ -94,7 +100,7 @@ class HIDDeviceUSB implements HIDDevice {
|
||||
return mDevice;
|
||||
}
|
||||
|
||||
String getDeviceName() {
|
||||
public String getDeviceName() {
|
||||
return getManufacturerName() + " " + getProductName() + "(0x" + String.format("%x", getVendorId()) + "/0x" + String.format("%x", getProductId()) + ")";
|
||||
}
|
||||
|
||||
|
@@ -12,14 +12,14 @@ public class SDL {
|
||||
|
||||
// This function should be called first and sets up the native code
|
||||
// so it can call into the Java classes
|
||||
static public void setupJNI() {
|
||||
public static void setupJNI() {
|
||||
SDLActivity.nativeSetupJNI();
|
||||
SDLAudioManager.nativeSetupJNI();
|
||||
SDLControllerManager.nativeSetupJNI();
|
||||
}
|
||||
|
||||
// This function should be called each time the activity is started
|
||||
static public void initialize() {
|
||||
public static void initialize() {
|
||||
setContext(null);
|
||||
|
||||
SDLActivity.initialize();
|
||||
@@ -28,20 +28,20 @@ public class SDL {
|
||||
}
|
||||
|
||||
// This function stores the current activity (SDL or not)
|
||||
static public void setContext(Context context) {
|
||||
public static void setContext(Context context) {
|
||||
SDLAudioManager.setContext(context);
|
||||
mContext = context;
|
||||
}
|
||||
|
||||
static public Context getContext() {
|
||||
public static Context getContext() {
|
||||
return mContext;
|
||||
}
|
||||
|
||||
static void loadLibrary(String libraryName) throws UnsatisfiedLinkError, SecurityException, NullPointerException {
|
||||
public static void loadLibrary(String libraryName) throws UnsatisfiedLinkError, SecurityException, NullPointerException {
|
||||
loadLibrary(libraryName, mContext);
|
||||
}
|
||||
|
||||
static void loadLibrary(String libraryName, Context context) throws UnsatisfiedLinkError, SecurityException, NullPointerException {
|
||||
public static void loadLibrary(String libraryName, Context context) throws UnsatisfiedLinkError, SecurityException, NullPointerException {
|
||||
|
||||
if (libraryName == null) {
|
||||
throw new NullPointerException("No library name provided.");
|
||||
|
@@ -23,7 +23,6 @@ import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.LocaleList;
|
||||
import android.os.Message;
|
||||
import android.os.ParcelFileDescriptor;
|
||||
import android.util.DisplayMetrics;
|
||||
@@ -60,8 +59,8 @@ import java.util.Locale;
|
||||
public class SDLActivity extends Activity implements View.OnSystemUiVisibilityChangeListener {
|
||||
private static final String TAG = "SDL";
|
||||
private static final int SDL_MAJOR_VERSION = 3;
|
||||
private static final int SDL_MINOR_VERSION = 3;
|
||||
private static final int SDL_MICRO_VERSION = 0;
|
||||
private static final int SDL_MINOR_VERSION = 2;
|
||||
private static final int SDL_MICRO_VERSION = 14;
|
||||
/*
|
||||
// Display InputType.SOURCE/CLASS of events and devices
|
||||
//
|
||||
@@ -107,9 +106,11 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
if ((s & tst) == tst) src += " GAMEPAD";
|
||||
s2 &= ~tst;
|
||||
|
||||
if (Build.VERSION.SDK_INT >= 21) {
|
||||
tst = InputDevice.SOURCE_HDMI;
|
||||
if ((s & tst) == tst) src += " HDMI";
|
||||
s2 &= ~tst;
|
||||
}
|
||||
|
||||
tst = InputDevice.SOURCE_JOYSTICK;
|
||||
if ((s & tst) == tst) src += " JOYSTICK";
|
||||
@@ -144,9 +145,11 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
if ((s & tst) == tst) src += " TOUCHSCREEN";
|
||||
s2 &= ~tst;
|
||||
|
||||
if (Build.VERSION.SDK_INT >= 18) {
|
||||
tst = InputDevice.SOURCE_TOUCH_NAVIGATION;
|
||||
if ((s & tst) == tst) src += " TOUCH_NAVIGATION";
|
||||
s2 &= ~tst;
|
||||
}
|
||||
|
||||
tst = InputDevice.SOURCE_TRACKBALL;
|
||||
if ((s & tst) == tst) src += " TRACKBALL";
|
||||
@@ -908,6 +911,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
}
|
||||
break;
|
||||
case COMMAND_CHANGE_WINDOW_STYLE:
|
||||
if (Build.VERSION.SDK_INT >= 19 /* Android 4.4 (KITKAT) */) {
|
||||
if (context instanceof Activity) {
|
||||
Window window = ((Activity) context).getWindow();
|
||||
if (window != null) {
|
||||
@@ -940,6 +944,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
} else {
|
||||
Log.e(TAG, "error handling message, getContext() returned no Activity");
|
||||
}
|
||||
}
|
||||
break;
|
||||
case COMMAND_TEXTEDIT_HIDE:
|
||||
if (mTextEdit != null) {
|
||||
@@ -988,6 +993,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
msg.obj = data;
|
||||
boolean result = commandHandler.sendMessage(msg);
|
||||
|
||||
if (Build.VERSION.SDK_INT >= 19 /* Android 4.4 (KITKAT) */) {
|
||||
if (command == COMMAND_CHANGE_WINDOW_STYLE) {
|
||||
// Ensure we don't return until the resize has actually happened,
|
||||
// or 500ms have passed.
|
||||
@@ -1037,6 +1043,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
@@ -1323,17 +1330,10 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
public static boolean isChromebook() {
|
||||
// https://stackoverflow.com/questions/39784415/how-to-detect-programmatically-if-android-app-is-running-in-chrome-book-or-in
|
||||
if (getContext() != null) {
|
||||
if (getContext().getPackageManager().hasSystemFeature("org.chromium.arc")
|
||||
|| getContext().getPackageManager().hasSystemFeature("org.chromium.arc.device_management")) {
|
||||
return true;
|
||||
if (getContext() == null) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// Running on AVD emulator
|
||||
boolean isChromebookEmulator = (Build.MODEL != null && Build.MODEL.startsWith("sdk_gpc_"));
|
||||
return isChromebookEmulator;
|
||||
return getContext().getPackageManager().hasSystemFeature("org.chromium.arc.device_management");
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1766,6 +1766,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
private final Runnable rehideSystemUi = new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
if (Build.VERSION.SDK_INT >= 19 /* Android 4.4 (KITKAT) */) {
|
||||
int flags = View.SYSTEM_UI_FLAG_FULLSCREEN |
|
||||
View.SYSTEM_UI_FLAG_HIDE_NAVIGATION |
|
||||
View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY |
|
||||
@@ -1775,6 +1776,7 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
|
||||
SDLActivity.this.getWindow().getDecorView().setSystemUiVisibility(flags);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public void onSystemUiVisibilityChange(int visibility) {
|
||||
@@ -1968,9 +1970,12 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
Intent i = new Intent(Intent.ACTION_VIEW);
|
||||
i.setData(Uri.parse(url));
|
||||
|
||||
int flags = Intent.FLAG_ACTIVITY_NO_HISTORY
|
||||
| Intent.FLAG_ACTIVITY_MULTIPLE_TASK
|
||||
| Intent.FLAG_ACTIVITY_NEW_DOCUMENT;
|
||||
int flags = Intent.FLAG_ACTIVITY_NO_HISTORY | Intent.FLAG_ACTIVITY_MULTIPLE_TASK;
|
||||
if (Build.VERSION.SDK_INT >= 21 /* Android 5.0 (LOLLIPOP) */) {
|
||||
flags |= Intent.FLAG_ACTIVITY_NEW_DOCUMENT;
|
||||
} else {
|
||||
flags |= Intent.FLAG_ACTIVITY_CLEAR_WHEN_TASK_RESET;
|
||||
}
|
||||
i.addFlags(flags);
|
||||
|
||||
mSingleton.startActivity(i);
|
||||
@@ -2111,44 +2116,6 @@ public class SDLActivity extends Activity implements View.OnSystemUiVisibilityCh
|
||||
int requestCode;
|
||||
boolean multipleChoice;
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
public static String getPreferredLocales() {
|
||||
String result = "";
|
||||
if (Build.VERSION.SDK_INT >= 24 /* Android 7 (N) */) {
|
||||
LocaleList locales = LocaleList.getAdjustedDefault();
|
||||
for (int i = 0; i < locales.size(); i++) {
|
||||
if (i != 0) result += ",";
|
||||
result += formatLocale(locales.get(i));
|
||||
}
|
||||
} else if (mCurrentLocale != null) {
|
||||
result = formatLocale(mCurrentLocale);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public static String formatLocale(Locale locale) {
|
||||
String result = "";
|
||||
String lang = "";
|
||||
if (locale.getLanguage() == "in") {
|
||||
// Indonesian is "id" according to ISO 639.2, but on Android is "in" because of Java backwards compatibility
|
||||
lang = "id";
|
||||
} else if (locale.getLanguage() == "") {
|
||||
// Make sure language is never empty
|
||||
lang = "und";
|
||||
} else {
|
||||
lang = locale.getLanguage();
|
||||
}
|
||||
|
||||
if (locale.getCountry() == "") {
|
||||
result = lang;
|
||||
} else {
|
||||
result = lang + "_" + locale.getCountry();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -10,14 +10,14 @@ import android.util.Log;
|
||||
import java.util.Arrays;
|
||||
import java.util.ArrayList;
|
||||
|
||||
class SDLAudioManager {
|
||||
public class SDLAudioManager {
|
||||
protected static final String TAG = "SDLAudio";
|
||||
|
||||
protected static Context mContext;
|
||||
|
||||
private static AudioDeviceCallback mAudioDeviceCallback;
|
||||
|
||||
static void initialize() {
|
||||
public static void initialize() {
|
||||
mAudioDeviceCallback = null;
|
||||
|
||||
if(Build.VERSION.SDK_INT >= 24 /* Android 7.0 (N) */)
|
||||
@@ -26,25 +26,25 @@ class SDLAudioManager {
|
||||
@Override
|
||||
public void onAudioDevicesAdded(AudioDeviceInfo[] addedDevices) {
|
||||
for (AudioDeviceInfo deviceInfo : addedDevices) {
|
||||
nativeAddAudioDevice(deviceInfo.isSink(), deviceInfo.getProductName().toString(), deviceInfo.getId());
|
||||
addAudioDevice(deviceInfo.isSink(), deviceInfo.getProductName().toString(), deviceInfo.getId());
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onAudioDevicesRemoved(AudioDeviceInfo[] removedDevices) {
|
||||
for (AudioDeviceInfo deviceInfo : removedDevices) {
|
||||
nativeRemoveAudioDevice(deviceInfo.isSink(), deviceInfo.getId());
|
||||
removeAudioDevice(deviceInfo.isSink(), deviceInfo.getId());
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
static void setContext(Context context) {
|
||||
public static void setContext(Context context) {
|
||||
mContext = context;
|
||||
}
|
||||
|
||||
static void release(Context context) {
|
||||
public static void release(Context context) {
|
||||
// no-op atm
|
||||
}
|
||||
|
||||
@@ -74,7 +74,7 @@ class SDLAudioManager {
|
||||
return null;
|
||||
}
|
||||
|
||||
static void registerAudioDeviceCallback() {
|
||||
public static void registerAudioDeviceCallback() {
|
||||
if (Build.VERSION.SDK_INT >= 24 /* Android 7.0 (N) */) {
|
||||
AudioManager audioManager = (AudioManager) mContext.getSystemService(Context.AUDIO_SERVICE);
|
||||
// get an initial list now, before hotplug callbacks fire.
|
||||
@@ -82,16 +82,16 @@ class SDLAudioManager {
|
||||
if (dev.getType() == AudioDeviceInfo.TYPE_TELEPHONY) {
|
||||
continue; // Device cannot be opened
|
||||
}
|
||||
nativeAddAudioDevice(dev.isSink(), dev.getProductName().toString(), dev.getId());
|
||||
addAudioDevice(dev.isSink(), dev.getProductName().toString(), dev.getId());
|
||||
}
|
||||
for (AudioDeviceInfo dev : audioManager.getDevices(AudioManager.GET_DEVICES_INPUTS)) {
|
||||
nativeAddAudioDevice(dev.isSink(), dev.getProductName().toString(), dev.getId());
|
||||
addAudioDevice(dev.isSink(), dev.getProductName().toString(), dev.getId());
|
||||
}
|
||||
audioManager.registerAudioDeviceCallback(mAudioDeviceCallback, null);
|
||||
}
|
||||
}
|
||||
|
||||
static void unregisterAudioDeviceCallback() {
|
||||
public static void unregisterAudioDeviceCallback() {
|
||||
if (Build.VERSION.SDK_INT >= 24 /* Android 7.0 (N) */) {
|
||||
AudioManager audioManager = (AudioManager) mContext.getSystemService(Context.AUDIO_SERVICE);
|
||||
audioManager.unregisterAudioDeviceCallback(mAudioDeviceCallback);
|
||||
@@ -99,7 +99,7 @@ class SDLAudioManager {
|
||||
}
|
||||
|
||||
/** This method is called by SDL using JNI. */
|
||||
static void audioSetThreadPriority(boolean recording, int device_id) {
|
||||
public static void audioSetThreadPriority(boolean recording, int device_id) {
|
||||
try {
|
||||
|
||||
/* Set thread name */
|
||||
@@ -117,10 +117,10 @@ class SDLAudioManager {
|
||||
}
|
||||
}
|
||||
|
||||
static native int nativeSetupJNI();
|
||||
public static native int nativeSetupJNI();
|
||||
|
||||
static native void nativeRemoveAudioDevice(boolean recording, int deviceId);
|
||||
public static native void removeAudioDevice(boolean recording, int deviceId);
|
||||
|
||||
static native void nativeAddAudioDevice(boolean recording, String name, int deviceId);
|
||||
public static native void addAudioDevice(boolean recording, String name, int deviceId);
|
||||
|
||||
}
|
||||
|
@@ -20,20 +20,20 @@ import android.view.View;
|
||||
public class SDLControllerManager
|
||||
{
|
||||
|
||||
static native int nativeSetupJNI();
|
||||
public static native int nativeSetupJNI();
|
||||
|
||||
static native void nativeAddJoystick(int device_id, String name, String desc,
|
||||
public static native void nativeAddJoystick(int device_id, String name, String desc,
|
||||
int vendor_id, int product_id,
|
||||
int button_mask,
|
||||
int naxes, int axis_mask, int nhats, boolean can_rumble);
|
||||
static native void nativeRemoveJoystick(int device_id);
|
||||
static native void nativeAddHaptic(int device_id, String name);
|
||||
static native void nativeRemoveHaptic(int device_id);
|
||||
static public native boolean onNativePadDown(int device_id, int keycode);
|
||||
static public native boolean onNativePadUp(int device_id, int keycode);
|
||||
static native void onNativeJoy(int device_id, int axis,
|
||||
public static native void nativeRemoveJoystick(int device_id);
|
||||
public static native void nativeAddHaptic(int device_id, String name);
|
||||
public static native void nativeRemoveHaptic(int device_id);
|
||||
public static native boolean onNativePadDown(int device_id, int keycode);
|
||||
public static native boolean onNativePadUp(int device_id, int keycode);
|
||||
public static native void onNativeJoy(int device_id, int axis,
|
||||
float value);
|
||||
static native void onNativeHat(int device_id, int hat_id,
|
||||
public static native void onNativeHat(int device_id, int hat_id,
|
||||
int x, int y);
|
||||
|
||||
protected static SDLJoystickHandler mJoystickHandler;
|
||||
@@ -41,9 +41,13 @@ public class SDLControllerManager
|
||||
|
||||
private static final String TAG = "SDLControllerManager";
|
||||
|
||||
static void initialize() {
|
||||
public static void initialize() {
|
||||
if (mJoystickHandler == null) {
|
||||
mJoystickHandler = new SDLJoystickHandler();
|
||||
if (Build.VERSION.SDK_INT >= 19 /* Android 4.4 (KITKAT) */) {
|
||||
mJoystickHandler = new SDLJoystickHandler_API19();
|
||||
} else {
|
||||
mJoystickHandler = new SDLJoystickHandler_API16();
|
||||
}
|
||||
}
|
||||
|
||||
if (mHapticHandler == null) {
|
||||
@@ -58,48 +62,48 @@ public class SDLControllerManager
|
||||
}
|
||||
|
||||
// Joystick glue code, just a series of stubs that redirect to the SDLJoystickHandler instance
|
||||
static public boolean handleJoystickMotionEvent(MotionEvent event) {
|
||||
public static boolean handleJoystickMotionEvent(MotionEvent event) {
|
||||
return mJoystickHandler.handleMotionEvent(event);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
static void pollInputDevices() {
|
||||
public static void pollInputDevices() {
|
||||
mJoystickHandler.pollInputDevices();
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
static void pollHapticDevices() {
|
||||
public static void pollHapticDevices() {
|
||||
mHapticHandler.pollHapticDevices();
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
static void hapticRun(int device_id, float intensity, int length) {
|
||||
public static void hapticRun(int device_id, float intensity, int length) {
|
||||
mHapticHandler.run(device_id, intensity, length);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
static void hapticRumble(int device_id, float low_frequency_intensity, float high_frequency_intensity, int length) {
|
||||
public static void hapticRumble(int device_id, float low_frequency_intensity, float high_frequency_intensity, int length) {
|
||||
mHapticHandler.rumble(device_id, low_frequency_intensity, high_frequency_intensity, length);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method is called by SDL using JNI.
|
||||
*/
|
||||
static void hapticStop(int device_id)
|
||||
public static void hapticStop(int device_id)
|
||||
{
|
||||
mHapticHandler.stop(device_id);
|
||||
}
|
||||
|
||||
// Check if a given device is considered a possible SDL joystick
|
||||
static public boolean isDeviceSDLJoystick(int deviceId) {
|
||||
public static boolean isDeviceSDLJoystick(int deviceId) {
|
||||
InputDevice device = InputDevice.getDevice(deviceId);
|
||||
// We cannot use InputDevice.isVirtual before API 16, so let's accept
|
||||
// only nonnegative device ids (VIRTUAL_KEYBOARD equals -1)
|
||||
@@ -129,16 +133,33 @@ public class SDLControllerManager
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* Actual joystick functionality available for API >= 19 devices */
|
||||
class SDLJoystickHandler {
|
||||
|
||||
/**
|
||||
* Handles given MotionEvent.
|
||||
* @param event the event to be handled.
|
||||
* @return if given event was processed.
|
||||
*/
|
||||
public boolean handleMotionEvent(MotionEvent event) {
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handles adding and removing of input devices.
|
||||
*/
|
||||
public void pollInputDevices() {
|
||||
}
|
||||
}
|
||||
|
||||
/* Actual joystick functionality available for API >= 12 devices */
|
||||
class SDLJoystickHandler_API16 extends SDLJoystickHandler {
|
||||
|
||||
static class SDLJoystick {
|
||||
int device_id;
|
||||
String name;
|
||||
String desc;
|
||||
ArrayList<InputDevice.MotionRange> axes;
|
||||
ArrayList<InputDevice.MotionRange> hats;
|
||||
public int device_id;
|
||||
public String name;
|
||||
public String desc;
|
||||
public ArrayList<InputDevice.MotionRange> axes;
|
||||
public ArrayList<InputDevice.MotionRange> hats;
|
||||
}
|
||||
static class RangeComparator implements Comparator<InputDevice.MotionRange> {
|
||||
@Override
|
||||
@@ -189,15 +210,13 @@ class SDLJoystickHandler {
|
||||
|
||||
private final ArrayList<SDLJoystick> mJoysticks;
|
||||
|
||||
SDLJoystickHandler() {
|
||||
public SDLJoystickHandler_API16() {
|
||||
|
||||
mJoysticks = new ArrayList<SDLJoystick>();
|
||||
}
|
||||
|
||||
/**
|
||||
* Handles adding and removing of input devices.
|
||||
*/
|
||||
void pollInputDevices() {
|
||||
@Override
|
||||
public void pollInputDevices() {
|
||||
int[] deviceIds = InputDevice.getDeviceIds();
|
||||
|
||||
for (int device_id : deviceIds) {
|
||||
@@ -279,12 +298,8 @@ class SDLJoystickHandler {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handles given MotionEvent.
|
||||
* @param event the event to be handled.
|
||||
* @return if given event was processed.
|
||||
*/
|
||||
boolean handleMotionEvent(MotionEvent event) {
|
||||
@Override
|
||||
public boolean handleMotionEvent(MotionEvent event) {
|
||||
int actionPointerIndex = event.getActionIndex();
|
||||
int action = event.getActionMasked();
|
||||
if (action == MotionEvent.ACTION_MOVE) {
|
||||
@@ -306,7 +321,7 @@ class SDLJoystickHandler {
|
||||
return true;
|
||||
}
|
||||
|
||||
String getJoystickDescriptor(InputDevice joystickDevice) {
|
||||
public String getJoystickDescriptor(InputDevice joystickDevice) {
|
||||
String desc = joystickDevice.getDescriptor();
|
||||
|
||||
if (desc != null && !desc.isEmpty()) {
|
||||
@@ -315,16 +330,34 @@ class SDLJoystickHandler {
|
||||
|
||||
return joystickDevice.getName();
|
||||
}
|
||||
public int getProductId(InputDevice joystickDevice) {
|
||||
return 0;
|
||||
}
|
||||
public int getVendorId(InputDevice joystickDevice) {
|
||||
return 0;
|
||||
}
|
||||
public int getAxisMask(List<InputDevice.MotionRange> ranges) {
|
||||
return -1;
|
||||
}
|
||||
public int getButtonMask(InputDevice joystickDevice) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
int getProductId(InputDevice joystickDevice) {
|
||||
class SDLJoystickHandler_API19 extends SDLJoystickHandler_API16 {
|
||||
|
||||
@Override
|
||||
public int getProductId(InputDevice joystickDevice) {
|
||||
return joystickDevice.getProductId();
|
||||
}
|
||||
|
||||
int getVendorId(InputDevice joystickDevice) {
|
||||
@Override
|
||||
public int getVendorId(InputDevice joystickDevice) {
|
||||
return joystickDevice.getVendorId();
|
||||
}
|
||||
|
||||
int getAxisMask(List<InputDevice.MotionRange> ranges) {
|
||||
@Override
|
||||
public int getAxisMask(List<InputDevice.MotionRange> ranges) {
|
||||
// For compatibility, keep computing the axis mask like before,
|
||||
// only really distinguishing 2, 4 and 6 axes.
|
||||
int axis_mask = 0;
|
||||
@@ -360,7 +393,8 @@ class SDLJoystickHandler {
|
||||
return axis_mask;
|
||||
}
|
||||
|
||||
int getButtonMask(InputDevice joystickDevice) {
|
||||
@Override
|
||||
public int getButtonMask(InputDevice joystickDevice) {
|
||||
int button_mask = 0;
|
||||
int[] keys = new int[] {
|
||||
KeyEvent.KEYCODE_BUTTON_A,
|
||||
@@ -457,7 +491,7 @@ class SDLJoystickHandler {
|
||||
|
||||
class SDLHapticHandler_API31 extends SDLHapticHandler {
|
||||
@Override
|
||||
void run(int device_id, float intensity, int length) {
|
||||
public void run(int device_id, float intensity, int length) {
|
||||
SDLHaptic haptic = getHaptic(device_id);
|
||||
if (haptic != null) {
|
||||
vibrate(haptic.vib, intensity, length);
|
||||
@@ -465,7 +499,7 @@ class SDLHapticHandler_API31 extends SDLHapticHandler {
|
||||
}
|
||||
|
||||
@Override
|
||||
void rumble(int device_id, float low_frequency_intensity, float high_frequency_intensity, int length) {
|
||||
public void rumble(int device_id, float low_frequency_intensity, float high_frequency_intensity, int length) {
|
||||
InputDevice device = InputDevice.getDevice(device_id);
|
||||
if (device == null) {
|
||||
return;
|
||||
@@ -509,7 +543,7 @@ class SDLHapticHandler_API31 extends SDLHapticHandler {
|
||||
|
||||
class SDLHapticHandler_API26 extends SDLHapticHandler {
|
||||
@Override
|
||||
void run(int device_id, float intensity, int length) {
|
||||
public void run(int device_id, float intensity, int length) {
|
||||
SDLHaptic haptic = getHaptic(device_id);
|
||||
if (haptic != null) {
|
||||
if (intensity == 0.0f) {
|
||||
@@ -541,36 +575,36 @@ class SDLHapticHandler_API26 extends SDLHapticHandler {
|
||||
class SDLHapticHandler {
|
||||
|
||||
static class SDLHaptic {
|
||||
int device_id;
|
||||
String name;
|
||||
Vibrator vib;
|
||||
public int device_id;
|
||||
public String name;
|
||||
public Vibrator vib;
|
||||
}
|
||||
|
||||
private final ArrayList<SDLHaptic> mHaptics;
|
||||
|
||||
SDLHapticHandler() {
|
||||
public SDLHapticHandler() {
|
||||
mHaptics = new ArrayList<SDLHaptic>();
|
||||
}
|
||||
|
||||
void run(int device_id, float intensity, int length) {
|
||||
public void run(int device_id, float intensity, int length) {
|
||||
SDLHaptic haptic = getHaptic(device_id);
|
||||
if (haptic != null) {
|
||||
haptic.vib.vibrate(length);
|
||||
}
|
||||
}
|
||||
|
||||
void rumble(int device_id, float low_frequency_intensity, float high_frequency_intensity, int length) {
|
||||
public void rumble(int device_id, float low_frequency_intensity, float high_frequency_intensity, int length) {
|
||||
// Not supported in older APIs
|
||||
}
|
||||
|
||||
void stop(int device_id) {
|
||||
public void stop(int device_id) {
|
||||
SDLHaptic haptic = getHaptic(device_id);
|
||||
if (haptic != null) {
|
||||
haptic.vib.cancel();
|
||||
}
|
||||
}
|
||||
|
||||
void pollHapticDevices() {
|
||||
public void pollHapticDevices() {
|
||||
|
||||
final int deviceId_VIBRATOR_SERVICE = 999999;
|
||||
boolean hasVibratorService = false;
|
||||
@@ -690,31 +724,31 @@ class SDLGenericMotionListener_API14 implements View.OnGenericMotionListener {
|
||||
return consumed;
|
||||
}
|
||||
|
||||
boolean supportsRelativeMouse() {
|
||||
public boolean supportsRelativeMouse() {
|
||||
return false;
|
||||
}
|
||||
|
||||
boolean inRelativeMode() {
|
||||
public boolean inRelativeMode() {
|
||||
return false;
|
||||
}
|
||||
|
||||
boolean setRelativeMouseEnabled(boolean enabled) {
|
||||
public boolean setRelativeMouseEnabled(boolean enabled) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void reclaimRelativeMouseModeIfNeeded() {
|
||||
public void reclaimRelativeMouseModeIfNeeded() {
|
||||
|
||||
}
|
||||
|
||||
boolean checkRelativeEvent(MotionEvent event) {
|
||||
public boolean checkRelativeEvent(MotionEvent event) {
|
||||
return inRelativeMode();
|
||||
}
|
||||
|
||||
float getEventX(MotionEvent event, int pointerIndex) {
|
||||
public float getEventX(MotionEvent event, int pointerIndex) {
|
||||
return event.getX(pointerIndex);
|
||||
}
|
||||
|
||||
float getEventY(MotionEvent event, int pointerIndex) {
|
||||
public float getEventY(MotionEvent event, int pointerIndex) {
|
||||
return event.getY(pointerIndex);
|
||||
}
|
||||
|
||||
@@ -726,23 +760,23 @@ class SDLGenericMotionListener_API24 extends SDLGenericMotionListener_API14 {
|
||||
private boolean mRelativeModeEnabled;
|
||||
|
||||
@Override
|
||||
boolean supportsRelativeMouse() {
|
||||
public boolean supportsRelativeMouse() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean inRelativeMode() {
|
||||
public boolean inRelativeMode() {
|
||||
return mRelativeModeEnabled;
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean setRelativeMouseEnabled(boolean enabled) {
|
||||
public boolean setRelativeMouseEnabled(boolean enabled) {
|
||||
mRelativeModeEnabled = enabled;
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
float getEventX(MotionEvent event, int pointerIndex) {
|
||||
public float getEventX(MotionEvent event, int pointerIndex) {
|
||||
if (mRelativeModeEnabled && event.getToolType(pointerIndex) == MotionEvent.TOOL_TYPE_MOUSE) {
|
||||
return event.getAxisValue(MotionEvent.AXIS_RELATIVE_X, pointerIndex);
|
||||
} else {
|
||||
@@ -751,7 +785,7 @@ class SDLGenericMotionListener_API24 extends SDLGenericMotionListener_API14 {
|
||||
}
|
||||
|
||||
@Override
|
||||
float getEventY(MotionEvent event, int pointerIndex) {
|
||||
public float getEventY(MotionEvent event, int pointerIndex) {
|
||||
if (mRelativeModeEnabled && event.getToolType(pointerIndex) == MotionEvent.TOOL_TYPE_MOUSE) {
|
||||
return event.getAxisValue(MotionEvent.AXIS_RELATIVE_Y, pointerIndex);
|
||||
} else {
|
||||
@@ -765,17 +799,17 @@ class SDLGenericMotionListener_API26 extends SDLGenericMotionListener_API24 {
|
||||
private boolean mRelativeModeEnabled;
|
||||
|
||||
@Override
|
||||
boolean supportsRelativeMouse() {
|
||||
public boolean supportsRelativeMouse() {
|
||||
return (!SDLActivity.isDeXMode() || Build.VERSION.SDK_INT >= 27 /* Android 8.1 (O_MR1) */);
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean inRelativeMode() {
|
||||
public boolean inRelativeMode() {
|
||||
return mRelativeModeEnabled;
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean setRelativeMouseEnabled(boolean enabled) {
|
||||
public boolean setRelativeMouseEnabled(boolean enabled) {
|
||||
if (!SDLActivity.isDeXMode() || Build.VERSION.SDK_INT >= 27 /* Android 8.1 (O_MR1) */) {
|
||||
if (enabled) {
|
||||
SDLActivity.getContentView().requestPointerCapture();
|
||||
@@ -790,25 +824,25 @@ class SDLGenericMotionListener_API26 extends SDLGenericMotionListener_API24 {
|
||||
}
|
||||
|
||||
@Override
|
||||
void reclaimRelativeMouseModeIfNeeded() {
|
||||
public void reclaimRelativeMouseModeIfNeeded() {
|
||||
if (mRelativeModeEnabled && !SDLActivity.isDeXMode()) {
|
||||
SDLActivity.getContentView().requestPointerCapture();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
boolean checkRelativeEvent(MotionEvent event) {
|
||||
public boolean checkRelativeEvent(MotionEvent event) {
|
||||
return event.getSource() == InputDevice.SOURCE_MOUSE_RELATIVE;
|
||||
}
|
||||
|
||||
@Override
|
||||
float getEventX(MotionEvent event, int pointerIndex) {
|
||||
public float getEventX(MotionEvent event, int pointerIndex) {
|
||||
// Relative mouse in capture mode will only have relative for X/Y
|
||||
return event.getX(pointerIndex);
|
||||
}
|
||||
|
||||
@Override
|
||||
float getEventY(MotionEvent event, int pointerIndex) {
|
||||
public float getEventY(MotionEvent event, int pointerIndex) {
|
||||
// Relative mouse in capture mode will only have relative for X/Y
|
||||
return event.getY(pointerIndex);
|
||||
}
|
||||
|
@@ -14,14 +14,14 @@ public class SDLDummyEdit extends View implements View.OnKeyListener
|
||||
InputConnection ic;
|
||||
int input_type;
|
||||
|
||||
SDLDummyEdit(Context context) {
|
||||
public SDLDummyEdit(Context context) {
|
||||
super(context);
|
||||
setFocusableInTouchMode(true);
|
||||
setFocusable(true);
|
||||
setOnKeyListener(this);
|
||||
}
|
||||
|
||||
void setInputType(int input_type) {
|
||||
public void setInputType(int input_type) {
|
||||
this.input_type = input_type;
|
||||
}
|
||||
|
||||
|
@@ -7,12 +7,12 @@ import android.view.*;
|
||||
import android.view.inputmethod.BaseInputConnection;
|
||||
import android.widget.EditText;
|
||||
|
||||
class SDLInputConnection extends BaseInputConnection
|
||||
public class SDLInputConnection extends BaseInputConnection
|
||||
{
|
||||
protected EditText mEditText;
|
||||
protected String mCommittedText = "";
|
||||
|
||||
SDLInputConnection(View targetView, boolean fullEditor) {
|
||||
public SDLInputConnection(View targetView, boolean fullEditor) {
|
||||
super(targetView, fullEditor);
|
||||
mEditText = new EditText(SDL.getContext());
|
||||
}
|
||||
|
@@ -40,10 +40,10 @@ public class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
|
||||
protected float mWidth, mHeight;
|
||||
|
||||
// Is SurfaceView ready for rendering
|
||||
protected boolean mIsSurfaceReady;
|
||||
public boolean mIsSurfaceReady;
|
||||
|
||||
// Startup
|
||||
protected SDLSurface(Context context) {
|
||||
public SDLSurface(Context context) {
|
||||
super(context);
|
||||
getHolder().addCallback(this);
|
||||
|
||||
@@ -66,11 +66,11 @@ public class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
|
||||
mIsSurfaceReady = false;
|
||||
}
|
||||
|
||||
protected void handlePause() {
|
||||
public void handlePause() {
|
||||
enableSensor(Sensor.TYPE_ACCELEROMETER, false);
|
||||
}
|
||||
|
||||
protected void handleResume() {
|
||||
public void handleResume() {
|
||||
setFocusable(true);
|
||||
setFocusableInTouchMode(true);
|
||||
requestFocus();
|
||||
@@ -80,7 +80,7 @@ public class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
|
||||
enableSensor(Sensor.TYPE_ACCELEROMETER, true);
|
||||
}
|
||||
|
||||
protected Surface getNativeSurface() {
|
||||
public Surface getNativeSurface() {
|
||||
return getHolder().getSurface();
|
||||
}
|
||||
|
||||
@@ -121,12 +121,14 @@ public class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
|
||||
float density = 1.0f;
|
||||
try
|
||||
{
|
||||
if (Build.VERSION.SDK_INT >= 17 /* Android 4.2 (JELLY_BEAN_MR1) */) {
|
||||
DisplayMetrics realMetrics = new DisplayMetrics();
|
||||
mDisplay.getRealMetrics( realMetrics );
|
||||
nDeviceWidth = realMetrics.widthPixels;
|
||||
nDeviceHeight = realMetrics.heightPixels;
|
||||
// Use densityDpi instead of density to more closely match what the UI scale is
|
||||
density = (float)realMetrics.densityDpi / 160.0f;
|
||||
}
|
||||
} catch(Exception ignored) {
|
||||
}
|
||||
|
||||
@@ -297,7 +299,7 @@ public class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
|
||||
}
|
||||
|
||||
// Sensor events
|
||||
protected void enableSensor(int sensortype, boolean enabled) {
|
||||
public void enableSensor(int sensortype, boolean enabled) {
|
||||
// TODO: This uses getDefaultSensor - what if we have >1 accels?
|
||||
if (enabled) {
|
||||
mSensorManager.registerListener(this,
|
||||
@@ -361,7 +363,6 @@ public class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
|
||||
}
|
||||
|
||||
// Captured pointer events for API 26.
|
||||
@Override
|
||||
public boolean onCapturedPointerEvent(MotionEvent event)
|
||||
{
|
||||
int action = event.getActionMasked();
|
||||
|
@@ -116,7 +116,7 @@ expression e;
|
||||
@@
|
||||
- SDL_JoystickGetDevicePlayerIndex(e)
|
||||
+ /* FIXME MIGRATION: check for valid instance */
|
||||
+ SDL_GetJoystickPlayerIndexForID(GetJoystickInstanceFromIndex(e))
|
||||
+ SDL_GetJoystickInstancePlayerIndex(GetJoystickInstanceFromIndex(e))
|
||||
|
||||
@@
|
||||
expression e;
|
||||
@@ -130,7 +130,7 @@ expression e;
|
||||
@@
|
||||
- SDL_JoystickPathForIndex(e)
|
||||
+ /* FIXME MIGRATION: check for valid instance */
|
||||
+ SDL_GetJoystickPathForID(GetJoystickInstanceFromIndex(e))
|
||||
+ SDL_GetJoystickInstancePath(GetJoystickInstanceFromIndex(e))
|
||||
|
||||
@@
|
||||
expression e;
|
||||
@@ -144,28 +144,28 @@ expression e;
|
||||
@@
|
||||
- SDL_GameControllerMappingForDeviceIndex(e)
|
||||
+ /* FIXME MIGRATION: check for valid instance */
|
||||
+ SDL_GetGamepadMappingForID(GetJoystickInstanceFromIndex(e))
|
||||
+ SDL_GetGamepadInstanceMapping(GetJoystickInstanceFromIndex(e))
|
||||
|
||||
@@
|
||||
expression e;
|
||||
@@
|
||||
- SDL_GameControllerNameForIndex(e)
|
||||
+ /* FIXME MIGRATION: check for valid instance */
|
||||
+ SDL_GetGamepadNameForID(GetJoystickInstanceFromIndex(e))
|
||||
+ SDL_GetGamepadInstanceName(GetJoystickInstanceFromIndex(e))
|
||||
|
||||
@@
|
||||
expression e;
|
||||
@@
|
||||
- SDL_GameControllerPathForIndex(e)
|
||||
+ /* FIXME MIGRATION: check for valid instance */
|
||||
+ SDL_GetGamepadPathForID(GetJoystickInstanceFromIndex(e))
|
||||
+ SDL_GetGamepadInstancePath(GetJoystickInstanceFromIndex(e))
|
||||
|
||||
@@
|
||||
expression e;
|
||||
@@
|
||||
- SDL_GameControllerTypeForIndex(e)
|
||||
+ /* FIXME MIGRATION: check for valid instance */
|
||||
+ SDL_GetGamepadTypeForID(GetJoystickInstanceFromIndex(e))
|
||||
+ SDL_GetGamepadInstanceType(GetJoystickInstanceFromIndex(e))
|
||||
|
||||
|
||||
// SDL_Has3DNow() has been removed; there is no replacement.
|
||||
|
@@ -542,7 +542,6 @@ class AndroidApiVersion:
|
||||
def __repr__(self) -> str:
|
||||
return f"<{self.name} ({'.'.join(str(v) for v in self.ints)})>"
|
||||
|
||||
ANDROID_ABI_EXTRA_LINK_OPTIONS = {}
|
||||
|
||||
class Releaser:
|
||||
def __init__(self, release_info: dict, commit: str, revision: str, root: Path, dist_path: Path, section_printer: SectionPrinter, executer: Executer, cmake_generator: str, deps_path: Path, overwrite: bool, github: bool, fast: bool):
|
||||
@@ -1014,7 +1013,6 @@ class Releaser:
|
||||
android_devel_file_tree = ArchiveFileTree()
|
||||
|
||||
for android_abi in android_abis:
|
||||
extra_link_options = ANDROID_ABI_EXTRA_LINK_OPTIONS.get(android_abi, "")
|
||||
with self.section_printer.group(f"Building for Android {android_api} {android_abi}"):
|
||||
build_dir = self.root / "build-android" / f"{android_abi}-build"
|
||||
install_dir = self.root / "install-android" / f"{android_abi}-install"
|
||||
@@ -1025,11 +1023,8 @@ class Releaser:
|
||||
"cmake",
|
||||
"-S", str(self.root),
|
||||
"-B", str(build_dir),
|
||||
# NDK 21e does not support -ffile-prefix-map
|
||||
# f'''-DCMAKE_C_FLAGS="-ffile-prefix-map={self.root}=/src/{self.project}"''',
|
||||
# f'''-DCMAKE_CXX_FLAGS="-ffile-prefix-map={self.root}=/src/{self.project}"''',
|
||||
f"-DCMAKE_EXE_LINKER_FLAGS={extra_link_options}",
|
||||
f"-DCMAKE_SHARED_LINKER_FLAGS={extra_link_options}",
|
||||
f'''-DCMAKE_C_FLAGS="-ffile-prefix-map={self.root}=/src/{self.project}"''',
|
||||
f'''-DCMAKE_CXX_FLAGS="-ffile-prefix-map={self.root}=/src/{self.project}"''',
|
||||
f"-DCMAKE_TOOLCHAIN_FILE={cmake_toolchain_file}",
|
||||
f"-DCMAKE_PREFIX_PATH={str(android_deps_path)}",
|
||||
f"-DCMAKE_FIND_ROOT_PATH_MODE_PACKAGE=BOTH",
|
||||
@@ -1535,7 +1530,7 @@ def main(argv=None) -> int:
|
||||
parser.error("Invalid --android-api, and/or could not be detected")
|
||||
android_api_path = Path(args.android_home) / f"platforms/{args.android_api.name}"
|
||||
if not android_api_path.is_dir():
|
||||
logger.warning(f"Android API directory does not exist ({android_api_path})")
|
||||
parser.error(f"Android API directory does not exist ({android_api_path})")
|
||||
with section_printer.group("Android arguments"):
|
||||
print(f"android_home = {args.android_home}")
|
||||
print(f"android_ndk_home = {args.android_ndk_home}")
|
||||
|
@@ -1,127 +0,0 @@
|
||||
#!/bin/bash
|
||||
progname="${0##*/}"
|
||||
progname="${progname%.sh}"
|
||||
|
||||
# usage: check_elf_alignment.sh [path to *.so files|path to *.apk]
|
||||
|
||||
cleanup_trap() {
|
||||
if [ -n "${tmp}" -a -d "${tmp}" ]; then
|
||||
rm -rf ${tmp}
|
||||
fi
|
||||
exit $1
|
||||
}
|
||||
|
||||
usage() {
|
||||
echo "Host side script to check the ELF alignment of shared libraries."
|
||||
echo "Shared libraries are reported ALIGNED when their ELF regions are"
|
||||
echo "16 KB or 64 KB aligned. Otherwise they are reported as UNALIGNED."
|
||||
echo
|
||||
echo "Usage: ${progname} [input-path|input-APK|input-APEX]"
|
||||
}
|
||||
|
||||
if [ ${#} -ne 1 ]; then
|
||||
usage
|
||||
exit
|
||||
fi
|
||||
|
||||
case ${1} in
|
||||
--help | -h | -\?)
|
||||
usage
|
||||
exit
|
||||
;;
|
||||
|
||||
*)
|
||||
dir="${1}"
|
||||
;;
|
||||
esac
|
||||
|
||||
if ! [ -f "${dir}" -o -d "${dir}" ]; then
|
||||
echo "Invalid file: ${dir}" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ "${dir}" == *.apk ]]; then
|
||||
trap 'cleanup_trap' EXIT
|
||||
|
||||
echo
|
||||
echo "Recursively analyzing $dir"
|
||||
echo
|
||||
|
||||
if { zipalign --help 2>&1 | grep -q "\-P <pagesize_kb>"; }; then
|
||||
echo "=== APK zip-alignment ==="
|
||||
zipalign -v -c -P 16 4 "${dir}" | egrep 'lib/arm64-v8a|lib/x86_64|Verification'
|
||||
echo "========================="
|
||||
else
|
||||
echo "NOTICE: Zip alignment check requires build-tools version 35.0.0-rc3 or higher."
|
||||
echo " You can install the latest build-tools by running the below command"
|
||||
echo " and updating your \$PATH:"
|
||||
echo
|
||||
echo " sdkmanager \"build-tools;35.0.0-rc3\""
|
||||
fi
|
||||
|
||||
dir_filename=$(basename "${dir}")
|
||||
tmp=$(mktemp -d -t "${dir_filename%.apk}_out_XXXXX")
|
||||
unzip "${dir}" lib/* -d "${tmp}" >/dev/null 2>&1
|
||||
dir="${tmp}"
|
||||
fi
|
||||
|
||||
if [[ "${dir}" == *.apex ]]; then
|
||||
trap 'cleanup_trap' EXIT
|
||||
|
||||
echo
|
||||
echo "Recursively analyzing $dir"
|
||||
echo
|
||||
|
||||
dir_filename=$(basename "${dir}")
|
||||
tmp=$(mktemp -d -t "${dir_filename%.apex}_out_XXXXX")
|
||||
deapexer extract "${dir}" "${tmp}" || { echo "Failed to deapex." && exit 1; }
|
||||
dir="${tmp}"
|
||||
fi
|
||||
|
||||
RED="\e[31m"
|
||||
GREEN="\e[32m"
|
||||
ENDCOLOR="\e[0m"
|
||||
|
||||
unaligned_libs=()
|
||||
unaligned_critical_libs=()
|
||||
|
||||
echo
|
||||
echo "=== ELF alignment ==="
|
||||
|
||||
matches="$(find "${dir}" -type f)"
|
||||
IFS=$'\n'
|
||||
for match in $matches; do
|
||||
# We could recursively call this script or rewrite it to though.
|
||||
[[ "${match}" == *".apk" ]] && echo "WARNING: doesn't recursively inspect .apk file: ${match}"
|
||||
[[ "${match}" == *".apex" ]] && echo "WARNING: doesn't recursively inspect .apex file: ${match}"
|
||||
|
||||
[[ $(file "${match}") == *"ELF"* ]] || continue
|
||||
|
||||
res="$(objdump -p "${match}" | grep LOAD | awk '{ print $NF }' | head -1)"
|
||||
if [[ $res =~ 2\*\*(1[4-9]|[2-9][0-9]|[1-9][0-9]{2,}) ]]; then
|
||||
echo -e "${match}: ${GREEN}ALIGNED${ENDCOLOR} ($res)"
|
||||
else
|
||||
unaligned_libs+=("${match}")
|
||||
# Check if this is a critical architecture (arm64-v8a or x86_64)
|
||||
if [[ "${match}" == *"arm64-v8a"* ]] || [[ "${match}" == *"x86_64"* ]]; then
|
||||
unaligned_critical_libs+=("${match}")
|
||||
echo -e "${match}: ${RED}UNALIGNED${ENDCOLOR} ($res)"
|
||||
else
|
||||
echo -e "${match}: UNALIGNED ($res)"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
if [ ${#unaligned_libs[@]} -gt 0 ]; then
|
||||
echo -e "Found ${#unaligned_libs[@]} unaligned libs (only arm64-v8a/x86_64 libs need to be aligned).${ENDCOLOR}"
|
||||
fi
|
||||
echo "====================="
|
||||
|
||||
# Exit with appropriate code: 1 if critical unaligned libs found, 0 otherwise
|
||||
if [ ${#unaligned_critical_libs[@]} -gt 0 ]; then
|
||||
echo -e "${RED}Found ${#unaligned_critical_libs[@]} critical unaligned libs.${ENDCOLOR}"
|
||||
exit 1
|
||||
else
|
||||
echo -e "${GREEN}ELF Verification Successful${ENDCOLOR}"
|
||||
exit 0
|
||||
fi
|
@@ -183,7 +183,7 @@
|
||||
],
|
||||
"api-minimum": 21,
|
||||
"api-target": 35,
|
||||
"ndk-minimum": 28,
|
||||
"ndk-minimum": 21,
|
||||
"aar-files": {
|
||||
"": [
|
||||
"android-project/app/proguard-rules.pro:proguard.txt",
|
||||
|
21
build-scripts/strip_fPIC.sh
Executable file
21
build-scripts/strip_fPIC.sh
Executable file
@@ -0,0 +1,21 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# libtool assumes that the compiler can handle the -fPIC flag
|
||||
# This isn't always true (for example, nasm can't handle it)
|
||||
command=""
|
||||
while [ $# -gt 0 ]; do
|
||||
case "$1" in
|
||||
-?PIC)
|
||||
# Ignore -fPIC and -DPIC options
|
||||
;;
|
||||
-fno-common)
|
||||
# Ignore -fPIC and -DPIC options
|
||||
;;
|
||||
*)
|
||||
command="$command $1"
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
echo $command
|
||||
exec $command
|
@@ -32,7 +32,6 @@ my $wikisubdir = '';
|
||||
my $incsubdir = 'include';
|
||||
my $readmesubdir = undef;
|
||||
my $apiprefixregex = undef;
|
||||
my $apipropertyregex = undef;
|
||||
my $versionfname = 'include/SDL_version.h';
|
||||
my $versionmajorregex = '\A\#define\s+SDL_MAJOR_VERSION\s+(\d+)\Z';
|
||||
my $versionminorregex = '\A\#define\s+SDL_MINOR_VERSION\s+(\d+)\Z';
|
||||
@@ -44,6 +43,7 @@ my $wikiurl = 'https://wiki.libsdl.org';
|
||||
my $bugreporturl = 'https://github.com/libsdl-org/sdlwiki/issues/new';
|
||||
my $srcpath = undef;
|
||||
my $wikipath = undef;
|
||||
my $wikireadmesubdir = 'README';
|
||||
my $warn_about_missing = 0;
|
||||
my $copy_direction = 0;
|
||||
my $optionsfname = undef;
|
||||
@@ -58,11 +58,6 @@ my $quickreftitle = undef;
|
||||
my $quickrefurl = undef;
|
||||
my $quickrefdesc = undef;
|
||||
my $quickrefmacroregex = undef;
|
||||
my $envvarenabled = 0;
|
||||
my $envvartitle = 'Environment Variables';
|
||||
my $envvardesc = undef;
|
||||
my $envvarsymregex = undef;
|
||||
my $envvarsymreplace = undef;
|
||||
my $changeformat = undef;
|
||||
my $manpath = undef;
|
||||
my $gitrev = undef;
|
||||
@@ -116,7 +111,6 @@ if (defined $optionsfname) {
|
||||
$srcpath = $val, next if $key eq 'srcpath';
|
||||
$wikipath = $val, next if $key eq 'wikipath';
|
||||
$apiprefixregex = $val, next if $key eq 'apiprefixregex';
|
||||
$apipropertyregex = $val, next if $key eq 'apipropertyregex';
|
||||
$projectfullname = $val, next if $key eq 'projectfullname';
|
||||
$projectshortname = $val, next if $key eq 'projectshortname';
|
||||
$wikisubdir = $val, next if $key eq 'wikisubdir';
|
||||
@@ -142,11 +136,6 @@ if (defined $optionsfname) {
|
||||
$quickrefurl = $val, next if $key eq 'quickrefurl';
|
||||
$quickrefdesc = $val, next if $key eq 'quickrefdesc';
|
||||
$quickrefmacroregex = $val, next if $key eq 'quickrefmacroregex';
|
||||
$envvarenabled = int($val), next if $key eq 'envvarenabled';
|
||||
$envvartitle = $val, next if $key eq 'envvartitle';
|
||||
$envvardesc = $val, next if $key eq 'envvardesc';
|
||||
$envvarsymregex = $val, next if $key eq 'envvarsymregex';
|
||||
$envvarsymreplace = $val, next if $key eq 'envvarsymreplace';
|
||||
}
|
||||
}
|
||||
close(OPTIONS);
|
||||
@@ -353,7 +342,7 @@ sub wikify_chunk {
|
||||
|
||||
# Convert obvious API things to wikilinks.
|
||||
if (defined $apiprefixregex) {
|
||||
$str =~ s/(\A|[^\/a-zA-Z0-9_\[])($apiprefixregex[a-zA-Z0-9_]+)/$1\[$2\]\($2\)/gms;
|
||||
$str =~ s/(\A|[^\/a-zA-Z0-9_])($apiprefixregex[a-zA-Z0-9_]+)/$1\[$2\]\($2\)/gms;
|
||||
}
|
||||
|
||||
$str = $codedstr . $str;
|
||||
@@ -436,7 +425,6 @@ sub dewikify_chunk {
|
||||
}
|
||||
} elsif ($dewikify_mode eq 'manpage') {
|
||||
# make sure these can't become part of roff syntax.
|
||||
$str =~ s/\\/\\(rs/gms;
|
||||
$str =~ s/\./\\[char46]/gms;
|
||||
$str =~ s/"/\\(dq/gms;
|
||||
$str =~ s/'/\\(aq/gms;
|
||||
@@ -838,23 +826,21 @@ sub print_big_ascii_string {
|
||||
die("Don't have a big ascii entry for '$ch'!\n") if not defined $rowsref;
|
||||
my $row = @$rowsref[$rownum];
|
||||
|
||||
my $outstr = '';
|
||||
if ($lowascii) {
|
||||
my @x = split //, $row;
|
||||
foreach (@x) {
|
||||
$outstr .= ($_ eq "\x{2588}") ? 'X' : ' ';
|
||||
my $v = ($_ eq "\x{2588}") ? 'X' : ' ';
|
||||
print $fh $v;
|
||||
}
|
||||
} else {
|
||||
$outstr = $row;
|
||||
print $fh $row;
|
||||
}
|
||||
|
||||
$charidx++;
|
||||
if ($charidx == $charcount) {
|
||||
$outstr =~ s/\s*\Z//; # dump extra spaces at the end of the line.
|
||||
} else {
|
||||
$outstr .= ' '; # space between glyphs.
|
||||
|
||||
if ($charidx < $charcount) {
|
||||
print $fh " ";
|
||||
}
|
||||
print $fh $outstr;
|
||||
}
|
||||
print $fh "\n";
|
||||
}
|
||||
@@ -1045,58 +1031,10 @@ sub generate_quickref {
|
||||
}
|
||||
|
||||
|
||||
sub generate_envvar_wiki_page {
|
||||
my $briefsref = shift;
|
||||
my $path = shift;
|
||||
|
||||
return if not $envvarenabled or not defined $envvarsymregex or not defined $envvarsymreplace;
|
||||
|
||||
my $replace = "\"$envvarsymreplace\"";
|
||||
my $tmppath = "$path.tmp";
|
||||
open(my $fh, '>', $tmppath) or die("Can't open '$tmppath': $!\n");
|
||||
|
||||
print $fh "<!-- DO NOT EDIT THIS PAGE ON THE WIKI. IT WILL BE OVERWRITTEN BY WIKIHEADERS AND CHANGES WILL BE LOST! -->\n\n";
|
||||
print $fh "# $envvartitle\n\n";
|
||||
|
||||
if (defined $envvardesc) {
|
||||
my $desc = "$envvardesc";
|
||||
$desc =~ s/\\n/\n/g; # replace "\n" strings with actual newlines.
|
||||
print $fh "$desc\n\n";
|
||||
}
|
||||
|
||||
print $fh "## Environment Variable List\n\n";
|
||||
|
||||
foreach (sort keys %headersyms) {
|
||||
my $sym = $_;
|
||||
next if $headersymstype{$sym} != 2; # not a #define? skip it.
|
||||
my $hint = "$_";
|
||||
next if not $hint =~ s/$envvarsymregex/$replace/ee;
|
||||
|
||||
my $brief = $$briefsref{$sym};
|
||||
if (not defined $brief) {
|
||||
$brief = '';
|
||||
} else {
|
||||
$brief = "$brief";
|
||||
chomp($brief);
|
||||
my $thiswikitype = defined $wikitypes{$sym} ? $wikitypes{$sym} : 'md'; # default to MarkDown for new stuff.
|
||||
$brief = ": " . dewikify($thiswikitype, $brief);
|
||||
}
|
||||
print $fh "- [$hint]($sym)$brief\n";
|
||||
}
|
||||
|
||||
print $fh "\n";
|
||||
|
||||
close($fh);
|
||||
|
||||
rename($tmppath, $path) or die("Can't rename '$tmppath' to '$path': $!\n");
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
my $incpath = "$srcpath";
|
||||
$incpath .= "/$incsubdir" if $incsubdir ne '';
|
||||
|
||||
my $wikireadmepath = "$wikipath/$wikireadmesubdir";
|
||||
my $readmepath = undef;
|
||||
if (defined $readmesubdir) {
|
||||
$readmepath = "$srcpath/$readmesubdir";
|
||||
@@ -1428,7 +1366,7 @@ while (my $d = readdir(DH)) {
|
||||
# update strings now that we know everything pending is to be applied to this declaration. Add pending blank lines and the new text.
|
||||
|
||||
# At Sam's request, don't list property defines with functions. (See #9440)
|
||||
my $is_property = (defined $apipropertyregex) ? /$apipropertyregex/ : 0;
|
||||
my $is_property = /\A\s*\#\s*define\s+SDL_PROP_/;
|
||||
if (!$is_property) {
|
||||
if ($blank_lines > 0) {
|
||||
while ($blank_lines > 0) {
|
||||
@@ -2145,16 +2083,19 @@ if ($copy_direction == 1) { # --copy-to-headers
|
||||
}
|
||||
|
||||
if (defined $readmepath) {
|
||||
if ( -d $wikireadmepath ) {
|
||||
mkdir($readmepath); # just in case
|
||||
opendir(DH, $wikipath) or die("Can't opendir '$wikipath': $!\n");
|
||||
opendir(DH, $wikireadmepath) or die("Can't opendir '$wikireadmepath': $!\n");
|
||||
while (readdir(DH)) {
|
||||
my $dent = $_;
|
||||
if ($dent =~ /\AREADME\-.*?\.md\Z/) { # we only bridge Markdown files here that start with "README-".
|
||||
filecopy("$wikipath/$dent", "$readmepath/$dent", "\n");
|
||||
if ($dent =~ /\A(.*?)\.md\Z/) { # we only bridge Markdown files here.
|
||||
next if $1 eq 'FrontPage';
|
||||
filecopy("$wikireadmepath/$dent", "$readmepath/README-$dent", "\n");
|
||||
}
|
||||
}
|
||||
closedir(DH);
|
||||
}
|
||||
}
|
||||
|
||||
} elsif ($copy_direction == -1) { # --copy-to-wiki
|
||||
|
||||
@@ -2758,27 +2699,31 @@ __EOF__
|
||||
# Write out READMEs...
|
||||
if (defined $readmepath) {
|
||||
if ( -d $readmepath ) {
|
||||
mkdir($wikipath); # just in case
|
||||
mkdir($wikireadmepath); # just in case
|
||||
opendir(DH, $readmepath) or die("Can't opendir '$readmepath': $!\n");
|
||||
while (my $d = readdir(DH)) {
|
||||
my $dent = $d;
|
||||
if ($dent =~ /\AREADME\-.*?\.md\Z/) { # we only bridge Markdown files here that start with "README-".
|
||||
filecopy("$readmepath/$dent", "$wikipath/$dent", "\n");
|
||||
if ($dent =~ /\AREADME\-(.*?\.md)\Z/) { # we only bridge Markdown files here.
|
||||
my $wikifname = $1;
|
||||
next if $wikifname eq 'FrontPage.md';
|
||||
filecopy("$readmepath/$dent", "$wikireadmepath/$wikifname", "\n");
|
||||
}
|
||||
}
|
||||
closedir(DH);
|
||||
|
||||
my @pages = ();
|
||||
opendir(DH, $wikipath) or die("Can't opendir '$wikipath': $!\n");
|
||||
opendir(DH, $wikireadmepath) or die("Can't opendir '$wikireadmepath': $!\n");
|
||||
while (my $d = readdir(DH)) {
|
||||
my $dent = $d;
|
||||
if ($dent =~ /\A(README\-.*?)\.md\Z/) {
|
||||
push @pages, $1;
|
||||
if ($dent =~ /\A(.*?)\.(mediawiki|md)\Z/) {
|
||||
my $wikiname = $1;
|
||||
next if $wikiname eq 'FrontPage';
|
||||
push @pages, $wikiname;
|
||||
}
|
||||
}
|
||||
closedir(DH);
|
||||
|
||||
open(FH, '>', "$wikipath/READMEs.md") or die("Can't open '$wikipath/READMEs.md': $!\n");
|
||||
open(FH, '>', "$wikireadmepath/FrontPage.md") or die("Can't open '$wikireadmepath/FrontPage.md': $!\n");
|
||||
print FH "# All READMEs available here\n\n";
|
||||
foreach (sort @pages) {
|
||||
my $wikiname = $_;
|
||||
@@ -2793,11 +2738,6 @@ __EOF__
|
||||
generate_quickref(\%briefs, "$wikipath/QuickReference.md", 0);
|
||||
generate_quickref(\%briefs, "$wikipath/QuickReferenceNoUnicode.md", 1);
|
||||
}
|
||||
|
||||
if ($envvarenabled and defined $envvarsymregex and defined $envvarsymreplace) {
|
||||
generate_envvar_wiki_page(\%briefs, "$wikipath/EnvironmentVariables.md");
|
||||
}
|
||||
|
||||
} elsif ($copy_direction == -2) { # --copy-to-manpages
|
||||
# This only takes from the wiki data, since it has sections we omit from the headers, like code examples.
|
||||
|
||||
@@ -3041,12 +2981,10 @@ __EOF__
|
||||
}
|
||||
|
||||
if (defined $returns) {
|
||||
# Check for md link in return type: ([SDL_Renderer](SDL_Renderer) *)
|
||||
# This would've prevented the next regex from working properly (it'd leave " *)")
|
||||
$returns =~ s/\A\(\[.*?\]\((.*?)\)/\($1/ms;
|
||||
# Chop datatype in parentheses off the front.
|
||||
$returns =~ s/\A\(.*?\) //;
|
||||
|
||||
if(!($returns =~ s/\A\([^\[]*\[[^\]]*\]\([^\)]*\)[^\)]*\) //ms)) {
|
||||
$returns =~ s/\A\([^\)]*\) //ms;
|
||||
}
|
||||
$returns = dewikify($wikitype, $returns);
|
||||
$str .= ".SH RETURN VALUE\n";
|
||||
$str .= "$returns\n";
|
||||
|
@@ -1,189 +0,0 @@
|
||||
if(NGAGESDK)
|
||||
function(SDL_Preseed_CMakeCache)
|
||||
set(COMPILER_SUPPORTS_ARMNEON "" CACHE INTERNAL "Test COMPILER_SUPPORTS_ARMNEON")
|
||||
set(COMPILER_SUPPORTS_FDIAGNOSTICS_COLOR_ALWAYS "" CACHE INTERNAL "Test COMPILER_SUPPORTS_FDIAGNOSTICS_COLOR_ALWAYS")
|
||||
set(COMPILER_SUPPORTS_SYNC_LOCK_TEST_AND_SET "" CACHE INTERNAL "Test COMPILER_SUPPORTS_SYNC_LOCK_TEST_AND_SET")
|
||||
set(HAVE_CLANG_COMMENT_BLOCK_COMMANDS "" CACHE INTERNAL "Test HAVE_CLANG_COMMENT_BLOCK_COMMANDS")
|
||||
set(HAVE_ALLOCA_H "" CACHE INTERNAL "Have include alloca.h")
|
||||
set(HAVE_LIBM "1" CACHE INTERNAL "Have library m")
|
||||
set(HAVE_POSIX_SPAWN "" CACHE INTERNAL "Have symbol posix_spawn")
|
||||
set(HAVE_MALLOC "1" CACHE INTERNAL "Have include malloc.h")
|
||||
set(LIBC_HAS_ABS "1" CACHE INTERNAL "Have symbol abs")
|
||||
set(LIBC_HAS_ACOS "1" CACHE INTERNAL "Have symbol acos")
|
||||
set(LIBC_HAS_ACOSF "" CACHE INTERNAL "Have symbol acosf")
|
||||
set(LIBC_HAS_ASIN "1" CACHE INTERNAL "Have symbol asin")
|
||||
set(LIBC_HAS_ASINF "" CACHE INTERNAL "Have symbol asinf")
|
||||
set(LIBC_HAS_ATAN "1" CACHE INTERNAL "Have symbol atan")
|
||||
set(LIBC_HAS_ATAN2 "1" CACHE INTERNAL "Have symbol atan2")
|
||||
set(LIBC_HAS_ATAN2F "" CACHE INTERNAL "Have symbol atan2f")
|
||||
set(LIBC_HAS_ATANF "" CACHE INTERNAL "Have symbol atanf")
|
||||
set(LIBC_HAS_ATOF "" CACHE INTERNAL "Have symbol atof")
|
||||
set(LIBC_HAS_ATOI "" CACHE INTERNAL "Have symbol atoi")
|
||||
set(LIBC_HAS_BCOPY "1" CACHE INTERNAL "Have symbol bcopy")
|
||||
set(LIBC_HAS_CALLOC "" CACHE INTERNAL "Have symbol calloc")
|
||||
set(LIBC_HAS_CEIL "1" CACHE INTERNAL "Have symbol ceil")
|
||||
set(LIBC_HAS_CEILF "" CACHE INTERNAL "Have symbol ceilf")
|
||||
set(LIBC_HAS_COPYSIGN "1" CACHE INTERNAL "Have symbol copysign")
|
||||
set(LIBC_HAS_COPYSIGNF "1" CACHE INTERNAL "Have symbol copysignf")
|
||||
set(LIBC_HAS_COS "1" CACHE INTERNAL "Have symbol cos")
|
||||
set(LIBC_HAS_COSF "" CACHE INTERNAL "Have symbol cosf")
|
||||
set(LIBC_HAS_EXP "1" CACHE INTERNAL "Have symbol exp")
|
||||
set(LIBC_HAS_EXPF "" CACHE INTERNAL "Have symbol expf")
|
||||
set(LIBC_HAS_FABS "1" CACHE INTERNAL "Have symbol fabs")
|
||||
set(LIBC_HAS_FABSF "1" CACHE INTERNAL "Have symbol fabsf")
|
||||
set(LIBC_HAS_FLOAT_H "1" CACHE INTERNAL "Have include float.h")
|
||||
set(LIBC_HAS_FLOOR "1" CACHE INTERNAL "Have symbol floor")
|
||||
set(LIBC_HAS_FLOORF "" CACHE INTERNAL "Have symbol floorf")
|
||||
set(LIBC_HAS_FMOD "" CACHE INTERNAL "Have symbol fmod")
|
||||
set(LIBC_HAS_FMODF "" CACHE INTERNAL "Have symbol fmodf")
|
||||
set(LIBC_HAS_FOPEN64 "" CACHE INTERNAL "Have symbol fopen64")
|
||||
set(LIBC_HAS_FREE "1" CACHE INTERNAL "Have symbol free")
|
||||
set(LIBC_HAS_FSEEKO "" CACHE INTERNAL "Have symbol fseeko")
|
||||
set(LIBC_HAS_FSEEKO64 "" CACHE INTERNAL "Have symbol fseeko64")
|
||||
set(LIBC_HAS_GETENV "" CACHE INTERNAL "Have symbol getenv")
|
||||
set(LIBC_HAS_ICONV_H "" CACHE INTERNAL "Have include iconv.h")
|
||||
set(LIBC_HAS_INDEX "1" CACHE INTERNAL "Have symbol index")
|
||||
set(LIBC_HAS_INTTYPES_H "1" CACHE INTERNAL "Have include inttypes.h")
|
||||
set(LIBC_HAS_ISINF "1" CACHE INTERNAL "Have include isinf(double)")
|
||||
set(LIBC_ISINF_HANDLES_FLOAT "1" CACHE INTERNAL "Have include isinf(float)")
|
||||
set(LIBC_HAS_ISINFF "1" CACHE INTERNAL "Have include isinff(float)")
|
||||
set(LIBC_HAS_ISNAN "1" CACHE INTERNAL "Have include isnan(double)")
|
||||
set(LIBC_ISNAN_HANDLES_FLOAT "1" CACHE INTERNAL "Have include isnan(float)")
|
||||
set(LIBC_HAS_ISNANF "1" CACHE INTERNAL "Have include isnanf(float)")
|
||||
set(LIBC_HAS_ITOA "" CACHE INTERNAL "Have symbol itoa")
|
||||
set(LIBC_HAS_LIMITS_H "1" CACHE INTERNAL "Have include limits.h")
|
||||
set(LIBC_HAS_LOG "1" CACHE INTERNAL "Have symbol log")
|
||||
set(LIBC_HAS_LOG10 "" CACHE INTERNAL "Have symbol log10")
|
||||
set(LIBC_HAS_LOG10F "" CACHE INTERNAL "Have symbol log10f")
|
||||
set(LIBC_HAS_LOGF "" CACHE INTERNAL "Have symbol logf")
|
||||
set(LIBC_HAS_LROUND "" CACHE INTERNAL "Have symbol lround")
|
||||
set(LIBC_HAS_LROUNDF "" CACHE INTERNAL "Have symbol lroundf")
|
||||
set(LIBC_HAS_MALLOC "1" CACHE INTERNAL "Have symbol malloc")
|
||||
set(LIBC_HAS_MALLOC_H "" CACHE INTERNAL "Have include malloc.h")
|
||||
set(LIBC_HAS_MATH_H "1" CACHE INTERNAL "Have include math.h")
|
||||
set(LIBC_HAS_MEMCMP "1" CACHE INTERNAL "Have symbol memcmp")
|
||||
set(LIBC_HAS_MEMCPY "" CACHE INTERNAL "Have symbol memcpy")
|
||||
set(LIBC_HAS_MEMMOVE "" CACHE INTERNAL "Have symbol memmove")
|
||||
set(LIBC_HAS_MEMORY_H "" CACHE INTERNAL "Have include memory.h")
|
||||
set(LIBC_HAS_MEMSET "" CACHE INTERNAL "Have symbol memset")
|
||||
set(LIBC_HAS_MODF "1" CACHE INTERNAL "Have symbol modf")
|
||||
set(LIBC_HAS_MODFF "" CACHE INTERNAL "Have symbol modff")
|
||||
set(LIBC_HAS_POW "1" CACHE INTERNAL "Have symbol pow")
|
||||
set(LIBC_HAS_POWF "" CACHE INTERNAL "Have symbol powf")
|
||||
set(LIBC_HAS_PUTENV "" CACHE INTERNAL "Have symbol putenv")
|
||||
set(LIBC_HAS_REALLOC "" CACHE INTERNAL "Have symbol realloc")
|
||||
set(LIBC_HAS_RINDEX "1" CACHE INTERNAL "Have symbol rindex")
|
||||
set(LIBC_HAS_ROUND "" CACHE INTERNAL "Have symbol round")
|
||||
set(LIBC_HAS_ROUNDF "" CACHE INTERNAL "Have symbol roundf")
|
||||
set(LIBC_HAS_SCALBN "1" CACHE INTERNAL "Have symbol scalbn")
|
||||
set(LIBC_HAS_SCALBNF "" CACHE INTERNAL "Have symbol scalbnf")
|
||||
set(LIBC_HAS_SETENV "" CACHE INTERNAL "Have symbol setenv")
|
||||
set(LIBC_HAS_SIGNAL_H "" CACHE INTERNAL "Have include signal.h")
|
||||
set(LIBC_HAS_SIN "1" CACHE INTERNAL "Have symbol sin")
|
||||
set(LIBC_HAS_SINF "" CACHE INTERNAL "Have symbol sinf")
|
||||
set(LIBC_HAS_SQR "" CACHE INTERNAL "Have symbol sqr")
|
||||
set(LIBC_HAS_SQRT "1" CACHE INTERNAL "Have symbol sqrt")
|
||||
set(LIBC_HAS_SQRTF "" CACHE INTERNAL "Have symbol sqrtf")
|
||||
set(LIBC_HAS_SSCANF "1" CACHE INTERNAL "Have symbol sscanf")
|
||||
set(LIBC_HAS_STDARG_H "1" CACHE INTERNAL "Have include stdarg.h")
|
||||
set(LIBC_HAS_STDBOOL_H "1" CACHE INTERNAL "Have include stdbool.h")
|
||||
set(LIBC_HAS_STDDEF_H "1" CACHE INTERNAL "Have include stddef.h")
|
||||
set(LIBC_HAS_STDINT_H "1" CACHE INTERNAL "Have include stdint.h")
|
||||
set(LIBC_HAS_STDIO_H "1" CACHE INTERNAL "Have include stdio.h")
|
||||
set(LIBC_HAS_STDLIB_H "1" CACHE INTERNAL "Have include stdlib.h")
|
||||
set(LIBC_HAS_STRCASESTR "" CACHE INTERNAL "Have symbol strcasestr")
|
||||
set(LIBC_HAS_STRCHR "1" CACHE INTERNAL "Have symbol strchr")
|
||||
set(LIBC_HAS_STRCMP "1" CACHE INTERNAL "Have symbol strcmp")
|
||||
set(LIBC_HAS_STRINGS_H "" CACHE INTERNAL "Have include strings.h")
|
||||
set(LIBC_HAS_STRING_H "1" CACHE INTERNAL "Have include string.h")
|
||||
set(LIBC_HAS_STRLCAT "" CACHE INTERNAL "Have symbol strlcat")
|
||||
set(LIBC_HAS_STRLCPY "" CACHE INTERNAL "Have symbol strlcpy")
|
||||
set(LIBC_HAS_STRLEN "1" CACHE INTERNAL "Have symbol strlen")
|
||||
set(LIBC_HAS_STRNCMP "1" CACHE INTERNAL "Have symbol strncmp")
|
||||
set(LIBC_HAS_STRNLEN "" CACHE INTERNAL "Have symbol strnlen")
|
||||
set(LIBC_HAS_STRNSTR "" CACHE INTERNAL "Have symbol strnstr")
|
||||
set(LIBC_HAS_STRPBRK "1" CACHE INTERNAL "Have symbol strpbrk")
|
||||
set(LIBC_HAS_STRRCHR "1" CACHE INTERNAL "Have symbol strrchr")
|
||||
set(LIBC_HAS_STRSTR "1" CACHE INTERNAL "Have symbol strstr")
|
||||
set(LIBC_HAS_STRTOD "" CACHE INTERNAL "Have symbol strtod")
|
||||
set(LIBC_HAS_STRTOK_R "" CACHE INTERNAL "Have symbol strtok_r")
|
||||
set(LIBC_HAS_STRTOL "" CACHE INTERNAL "Have symbol strtol")
|
||||
set(LIBC_HAS_STRTOLL "" CACHE INTERNAL "Have symbol strtoll")
|
||||
set(LIBC_HAS_STRTOUL "" CACHE INTERNAL "Have symbol strtoul")
|
||||
set(LIBC_HAS_STRTOULL "" CACHE INTERNAL "Have symbol strtoull")
|
||||
set(LIBC_HAS_SYS_TYPES_H "1" CACHE INTERNAL "Have include sys/types.h")
|
||||
set(LIBC_HAS_TAN "1" CACHE INTERNAL "Have symbol tan")
|
||||
set(LIBC_HAS_TANF "" CACHE INTERNAL "Have symbol tanf")
|
||||
set(LIBC_HAS_TIME_H "1" CACHE INTERNAL "Have include time.h")
|
||||
set(LIBC_HAS_TRUNC "" CACHE INTERNAL "Have symbol trunc")
|
||||
set(LIBC_HAS_TRUNCF "" CACHE INTERNAL "Have symbol truncf")
|
||||
set(LIBC_HAS_UNSETENV "" CACHE INTERNAL "Have symbol unsetenv")
|
||||
set(LIBC_HAS_VSNPRINTF "" CACHE INTERNAL "Have symbol vsnprintf")
|
||||
set(LIBC_HAS_VSSCANF "" CACHE INTERNAL "Have symbol vsscanf")
|
||||
set(LIBC_HAS_WCHAR_H "1" CACHE INTERNAL "Have include wchar.h")
|
||||
set(LIBC_HAS_WCSCMP "" CACHE INTERNAL "Have symbol wcscmp")
|
||||
set(LIBC_HAS_WCSDUP "" CACHE INTERNAL "Have symbol wcsdup")
|
||||
set(LIBC_HAS_WCSLCAT "" CACHE INTERNAL "Have symbol wcslcat")
|
||||
set(LIBC_HAS_WCSLCPY "" CACHE INTERNAL "Have symbol wcslcpy")
|
||||
set(LIBC_HAS_WCSLEN "" CACHE INTERNAL "Have symbol wcslen")
|
||||
set(LIBC_HAS_WCSNCMP "" CACHE INTERNAL "Have symbol wcsncmp")
|
||||
set(LIBC_HAS_WCSNLEN "" CACHE INTERNAL "Have symbol wcsnlen")
|
||||
set(LIBC_HAS_WCSSTR "" CACHE INTERNAL "Have symbol wcsstr")
|
||||
set(LIBC_HAS_WCSTOL "" CACHE INTERNAL "Have symbol wcstol")
|
||||
set(LIBC_HAS__EXIT "" CACHE INTERNAL "Have symbol _Exit")
|
||||
set(LIBC_HAS__I64TOA "" CACHE INTERNAL "Have symbol _i64toa")
|
||||
set(LIBC_HAS__LTOA "" CACHE INTERNAL "Have symbol _ltoa")
|
||||
set(LIBC_HAS__STRREV "" CACHE INTERNAL "Have symbol _strrev")
|
||||
set(LIBC_HAS__UI64TOA "" CACHE INTERNAL "Have symbol _ui64toa")
|
||||
set(LIBC_HAS__UITOA "" CACHE INTERNAL "Have symbol _uitoa")
|
||||
set(LIBC_HAS__ULTOA "" CACHE INTERNAL "Have symbol _ultoa")
|
||||
set(LIBC_HAS__WCSDUP "" CACHE INTERNAL "Have symbol _wcsdup")
|
||||
set(LIBC_IS_GLIBC "" CACHE INTERNAL "Have symbol __GLIBC__")
|
||||
set(_ALLOCA_IN_MALLOC_H "" CACHE INTERNAL "Have symbol _alloca")
|
||||
set(HAVE_GCC_WALL "1" CACHE INTERNAL "Test HAVE_GCC_WALL")
|
||||
set(HAVE_GCC_WUNDEF "1" CACHE INTERNAL "Test HAVE_GCC_WUNDEF")
|
||||
set(HAVE_GCC_WFLOAT_CONVERSION "" CACHE INTERNAL "Test HAVE_GCC_WFLOAT_CONVERSION")
|
||||
set(HAVE_GCC_NO_STRICT_ALIASING "1" CACHE INTERNAL "Test HAVE_GCC_NO_STRICT_ALIASING")
|
||||
set(HAVE_GCC_WDOCUMENTATION "" CACHE INTERNAL "Test HAVE_GCC_WDOCUMENTATION")
|
||||
set(HAVE_GCC_WDOCUMENTATION_UNKNOWN_COMMAND "" CACHE INTERNAL "Test HAVE_GCC_WDOCUMENTATION_UNKNOWN_COMMAND")
|
||||
set(HAVE_GCC_COMMENT_BLOCK_COMMANDS "" CACHE INTERNAL "Test HAVE_GCC_COMMENT_BLOCK_COMMANDS")
|
||||
set(HAVE_GCC_WSHADOW "1" CACHE INTERNAL "Test HAVE_GCC_WSHADOW")
|
||||
set(HAVE_GCC_WUNUSED_LOCAL_TYPEDEFS "" CACHE INTERNAL "Test HAVE_GCC_WUNUSED_LOCAL_TYPEDEFS")
|
||||
set(HAVE_GCC_WIMPLICIT_FALLTHROUGH "" CACHE INTERNAL "Test HAVE_GCC_WIMPLICIT_FALLTHROUGH")
|
||||
set(HAVE_GCC_FVISIBILITY "" CACHE INTERNAL "Test HAVE_GCC_FVISIBILITY")
|
||||
set(HAVE_ST_MTIM "" CACHE INTERNAL "Test HAVE_ST_MTIM")
|
||||
#set(HAVE_O_CLOEXEC "" CACHE INTERNAL "Test HAVE_O_CLOEXEC")
|
||||
#set(COMPILER_SUPPORTS_FDIAGNOSTICS_COLOR "" CACHE INTERNAL "Test COMPILER_SUPPORTS_FDIAGNOSTICS_COLOR")
|
||||
set(COMPILER_SUPPORTS_GCC_ATOMICS "" CACHE INTERNAL "Test COMPILER_SUPPORTS_GCC_ATOMICS")
|
||||
set(LINKER_SUPPORTS_VERSION_SCRIPT "" CACHE INTERNAL "Test LINKER_SUPPORTS_VERSION_SCRIPT")
|
||||
set(LINKER_SUPPORTS_WL_NO_UNDEFINED "" CACHE INTERNAL "Test LINKER_SUPPORTS_WL_NO_UNDEFINED")
|
||||
set(ICONV_IN_LIBC "" CACHE INTERNAL "Test ICONV_IN_LIBC")
|
||||
set(ICONV_IN_LIBICONV "" CACHE INTERNAL "Test ICONV_IN_LIBICONV")
|
||||
#set(LIBC_HAS_WORKING_LIBUNWIND "" CACHE INTERNAL "Test LIBC_HAS_WORKING_LIBUNWIND")
|
||||
#set(LIBUNWIND_HAS_WORKINGLIBUNWIND "" CACHE INTERNAL "Test LIBUNWIND_HAS_WORKINGLIBUNWIND")
|
||||
set(HAVE_GETPAGESIZE "" CACHE INTERNAL "Have symbol getpagesize")
|
||||
set(HAVE_SIGACTION "" CACHE INTERNAL "Have symbol sigaction")
|
||||
set(HAVE_SA_SIGACTION "" CACHE INTERNAL "Have symbol sa_sigaction")
|
||||
set(HAVE_SETJMP "" CACHE INTERNAL "Have symbol setjmp")
|
||||
set(HAVE_NANOSLEEP "" CACHE INTERNAL "Have symbol nanosleep")
|
||||
set(HAVE_GMTIME_R "" CACHE INTERNAL "Have symbol gmtime_r")
|
||||
set(HAVE_LOCALTIME_R "" CACHE INTERNAL "Have symbol localtime_r")
|
||||
set(HAVE_NL_LANGINFO "" CACHE INTERNAL "Have symbol nl_langinfo")
|
||||
set(HAVE_SYSCONF "" CACHE INTERNAL "Have symbol sysconf")
|
||||
set(HAVE_SYSCTLBYNAME "" CACHE INTERNAL "Have symbol sysctlbyname")
|
||||
set(HAVE_GETAUXVAL "" CACHE INTERNAL "Have symbol getauxval")
|
||||
set(HAVE_ELF_AUX_INFO "" CACHE INTERNAL "Have symbol elf_aux_info")
|
||||
set(HAVE_POLL "" CACHE INTERNAL "Have symbol poll")
|
||||
set(HAVE_MEMFD_CREATE "" CACHE INTERNAL "Have symbol memfd_create")
|
||||
set(HAVE_POSIX_FALLOCATE "" CACHE INTERNAL "Have symbol posix_fallocate")
|
||||
set(HAVE_DLOPEN_IN_LIBC "" CACHE INTERNAL "Have symbol dlopen")
|
||||
|
||||
set(HAVE_GETHOSTNAME "" CACHE INTERNAL "Have symbol gethostname")
|
||||
set(HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR "" CACHE INTERNAL "Have symbol addchdir")
|
||||
set(HAVE_POSIX_SPAWN_FILE_ACTIONS_ADDCHDIR_NP "" CACHE INTERNAL "Have symbol addchdir_np")
|
||||
set(HAVE_FDATASYNC "" CACHE INTERNAL "Have symbol fdatasync")
|
||||
|
||||
set(HAVE_SDL_FSOPS "1" CACHE INTERNAL "Enable SDL_FSOPS")
|
||||
set(HAVE_SDL_LOCALE "1" CACHE INTERNAL "Enable SDL_LOCALE")
|
||||
endfunction()
|
||||
endif()
|
@@ -362,6 +362,9 @@ function(SDL_PrintSummary)
|
||||
message(STATUS "")
|
||||
message(STATUS " Build Shared Library: ${SDL_SHARED}")
|
||||
message(STATUS " Build Static Library: ${SDL_STATIC}")
|
||||
if(SDL_STATIC)
|
||||
message(STATUS " Build Static Library with Position Independent Code: ${SDL_STATIC_PIC}")
|
||||
endif()
|
||||
if(APPLE)
|
||||
message(STATUS " Build libraries as Apple Framework: ${SDL_FRAMEWORK}")
|
||||
endif()
|
||||
|
@@ -1,10 +1,3 @@
|
||||
macro(check_c_source_compiles_static SOURCE VAR)
|
||||
set(saved_CMAKE_TRY_COMPILE_TARGET_TYPE "${CMAKE_TRY_COMPILE_TARGET_TYPE}")
|
||||
set(CMAKE_TRY_COMPILE_TARGET_TYPE "STATIC_LIBRARY")
|
||||
check_c_source_compiles("${SOURCE}" ${VAR} ${ARGN})
|
||||
set(CMAKE_TRY_COMPILE_TARGET_TYPE "${saved_CMAKE_TRY_COMPILE_TARGET_TYPE}")
|
||||
endmacro()
|
||||
|
||||
macro(FindLibraryAndSONAME _LIB)
|
||||
cmake_parse_arguments(_FLAS "" "" "LIBDIRS" ${ARGN})
|
||||
|
||||
@@ -281,11 +274,10 @@ macro(CheckX11)
|
||||
set(Xrandr_PKG_CONFIG_SPEC xrandr)
|
||||
set(Xrender_PKG_CONFIG_SPEC xrender)
|
||||
set(Xss_PKG_CONFIG_SPEC xscrnsaver)
|
||||
set(Xtst_PKG_CONFIG_SPEC xtst)
|
||||
|
||||
find_package(X11)
|
||||
|
||||
foreach(_LIB X11 Xext Xcursor Xi Xfixes Xrandr Xrender Xss Xtst)
|
||||
foreach(_LIB X11 Xext Xcursor Xi Xfixes Xrandr Xrender Xss)
|
||||
get_filename_component(_libdir "${X11_${_LIB}_LIB}" DIRECTORY)
|
||||
FindLibraryAndSONAME("${_LIB}" LIBDIRS ${_libdir})
|
||||
endforeach()
|
||||
@@ -318,7 +310,6 @@ macro(CheckX11)
|
||||
find_file(HAVE_XSYNC_H NAMES "X11/extensions/sync.h" HINTS "${X11_INCLUDEDIR}")
|
||||
find_file(HAVE_XSS_H NAMES "X11/extensions/scrnsaver.h" HINTS "${X11_INCLUDEDIR}")
|
||||
find_file(HAVE_XSHAPE_H NAMES "X11/extensions/shape.h" HINTS "${X11_INCLUDEDIR}")
|
||||
find_file(HAVE_XTEST_H NAMES "X11/extensions/XTest.h" HINTS "${X11_INCLUDEDIR}")
|
||||
find_file(HAVE_XDBE_H NAMES "X11/extensions/Xdbe.h" HINTS "${X11_INCLUDEDIR}")
|
||||
find_file(HAVE_XEXT_H NAMES "X11/extensions/Xext.h" HINTS "${X11_INCLUDEDIR}")
|
||||
|
||||
@@ -376,7 +367,7 @@ macro(CheckX11)
|
||||
|
||||
list(APPEND CMAKE_REQUIRED_LIBRARIES ${X11_LIB})
|
||||
|
||||
check_c_source_compiles_static("
|
||||
check_c_source_compiles("
|
||||
#include <X11/Xlib.h>
|
||||
int main(int argc, char **argv) {
|
||||
Display *display;
|
||||
@@ -390,7 +381,7 @@ macro(CheckX11)
|
||||
set(SDL_VIDEO_DRIVER_X11_SUPPORTS_GENERIC_EVENTS 1)
|
||||
endif()
|
||||
|
||||
check_include_file("X11/XKBlib.h" SDL_VIDEO_DRIVER_X11_HAS_XKBLIB)
|
||||
check_symbol_exists(XkbLookupKeySym "X11/Xlib.h;X11/XKBlib.h" SDL_VIDEO_DRIVER_X11_HAS_XKBLOOKUPKEYSYM)
|
||||
|
||||
if(SDL_X11_XCURSOR AND HAVE_XCURSOR_H AND XCURSOR_LIB)
|
||||
set(HAVE_X11_XCURSOR TRUE)
|
||||
@@ -416,19 +407,8 @@ macro(CheckX11)
|
||||
endif()
|
||||
set(SDL_VIDEO_DRIVER_X11_XINPUT2 1)
|
||||
|
||||
# Check for scroll info
|
||||
check_c_source_compiles("
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Xproto.h>
|
||||
#include <X11/extensions/XInput2.h>
|
||||
XIScrollClassInfo *s;
|
||||
int main(int argc, char **argv) {}" HAVE_XINPUT2_SCROLLINFO)
|
||||
if(HAVE_XINPUT2_SCROLLINFO)
|
||||
set(SDL_VIDEO_DRIVER_X11_XINPUT2_SUPPORTS_SCROLLINFO 1)
|
||||
endif()
|
||||
|
||||
# Check for multitouch
|
||||
check_c_source_compiles_static("
|
||||
check_c_source_compiles("
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Xproto.h>
|
||||
#include <X11/extensions/XInput2.h>
|
||||
@@ -445,7 +425,7 @@ macro(CheckX11)
|
||||
|
||||
# check along with XInput2.h because we use Xfixes with XIBarrierReleasePointer
|
||||
if(SDL_X11_XFIXES AND HAVE_XFIXES_H_ AND HAVE_XINPUT2_H)
|
||||
check_c_source_compiles_static("
|
||||
check_c_source_compiles("
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/Xproto.h>
|
||||
#include <X11/extensions/XInput2.h>
|
||||
@@ -492,16 +472,6 @@ macro(CheckX11)
|
||||
set(SDL_VIDEO_DRIVER_X11_XSHAPE 1)
|
||||
set(HAVE_X11_XSHAPE TRUE)
|
||||
endif()
|
||||
|
||||
if(SDL_X11_XTEST AND HAVE_XTEST_H AND XTST_LIB)
|
||||
if(HAVE_X11_SHARED)
|
||||
set(SDL_VIDEO_DRIVER_X11_DYNAMIC_XTEST "\"${XTST_LIB_SONAME}\"")
|
||||
else()
|
||||
sdl_link_dependency(xtst LIBS X11::Xtst CMAKE_MODULE X11 PKG_CONFIG_SPECS ${Xtst_PKG_CONFIG_SPEC})
|
||||
endif()
|
||||
set(SDL_VIDEO_DRIVER_X11_XTEST 1)
|
||||
set(HAVE_X11_XTEST TRUE)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
if(NOT HAVE_X11)
|
||||
@@ -605,18 +575,6 @@ macro(CheckWayland)
|
||||
sdl_link_dependency(wayland LIBS PkgConfig::PC_WAYLAND PKG_CONFIG_PREFIX PC_WAYLAND PKG_CONFIG_SPECS ${WAYLAND_PKG_CONFIG_SPEC})
|
||||
endif()
|
||||
|
||||
# xkbcommon doesn't provide internal version defines, so generate them here.
|
||||
if (PC_WAYLAND_xkbcommon_VERSION MATCHES "^([0-9]+)\\.([0-9]+)\\.([0-9]+)")
|
||||
set(SDL_XKBCOMMON_VERSION_MAJOR ${CMAKE_MATCH_1})
|
||||
set(SDL_XKBCOMMON_VERSION_MINOR ${CMAKE_MATCH_2})
|
||||
set(SDL_XKBCOMMON_VERSION_PATCH ${CMAKE_MATCH_3})
|
||||
else()
|
||||
message(WARNING "Failed to parse xkbcommon version; defaulting to lowest supported (0.5.0)")
|
||||
set(SDL_XKBCOMMON_VERSION_MAJOR 0)
|
||||
set(SDL_XKBCOMMON_VERSION_MINOR 5)
|
||||
set(SDL_XKBCOMMON_VERSION_PATCH 0)
|
||||
endif()
|
||||
|
||||
if(SDL_WAYLAND_LIBDECOR)
|
||||
set(LibDecor_PKG_CONFIG_SPEC libdecor-0)
|
||||
pkg_check_modules(PC_LIBDECOR IMPORTED_TARGET ${LibDecor_PKG_CONFIG_SPEC})
|
||||
@@ -837,7 +795,7 @@ endmacro()
|
||||
macro(CheckPTHREAD)
|
||||
cmake_push_check_state()
|
||||
if(SDL_PTHREADS)
|
||||
if(ANDROID OR SDL_PTHREADS_PRIVATE)
|
||||
if(ANDROID)
|
||||
# the android libc provides built-in support for pthreads, so no
|
||||
# additional linking or compile flags are necessary
|
||||
elseif(LINUX)
|
||||
@@ -884,9 +842,6 @@ macro(CheckPTHREAD)
|
||||
set(PTHREAD_LDFLAGS "-pthread")
|
||||
elseif(QNX)
|
||||
# pthread support is baked in
|
||||
elseif(HURD)
|
||||
set(PTHREAD_CFLAGS "-D_REENTRANT")
|
||||
set(PTHREAD_LDFLAGS "-pthread")
|
||||
else()
|
||||
set(PTHREAD_CFLAGS "-D_REENTRANT")
|
||||
set(PTHREAD_LDFLAGS "-lpthread")
|
||||
@@ -1122,14 +1077,6 @@ endmacro()
|
||||
|
||||
# Check for HIDAPI support
|
||||
macro(CheckHIDAPI)
|
||||
if(ANDROID)
|
||||
enable_language(CXX)
|
||||
sdl_sources("${SDL3_SOURCE_DIR}/src/hidapi/android/hid.cpp")
|
||||
endif()
|
||||
if(IOS OR TVOS)
|
||||
sdl_sources("${SDL3_SOURCE_DIR}/src/hidapi/ios/hid.m")
|
||||
set(SDL_FRAMEWORK_COREBLUETOOTH 1)
|
||||
endif()
|
||||
if(SDL_HIDAPI)
|
||||
set(HAVE_HIDAPI ON)
|
||||
if(SDL_HIDAPI_LIBUSB)
|
||||
@@ -1138,7 +1085,7 @@ macro(CheckHIDAPI)
|
||||
if(LibUSB_FOUND)
|
||||
cmake_push_check_state()
|
||||
list(APPEND CMAKE_REQUIRED_LIBRARIES LibUSB::LibUSB)
|
||||
check_c_source_compiles_static("
|
||||
check_c_source_compiles("
|
||||
#include <stddef.h>
|
||||
#include <libusb.h>
|
||||
int main(int argc, char **argv) {
|
||||
@@ -1162,6 +1109,14 @@ macro(CheckHIDAPI)
|
||||
endif()
|
||||
|
||||
if(HAVE_HIDAPI)
|
||||
if(ANDROID)
|
||||
enable_language(CXX)
|
||||
sdl_sources("${SDL3_SOURCE_DIR}/src/hidapi/android/hid.cpp")
|
||||
endif()
|
||||
if(IOS OR TVOS)
|
||||
sdl_sources("${SDL3_SOURCE_DIR}/src/hidapi/ios/hid.m")
|
||||
set(SDL_FRAMEWORK_COREBLUETOOTH 1)
|
||||
endif()
|
||||
set(HAVE_SDL_HIDAPI TRUE)
|
||||
|
||||
if(SDL_JOYSTICK AND SDL_HIDAPI_JOYSTICK)
|
||||
@@ -1169,7 +1124,6 @@ macro(CheckHIDAPI)
|
||||
set(HAVE_SDL_JOYSTICK TRUE)
|
||||
set(HAVE_HIDAPI_JOYSTICK TRUE)
|
||||
sdl_glob_sources("${SDL3_SOURCE_DIR}/src/joystick/hidapi/*.c")
|
||||
sdl_glob_sources("${SDL3_SOURCE_DIR}/src/haptic/hidapi/*.c")
|
||||
endif()
|
||||
else()
|
||||
set(SDL_HIDAPI_DISABLED 1)
|
||||
|
@@ -160,63 +160,3 @@ function(SDL_AddCommonCompilerFlags TARGET)
|
||||
endif()
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
function(check_x86_source_compiles BODY VAR)
|
||||
if(ARGN)
|
||||
message(FATAL_ERROR "Unknown arguments: ${ARGN}")
|
||||
endif()
|
||||
if(APPLE_MULTIARCH AND (SDL_CPU_X86 OR SDL_CPU_X64))
|
||||
set(test_conditional 1)
|
||||
else()
|
||||
set(test_conditional 0)
|
||||
endif()
|
||||
check_c_source_compiles("
|
||||
#if ${test_conditional}
|
||||
# if defined(__i386__) || defined(__x86_64__)
|
||||
# define test_enabled 1
|
||||
# else
|
||||
# define test_enabled 0 /* feign success in Apple multi-arch configs */
|
||||
# endif
|
||||
#else /* test normally */
|
||||
# define test_enabled 1
|
||||
#endif
|
||||
#if test_enabled
|
||||
${BODY}
|
||||
#else
|
||||
int main(int argc, char *argv[]) {
|
||||
(void)argc;
|
||||
(void)argv;
|
||||
return 0;
|
||||
}
|
||||
#endif" ${VAR})
|
||||
endfunction()
|
||||
|
||||
function(check_arm_source_compiles BODY VAR)
|
||||
if(ARGN)
|
||||
message(FATAL_ERROR "Unknown arguments: ${ARGN}")
|
||||
endif()
|
||||
if(APPLE_MULTIARCH AND (SDL_CPU_ARM32 OR SDL_CPU_ARM64))
|
||||
set(test_conditional 1)
|
||||
else()
|
||||
set(test_conditional 0)
|
||||
endif()
|
||||
check_c_source_compiles("
|
||||
#if ${test_conditional}
|
||||
# if defined(__arm__) || defined(__aarch64__)
|
||||
# define test_enabled 1
|
||||
# else
|
||||
# define test_enabled 0 /* feign success in Apple multi-arch configs */
|
||||
# endif
|
||||
#else /* test normally */
|
||||
# define test_enabled 1
|
||||
#endif
|
||||
#if test_enabled
|
||||
${BODY}
|
||||
#else
|
||||
int main(int argc, char *argv[]) {
|
||||
(void)argc;
|
||||
(void)argv;
|
||||
return 0;
|
||||
}
|
||||
#endif" ${VAR})
|
||||
endfunction()
|
||||
|
@@ -4,15 +4,15 @@ function(SDL_DetectTargetCPUArchitectures DETECTED_ARCHS)
|
||||
|
||||
if(APPLE AND CMAKE_OSX_ARCHITECTURES)
|
||||
foreach(known_arch IN LISTS known_archs)
|
||||
set(SDL_CPU_${known_arch} "0" PARENT_SCOPE)
|
||||
set(SDL_CPU_${known_arch} "0")
|
||||
endforeach()
|
||||
set(detected_archs)
|
||||
foreach(osx_arch IN LISTS CMAKE_OSX_ARCHITECTURES)
|
||||
if(osx_arch STREQUAL "x86_64")
|
||||
set(SDL_CPU_X64 "1" PARENT_SCOPE)
|
||||
set(SDL_CPU_X64 "1")
|
||||
list(APPEND detected_archs "X64")
|
||||
elseif(osx_arch STREQUAL "arm64")
|
||||
set(SDL_CPU_ARM64 "1" PARENT_SCOPE)
|
||||
set(SDL_CPU_ARM64 "1")
|
||||
list(APPEND detected_archs "ARM64")
|
||||
endif()
|
||||
endforeach()
|
||||
|
@@ -22,12 +22,8 @@ function(SDL_DetectCMakePlatform)
|
||||
set(sdl_cmake_platform Haiku)
|
||||
elseif(NINTENDO_3DS)
|
||||
set(sdl_cmake_platform n3ds)
|
||||
elseif(NGAGESDK)
|
||||
set(sdl_cmake_platform ngage)
|
||||
elseif(PS2)
|
||||
set(sdl_cmake_platform ps2)
|
||||
elseif(RISCOS)
|
||||
set(sdl_cmake_platform RISCOS)
|
||||
elseif(VITA)
|
||||
set(sdl_cmake_platform Vita)
|
||||
elseif(CMAKE_SYSTEM_NAME MATCHES ".*Linux")
|
||||
@@ -38,9 +34,8 @@ function(SDL_DetectCMakePlatform)
|
||||
set(sdl_cmake_platform NetBSD)
|
||||
elseif(CMAKE_SYSTEM_NAME MATCHES "kOpenBSD.*|OpenBSD.*")
|
||||
set(sdl_cmake_platform OpenBSD)
|
||||
elseif(CMAKE_SYSTEM_NAME STREQUAL "GNU")
|
||||
# GNU/Hurd must be checked AFTER RISCOS
|
||||
set(sdl_cmake_platform Hurd)
|
||||
elseif(CMAKE_SYSTEM_NAME MATCHES ".*GNU.*")
|
||||
set(sdl_cmake_platform GNU)
|
||||
elseif(CMAKE_SYSTEM_NAME MATCHES ".*BSDI.*")
|
||||
set(sdl_cmake_platform BSDi)
|
||||
elseif(CMAKE_SYSTEM_NAME MATCHES "DragonFly.*|FreeBSD")
|
||||
|
@@ -1,40 +1,18 @@
|
||||
add_library(SDL3-collector INTERFACE)
|
||||
add_library(SDL3_test-collector INTERFACE)
|
||||
|
||||
function(sdl_source_group prefix_directory)
|
||||
set(prefixed_list)
|
||||
file(TO_CMAKE_PATH ${prefix_directory} normalized_prefix_path)
|
||||
foreach(file in ${ARGN})
|
||||
file(TO_CMAKE_PATH ${file} normalized_path)
|
||||
string(FIND "${normalized_path}" ${normalized_prefix_path} position)
|
||||
if("${position}" EQUAL 0)
|
||||
list(APPEND prefixed_list ${file})
|
||||
endif()
|
||||
endforeach()
|
||||
if(prefixed_list)
|
||||
source_group(TREE ${prefix_directory} FILES ${prefixed_list})
|
||||
endif()
|
||||
endfunction()
|
||||
|
||||
# Use sdl_glob_sources to add glob sources to SDL3-shared, to SDL3-static, or to both.
|
||||
function(sdl_glob_sources)
|
||||
cmake_parse_arguments(ARGS "" "" "SHARED;STATIC" ${ARGN})
|
||||
if(ARGS_SHARED)
|
||||
file(GLOB shared_sources CONFIGURE_DEPENDS ${ARGS_SHARED})
|
||||
endif()
|
||||
if(ARGS_STATIC)
|
||||
file(GLOB static_sources CONFIGURE_DEPENDS ${ARGS_STATIC})
|
||||
endif()
|
||||
if(ARGS_UNPARSED_ARGUMENTS)
|
||||
file(GLOB both_sources CONFIGURE_DEPENDS ${ARGS_UNPARSED_ARGUMENTS})
|
||||
endif()
|
||||
file(GLOB shared_sources ${ARGS_SHARED})
|
||||
file(GLOB static_sources ${ARGS_STATIC})
|
||||
file(GLOB both_sources ${ARGS_UNPARSED_ARGUMENTS})
|
||||
if(TARGET SDL3-shared)
|
||||
target_sources(SDL3-shared PRIVATE ${shared_sources} ${both_sources})
|
||||
endif()
|
||||
if(TARGET SDL3-static)
|
||||
target_sources(SDL3-static PRIVATE ${static_sources} ${both_sources})
|
||||
endif()
|
||||
sdl_source_group(${PROJECT_SOURCE_DIR} ${shared_sources} ${shared_sources} ${both_sources})
|
||||
set_property(TARGET SDL3-collector APPEND PROPERTY INTERFACE_SOURCES ${shared_sources} ${static_sources} ${both_sources})
|
||||
endfunction()
|
||||
|
||||
@@ -47,7 +25,6 @@ function(sdl_sources)
|
||||
if(TARGET SDL3-static)
|
||||
target_sources(SDL3-static PRIVATE ${ARGS_STATIC} ${ARGS_UNPARSED_ARGUMENTS})
|
||||
endif()
|
||||
sdl_source_group(${PROJECT_SOURCE_DIR} ${ARGS_SHARED} ${ARGS_STATIC} ${ARGS_UNPARSED_ARGUMENTS})
|
||||
set_property(TARGET SDL3-collector APPEND PROPERTY INTERFACE_SOURCES ${ARGS_SHARED} ${ARGS_STATIC} ${ARGS_UNPARSED_ARGUMENTS})
|
||||
endfunction()
|
||||
|
@@ -96,14 +96,12 @@ if(TEST_STATIC)
|
||||
add_executable(gui-static WIN32 main_gui.c)
|
||||
target_link_libraries(gui-static PRIVATE SDL3::SDL3-static)
|
||||
|
||||
if(TEST_SHARED)
|
||||
# Assume SDL library has been built with `set(CMAKE_POSITION_INDEPENDENT_CODE ON)`
|
||||
add_library(sharedlib-static SHARED main_lib.c)
|
||||
target_link_libraries(sharedlib-static PRIVATE SDL3::SDL3-static)
|
||||
generate_export_header(sharedlib-static EXPORT_MACRO_NAME MYLIBRARY_EXPORT)
|
||||
target_compile_definitions(sharedlib-static PRIVATE "EXPORT_HEADER=\"${CMAKE_CURRENT_BINARY_DIR}/sharedlib-static_export.h\"")
|
||||
set_target_properties(sharedlib-static PROPERTIES C_VISIBILITY_PRESET "hidden")
|
||||
endif()
|
||||
|
||||
if(TEST_TEST)
|
||||
add_executable(sdltest-static sdltest.c)
|
||||
|
@@ -1,37 +1,24 @@
|
||||
#define SDL_MAIN_USE_CALLBACKS
|
||||
#include <SDL3/SDL_main.h>
|
||||
#include <SDL3/SDL.h>
|
||||
#include <SDL3/SDL_main.h>
|
||||
|
||||
static SDL_Window *window;
|
||||
|
||||
SDL_AppResult SDL_AppEvent(void *appstate, SDL_Event *event)
|
||||
{
|
||||
return SDL_APP_CONTINUE;
|
||||
}
|
||||
|
||||
SDL_AppResult SDL_AppIterate(void *appstate)
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
SDL_Window *window = NULL;
|
||||
SDL_Surface *screenSurface = NULL;
|
||||
screenSurface = SDL_GetWindowSurface(window);
|
||||
SDL_FillSurfaceRect(screenSurface, NULL, SDL_MapSurfaceRGB(screenSurface, 0xff, 0xff, 0xff));
|
||||
SDL_UpdateWindowSurface(window);
|
||||
return SDL_APP_CONTINUE;
|
||||
}
|
||||
|
||||
SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[])
|
||||
{
|
||||
if (!SDL_Init(SDL_INIT_VIDEO)) {
|
||||
SDL_Log("Could not initialize SDL: %s", SDL_GetError());
|
||||
return SDL_APP_FAILURE;
|
||||
return 1;
|
||||
}
|
||||
window = SDL_CreateWindow("Hello SDL", 640, 480, 0);
|
||||
if (!window) {
|
||||
SDL_Log("could not create window: %s", SDL_GetError());
|
||||
return SDL_APP_FAILURE;
|
||||
return 1;
|
||||
}
|
||||
return SDL_APP_CONTINUE;
|
||||
}
|
||||
|
||||
void SDL_AppQuit(void *appstate, SDL_AppResult result) {
|
||||
screenSurface = SDL_GetWindowSurface(window);
|
||||
SDL_FillSurfaceRect(screenSurface, NULL, SDL_MapSurfaceRGB(screenSurface, 0xff, 0xff, 0xff));
|
||||
SDL_UpdateWindowSurface(window);
|
||||
SDL_Delay(100);
|
||||
SDL_DestroyWindow(window);
|
||||
SDL_Quit();
|
||||
return 0;
|
||||
}
|
||||
|
@@ -1,24 +1,9 @@
|
||||
#define SDL_MAIN_USE_CALLBACKS
|
||||
#include <SDL3/SDL.h>
|
||||
#include <SDL3/SDL_main.h>
|
||||
#include <SDL3/SDL_test.h>
|
||||
|
||||
SDL_AppResult SDL_AppEvent(void *appstate, SDL_Event *event)
|
||||
{
|
||||
return SDL_APP_SUCCESS;
|
||||
}
|
||||
|
||||
SDL_AppResult SDL_AppIterate(void *appstate)
|
||||
{
|
||||
return SDL_APP_SUCCESS;
|
||||
}
|
||||
|
||||
SDL_AppResult SDL_AppInit(void **appstate, int argc, char *argv[])
|
||||
{
|
||||
int main(int argc, char *argv[]) {
|
||||
SDLTest_CommonState state;
|
||||
SDLTest_CommonDefaultArgs(&state, argc, argv);
|
||||
return SDL_APP_SUCCESS;
|
||||
}
|
||||
|
||||
void SDL_AppQuit(void *appstate, SDL_AppResult result) {
|
||||
return 0;
|
||||
}
|
||||
|
@@ -149,7 +149,7 @@ target_link_libraries(yourgame PRIVATE SDL3::SDL3)
|
||||
|
||||
If you use ndk-build, add the following before `include $(BUILD_SHARED_LIBRARY)` to your `Android.mk`:
|
||||
```
|
||||
LOCAL_SHARED_LIBRARIES := SDL3 SDL3-Headers
|
||||
LOCAL_SHARED_LIBARARIES := SDL3 SDL3-Headers
|
||||
```
|
||||
And add the following at the bottom:
|
||||
```
|
||||
|
@@ -157,7 +157,7 @@ flags to the compiler.
|
||||
- Use [`CMAKE_EXE_LINKER_FLAGS`](https://cmake.org/cmake/help/latest/variable/CMAKE_EXE_LINKER_FLAGS.html) to pass extra option to the linker for executables.
|
||||
- Use [`CMAKE_SHARED_LINKER_FLAGS`](https://cmake.org/cmake/help/latest/variable/CMAKE_SHARED_LINKER_FLAGS.html) to pass extra options to the linker for shared libraries.
|
||||
|
||||
#### Compile Options Examples
|
||||
#### Examples
|
||||
|
||||
- build a SDL library optimized for (more) modern x64 microprocessor architectures.
|
||||
|
||||
@@ -240,7 +240,7 @@ Append with a version number to target a specific SDK revision: e.g. `iphoneos12
|
||||
|
||||
CMake documentation: [link](https://cmake.org/cmake/help/latest/variable/CMAKE_OSX_SYSROOT.html)
|
||||
|
||||
#### Apple Examples
|
||||
#### Examples
|
||||
|
||||
- for macOS, building a dylib and/or static library for x86_64 and arm64:
|
||||
|
||||
@@ -328,8 +328,8 @@ Configure your project with `-DSDL_LIBC=ON` to make use of sanitizers.
|
||||
### CMake fails to build without X11 or Wayland support
|
||||
|
||||
Install the required system packages prior to running CMake.
|
||||
See [README-linux.md](README-linux.md#build-dependencies) for the list of dependencies on Linux.
|
||||
Other unix operating systems should provide similar packages.
|
||||
See [README-linux](linux#build-dependencies) for the list of dependencies on Linux.
|
||||
Other unix operationg systems should provide similar packages.
|
||||
|
||||
If you **really** don't need to show windows, add `-DSDL_UNIX_CONSOLE_BUILD=ON` to the CMake configure command.
|
||||
|
||||
|
@@ -34,12 +34,6 @@ things, you might confuse it. This is to the benefit of documentation, though,
|
||||
where we would rather you not do surprising things.
|
||||
|
||||
|
||||
## UTF-8 only!
|
||||
|
||||
All text must be UTF-8 encoded. The wiki will refuse to update files that are
|
||||
malformed.
|
||||
|
||||
|
||||
## We _sort of_ write in Doxygen format.
|
||||
|
||||
To document a symbol, we use something that looks like Doxygen (and Javadoc)
|
||||
@@ -162,23 +156,6 @@ wikiheaders will wordwrap header comments so they fit in 80 columns, so if you
|
||||
don't leave a blank line between paragraphs, they will smush into a single
|
||||
block of text when wordwrapping.
|
||||
|
||||
## Lists must be the start of a new paragraph.
|
||||
|
||||
If you write this:
|
||||
|
||||
```
|
||||
Here is some text without a blank line
|
||||
before an unordered list!
|
||||
- item a
|
||||
- item b
|
||||
- item c
|
||||
```
|
||||
|
||||
...then wikiheaders will word wrap this as a single paragraph, mangling the list.
|
||||
|
||||
Put a blank line before the list, and everything will format and wrap correctly.
|
||||
|
||||
This is a limitation of wikiheaders. Don't get bit by it!
|
||||
|
||||
## Don't worry about word wrapping.
|
||||
|
||||
@@ -327,21 +304,6 @@ to the headers:
|
||||
- "Version"
|
||||
- "See Also"
|
||||
|
||||
## Unrecognized sections are removed from the headers!
|
||||
|
||||
If you add Doxygen with a `##` (`###`, etc) section header, it'll
|
||||
migrate to the wiki and be _removed_ from the headers. Generally
|
||||
the correct thing to do is _never use section headers in the Doxygen_.
|
||||
|
||||
## wikiheaders will reorder standard sections.
|
||||
|
||||
The standard sections are always kept in a consistent order by
|
||||
wikiheaders, both in the headers and the wiki. If they're placed in
|
||||
a non-standard order, wikiheaders will reorder them.
|
||||
|
||||
For sections that aren't standard, wikiheaders will place them at
|
||||
the end of the wiki page, in the order they were seen when it loaded
|
||||
the page for processing.
|
||||
|
||||
## It's okay to repeat yourself.
|
||||
|
||||
@@ -356,7 +318,7 @@ through, header users can search for the function name.
|
||||
|
||||
You might be reading this document on the wiki! Any `README-*.md` files in
|
||||
the docs directory are bridged to the wiki, so `docs/README-linux.md` lands
|
||||
at https://wiki.libsdl.org/SDL3/README-linux ...these are just copied directly
|
||||
at https://wiki.libsdl.org/SDL3/README/linux ...these are just copied directly
|
||||
without any further processing by wikiheaders, and changes go in both
|
||||
directions.
|
||||
|
||||
@@ -446,19 +408,3 @@ Beyond stripping the initial ` * ` portion off each line, these comments are
|
||||
treated as pure Markdown. They don't support any Doxygen tags like `\sa` or
|
||||
`\since`.
|
||||
|
||||
## Enum/struct versioning
|
||||
|
||||
If you have an enum or struct, it'll list its `\since` field as the first SDL
|
||||
release it was available in. However, we might later add new values to an enum
|
||||
or fields to a struct. These lines, arriving in a newer version, should have a
|
||||
note about that, like this one on SDL_SCALEMODE_PIXELART:
|
||||
|
||||
```c
|
||||
typedef enum SDL_ScaleMode
|
||||
{
|
||||
SDL_SCALEMODE_INVALID = -1,
|
||||
SDL_SCALEMODE_NEAREST, /**< nearest pixel sampling */
|
||||
SDL_SCALEMODE_LINEAR, /**< linear filtering */
|
||||
SDL_SCALEMODE_PIXELART /**< nearest pixel sampling with improved scaling for pixel art (since SDL 3.3.0) */
|
||||
} SDL_ScaleMode;
|
||||
```
|
||||
|
@@ -103,7 +103,7 @@ getting started.
|
||||
|
||||
Another option is to use SDL' main callbacks, which handle this for you
|
||||
without platform-specific code in your app. Please refer to
|
||||
[the wiki](https://wiki.libsdl.org/SDL3/README-main-functions#main-callbacks-in-sdl3)
|
||||
[the wiki](https://wiki.libsdl.org/SDL3/README/main-functions#main-callbacks-in-sdl3)
|
||||
or `docs/README-main-functions.md` in the SDL source code.
|
||||
|
||||
|
||||
@@ -230,7 +230,7 @@ tools.
|
||||
mkdir build
|
||||
cd build
|
||||
emcmake cmake ..
|
||||
# you can also try `emcmake cmake -G Ninja ..` and then use `ninja` instead of this command.
|
||||
# you can also do `emcmake cmake -G Ninja ..` and then use `ninja` instead of this command.
|
||||
emmake make -j4
|
||||
```
|
||||
|
||||
@@ -239,7 +239,7 @@ If you want to build with thread support, something like this works:
|
||||
```bash
|
||||
mkdir build
|
||||
cd build
|
||||
emcmake cmake -DSDL_PTHREADS=ON ..
|
||||
emcmake cmake -DSDL_THREADS=ON ..
|
||||
# you can also do `emcmake cmake -G Ninja ..` and then use `ninja` instead of this command.
|
||||
emmake make -j4
|
||||
```
|
||||
|
@@ -12,44 +12,9 @@ Instructions:
|
||||
2. Select your desired target, and hit build.
|
||||
|
||||
|
||||
Using the Simple DirectMedia Layer for iOS with the SDL3 xcFramework
|
||||
Using the Simple DirectMedia Layer for iOS
|
||||
==============================================================================
|
||||
|
||||
The recommended way to use SDL for iOS is by including the SDL3.xcframework which is now a build target of the SDL.xcodeproj file. An xcframework is a new (Xcode 11) uber-framework which can handle any combination of processor type and target OS platform.
|
||||
You can either build the SDL3.xcframework yourself or download the latest release disk image asset (*.dmg).
|
||||
|
||||
In the past, iOS devices were always an ARM variant processor, and the simulator was always i386 or x86_64, and thus libraries could be combined into a single framework for both simulator and device. With the introduction of the Apple Silicon ARM-based machines, regular frameworks would collide as CPU type was no longer sufficient to differentiate the platform. So Apple created the new xcframework library package.
|
||||
|
||||
The xcframework target builds into a Products directory alongside the SDL.xcodeproj file, as SDL3.xcframework. This can be brought in to any iOS project and will function properly for both simulator and device, no matter their CPUs. Note that Intel Macs cannot cross-compile for Apple Silicon Macs. If you need AS compatibility, perform this build on an Apple Silicon Mac.
|
||||
|
||||
This target requires Xcode 11 or later. The target will simply fail to build if attempted on older Xcodes.
|
||||
|
||||
In addition, on Apple platforms, main() cannot be in a dynamically loaded library.
|
||||
However, unlike in SDL2, in SDL3 SDL_main is implemented inline in SDL_main.h, so you don't need to link against a static libSDL3main.lib, and you don't need to copy a .c file from the SDL3 source either.
|
||||
This means that iOS apps which used the statically-linked libSDL3.lib and now link with the xcframwork can just `#include <SDL3/SDL_main.h>` in the source file that contains their standard `int main(int argc, char *argv[])` function to get a header-only SDL_main implementation that calls the `SDL_RunApp()` with your standard main function.
|
||||
|
||||
To use the SDL3.xcframework follow these steps:
|
||||
|
||||
1. Run Xcode and create a new project using the iOS Game template, selecting the Objective C language and Metal game technology.
|
||||
2. In the main view, delete all files except for Assets and LaunchScreen
|
||||
3. Select the project in the main view, go to the "General" tab, scroll down to "Frameworks, Libraries, and Embedded Content", and drag and drop the SDL3.xcframework
|
||||
4. Still in "Frameworks, Libraries, and Embedded Content", select "Embed & Sign" for the SDL3.xcframework.
|
||||
5. Add the source files that you would normally have for an SDL program, making sure to have #include <SDL3/SDL_main.h> at the top of the file containing your main() function.
|
||||
6. Add any assets that your application needs.
|
||||
7. Enjoy!
|
||||
|
||||
Using an xcFramework is similar to using a regular framework. However, issues have been seen with the build system not seeing the headers in the xcFramework. To remedy this, add the path to the xcFramework in your app's target ==> Build Settings ==> Framework Search Paths and mark it recursive (this is critical). Also critical is to remove "*.framework" from Build Settings ==> Sub-Directories to Exclude in Recursive Searches. Clean the build folder, and on your next build the build system should be able to see any of these in your code, as expected:
|
||||
|
||||
#include "SDL3/SDL_main.h"
|
||||
#include <SDL3/SDL.h>
|
||||
#include <SDL3/SDL_main.h>
|
||||
|
||||
|
||||
Using the Simple DirectMedia Layer for iOS by adding the SDL3 Xcode project
|
||||
==============================================================================
|
||||
|
||||
To maintain compatibility with older Xcode versions than version 11 you can add the SDL3 Xcode project file to your project:
|
||||
|
||||
1. Run Xcode and create a new project using the iOS Game template, selecting the Objective C language and Metal game technology.
|
||||
2. In the main view, delete all files except for Assets and LaunchScreen
|
||||
3. Right click the project in the main view, select "Add Files...", and add the SDL project, Xcode/SDL/SDL.xcodeproj
|
||||
@@ -61,18 +26,6 @@ To maintain compatibility with older Xcode versions than version 11 you can add
|
||||
9. Add any assets that your application needs.
|
||||
10. Enjoy!
|
||||
|
||||
Notes for distributing your iOS app on the AppStore when using the embedded SDL3 Xcode project:
|
||||
Embedding the SDL3 Xcode project makes SDL3.framework a target of your app, so it will be included in the archive created during the "Archive" step required for App Store submission. As this prevents successful distribution, remove the framework via a script in the Build Phase after the "Embed & Sign" step.
|
||||
|
||||
1. Select the project in the main view, go to the "Build Phases" tab, click on the big '+' in this tab and click "New Run Script Phase".
|
||||
2. Scroll down to "Run Script" (after the "Embed SDL3 Framework") and enter the following script:
|
||||
```
|
||||
if [ -d "$INSTALL_ROOT/Library" ]; then
|
||||
echo "Removing SDL3.framework from INSTALL_ROOT for archiving"
|
||||
rm -rf "$INSTALL_ROOT/Library"
|
||||
fi
|
||||
```
|
||||
3. Below the script entry uncheck the "Run Script:" options "For install builds only" and "Based on dependency analysis"
|
||||
|
||||
TODO: Add information regarding App Store requirements such as icons, etc.
|
||||
|
||||
@@ -201,7 +154,26 @@ More information on this subject is available here:
|
||||
http://developer.apple.com/library/ios/#documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/Introduction/Introduction.html
|
||||
|
||||
|
||||
Notes -- xcFramework
|
||||
==============================================================================
|
||||
|
||||
The SDL.xcodeproj file now includes a target to build SDL3.xcframework. An xcframework is a new (Xcode 11) uber-framework which can handle any combination of processor type and target OS platform.
|
||||
|
||||
In the past, iOS devices were always an ARM variant processor, and the simulator was always i386 or x86_64, and thus libraries could be combined into a single framework for both simulator and device. With the introduction of the Apple Silicon ARM-based machines, regular frameworks would collide as CPU type was no longer sufficient to differentiate the platform. So Apple created the new xcframework library package.
|
||||
|
||||
The xcframework target builds into a Products directory alongside the SDL.xcodeproj file, as SDL3.xcframework. This can be brought in to any iOS project and will function properly for both simulator and device, no matter their CPUs. Note that Intel Macs cannot cross-compile for Apple Silicon Macs. If you need AS compatibility, perform this build on an Apple Silicon Mac.
|
||||
|
||||
This target requires Xcode 11 or later. The target will simply fail to build if attempted on older Xcodes.
|
||||
|
||||
In addition, on Apple platforms, main() cannot be in a dynamically loaded library.
|
||||
However, unlike in SDL2, in SDL3 SDL_main is implemented inline in SDL_main.h, so you don't need to link against a static libSDL3main.lib, and you don't need to copy a .c file from the SDL3 source either.
|
||||
This means that iOS apps which used the statically-linked libSDL3.lib and now link with the xcframwork can just `#include <SDL3/SDL_main.h>` in the source file that contains their standard `int main(int argc, char *argv[])` function to get a header-only SDL_main implementation that calls the `SDL_RunApp()` with your standard main function.
|
||||
|
||||
Using an xcFramework is similar to using a regular framework. However, issues have been seen with the build system not seeing the headers in the xcFramework. To remedy this, add the path to the xcFramework in your app's target ==> Build Settings ==> Framework Search Paths and mark it recursive (this is critical). Also critical is to remove "*.framework" from Build Settings ==> Sub-Directories to Exclude in Recursive Searches. Clean the build folder, and on your next build the build system should be able to see any of these in your code, as expected:
|
||||
|
||||
#include "SDL_main.h"
|
||||
#include <SDL.h>
|
||||
#include <SDL_main.h>
|
||||
|
||||
|
||||
Notes -- iPhone SDL limitations
|
||||
|
@@ -17,7 +17,7 @@ Ubuntu 18.04, all available features enabled:
|
||||
sudo apt-get install build-essential git make \
|
||||
pkg-config cmake ninja-build gnome-desktop-testing libasound2-dev libpulse-dev \
|
||||
libaudio-dev libjack-dev libsndio-dev libx11-dev libxext-dev \
|
||||
libxrandr-dev libxcursor-dev libxfixes-dev libxi-dev libxss-dev libxtst-dev \
|
||||
libxrandr-dev libxcursor-dev libxfixes-dev libxi-dev libxss-dev \
|
||||
libxkbcommon-dev libdrm-dev libgbm-dev libgl1-mesa-dev libgles2-mesa-dev \
|
||||
libegl1-mesa-dev libdbus-1-dev libibus-1.0-dev libudev-dev
|
||||
|
||||
@@ -26,7 +26,7 @@ Ubuntu 22.04+ can also add `libpipewire-0.3-dev libwayland-dev libdecor-0-dev li
|
||||
Fedora 35, all available features enabled:
|
||||
|
||||
sudo yum install gcc git-core make cmake \
|
||||
alsa-lib-devel pulseaudio-libs-devel pipewire-devel \
|
||||
alsa-lib-devel pulseaudio-libs-devel nas-devel pipewire-devel \
|
||||
libX11-devel libXext-devel libXrandr-devel libXcursor-devel libXfixes-devel \
|
||||
libXi-devel libXScrnSaver-devel dbus-devel ibus-devel \
|
||||
systemd-devel mesa-libGL-devel libxkbcommon-devel mesa-libGLES-devel \
|
||||
@@ -43,12 +43,10 @@ NOTES:
|
||||
openSUSE Tumbleweed:
|
||||
|
||||
sudo zypper in libunwind-devel libusb-1_0-devel Mesa-libGL-devel libxkbcommon-devel libdrm-devel \
|
||||
libgbm-devel pipewire-devel libpulse-devel sndio-devel Mesa-libEGL-devel alsa-devel xwayland-devel \
|
||||
wayland-devel wayland-protocols-devel
|
||||
libgbm-devel pipewire-devel libpulse-devel sndio-devel Mesa-libEGL-devel
|
||||
|
||||
Arch:
|
||||
|
||||
sudo pacman -S alsa-lib cmake hidapi ibus jack libdecor libgl libpulse libusb libx11 libxcursor libxext libxinerama libxkbcommon libxrandr libxrender libxss libxtst mesa ninja pipewire sndio vulkan-driver vulkan-headers wayland wayland-protocols
|
||||
sudo pacman -S alsa-lib cmake hidapi ibus jack libdecor libgl libpulse libusb libx11 libxcursor libxext libxinerama libxkbcommon libxrandr libxrender libxss mesa ninja pipewire sndio vulkan-driver vulkan-headers wayland wayland-protocols
|
||||
|
||||
|
||||
Joystick does not work
|
||||
|
@@ -49,7 +49,7 @@ NSApplicationDelegate implementation:
|
||||
```objc
|
||||
- (NSApplicationTerminateReply)applicationShouldTerminate:(NSApplication *)sender
|
||||
{
|
||||
if (SDL_EventEnabled(SDL_EVENT_QUIT)) {
|
||||
if (SDL_GetEventState(SDL_EVENT_QUIT) == SDL_ENABLE) {
|
||||
SDL_Event event;
|
||||
SDL_zero(event);
|
||||
event.type = SDL_EVENT_QUIT;
|
||||
@@ -61,7 +61,7 @@ NSApplicationDelegate implementation:
|
||||
|
||||
- (BOOL)application:(NSApplication *)theApplication openFile:(NSString *)filename
|
||||
{
|
||||
if (SDL_EventEnabled(SDL_EVENT_DROP_FILE)) {
|
||||
if (SDL_GetEventState(SDL_EVENT_DROP_FILE) == SDL_ENABLE) {
|
||||
SDL_Event event;
|
||||
SDL_zero(event);
|
||||
event.type = SDL_EVENT_DROP_FILE;
|
||||
|
@@ -1459,7 +1459,7 @@ The following symbols have been removed:
|
||||
* SDL_RENDERER_PRESENTVSYNC - replaced with SDL_PROP_RENDERER_CREATE_PRESENT_VSYNC_NUMBER during renderer creation and SDL_PROP_RENDERER_VSYNC_NUMBER after renderer creation
|
||||
* SDL_RENDERER_SOFTWARE - you can check whether the name of the renderer is `SDL_SOFTWARE_RENDERER`
|
||||
* SDL_RENDERER_TARGETTEXTURE - all renderers support target texture functionality
|
||||
* SDL_ScaleModeBest - use SDL_SCALEMODE_LINEAR instead
|
||||
* SDL_ScaleModeBest = use SDL_SCALEMODE_LINEAR instead
|
||||
|
||||
## SDL_rwops.h
|
||||
|
||||
|
@@ -1,64 +1,5 @@
|
||||
# Nokia N-Gage
|
||||
Support for the Nokia N-Gage has been removed from SDL3 (but will make a
|
||||
comeback when newer compilers are available for the platform).
|
||||
|
||||
SDL port for the Nokia N-Gage
|
||||
[Homebrew toolchain](https://github.com/ngagesdk/ngage-toolchain)
|
||||
contributed by:
|
||||
SDL2 still supports this platform.
|
||||
|
||||
- [Michael Fitzmayer](https://github.com/mupfdev)
|
||||
|
||||
- [Anonymous Maarten](https://github.com/madebr)
|
||||
|
||||
Many thanks to:
|
||||
|
||||
- icculus and slouken for always making room for us, even when we show up in 2025
|
||||
still waving the N-Gage flag.
|
||||
|
||||
- The Nokia N-Gage [Discord community](https://discord.gg/dbUzqJ26vs)
|
||||
who keeps the platform alive.
|
||||
|
||||
- The staff and supporters of the
|
||||
[Suomen pelimuseo](https://www.vapriikki.fi/nayttelyt/fantastinen-floppi/), and
|
||||
to Heikki Jungmann, for their ongoing love and dedication for the Nokia N-Gage --
|
||||
you guys are awesome!
|
||||
|
||||
## History
|
||||
|
||||
When SDL support was discontinued due to the lack of C99 support at the time,
|
||||
this version was rebuilt from the ground up after resolving the compiler issues.
|
||||
|
||||
In contrast to the earlier SDL2 port, this version features a dedicated rendering
|
||||
backend and a functional, albeit limited, audio interface. Support for the
|
||||
software renderer has been removed.
|
||||
|
||||
The outcome is a significantly leaner and more efficient SDL port, which we hope
|
||||
will breathe new life into this beloved yet obscure platform.
|
||||
|
||||
## To the Stubborn Legends of the DC Scene
|
||||
|
||||
This port is lovingly dedicated to the ever-nostalgic Dreamcast homebrew scene --
|
||||
because if we managed to pull this off for the N-Gage (yes, the N-Gage), surely
|
||||
you guys can stop clinging to SDL2 like it's a rare Shenmue prototype and finally
|
||||
make the leap to SDL3. It's 2025, not 1999 -- and let's be honest, you're rocking
|
||||
a state-of-the-art C23 compiler. The irony writes itself.
|
||||
|
||||
## Existing Issues and Limitations
|
||||
|
||||
- For now, the new
|
||||
[SDL3 main callbacks](https://wiki.libsdl.org/SDL3/README-main-functions#main-callbacks-in-sdl3)
|
||||
are not optional and must be used. This is important as the callbacks
|
||||
are optional on other platforms.
|
||||
|
||||
- If the application is put in the background while sound is playing,
|
||||
some of the audio is looped until the app is back in focus.
|
||||
|
||||
- It is recommended initialising SDLs audio sub-system even when it
|
||||
is not required. The backend is started at a higher level. Initialising
|
||||
SDLs audio sub-system ensures that the backend is properly deinitialised.
|
||||
|
||||
- Because the audio sample rate can change during phone calls, the sample
|
||||
rate is currently fixed at 8kHz to ensure stable behavior. Although
|
||||
dynamically adjusting the sample rate is theoretically possible, the
|
||||
current implementation doesn't support it yet. This limitation is
|
||||
expected to be resolved in a future update.
|
||||
|
||||
- Dependency tracking is currently non-functional.
|
||||
|
@@ -11,8 +11,7 @@
|
||||
- [macOS](README-macos.md)
|
||||
- [NetBSD](README-bsd.md)
|
||||
- [Nintendo Switch](README-switch.md)
|
||||
- [Nintendo 3DS](README-n3ds.md)
|
||||
- [Nokia N-Gage](README-ngage.md)
|
||||
- [Nintendo 3DS](README-3ds.md)
|
||||
- [OpenBSD](README-bsd.md)
|
||||
- [PlayStation 2](README-ps2.md)
|
||||
- [PlayStation 4](README-ps4.md)
|
||||
@@ -34,6 +33,7 @@ All of these still work with [SDL2](/SDL2), which is an incompatible API, but an
|
||||
|
||||
- Google Stadia
|
||||
- NaCL
|
||||
- Nokia N-Gage
|
||||
- OS/2
|
||||
- QNX
|
||||
- WinPhone
|
||||
|
@@ -1,13 +1,13 @@
|
||||
PSP
|
||||
======
|
||||
SDL port for the Sony PSP contributed by:
|
||||
- Captain Lex
|
||||
- Captian Lex
|
||||
- Francisco Javier Trujillo Mata
|
||||
- Wouter Wijsman
|
||||
|
||||
|
||||
Credit to
|
||||
Marcus R.Brown, Jim Paris, Matthew H for the original SDL 1.2 for PSP
|
||||
Marcus R.Brown,Jim Paris,Matthew H for the original SDL 1.2 for PSP
|
||||
Geecko for his PSP GU lib "Glib2d"
|
||||
|
||||
## Building
|
||||
|
@@ -47,15 +47,8 @@ encounter limitations or behavior that is different from other windowing systems
|
||||
|
||||
### Warping the mouse cursor to or from a point outside the window doesn't work
|
||||
|
||||
- Warping the cursor on Wayland requires that either the `wp_pointer_warp_v1` or `zwp_pointer_confinement_v1` protocol
|
||||
is supported by the compositor. Compositors typically restrict pointer warps to be within the window that currently
|
||||
has mouse focus.
|
||||
|
||||
### Minimize/Restored window events are not sent, and the ```SDL_WINDOW_MINIMIZED``` flag is not set.
|
||||
|
||||
- Wayland windows do not currently report the minimized state, aside from when it is activated programmatically via
|
||||
```SDL_MinimizeWindow()```. Minimizing a window from the window controls or a desktop shortcut will not send a
|
||||
minimized event or flag the window as being minimized.
|
||||
- The cursor can be warped only within the window with mouse focus, provided that the `zwp_pointer_confinement_v1`
|
||||
protocol is supported by the compositor.
|
||||
|
||||
### The application icon can't be set via ```SDL_SetWindowIcon()```
|
||||
|
||||
@@ -66,15 +59,6 @@ encounter limitations or behavior that is different from other windowing systems
|
||||
`SDL_APP_ID` hint string, the desktop entry file name should match the application ID. For example, if your
|
||||
application ID is set to `org.my_org.sdl_app`, the desktop entry file should be named `org.my_org.sdl_app.desktop`.
|
||||
|
||||
### The application progress bar can't be set via ```SDL_SetWindowProgressState()``` or ```SDL_SetWindowProgressValue()```
|
||||
|
||||
- Only some Desktop Environemnts support the underlying API. Known compatible DEs: Unity, KDE
|
||||
- The underlying API requires a desktop entry file, aka a `.desktop` file.
|
||||
Please see the [Desktop Entry Specification](https://specifications.freedesktop.org/desktop-entry-spec/latest/) for
|
||||
more information on the format of this file. Note that if your application manually sets the application ID via the
|
||||
`SDL_APP_ID` hint string, the desktop entry file name should match the application ID. For example, if your
|
||||
application ID is set to `org.my_org.sdl_app`, the desktop entry file should be named `org.my_org.sdl_app.desktop`.
|
||||
|
||||
### Keyboard grabs don't work when running under XWayland
|
||||
|
||||
- On GNOME based desktops, the dconf setting `org/gnome/mutter/wayland/xwayland-allow-grabs` must be enabled.
|
||||
|
@@ -15,8 +15,6 @@
|
||||
|
||||
* Create a GitHub release and attach the archives you just generated.
|
||||
|
||||
* If this is a feature release, also tag the sdlwiki with the same tag.
|
||||
|
||||
## New feature release
|
||||
|
||||
* Update `WhatsNew.txt`
|
||||
|
@@ -16,6 +16,13 @@ else()
|
||||
endif()
|
||||
set(HAVE_EXAMPLES_LINK_SHARED "${SDL_EXAMPLES_LINK_SHARED}" PARENT_SCOPE)
|
||||
|
||||
# CMake incorrectly detects opengl32.lib being present on MSVC ARM64
|
||||
if(NOT (MSVC AND SDL_CPU_ARM64))
|
||||
# Prefer GLVND, if present
|
||||
set(OpenGL_GL_PREFERENCE GLVND)
|
||||
find_package(OpenGL)
|
||||
endif()
|
||||
|
||||
set(SDL_EXAMPLE_EXECUTABLES)
|
||||
|
||||
if(CMAKE_RUNTIME_OUTPUT_DIRECTORY)
|
||||
@@ -57,12 +64,17 @@ macro(add_sdl_example_executable TARGET)
|
||||
if(NOT AST_SOURCES)
|
||||
message(FATAL_ERROR "add_sdl_example_executable needs at least one source")
|
||||
endif()
|
||||
set(EXTRA_SOURCES "")
|
||||
if(AST_DATAFILES)
|
||||
list(APPEND EXTRA_SOURCES ${DATAFILES})
|
||||
endif()
|
||||
if(ANDROID)
|
||||
add_library(${TARGET} SHARED ${AST_SOURCES} ${AST_DATAFILES})
|
||||
add_library(${TARGET} SHARED ${AST_SOURCES} ${EXTRA_SOURCES})
|
||||
else()
|
||||
add_executable(${TARGET} ${AST_SOURCES} ${AST_DATAFILES})
|
||||
add_executable(${TARGET} ${AST_SOURCES} ${EXTRA_SOURCES})
|
||||
endif()
|
||||
SDL_AddCommonCompilerFlags(${TARGET})
|
||||
target_include_directories(${TARGET} PRIVATE "${SDL3_SOURCE_DIR}/src/video/khronos")
|
||||
target_link_libraries(${TARGET} PRIVATE SDL3::${sdl_name_component})
|
||||
|
||||
list(APPEND SDL_EXAMPLE_EXECUTABLES ${TARGET})
|
||||
@@ -73,9 +85,13 @@ macro(add_sdl_example_executable TARGET)
|
||||
COMMAND ${CMAKE_COMMAND} ARGS -E copy_if_different ${AST_DATAFILES} $<TARGET_FILE_DIR:${TARGET}>/sdl-${TARGET}
|
||||
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
|
||||
)
|
||||
elseif(NOT APPLE AND NOT N3DS)
|
||||
else()
|
||||
add_dependencies(${TARGET} copy-sdl-example-resources)
|
||||
endif()
|
||||
if(APPLE)
|
||||
# Make sure resource files get installed into macOS/iOS .app bundles.
|
||||
set_target_properties(${TARGET} PROPERTIES RESOURCE "${AST_DATAFILES}")
|
||||
endif()
|
||||
if(EMSCRIPTEN)
|
||||
foreach(res IN LISTS AST_DATAFILES)
|
||||
get_filename_component(res_name "${res}" NAME)
|
||||
@@ -85,45 +101,24 @@ macro(add_sdl_example_executable TARGET)
|
||||
set_property(TARGET ${TARGET} APPEND PROPERTY ADDITIONAL_CLEAN_FILES "$<TARGET_FILE_DIR:${TARGET}>/$<JOIN:${AST_DATAFILES},$<SEMICOLON>$<TARGET_FILE_DIR:${TARGET}>/>")
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
# Set Apple App ID / Bundle ID. This is needed to launch apps on some Apple
|
||||
# platforms (iOS, for example).
|
||||
set_target_properties(${TARGET} PROPERTIES
|
||||
RESOURCES "${AST_DATAFILES}"
|
||||
MACOSX_BUNDLE TRUE
|
||||
MACOSX_BUNDLE_GUI_IDENTIFIER "org.libsdl.${TARGET}"
|
||||
MACOSX_BUNDLE_BUNDLE_VERSION "${SDL3_VERSION}"
|
||||
MACOSX_BUNDLE_SHORT_VERSION_STRING "${SDL3_VERSION}"
|
||||
)
|
||||
set_property(SOURCE ${AST_DATAFILES} PROPERTY MACOSX_PACKAGE_LOCATION "Resources")
|
||||
elseif(WINDOWS)
|
||||
if(WINDOWS)
|
||||
# CET support was added in VS 16.7
|
||||
if(MSVC_VERSION GREATER 1926 AND CMAKE_GENERATOR_PLATFORM MATCHES "Win32|x64")
|
||||
set_property(TARGET ${TARGET} APPEND_STRING PROPERTY LINK_FLAGS " -CETCOMPAT")
|
||||
endif()
|
||||
elseif(PSP)
|
||||
target_link_libraries(${TARGET} PRIVATE GL)
|
||||
elseif(EMSCRIPTEN)
|
||||
set_property(TARGET ${TARGET} PROPERTY SUFFIX ".html")
|
||||
target_link_options(${TARGET} PRIVATE -sALLOW_MEMORY_GROWTH=1)
|
||||
elseif(N3DS)
|
||||
set(ROMFS_DIR "${CMAKE_CURRENT_BINARY_DIR}/romfs/${TARGET}")
|
||||
file(MAKE_DIRECTORY "${ROMFS_DIR}")
|
||||
file(COPY ${AST_DATAFILES} DESTINATION "${ROMFS_DIR}")
|
||||
ctr_generate_smdh("${TARGET}.smdh"
|
||||
NAME "SDL-${TARGET}"
|
||||
DESCRIPTION "SDL3 example application"
|
||||
AUTHOR "SDL3 Contributors"
|
||||
ICON "${CMAKE_CURRENT_SOURCE_DIR}/../test/n3ds/logo48x48.png"
|
||||
)
|
||||
ctr_create_3dsx(
|
||||
${TARGET}
|
||||
ROMFS "${ROMFS_DIR}"
|
||||
SMDH "${TARGET}.smdh"
|
||||
)
|
||||
elseif(NGAGE)
|
||||
string(MD5 TARGET_MD5 "${TARGET}")
|
||||
string(SUBSTRING "${TARGET_MD5}" 0 8 TARGET_MD5_8)
|
||||
target_link_options(${TARGET} PRIVATE "SHELL:-s UID3=0x${TARGET_MD5_8}")
|
||||
endif()
|
||||
|
||||
if(OPENGL_FOUND)
|
||||
target_compile_definitions(${TARGET} PRIVATE HAVE_OPENGL)
|
||||
endif()
|
||||
|
||||
# FIXME: only add "${SDL3_BINARY_DIR}/include-config-$<LOWER_CASE:$<CONFIG>>" + include paths of external dependencies
|
||||
target_include_directories(${TARGET} PRIVATE "$<TARGET_PROPERTY:SDL3::${sdl_name_component},INCLUDE_DIRECTORIES>")
|
||||
endmacro()
|
||||
|
||||
add_sdl_example_executable(renderer-clear SOURCES renderer/01-clear/clear.c)
|
||||
@@ -141,12 +136,10 @@ add_sdl_example_executable(renderer-viewport SOURCES renderer/14-viewport/viewpo
|
||||
add_sdl_example_executable(renderer-cliprect SOURCES renderer/15-cliprect/cliprect.c DATAFILES ${CMAKE_CURRENT_SOURCE_DIR}/../test/sample.bmp)
|
||||
add_sdl_example_executable(renderer-read-pixels SOURCES renderer/17-read-pixels/read-pixels.c DATAFILES ${CMAKE_CURRENT_SOURCE_DIR}/../test/sample.bmp)
|
||||
add_sdl_example_executable(renderer-debug-text SOURCES renderer/18-debug-text/debug-text.c)
|
||||
add_sdl_example_executable(renderer-affine-textures SOURCES renderer/19-affine-textures/affine-textures.c DATAFILES ${CMAKE_CURRENT_SOURCE_DIR}/../test/sample.bmp)
|
||||
add_sdl_example_executable(audio-simple-playback SOURCES audio/01-simple-playback/simple-playback.c)
|
||||
add_sdl_example_executable(audio-simple-playback-callback SOURCES audio/02-simple-playback-callback/simple-playback-callback.c)
|
||||
add_sdl_example_executable(audio-load-wav SOURCES audio/03-load-wav/load-wav.c DATAFILES ${CMAKE_CURRENT_SOURCE_DIR}/../test/sample.wav)
|
||||
add_sdl_example_executable(audio-multiple-streams SOURCES audio/04-multiple-streams/multiple-streams.c DATAFILES ${CMAKE_CURRENT_SOURCE_DIR}/../test/sample.wav ${CMAKE_CURRENT_SOURCE_DIR}/../test/sword.wav)
|
||||
add_sdl_example_executable(audio-planar-data SOURCES audio/05-planar-data/planar-data.c)
|
||||
add_sdl_example_executable(input-joystick-polling SOURCES input/01-joystick-polling/joystick-polling.c)
|
||||
add_sdl_example_executable(input-joystick-events SOURCES input/02-joystick-events/joystick-events.c)
|
||||
add_sdl_example_executable(camera-read-and-draw SOURCES camera/01-read-and-draw/read-and-draw.c)
|
||||
@@ -182,6 +175,28 @@ if(PSP)
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if(N3DS)
|
||||
set(ROMFS_DIR "${CMAKE_CURRENT_BINARY_DIR}/romfs")
|
||||
file(MAKE_DIRECTORY "${ROMFS_DIR}")
|
||||
file(COPY ${RESOURCE_FILES} DESTINATION "${ROMFS_DIR}")
|
||||
|
||||
foreach(APP ${SDL_EXAMPLE_EXECUTABLES})
|
||||
get_target_property(TARGET_BINARY_DIR ${APP} BINARY_DIR)
|
||||
set(SMDH_FILE "${TARGET_BINARY_DIR}/${APP}.smdh")
|
||||
ctr_generate_smdh("${SMDH_FILE}"
|
||||
NAME "SDL-${APP}"
|
||||
DESCRIPTION "SDL3 Test suite"
|
||||
AUTHOR "SDL3 Contributors"
|
||||
ICON "${CMAKE_CURRENT_SOURCE_DIR}/../test/n3ds/logo48x48.png"
|
||||
)
|
||||
ctr_create_3dsx(
|
||||
${APP}
|
||||
ROMFS "${ROMFS_DIR}"
|
||||
SMDH "${SMDH_FILE}"
|
||||
)
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if(RISCOS)
|
||||
set(SDL_EXAMPLE_EXECUTABLES_AIF)
|
||||
foreach(APP ${SDL_EXAMPLE_EXECUTABLES})
|
||||
@@ -196,6 +211,18 @@ if(RISCOS)
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
# Set Apple App ID / Bundle ID. This is needed to launch apps on some Apple
|
||||
# platforms (iOS, for example).
|
||||
if(APPLE)
|
||||
foreach(CURRENT_TARGET ${SDL_EXAMPLE_EXECUTABLES})
|
||||
set_target_properties("${CURRENT_TARGET}" PROPERTIES
|
||||
MACOSX_BUNDLE_GUI_IDENTIFIER "org.libsdl.${CURRENT_TARGET}"
|
||||
MACOSX_BUNDLE_BUNDLE_VERSION "${SDL3_VERSION}"
|
||||
MACOSX_BUNDLE_SHORT_VERSION_STRING "${SDL3_VERSION}"
|
||||
)
|
||||
endforeach()
|
||||
endif()
|
||||
|
||||
if(SDL_INSTALL_EXAMPLES)
|
||||
if(RISCOS)
|
||||
install(
|
||||
|
@@ -1,5 +1,5 @@
|
||||
If you're running this in a web browser, you need to click the window before you'll hear anything!
|
||||
|
||||
This example code loads two .wav files, puts them in audio streams and binds
|
||||
This example code loads two .wav files, puts them an audio streams and binds
|
||||
them for playback, repeating both sounds on loop. This shows several streams
|
||||
mixing into a single playback device.
|
||||
|
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* This example code loads two .wav files, puts them in audio streams and
|
||||
* This example code loads two .wav files, puts them an audio streams and
|
||||
* binds them for playback, repeating both sounds on loop. This shows several
|
||||
* streams mixing into a single playback device.
|
||||
*
|
||||
|
@@ -1,7 +0,0 @@
|
||||
This example code draws two clickable buttons. Each causes a sound to play,
|
||||
fed to either the left or right audio channel through separate (planar)
|
||||
arrays.
|
||||
|
||||
Planar audio can feed both channels at the same time from different arrays,
|
||||
as well, but this example only uses one channel at a time for clarity. A
|
||||
NULL array will supply silence for that channel.
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user