Skip to content

sdl3-image: init at 3.2.4 - #384531

Merged
donovanglover merged 2 commits into
NixOS:masterfrom
evysgarden:add-package-sdl3-image
Mar 8, 2025
Merged

donovanglover merged 2 commits into
NixOS:masterfrom
evysgarden:add-package-sdl3-image

Conversation

@evysgarden

@evysgarden evysgarden commented Feb 23, 2025 •

Copy link
Copy Markdown
Contributor

SDL3_image has been released and is not in nixpkgs yet. sdl3 already is.
https://wiki.libsdl.org/SDL3_image/FrontPage

closes #383749

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch from bd51728 to d258e6a Compare February 23, 2025 15:03
@github-actions github-actions Bot added 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Feb 23, 2025
@NixOSInfra NixOSInfra added the 12.first-time contribution This PR is the author's first one; please be gentle! label Feb 23, 2025
@evysgarden evysgarden changed the title add package sdl3-image sdl3-image: 3.2.0 Feb 23, 2025
@evysgarden evysgarden changed the title sdl3-image: 3.2.0 sdl3-image: init at 3.2.0 Feb 23, 2025
@evysgarden

Copy link
Copy Markdown
Contributor Author

@ofborg eval
@ofborg build sdl3-image

@ethancedwards8

Copy link
Copy Markdown
Member

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 384531


aarch64-darwin

✅ 1 package built:
  • sdl3-image

Comment thread pkgs/by-name/sd/sdl3-image/package.nix Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

3.2.4 was recently released

@evysgarden evysgarden Mar 4, 2025 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SDL_Image >=3.2.2 depends on SDL3 3.2.6 (nixpkgs is at 3.2.2)

SDL3 3.2.6 has been merged. switched to sdl3-image 3.2.4

Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
@evysgarden

Copy link
Copy Markdown
Contributor Author

thx for the feedback ^^

implementing changes rn.
SDL3 needs to be updated for the newer versions so I'll stick to SDL3_Image 3.2.0 for now.

@github-actions github-actions Bot added the 8.has: maintainer-list (update) This PR changes `maintainers/maintainer-list.nix` label Mar 4, 2025
@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch 2 times, most recently from c66da70 to d637984 Compare March 4, 2025 13:52
@evysgarden

Copy link
Copy Markdown
Contributor Author

@ofborg build sdl3-image

@evysgarden

Copy link
Copy Markdown
Contributor Author

i have implemented the requested changes to my best abilities

@evysgarden
evysgarden requested a review from marcin-serwin March 4, 2025 14:29

@ethancedwards8 ethancedwards8 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'll have to squash all those commits. One commit per package + a maintainer commit

@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch from d637984 to e2a6267 Compare March 4, 2025 16:39
@evysgarden evysgarden changed the title sdl3-image: init at 3.2.0 sdl3-image: init at 3.2.4 Mar 4, 2025
@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch from e2a6267 to 50172db Compare March 4, 2025 16:41
@evysgarden

Copy link
Copy Markdown
Contributor Author

@ofborg build sdl3-image

@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch from 50172db to 6ebee94 Compare March 4, 2025 18:05

@marcin-serwin marcin-serwin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your commit messages need to follow contributing guidelines:

When adding yourself as maintainer in the same pull request, make a separate
commit with the message maintainers: add <handle>.

Format the commit messages in the following way:

(pkg-name): (from -> to | init at version | refactor | etc)

(Motivation for change. Link to release notes. Additional information.)

so

maintainers: add evythedemon
sdl3-image: init at 3.2.4

Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
Comment thread pkgs/by-name/sd/sdl3-image/package.nix Resolved
@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch from 6ebee94 to c3fbdf1 Compare March 4, 2025 18:24
@evysgarden

evysgarden commented Mar 4, 2025 •

Copy link
Copy Markdown
Contributor Author

implmented your suggestions, @marcin-serwin

@ofborg build sdl3-image

@evysgarden
evysgarden force-pushed the add-package-sdl3-image branch from c3fbdf1 to 0773546 Compare March 4, 2025 18:42
@wegank wegank added the 12.approvals: 2 This PR was reviewed and approved by two persons. label Mar 5, 2025
@donovanglover
donovanglover merged commit 36790a9 into NixOS:master Mar 8, 2025
@donovanglover

Copy link
Copy Markdown
Member

Grats on your first contribution to nixpkgs!

@evysgarden
evysgarden deleted the add-package-sdl3-image branch April 3, 2025 10:37
@Green-Sky

Copy link
Copy Markdown
Contributor

Is this going to get backported?

BTW, sdl image falls back to using STB image for png and jpeg, when the lib are not provided, which is a security nightmare. So I suggest providing those and explicitly disabling stb -DSDLIMAGE_BACKEND_STB=OFF .

Also jxl would be nice. :)

@evysgarden

Copy link
Copy Markdown
Contributor Author

Also jxl would be nice. :)

sure, though if you really need that feature, open an issue instead of discussing it here.

@evysgarden

Copy link
Copy Markdown
Contributor Author

BTW, sdl image falls back to using STB image for png and jpeg, when the lib are not provided, which is a security nightmare. So I suggest providing those and explicitly disabling stb -DSDLIMAGE_BACKEND_STB=OFF .

gonna look into that tmrw.

@marcin-serwin

Copy link
Copy Markdown
Contributor

BTW, sdl image falls back to using STB image for png and jpeg, when the lib are not provided, which is a security nightmare.

If I understood the code correctly then STB is actually preferred and it's the libs that are used as a fallback when it's disabled – see here. I've tried building it with libpng in buildInputs and it doesn't end up being linked to unless I explicitly disable the STB backend. I'm not familiar with STB security issues but if they're notable then I think the defaults should be changed upstream.

@evysgarden

Copy link
Copy Markdown
Contributor Author

Is this going to get backported?

#396924

@evysgarden evysgarden added the 9.needs: port to stable A PR needs a backport to the stable release. label Apr 7, 2025
@Green-Sky

Copy link
Copy Markdown
Contributor

BTW, sdl image falls back to using STB image for png and jpeg, when the lib are not provided, which is a security nightmare.

If I understood the code correctly then STB is actually preferred and it's the libs that are used as a fallback when it's disabled – see here. I've tried building it with libpng in buildInputs and it doesn't end up being linked to unless I explicitly disable the STB backend. I'm not familiar with STB security issues but if they're notable then I think the defaults should be changed upstream.

Oh.

I'm not familiar with STB security issues

It is just the general openness and sometimes time delays of fixes that make it a pain. (see project readme)

Personally I love stb libs and how easy they are to integrate and get going with your project. But I would not deploy them to actual production.

@mdaniels5757 mdaniels5757 added 8.has: port to stable This PR already has a backport to the stable release. and removed 9.needs: port to stable A PR needs a backport to the stable release. labels Jun 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

8.has: maintainer-list (update) This PR changes `maintainers/maintainer-list.nix` 8.has: port to stable This PR already has a backport to the stable release. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux. 12.approvals: 2 This PR was reviewed and approved by two persons. 12.first-time contribution This PR is the author's first one; please be gentle!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Package request: SDL3_Image

8 participants