Skip to content

Commit

Permalink
Merge commit '55b03c7493a7abed33cf803d1380a40fa8af903f'
Browse files Browse the repository at this point in the history
  • Loading branch information
Sibras committed Nov 6, 2022
2 parents ddb2acf + 55b03c7 commit 046d8d0
Show file tree
Hide file tree
Showing 27 changed files with 159 additions and 99 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ endif()
# See docs/release_checklist.md
set(SDL_MAJOR_VERSION 2)
set(SDL_MINOR_VERSION 24)
set(SDL_MICRO_VERSION 1)
set(SDL_MICRO_VERSION 2)
set(SDL_VERSION "${SDL_MAJOR_VERSION}.${SDL_MINOR_VERSION}.${SDL_MICRO_VERSION}")

# Set defaults preventing destination file conflicts
Expand Down Expand Up @@ -483,7 +483,7 @@ endforeach()
set_option(SDL_WAYLAND "Use Wayland video driver" ${UNIX_SYS})
dep_option(SDL_WAYLAND_SHARED "Dynamically load Wayland support" ON "SDL_WAYLAND" OFF)
dep_option(SDL_WAYLAND_LIBDECOR "Use client-side window decorations on Wayland" ON "SDL_WAYLAND" OFF)
dep_option(SDL_WAYLAND_LIBDECOR_SHARED "Dynamically load libdecor support" ON "SDL_WAYLAND_LIBDECOR" OFF)
dep_option(SDL_WAYLAND_LIBDECOR_SHARED "Dynamically load libdecor support" ON "SDL_WAYLAND_LIBDECOR;SDL_WAYLAND_SHARED" OFF)
dep_option(SDL_WAYLAND_QT_TOUCH "QtWayland server support for Wayland video driver" ON "SDL_WAYLAND" OFF)
set_option(SDL_RPI "Use Raspberry Pi video driver" ${UNIX_SYS})
set_option(SDL_COCOA "Use Cocoa video driver" ${APPLE})
Expand Down
2 changes: 1 addition & 1 deletion Makefile.os2
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
LIBNAME = SDL2
MAJOR_VERSION = 2
MINOR_VERSION = 24
MICRO_VERSION = 1
MICRO_VERSION = 2
VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(MICRO_VERSION)
DESCRIPTION = Simple DirectMedia Layer 2

Expand Down
6 changes: 3 additions & 3 deletions Makefile.w32
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@
LIBNAME = SDL2
MAJOR_VERSION = 2
MINOR_VERSION = 24
MICRO_VERSION = 1
MICRO_VERSION = 2
VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(MICRO_VERSION)
DESCRIPTION = Simple DirectMedia Layer 2

LIBHOME = .
DLLFILE = $(LIBHOME)/$(LIBNAME).dll
Expand All @@ -20,6 +19,8 @@ INCPATH+= -I"src/video/khronos"

LIBM = SDL2libm.lib
TLIB = SDL2test.lib
# user32.lib, gdi32.lib, ole32.lib and oleaut32.lib are actually
# among the default libraries in wlink.lnk for nt_dll linkage...
LIBS = user32.lib gdi32.lib winmm.lib imm32.lib ole32.lib oleaut32.lib shell32.lib setupapi.lib version.lib uuid.lib dxguid.lib $(LIBM)

CFLAGS = -bt=nt -d0 -q -bm -5s -fp5 -fpi87 -sg -oeatxhn -ei
Expand Down Expand Up @@ -253,7 +254,6 @@ $(LNKFILE): Makefile.w32
@%append $@ OPTION QUIET
@%append $@ OPTION IMPF=$(EXPFILE)
@%append $@ OPTION MAP=$(LIBHOME)/$^&.map
@%append $@ OPTION DESCRIPTION '@$#libsdl org:$(VERSION)$#@$(DESCRIPTION)'
@%append $@ OPTION ELIMINATE
@%append $@ OPTION SHOWDEAD

Expand Down
5 changes: 2 additions & 3 deletions VisualC/SDL/SDL.vcxproj.filters
Original file line number Diff line number Diff line change
Expand Up @@ -495,9 +495,6 @@
<ClInclude Include="..\..\src\haptic\SDL_haptic_c.h">
<Filter>haptic</Filter>
</ClInclude>
<ClInclude Include="..\..\src\hidapi\SDL_hidapi.h">
<Filter>hidapi</Filter>
</ClInclude>
<ClInclude Include="..\..\src\joystick\SDL_gamecontrollerdb.h">
<Filter>joystick</Filter>
</ClInclude>
Expand Down Expand Up @@ -835,6 +832,7 @@
<ClInclude Include="..\..\src\render\direct3d12\SDL_shaders_d3d12.h">
<Filter>render\direct3d12</Filter>
</ClInclude>
<ClInclude Include="..\..\src\hidapi\SDL_hidapi_c.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="..\..\src\audio\wasapi\SDL_wasapi.c" />
Expand Down Expand Up @@ -1351,6 +1349,7 @@
<ClCompile Include="..\..\src\render\direct3d12\SDL_shaders_d3d12.c">
<Filter>render\direct3d12</Filter>
</ClCompile>
<ClCompile Include="..\..\src\stdlib\SDL_mslibc.c" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="..\..\src\main\windows\version.rc" />
Expand Down
4 changes: 2 additions & 2 deletions Xcode/SDL/Info-Framework.plist
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>2.24.1</string>
<string>2.24.2</string>
<key>CFBundleSignature</key>
<string>SDLX</string>
<key>CFBundleVersion</key>
<string>2.24.1</string>
<string>2.24.2</string>
</dict>
</plist>
4 changes: 2 additions & 2 deletions Xcode/SDL/SDL.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -9397,7 +9397,7 @@
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DEPLOYMENT_POSTPROCESSING = YES;
DYLIB_COMPATIBILITY_VERSION = 2401.0.0;
DYLIB_CURRENT_VERSION = 2401.1.0;
DYLIB_CURRENT_VERSION = 2401.2.0;
DYLIB_INSTALL_NAME_BASE = "@rpath";
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_ALTIVEC_EXTENSIONS = YES;
Expand Down Expand Up @@ -9482,7 +9482,7 @@
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
DEBUG_INFORMATION_FORMAT = dwarf;
DYLIB_COMPATIBILITY_VERSION = 2401.0.0;
DYLIB_CURRENT_VERSION = 2401.1.0;
DYLIB_CURRENT_VERSION = 2401.2.0;
DYLIB_INSTALL_NAME_BASE = "@rpath";
ENABLE_STRICT_OBJC_MSGSEND = YES;
ENABLE_TESTABILITY = YES;
Expand Down
86 changes: 46 additions & 40 deletions cmake/sdlchecks.cmake
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
include(CMakeParseArguments)
macro(FindLibraryAndSONAME _LIB)
cmake_parse_arguments(FLAS "" "" "LIBDIRS" ${ARGN})

string(TOUPPER ${_LIB} _UPPERLNAME)
string(REGEX REPLACE "\\-" "_" _LNAME "${_UPPERLNAME}")

find_library(${_LNAME}_LIB ${_LIB})
find_library(${_LNAME}_LIB ${_LIB} PATHS ${FLAS_LIBDIRS})
if(${_LNAME}_LIB)
# reduce the library name for shared linking

Expand Down Expand Up @@ -131,7 +134,7 @@ macro(CheckPipewire)
if(SDL_PIPEWIRE_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic Pipewire loading")
endif()
FindLibraryAndSONAME("pipewire-0.3")
FindLibraryAndSONAME("pipewire-0.3" LIBDIRS ${PKG_PIPEWIRE_LIBRARY_DIRS})
if(SDL_PIPEWIRE_SHARED AND PIPEWIRE_0.3_LIB AND HAVE_SDL_LOADSO)
set(SDL_AUDIO_DRIVER_PIPEWIRE_DYNAMIC "\"${PIPEWIRE_0.3_LIB_SONAME}\"")
set(HAVE_PIPEWIRE_SHARED TRUE)
Expand Down Expand Up @@ -160,7 +163,7 @@ macro(CheckPulseAudio)
if(SDL_PULSEAUDIO_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic PulseAudio loading")
endif()
FindLibraryAndSONAME("pulse-simple")
FindLibraryAndSONAME("pulse-simple" LIBDIRS ${PKG_PULSEAUDIO_LIBRARY_DIRS})
if(SDL_PULSEAUDIO_SHARED AND PULSE_SIMPLE_LIB AND HAVE_SDL_LOADSO)
set(SDL_AUDIO_DRIVER_PULSEAUDIO_DYNAMIC "\"${PULSE_SIMPLE_LIB_SONAME}\"")
set(HAVE_PULSEAUDIO_SHARED TRUE)
Expand Down Expand Up @@ -189,7 +192,7 @@ macro(CheckJACK)
if(SDL_JACK_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic JACK audio loading")
endif()
FindLibraryAndSONAME("jack")
FindLibraryAndSONAME("jack" LIBDIRS ${PKG_JACK_LIBRARY_DIRS})
if(SDL_JACK_SHARED AND JACK_LIB AND HAVE_SDL_LOADSO)
set(SDL_AUDIO_DRIVER_JACK_DYNAMIC "\"${JACK_LIB_SONAME}\"")
set(HAVE_JACK_SHARED TRUE)
Expand Down Expand Up @@ -218,7 +221,7 @@ macro(CheckESD)
if(SDL_ESD_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic ESD loading")
endif()
FindLibraryAndSONAME(esd)
FindLibraryAndSONAME(esd LIBDIRS ${PKG_ESD_LIBRARY_DIRS})
if(SDL_ESD_SHARED AND ESD_LIB AND HAVE_SDL_LOADSO)
set(SDL_AUDIO_DRIVER_ESD_DYNAMIC "\"${ESD_LIB_SONAME}\"")
set(HAVE_ESD_SHARED TRUE)
Expand Down Expand Up @@ -312,7 +315,7 @@ macro(CheckSNDIO)
if(SDL_SNDIO_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic sndio loading")
endif()
FindLibraryAndSONAME("sndio")
FindLibraryAndSONAME("sndio" LIBDIRS ${PKG_SNDIO_LIBRARY_DIRS})
if(SDL_SNDIO_SHARED AND SNDIO_LIB AND HAVE_SDL_LOADSO)
set(SDL_AUDIO_DRIVER_SNDIO_DYNAMIC "\"${SNDIO_LIB_SONAME}\"")
set(HAVE_SNDIO_SHARED TRUE)
Expand Down Expand Up @@ -341,7 +344,7 @@ macro(CheckFusionSound)
if(FUSIONSOUND_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic FusionSound loading")
endif()
FindLibraryAndSONAME("fusionsound")
FindLibraryAndSONAME("fusionsound" LIBDIRS ${PKG_FUSIONSOUND_LIBRARY_DIRS})
if(FUSIONSOUND_SHARED AND FUSIONSOUND_LIB AND HAVE_SDL_LOADSO)
set(SDL_AUDIO_DRIVER_FUSIONSOUND_DYNAMIC "\"${FUSIONSOUND_LIB_SONAME}\"")
set(HAVE_FUSIONSOUND_SHARED TRUE)
Expand Down Expand Up @@ -637,9 +640,11 @@ endmacro()
# - HAVE_SDL_LOADSO opt
macro(CheckWayland)
if(SDL_WAYLAND)
pkg_check_modules(WAYLAND "wayland-client>=1.18" wayland-egl wayland-cursor egl "xkbcommon>=0.5.0")
set(WAYLAND_FOUND FALSE)
pkg_check_modules(PKG_WAYLAND "wayland-client>=1.18" wayland-egl wayland-cursor egl "xkbcommon>=0.5.0")

if(WAYLAND_FOUND)
if(PKG_WAYLAND_FOUND)
set(WAYLAND_FOUND TRUE)
find_program(WAYLAND_SCANNER NAMES wayland-scanner REQUIRED)
execute_process(
COMMAND ${WAYLAND_SCANNER} --version
Expand All @@ -662,8 +667,8 @@ macro(CheckWayland)
endif()

if(WAYLAND_FOUND)
target_link_directories(sdl-build-options INTERFACE "${WAYLAND_LIBRARY_DIRS}")
target_include_directories(sdl-build-options INTERFACE "${WAYLAND_INCLUDE_DIRS}")
target_link_directories(sdl-build-options INTERFACE "${PKG_WAYLAND_LIBRARY_DIRS}")
target_include_directories(sdl-build-options INTERFACE "${PKG_WAYLAND_INCLUDE_DIRS}")

set(HAVE_WAYLAND TRUE)
set(HAVE_SDL_VIDEO TRUE)
Expand All @@ -689,36 +694,36 @@ macro(CheckWayland)
if(SDL_WAYLAND_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic Wayland loading")
endif()
FindLibraryAndSONAME(wayland-client)
FindLibraryAndSONAME(wayland-egl)
FindLibraryAndSONAME(wayland-cursor)
FindLibraryAndSONAME(xkbcommon)
FindLibraryAndSONAME(wayland-client LIBDIRS ${PKG_WAYLAND_LIBRARY_DIRS})
FindLibraryAndSONAME(wayland-egl LIBDIRS ${PKG_WAYLAND_LIBRARY_DIRS})
FindLibraryAndSONAME(wayland-cursor LIBDIRS ${PKG_WAYLAND_LIBRARY_DIRS})
FindLibraryAndSONAME(xkbcommon LIBDIRS ${PKG_WAYLAND_LIBRARY_DIRS})
if(SDL_WAYLAND_SHARED AND WAYLAND_CLIENT_LIB AND WAYLAND_EGL_LIB AND WAYLAND_CURSOR_LIB AND XKBCOMMON_LIB AND HAVE_SDL_LOADSO)
set(SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC "\"${WAYLAND_CLIENT_LIB_SONAME}\"")
set(SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC_EGL "\"${WAYLAND_EGL_LIB_SONAME}\"")
set(SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC_CURSOR "\"${WAYLAND_CURSOR_LIB_SONAME}\"")
set(SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC_XKBCOMMON "\"${XKBCOMMON_LIB_SONAME}\"")
set(HAVE_WAYLAND_SHARED TRUE)
else()
list(APPEND EXTRA_LIBS ${WAYLAND_LIBRARIES})
list(APPEND EXTRA_LIBS ${PKG_WAYLAND_LIBRARIES})
endif()

if(SDL_WAYLAND_LIBDECOR)
pkg_check_modules(LIBDECOR libdecor-0)
if(LIBDECOR_FOUND)
pkg_check_modules(PKG_LIBDECOR libdecor-0)
if(PKG_LIBDECOR_FOUND)
set(HAVE_WAYLAND_LIBDECOR TRUE)
set(HAVE_LIBDECOR_H 1)
target_link_directories(sdl-build-options INTERFACE "${LIBDECOR_LIBRARY_DIRS}")
target_include_directories(sdl-build-options INTERFACE "${LIBDECOR_INCLUDE_DIRS}")
target_link_directories(sdl-build-options INTERFACE "${PKG_LIBDECOR_LIBRARY_DIRS}")
target_include_directories(sdl-build-options INTERFACE "${PKG_LIBDECOR_INCLUDE_DIRS}")
if(SDL_WAYLAND_LIBDECOR_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic libdecor loading")
endif()
FindLibraryAndSONAME(decor-0)
FindLibraryAndSONAME(decor-0 LIBDIRS ${PKG_LIBDECOR_LIBRARY_DIRS})
if(SDL_WAYLAND_LIBDECOR_SHARED AND DECOR_0_LIB AND HAVE_SDL_LOADSO)
set(HAVE_LIBDECOR_SHARED TRUE)
set(HAVE_WAYLAND_LIBDECOR_SHARED TRUE)
set(SDL_VIDEO_DRIVER_WAYLAND_DYNAMIC_LIBDECOR "\"${DECOR_0_LIB_SONAME}\"")
else()
list(APPEND EXTRA_LIBS ${LIBDECOR_LIBRARIES})
list(APPEND EXTRA_LIBS ${PKG_LIBDECOR_LIBRARIES})
endif()
endif()
endif()
Expand Down Expand Up @@ -764,7 +769,7 @@ macro(CheckDirectFB)
if(SDL_DIRECTFB_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic DirectFB loading")
endif()
FindLibraryAndSONAME("directfb")
FindLibraryAndSONAME("directfb" LIBDIRS ${PKG_DIRECTFB_LIBRARY_DIRS})
if(SDL_DIRECTFB_SHARED AND DIRECTFB_LIB AND HAVE_SDL_LOADSO)
set(SDL_VIDEO_DRIVER_DIRECTFB_DYNAMIC "\"${DIRECTFB_LIB_SONAME}\"")
set(HAVE_DIRECTFB_SHARED TRUE)
Expand Down Expand Up @@ -1170,19 +1175,19 @@ macro(CheckHIDAPI)
if(SDL_HIDAPI)
if(SDL_HIDAPI_LIBUSB)
set(HAVE_LIBUSB FALSE)
pkg_check_modules(LIBUSB libusb-1.0)
if(LIBUSB_FOUND)
check_include_file(libusb.h HAVE_LIBUSB_H ${LIBUSB_CFLAGS})
pkg_check_modules(PKG_LIBUSB libusb-1.0)
if(PKG_LIBUSB_FOUND)
check_include_file(libusb.h HAVE_LIBUSB_H ${PKG_LIBUSB_CFLAGS})
if(HAVE_LIBUSB_H)
set(HAVE_LIBUSB TRUE)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${LIBUSB_CFLAGS}")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${PKG_LIBUSB_CFLAGS}")
if(HIDAPI_ONLY_LIBUSB)
list(APPEND EXTRA_LIBS ${LIBUSB_LIBRARIES})
list(APPEND EXTRA_LIBS ${PKG_LIBUSB_LIBRARIES})
elseif(OS2)
set(SDL_LIBUSB_DYNAMIC "\"usb100.dll\"")
else()
# libusb is loaded dynamically, so don't add it to EXTRA_LIBS
FindLibraryAndSONAME("usb-1.0")
FindLibraryAndSONAME("usb-1.0" LIBDIRS ${PKG_LIBUSB_LIBRARY_DIRS})
if(USB_1.0_LIB)
set(SDL_LIBUSB_DYNAMIC "\"${USB_1.0_LIB_SONAME}\"")
endif()
Expand All @@ -1192,6 +1197,7 @@ macro(CheckHIDAPI)
if(HIDAPI_ONLY_LIBUSB AND NOT HAVE_LIBUSB)
set(HAVE_HIDAPI FALSE)
endif()
set(HAVE_HIDAPI_LIBUSB ${HAVE_LIBUSB})
endif()

if(HAVE_HIDAPI)
Expand All @@ -1211,6 +1217,8 @@ macro(CheckHIDAPI)
file(GLOB HIDAPI_JOYSTICK_SOURCES ${SDL2_SOURCE_DIR}/src/joystick/hidapi/*.c)
list(APPEND SOURCE_FILES ${HIDAPI_JOYSTICK_SOURCES})
endif()
else()
set(SDL_HIDAPI_DISABLED 1)
endif()
else()
set(SDL_HIDAPI_DISABLED 1)
Expand Down Expand Up @@ -1265,33 +1273,31 @@ endmacro()
# - HAVE_SDL_LOADSO opt
macro(CheckKMSDRM)
if(SDL_KMSDRM)
pkg_check_modules(KMSDRM libdrm gbm egl)
if(KMSDRM_FOUND AND HAVE_OPENGL_EGL)
link_directories(
${KMSDRM_LIBRARY_DIRS}
)
target_include_directories(sdl-build-options INTERFACE "${KMSDRM_INCLUDE_DIRS}")
pkg_check_modules(PKG_KMSDRM libdrm gbm egl)
if(PKG_KMSDRM_FOUND AND HAVE_OPENGL_EGL)
target_link_directories(sdl-build-options INTERFACE ${PKG_KMSDRM_LIBRARY_DIRS})
target_include_directories(sdl-build-options INTERFACE "${PKG_KMSDRM_INCLUDE_DIRS}")
set(HAVE_KMSDRM TRUE)
set(HAVE_SDL_VIDEO TRUE)

file(GLOB KMSDRM_SOURCES ${SDL2_SOURCE_DIR}/src/video/kmsdrm/*.c)
list(APPEND SOURCE_FILES ${KMSDRM_SOURCES})

list(APPEND EXTRA_CFLAGS ${KMSDRM_CFLAGS})
list(APPEND EXTRA_CFLAGS ${PKG_KMSDRM_CFLAGS})

set(SDL_VIDEO_DRIVER_KMSDRM 1)

if(SDL_KMSDRM_SHARED AND NOT HAVE_SDL_LOADSO)
message_warn("You must have SDL_LoadObject() support for dynamic KMS/DRM loading")
endif()
if(SDL_KMSDRM_SHARED AND HAVE_SDL_LOADSO)
FindLibraryAndSONAME(drm)
FindLibraryAndSONAME(gbm)
FindLibraryAndSONAME(drm LIBDIRS ${PKG_KMSDRM_LIBRARY_DIRS})
FindLibraryAndSONAME(gbm LIBDIRS ${PKG_KMSDRM_LIBRARY_DIRS})
set(SDL_VIDEO_DRIVER_KMSDRM_DYNAMIC "\"${DRM_LIB_SONAME}\"")
set(SDL_VIDEO_DRIVER_KMSDRM_DYNAMIC_GBM "\"${GBM_LIB_SONAME}\"")
set(HAVE_KMSDRM_SHARED TRUE)
else()
list(APPEND EXTRA_LIBS ${KMSDRM_LIBRARIES})
list(APPEND EXTRA_LIBS ${PKG_KMSDRM_LIBRARIES})
endif()
endif()
endif()
Expand Down
5 changes: 3 additions & 2 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -3438,7 +3438,7 @@ orig_CFLAGS="$CFLAGS"
# See docs/release_checklist.md
SDL_MAJOR_VERSION=2
SDL_MINOR_VERSION=24
SDL_MICRO_VERSION=1
SDL_MICRO_VERSION=2
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION

SDL_BINARY_AGE=`expr $SDL_MINOR_VERSION \* 100 + $SDL_MICRO_VERSION`
Expand Down Expand Up @@ -17952,7 +17952,8 @@ test -n "$SORT" || SORT="false"

if ! "$SORT" -V </dev/null >/dev/null
then :
as_fn_error $? "GNU sort(1) is required" "$LINENO" 5
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: sort(1) that supports the -V option is required to find dynamic libraries" >&5
printf "%s\n" "$as_me: WARNING: sort(1) that supports the -V option is required to find dynamic libraries" >&2;}
fi

# Check whether --enable-largefile was given.
Expand Down
4 changes: 2 additions & 2 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ dnl Set various version strings - taken gratefully from the GTk sources
# See docs/release_checklist.md
SDL_MAJOR_VERSION=2
SDL_MINOR_VERSION=24
SDL_MICRO_VERSION=1
SDL_MICRO_VERSION=2
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION

SDL_BINARY_AGE=`expr $SDL_MINOR_VERSION \* 100 + $SDL_MICRO_VERSION`
Expand Down Expand Up @@ -71,7 +71,7 @@ if [ test -z "$AWK" ]; then
fi

AC_CHECK_PROGS([SORT], [gsort sort], [false])
AS_IF([! "$SORT" -V </dev/null >/dev/null], [AC_MSG_ERROR([GNU sort(1) is required])])
AS_IF([! "$SORT" -V </dev/null >/dev/null], [AC_MSG_WARN([sort(1) that supports the -V option is required to find dynamic libraries])])

dnl 64-bit file offsets if possible unless --disable-largefile is specified
AC_SYS_LARGEFILE
Expand Down
4 changes: 2 additions & 2 deletions include/SDL_stdinc.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,9 @@
# include <ctype.h>
#endif
#ifdef HAVE_MATH_H
# if defined(__WINRT__)
# if defined(_MSC_VER)
/* Defining _USE_MATH_DEFINES is required to get M_PI to be defined on
WinRT. See http://msdn.microsoft.com/en-us/library/4hwaceh6.aspx
Visual Studio. See http://msdn.microsoft.com/en-us/library/4hwaceh6.aspx
for more information.
*/
# define _USE_MATH_DEFINES
Expand Down
Loading

0 comments on commit 046d8d0

Please sign in to comment.