Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 0 additions & 26 deletions pkgs/by-name/sd/SDL1/find-headers.patch

This file was deleted.

156 changes: 0 additions & 156 deletions pkgs/by-name/sd/SDL1/package.nix

This file was deleted.

16 changes: 0 additions & 16 deletions pkgs/by-name/sd/SDL1/setup-hook.sh

This file was deleted.

16 changes: 0 additions & 16 deletions pkgs/by-name/sd/SDL_image/clang16-webp-errors.patch

This file was deleted.

32 changes: 14 additions & 18 deletions pkgs/by-name/sd/SDL_image/package.nix
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
lib,
SDL,
fetchpatch,
fetchurl,
fetchFromGitHub,
giflib,
libXpm,
libjpeg,
Expand All @@ -11,29 +10,20 @@
libwebp,
pkg-config,
stdenv,
unstableGitUpdater,
}:

stdenv.mkDerivation (finalAttrs: {
pname = "SDL_image";
version = "1.2.12";
version = "1.2.12-unstable-2025-02-13";

src = fetchurl {
url = "https://www.libsdl.org/projects/SDL_image/release/SDL_image-${finalAttrs.version}.tar.gz";
hash = "sha256-C5ByKYRWEATehIR3RNVmgJ27na9zKp5QO5GhtahOVpk=";
src = fetchFromGitHub {
owner = "libsdl-org";
repo = "SDL_image";
rev = "74e8d577216e3c3a969e67b68b2e4769fcbf8fdd";
hash = "sha256-WSNH7Pw/tL5rgPQtOjxRGp2UlYSJJmXS2YQS+fAkXSc=";
};

patches = [
# Fixed security vulnerability in XCF image loader
(fetchpatch {
name = "CVE-2017-2887";
url = "https://github.com/libsdl-org/SDL_image/commit/e7723676825cd2b2ffef3316ec1879d7726618f2.patch";
includes = [ "IMG_xcf.c" ];
hash = "sha256-Z0nyEtE1LNGsGsN9SFG8ZyPDdunmvg81tUnEkrJQk5w=";
})
# Fixes incompatible function pointer type errors with clang 16
./clang16-webp-errors.patch
];

configureFlags = [
# Disable dynamic loading or else dlopen will fail because of no proper
# rpath
Expand Down Expand Up @@ -70,6 +60,12 @@ stdenv.mkDerivation (finalAttrs: {

strictDeps = true;

passthru.updateScript = unstableGitUpdater {
tagFormat = "release-1.*";
tagPrefix = "release-";
branch = "SDL-1.2";
};

meta = {
homepage = "http://www.libsdl.org/projects/SDL_image/";
description = "SDL image library";
Expand Down
9 changes: 9 additions & 0 deletions pkgs/by-name/sd/SDL_mixer/package.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
pkg-config,
smpeg,
stdenv,
# passthru.tests
onscripter-en,
# Boolean flags
enableNativeMidi ? false,
enableSdltest ? (!stdenv.hostPlatform.isDarwin),
Expand All @@ -20,6 +22,9 @@ stdenv.mkDerivation (finalAttrs: {
pname = "SDL_mixer";
version = "1.2.12";

# word of caution: while there is a somewhat maintained SDL-1.2 branch on
# https://github.com/libsdl-org/SDL_mixer, it switches from smpeg to mpg123 which
# breaks autoconf in a bunch of packages, it's better to cherry-pick patches as needed
src = fetchurl {
url = "http://www.libsdl.org/projects/SDL_mixer/release/SDL_mixer-${finalAttrs.version}.tar.gz";
hash = "sha256-FkQwgnmpdXmQSeSCavLPx4fK0quxGqFFYuQCUh+GmSo=";
Expand Down Expand Up @@ -102,6 +107,10 @@ stdenv.mkDerivation (finalAttrs: {

strictDeps = true;

passthru.tests = {
inherit onscripter-en;
};

meta = {
description = "SDL multi-channel audio mixer library";
homepage = "http://www.libsdl.org/projects/SDL_mixer/";
Expand Down
19 changes: 14 additions & 5 deletions pkgs/by-name/sd/SDL_net/package.nix
Original file line number Diff line number Diff line change
@@ -1,20 +1,23 @@
{
lib,
SDL,
fetchurl,
fetchFromGitHub,
pkg-config,
stdenv,
unstableGitUpdater,
# Boolean flags
enableSdltest ? (!stdenv.hostPlatform.isDarwin),
}:

stdenv.mkDerivation (finalAttrs: {
pname = "SDL_net";
version = "1.2.8";
version = "1.2.8-unstable-2024-04-23";

src = fetchurl {
url = "http://www.libsdl.org/projects/SDL_net/release/SDL_net-${finalAttrs.version}.tar.gz";
hash = "sha256-X0p6i7iE95PCeKw/NxO+QZgMXu3M7P8CYEETR3FPrLQ=";
src = fetchFromGitHub {
owner = "libsdl-org";
repo = "SDL_net";
rev = "0043be2e559f8d562d04bf62d6e3f4162ed8edad";
hash = "sha256-/W1Mq6hzJNNwpcx+VUT4DRGP3bE06GGMbYDGHBc4XlQ=";
};

nativeBuildInputs = [
Expand All @@ -32,6 +35,12 @@ stdenv.mkDerivation (finalAttrs: {

strictDeps = true;

passthru.updateScript = unstableGitUpdater {
tagFormat = "release-1.*";
tagPrefix = "release-";
branch = "SDL-1.2";
};

meta = {
homepage = "https://github.com/libsdl-org/SDL_net";
description = "SDL networking library";
Expand Down
Loading