Commit Graph

10897 Commits

Author SHA1 Message Date
Sam Lantinga d41fb3c480 Merge commit 'cfd5d8eb29c8958de3333632a96032d3481816e5' into main 2022-10-23 16:35:11 -07:00
Sam Lantinga 9c7b9e08b3 Merge commit '4ca5ea5b7e8333b2cde1b7cdddf167c67cc3f23c' into main 2022-10-23 16:35:09 -07:00
Sam Lantinga 8696350903 Merge commit '2dc788cb9ffa83a2840e62f5ad2d0a7055cfcb19' into main 2022-10-23 16:35:07 -07:00
Sam Lantinga e45ef5a6c0 Merge commit '5b8f830e342b296d255969bbaec5a1a3522f1083' into main 2022-10-23 16:35:05 -07:00
Sam Lantinga 491d594976 Merge commit '0e1d19cf680fc51635b3c52a9afa33fe03881bb5' into main 2022-10-23 16:35:03 -07:00
Sam Lantinga 26c9620a63 Merge commit 'a905a7869f18332579ff06ba3f7f3777708a3007' into main 2022-10-23 16:35:01 -07:00
Sam Lantinga e738cf80dc Merge commit '65a38a4015e54add093bdb3fbd2ad1cdc1770c72' into main 2022-10-23 16:34:59 -07:00
Sam Lantinga da4c97250a Merge commit '3f1b5efccaa727745b335b546a42bd650694ca08' into main 2022-10-23 16:34:57 -07:00
Sam Lantinga b3ba8f4065 Merge commit '3d415bc5d61e625189ccca6348ff1b70c469e45c' into main 2022-10-23 16:34:55 -07:00
Sam Lantinga 2d3e21ab0e Merge commit 'f37db957f8c5d9de53bdd58b2a95a2da0937307d' into main 2022-10-23 16:34:52 -07:00
Sam Lantinga 8047ece180 Merge commit '5ed091c12d4edefb366d78217b72cb75b563bfcd' into main 2022-10-23 16:34:50 -07:00
Sam Lantinga ef62b767f9 Merge commit '0823b5973a28ebad2ca6d34058c12602bc8a69f0' into main 2022-10-23 16:34:48 -07:00
Sam Lantinga e5fe522194 Merge commit '4264c0b67469896fced5ba8ac4c0e75acbb13ff1' into main 2022-10-23 16:34:46 -07:00
Sam Lantinga 57a98aa5e3 Merge commit '96361fc476a9f0a91ac021133bb44e6d97b16f11' into main 2022-10-23 16:34:44 -07:00
Sam Lantinga b5712c1bea Merge commit '11d53c84a7663d5a5861f3672990ca4b32376e3e' into main 2022-10-23 16:34:42 -07:00
Sam Lantinga 0d5fb2a0c2 Merge commit '94ac8ae08b19210efedd0e73b0c60010fb9308a0' into main 2022-10-23 16:34:40 -07:00
Sam Lantinga be3dc1acb5 Merge commit 'c6e89619794ed6307f9efb0b242a2cdb605e1dc3' into main 2022-10-23 16:34:38 -07:00
Sam Lantinga 3bc84acebc Merge commit 'd542f43b2aa23966913c08e4973793150e8073d0' into main 2022-10-23 16:34:36 -07:00
Sam Lantinga f20c2759f9 Merge commit 'f28cf2b0d3fa6b4b9c692b0aa04f2875a09e0dfa' into main 2022-10-23 16:34:34 -07:00
Sam Lantinga 284df27b5a Merge commit 'e7ab581d796aa83f7d028ea4249fdc66600df173' into main 2022-10-23 16:34:32 -07:00
Thomas Cashman 8db3a33872 #6433 Fix WINRT_IsScreenKeyboardShown on Xbox 2022-10-23 11:42:11 -07:00
Sam Lantinga 413500ab69 Replaced mouseWheelGesture with GCMouse support on iOS (thanks @russelltg!)
Fixes https://github.com/libsdl-org/SDL/issues/6411
2022-10-22 09:37:34 -07:00
Deve 2ebaafa6c9 Use translationInView for mouse wheel event 2022-10-22 09:31:39 -07:00
Anonymous Maarten c3b13346e0 On x86, pass -nodefaultlib to linker when wanting to avoid the C library 2022-10-22 09:28:00 -07:00
Simon McVittie d4d99e8c29 workflows: Check we can screen-scrape the SDL_REVISION from Linux builds
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-10-22 09:27:10 -07:00
Simon McVittie cfd5d8eb29 build: Regenerate ./configure
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-10-22 09:27:10 -07:00
Simon McVittie 4ca5ea5b7e build: Add a mechanism to mark builds with vendor info
Downstream distributors can use this to mark a version with their
preferred version information, like a Linux distribution package version
or the Steam revision it was built to be bundled into, or just to mark
it with the vendor it was built by or the environment it's intended to
be used in.

For instance, in Debian I'd use this by configuring with:

    --enable-vendor-info="${DEB_VENDOR} ${DEB_VERSION}"

to get a SDL_REVISION like:

    release-2.24.1-0-ga1d1946dc (Debian 2.24.1+dfsg-2)

which gives a Debian user enough information to track down the patches
and build-time configuration that were used for package revision 2.

In Autotools and CMake, this is a configure-time option like any other,
and will go into both SDL_REVISION (via SDL_revision.h) and
SDL_GetRevision().

In other build systems (MSVC, Xcode, etc.), defining the
SDL_VENDOR_INFO macro will get it into the output of SDL_GetRevision(),
although not SDL_REVISION.

Resolves: https://github.com/libsdl-org/SDL/issues/6418
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-10-22 09:27:10 -07:00
Simon McVittie 2dc788cb9f build: Expand version info in SDL_REVISION and SDL_GetRevision()
Instead of using a URL and git sha1, this uses `git describe` to
describe the version relative to the nearest previous git tag, which
gives a better indication of whether this is a release, a prerelease,
a slightly patched prerelease, or a long way after the last release
during active development.

This serves two purposes: it makes those APIs more informative, and it
also puts this information into the binary in a form that is easy to
screen-scrape using strings(1). For instance, if the bundled version of
SDL in a game has this, we can see at a glance what version it is.

It's also shorter than using the web address of the origin git
repository and the full git commit sha1.

Also write the computed version into a file ./VERSION in `make dist`
tarballs, so that when we build from a tarball on a system that doesn't
have git available, we still get the version details.

For the Perforce code path in showrev.sh, output the version number
followed by the Perforce revision, in a format reminiscent of
`git describe` (with p instead of g to indicate Perforce).

For the code path with no VCS available at all, put a suffix on the
version number to indicate that this is just a guess (we can't know
whether this SDL version is actually a git snapshot or has been
patched locally or similar).

Resolves: https://github.com/libsdl-org/SDL/issues/6418
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-10-22 09:27:10 -07:00
Sam Lantinga 5b8f830e34 Virtual joysticks don't need initial axis jitter protection
Fixes https://github.com/libsdl-org/SDL/issues/6426
2022-10-22 09:25:09 -07:00
Ozkan Sezer 0e1d19cf68 fix build errors resulting from -Wmisleading-indentation 2022-10-22 18:56:40 +03:00
Sam Lantinga a905a7869f Clear the previous bitmap when calculating a new window shape
Fixes https://github.com/libsdl-org/SDL/issues/6428
2022-10-22 08:50:18 -07:00
Ozkan Sezer 65a38a4015 hidapi, libusb: remove os/2 symbol load hack after os/2 loadso updates 2022-10-22 08:40:16 -07:00
Ozkan Sezer 3f1b5efcca os2 loadso improvements:
- SDL_LoadObject: upon failure, strip the .dll extension and retry,
  but only if module name has no path.
- SDL_LoadFunction: upon failure, retry with an underscore prepended,
  e.g. for gcc-built dlls.
2022-10-22 08:40:16 -07:00
Ozkan Sezer 3d415bc5d6 loadso, dlsym, SDL_LoadFunction: cleanup the underscored name path.
- strlcpy was passed a wrong buffer length parameter. has worked so
  far by luck.
- use memcpy instead of strlcpy for simplicity.
- 'append' has been a typo: should be 'prepend'.
2022-10-22 07:25:46 -04:00
Brad Smith f37db957f8 Use -lpthread on OpenBSD 2022-10-21 16:53:26 -07:00
Anonymous Maarten 5ed091c12d cmake: fix reporting of SDL_TESTS 2022-10-21 15:32:05 +02:00
Anonymous Maarten 0823b5973a cmake: fix finding wayland-libdecor
It was broken in 11d53c84a7
2022-10-21 15:31:43 +02:00
Ozkan Sezer 4264c0b674 os2: fix error message for SDL_LoadObject() 2022-10-21 11:21:40 +03:00
Anonymous Maarten 96361fc476 cmake: create and install sdl2.pc for MSVC & WATCOM 2022-10-20 19:02:31 +02:00
Anonymous Maarten 11d53c84a7 cmake: use pkg-config's library dirs as hint for finding a shared library 2022-10-20 19:01:28 +02:00
Anonymous Maarten 94ac8ae08b cmake: else() does not need an argument 2022-10-20 13:29:35 +02:00
Sam Lantinga c6e8961979 Define _USE_MATH_DEFINES for Visual Studio (thanks @pionere!)
Fixes https://github.com/libsdl-org/SDL/issues/3790
2022-10-19 08:05:47 -07:00
Anonymous Maarten d542f43b2a cmake: add SDL_INSTALL_CMAKEDIR cache variable to override location of cmake config files 2022-10-19 16:41:25 +02:00
Brad Smith f28cf2b0d3 Also remove the OpenBSD comment about OSS 2022-10-19 06:40:19 -07:00
Ryan C. Gordon e7ab581d79
coreaudio: Dispose of AudioQueue before waiting on the thread.
Otherwise the thread might block for a long time (more than 10 seconds!).
It's not clear to me why this happens, or why its safe to do this with a
resource that's still in use, but we have, until recently, always
disposed of the AudioQueue first, so changing back is probably okay.

Also changed the disposal to allow in-flight buffers to reach hardware;
otherwise you lose the last little bit of audio that's already been queued
but not played, which you can hear clearly in the loopwave test program.

Fixes #6377.
2022-10-19 09:14:16 -04:00
Sam Lantinga 5b6d36fd9f Merge commit 'aefc6b5bb57cd3aadc6964e26f2caac1d1c5f624' into main 2022-10-18 09:21:53 -07:00
Sam Lantinga 764e7c4f4b Merge commit '965ba1e09712fc57968d87c1cf60c541529fbd20' into main 2022-10-18 09:21:51 -07:00
Sam Lantinga 8b6f726546 Merge commit 'dfbb93dd0c4bcdea2a3edc0e3cb0f5dae153d16e' into main 2022-10-18 09:21:48 -07:00
Sam Lantinga 86695af483 Merge commit 'e8a4c23ce560dad786922e8d51496da2687e1723' into main 2022-10-18 09:21:46 -07:00
Sam Lantinga 8f7577d70a Merge commit '790fa3156cfee847a7c0b34986de0cd7fdd7438f' into main 2022-10-18 09:21:44 -07:00