158 Commits

Author SHA1 Message Date
Doron Behar
1af2d89b84 zlib: fix mingw build target (#571545) 2026-10-20 12:10:52 +00:00
Hans Joachim Kliemeck
bdac6308f0 zlib: backport fix for CVE-2026-85091
df84af25dc
2026-10-08 13:38:00 +00:00
Greg Hellings
92e7cd558e zlib: fix mingw build target
MinGW with LLVM compilers (e.g. pkgsCross.ucrtAarch64) do not support
that flag. It causes the configure script to incorrectly miss many of
its checks and the final link step fails, all complaining that this
argument is unknown. Removing it from MinGW targets only, in order to
not disturb any other usages
2026-10-07 19:57:20 -05:00
Artemis Tosini
82e9e3c3e8 zlib: fix shared library with modern llvm bintools
On FreeBSD and other platforms using modern bintools,
the linker will fail if given undefined versions in the version map.

The zlib configure script in its infinite wisdom uses an incorrect
version script during its test compile to determine if shared libraries
work, so always fails.
2026-10-02 12:02:47 -04:00
seth
785ec6b49a zlib: use default configure script on windows
This avoids the pitfalls of win32/Makefile.gcc (which prevents building
on compilers other than gcc without patching and has non-standard
installation behavior) and fixes cross compilation for ucrtAarch64

Putting the DLL's in `$out/bin` was given the approval of:

John Ericson <John.Ericson@Obsidian.Systems>
2026-08-19 17:50:14 +03:00
Doron Behar
51044d203a zlib: remove not needed anymore lld linker workaround
Tested that with this change the packages
`pkgsCross.x86_64-{freebsd,openbsd}.zlib` build from an `x86_64-linux`
build platform, and that their hashes actually are changed due to this.
2026-08-19 17:49:34 +03:00
Stefan Frijters
56f1baddca zlib: enable structuredAttrs 2026-08-03 00:51:21 +02:00
Alexandre Esteves
23ee096620 zlib: fix build on s390x 2026-03-24 18:36:26 +00:00
nixpkgs-ci[bot]
23ee7d594c Merge master into staging-next 2026-03-14 00:21:49 +00:00
Alexander Bantyev
2839911e81 various: add security-review team as a maintainer
Adds the @NixOS/security-review team as a maintainer to multiple
packages deemed to be important security-wise.

For the motivation of the package list, see:
https://github.com/NixOS/nixpkgs/issues/494349#issuecomment-4005099033
2026-03-05 15:19:44 +01:00
K900
cbf3eae457 Merge remote-tracking branch 'origin/staging-next' into staging 2026-02-24 09:56:30 +03:00
David McFarland
65346a4e79 zlib: fix cygwin build
Cygwin currently uses the same makefile as Windows, so it needs the same
workaround.
2026-02-23 22:36:31 -04:00
Doron Behar
b56433bafc zlib: simplify arguments & explain --shared & --static 2026-02-20 16:37:10 +02:00
Doron Behar
286186b380 zlib: always apply all substitutions
And use `--replace-fail` for Darwin substitutions.

Make it easier to find wrong substitutions relevant for platforms other
then your own.
2026-02-19 13:37:51 +02:00
Michael Daniels
cdb47d5b88 Merge branch 'staging-next' into staging 2026-02-17 19:55:41 -05:00
Martin Weinelt
1400e45293 zlib: 1.3.1 -> 1.3.2 (#491464) 2026-02-17 21:42:35 +00:00
Martin Weinelt
0f8161a0ef zlib: 1.3.1 -> 1.3.2
https://github.com/madler/zlib/releases/tag/v1.3.2
https://github.com/madler/zlib/compare/v1.3.1...v1.3.2
https://7asecurity.com/reports/pentest-report-zlib-RC1.1.pdf
2026-02-17 19:38:10 +01:00
Marcin Serwin
78524d5074 Revert "zlib: 1.3.1.2"
This reverts commit 6613b0c517.

This tag is not meant to be packaged, see
<https://github.com/madler/zlib/discussions/1128>.

Signed-off-by: Marcin Serwin <marcin@serwin.dev>
2026-02-16 16:12:33 +01:00
Sandro
290c04860a zlib: 1.3.1 -> 1.3.1.2 (#480369) 2026-02-16 13:18:17 +00:00
Marcin Serwin
09fafb198f zlib: disable static output on windows
The install script ignores the configured libdir in case of
windows. We could move it manually like it was done before
<https://github.com/NixOS/nixpkgs/pull/476830> but even before that we
did not move `libz.dll.a` so I think it makes sense to just disable this
split on windows.

Fixes: https://github.com/NixOS/nixpkgs/pull/476830#issuecomment-3902993079
Signed-off-by: Marcin Serwin <marcin@serwin.dev>
2026-02-15 10:20:45 +01:00
nixpkgs-ci[bot]
e217c74eac Merge staging-next into staging 2026-02-06 18:16:24 +00:00
Markus Sütter
196b385317 various: add meta.identifier.cpeParts to a batch of packages 2026-02-02 09:22:55 +01:00
Hans Joachim Kliemeck
6613b0c517 zlib: 1.3.1.2 2026-01-15 14:16:42 +01:00
Marcin Serwin
ff59162e82 zlib: fix static library path in pkg-config module
Specify the correct paths for installation in configuration phase. This
fixes the created pkg-config module and saves us from needing to move
files manually into the desired outputs.

Fixes: https://github.com/NixOS/nixpkgs/issues/66461
Signed-off-by: Marcin Serwin <marcin@serwin.dev>
2026-01-04 12:12:51 +01:00
Ihar Hrachyshka
567e8dfd8e treewide: clean up 'meta = with' pattern
This commit was created by a combination of scripts and tools:
- an ast-grep script to prefix things in meta with `lib.`,
- a modified nixf-diagnose / nixf combination to remove unused `with
lib;`, and
- regular nixfmt.

Co-authored-by: Wolfgang Walther <walther@technowledgy.de>
2025-12-10 18:09:49 +01:00
David McFarland
3cb108ca9c zlib: fix cygwin build 2025-12-05 15:44:42 -04:00
Wolfgang Walther
5a0711127c treewide: run nixfmt 1.0.0 2025-07-24 13:55:40 +02:00
Peder Bergebakken Sundt
5aba99242e treewide: fix typos in comments
Made with

```shell
git restore .
fd '\.nix$' pkgs/ --type f -j1 -x bash -xc "$(cat <<"EOF"
    typos --no-check-filenames --write-changes "$1"
    git diff --exit-code "$1" && exit
    #( git diff "$1" | grep -qE "^\+ +[^# ]") && git restore "$1"
    count1="$( bat --language nix --diff --style changes "$1" --theme "Monokai Extended" --color always | aha --no-header | grep -E '^<span style="color:olive;">~</span> ' | wc -l )"
    count2="$( bat --language nix --diff --style changes "$1" --theme "Monokai Extended" --color always | aha --no-header | grep -E '^<span style="color:olive;">~</span> (<span style="color:#f8f8f2;"> *</span>)?<span style="color:#75715e;">.*</span>$' | wc -l )"
    [[ $count1 -ne $count2 ]] && git restore "$1"
EOF
)" -- {}
```

and filtered with `GIT_DIFF_OPTS='--unified=15' git -c interactive.singleKey=true add --patch`

I initially tried using the tree-sitter cli, python bindings and even ast-grep through various means, but this is what I ended up with.
2025-02-24 10:44:41 +01:00
Silvan Mosberger
4f0dadbf38 treewide: format all inactive Nix files
After final improvements to the official formatter implementation,
this commit now performs the first treewide reformat of Nix files using it.
This is part of the implementation of RFC 166.

Only "inactive" files are reformatted, meaning only files that
aren't being touched by any PR with activity in the past 2 months.
This is to avoid conflicts for PRs that might soon be merged.
Later we can do a full treewide reformat to get the rest,
which should not cause as many conflicts.

A CI check has already been running for some time to ensure that new and
already-formatted files are formatted, so the files being reformatted here
should also stay formatted.

This commit was automatically created and can be verified using

    nix-build a08b3a4d19.tar.gz \
      --argstr baseRev b32a094368
    result/bin/apply-formatting $NIXPKGS_PATH
2024-12-10 20:26:33 +01:00
Audrey Dutcher
6234b3e818 zlib: link with --undefined-version on lld 2024-05-07 09:39:14 +02:00
Sergei Trofimovich
5c5f9bf221 zlib: 1.3 -> 1.3.1
Changes: https://github.com/madler/zlib/releases/tag/v1.3.1
2024-01-24 20:00:41 +00:00
github-actions[bot]
b4fdbf27f2 Merge master into staging-next 2023-09-09 06:01:15 +00:00
Moritz Angermann
a81e3dcd75 treewide: replace libc == "msvcrt" with isMinGW
msvcrt is only one of the libcs in MinGW. We therefore
replace explictly testing for msvcrt with the isMinGW
predicate. This lays the foundation for ucrt64 support.
2023-09-08 10:56:08 +00:00
Sergei Trofimovich
20a575b98e zlib: 1.2.13 -> 1.3
Changes: https://github.com/madler/zlib/releases/tag/v1.3
2023-08-22 08:39:24 +01:00
fetsorn
f7811fef7a zlib: fix typo
"verion" -> "version"
2023-05-09 18:02:16 +04:00
Artturin
f9fdf2d402 treewide: move NIX_CFLAGS_COMPILE to the env attrset
with structuredAttrs lists will be bash arrays which cannot be exported
which will be a issue with some patches and some wrappers like cc-wrapper

this makes it clearer that NIX_CFLAGS_COMPILE must be a string as lists
in env cause a eval failure
2023-02-22 21:23:04 +02:00
John Ericson
6e4a1b18d9 meta.pkgConfigModules: Init convention
See docs.

Follow-up work:

- Existing packages should be converted

- `defaultPkgConfigPackages` should assert on `meta.pkgConfigModules`
  and let `tests.pkg-config` alone test the build results.

CC @sternenseemann

Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2023-02-03 09:37:31 -05:00
John Ericson
3dcde1c342 zlib: Use finalAttrs instead of rec 2023-02-03 08:42:48 -05:00
Vladimír Čunát
40192db220 Merge #197116: zlib: cleanup
...into staging
2022-10-28 10:55:53 +02:00
Sandro Jäckel
401544bcac zlib: cleanup 2022-10-21 22:40:49 +02:00
Vladimír Čunát
735d63b668 zlib.src: shuffle download URLs
On sourceforge I see only versions up to 1.2.11:
  https://sourceforge.net/projects/libpng/files/zlib/
and the order is switched to avoid captcha (I didn't encounter it):
  https://github.com/NixOS/nixpkgs/pull/196167#issuecomment-1280333184
2022-10-20 12:49:53 +02:00
Artturin
017b667099 zlib: 1.2.12 -> 1.2.13 2022-10-15 21:46:15 +03:00
Winter
d56d587e85 zlib: add fixed patch for CVE-2022-37434 2022-08-08 14:33:13 -04:00
Winter
5323fa886e zlib: remove superfluous patch files 2022-08-08 14:26:43 -04:00
Robert Scott
d5aaf15094 Revert "zlib: add patch for CVE-2022-37434" 2022-08-08 11:16:19 -04:00
Robert Scott
c8f7a21ea2 zlib: add patch for CVE-2022-37434 2022-08-07 14:41:48 +01:00
Raito Bezarius
8335c46632 zlib: backport upstream fix on CRC validation
Starting zlib 1.2.12, CRC validation has became stricter.
This broke Keycloak ≥ 17 in certain situations, for details, see:

- https://github.com/keycloak/keycloak/issues/11316 ;
- https://github.com/NixOS/nixpkgs/issues/170539

This patch makes the CRC validation comprehensive with respect to older
or already existing checksums out there.
2022-06-10 01:20:03 +02:00
Artturin
f002ffed9a treewide: enable strictDeps in bootstrap packages 2022-05-22 16:40:26 +03:00
Janne Heß
c911240e9c Revert "Add mingwW64-llvm cross-system." 2022-05-18 13:50:23 +02:00
Shea Levy
504d38ae7b cross: Allow Windows toolchains to use ucrt as libc. 2022-05-06 10:54:52 -04:00