Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rawtherapee: Fix glibc-2.34 malloc build error #169732

Merged
merged 2 commits into from Apr 23, 2022
Merged

rawtherapee: Fix glibc-2.34 malloc build error #169732

merged 2 commits into from Apr 23, 2022

Conversation

ghost
Copy link

@ghost ghost commented Apr 22, 2022

Description of changes

This patch was contributed to https://github.com/Beep6581/RawTherapee by @Floessie. It's upstream and will have to be removed once rawtherapee-5.9 is packaged.

Fixes the following build error:

<..>-glibc-2.34-115-dev/include/wchar.h:582:24: error: 'malloc' attribute argument 1 is ambiguous
  582 |   __attribute_malloc__ __attr_dealloc_fclose;

For the upstream discussion, see Beep6581/RawTherapee#6324.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • 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/)
  • 22.05 Release Notes (or backporting 21.11 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
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

FOR MAINTAINERS: This patch will have to be removed once rawtherapee-5.9
is packaged.

Fixes the following rtengine.dir/myfile.cc.o build error:
<..>-glibc-2.34-115-dev/include/wchar.h:582:24: error: 'malloc' attribute argument 1 is ambiguous
  582 |   __attribute_malloc__ __attr_dealloc_fclose;

For the upstream discussion, see Beep6581/RawTherapee#6324.
Copy link
Contributor

@jcumming jcumming left a comment

Choose a reason for hiding this comment

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

Thanks for fixing this!

I would like 2 changes:

@ghost
Copy link
Author

ghost commented Apr 22, 2022

@jcumming

  1. Done (didn't fixup because that'll bother the upstream people, thanks Github, but I can if you want me to).
  2. It wouldn't be straightforward, since the upstream commit does not cleanly apply to 5.8, and I had to modify the patch (i.e. add the last two hunks by hand since those functions are gone from the dev branch).

@ofborg ofborg bot requested a review from jcumming April 22, 2022 15:35
Copy link
Contributor

@jcumming jcumming left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@ajs124 ajs124 merged commit 30b6651 into NixOS:master Apr 23, 2022
@ghost ghost deleted the rawtherapee-glibc-malloc branch April 24, 2022 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants