File mingw64-SDL3.spec of Package mingw64-SDL3

#
# spec file for package mingw64-SDL3
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


Name:           mingw64-SDL3
%define lname   mingw64-libSDL3
Version:        3.2.16
Release:        0
Summary:        Simple DirectMedia Layer Library
License:        Zlib
Group:          Development/Libraries/X11
URL:            https://libsdl.org/
#Git-Clone:     https://github.com/libsdl-org/SDL
Source:         https://github.com/libsdl-org/SDL/releases/download/release-%version/SDL3-%version.tar.gz
Source2:        https://github.com/libsdl-org/SDL/releases/download/release-%version/SDL3-%version.tar.gz.sig
Source3:        %name.keyring
BuildRequires:  mingw64-cross-cmake
BuildRequires:  mingw64-cross-gcc-c++
BuildRequires:  mingw64-cross-pkg-config
BuildRequires:  nasm
BuildArch:      noarch
%_mingw64_package_header_debug

%description
This is the "Simple DirectMedia Layer" library. It provides a generic
API for access to audio, keyboard, mouse, and display framebuffer
across multiple platforms.

%package -n %lname
Summary:        Simple DirectMedia Layer Library for MinGW-i686
Group:          System/Libraries
Provides:       SDL3 = %version-%release

%description -n %lname
This is the "Simple DirectMedia Layer" library. It provides a generic
API for access to audio, keyboard, mouse, and display framebuffer
across multiple platforms.

%package -n mingw64-libSDL3-devel
Summary:        SDL3 Library Developer Files
Group:          Development/Libraries/X11
Provides:       mingw64-SDL3-devel = %version-%release
Requires:       %lname = %version-%release

%description -n mingw64-libSDL3-devel
This package contains files needed for development with the SDL3
library.

%_mingw64_debug_package

%prep
%autosetup -n SDL3-%version

%build
%_mingw64_cmake \
%ifarch %ix86
	-DSDL_MMX:BOOL=OFF -DSDL_SSE:BOOL=OFF -DSDL_SSE2:BOOL=OFF \
%endif
	-DSDL_SSE3:BOOL=OFF -DSDL_3DNOW:BOOL=OFF
%make_build

%install
%_mingw64_cmake_install
rm %buildroot/%_mingw64_datadir/licenses/SDL3/LICENSE.txt

%files -n %lname
%license LICENSE.txt
%_mingw64_bindir/SDL3.dll

%files -n mingw64-libSDL3-devel
%_mingw64_libdir/libSDL3.dll.a
%_mingw64_libdir/libSDL3_test.a
%_mingw64_includedir/SDL3/
%_mingw64_libdir/pkgconfig/sdl3.pc
%_mingw64_libdir/cmake/SDL3/

%changelog
openSUSE Build Service is sponsored by