When creating ZIP files with non-ASCII names (such as some European
accent chars), something was detecting a buffer overflow and bailing
out. It turns out that this has been already fixed earlier this year in
Fedora, so let's reuse their patch as-is.
Bug: https://bugzilla.redhat.com/show_bug.cgi?id=2165653
* mpd-touch-screen-gui: use finalAttrs in mkDerivation; reformat
* musescore: use finalAttrs in mkDerivation
* syncthingtray: use stdenv.mkDerivation with a function; reformat
* ocrfeeder: use finalAttrs in mkDerivation; reformat
* castget: use finalAttrs in mkDerivation
* gnome-network-displays: use finalAttrs in mkDerivation
* mailreaders: use finalAttrs in mkDerivation
* mswatch: use finalAttrs in mkDerivation
* uhd: use finalAttrs in mkDerivation
* maxima: use finalAttrs in mkDerivation
* qalculate-gtk: use finalAttrs in mkDerivation
* qalculate-qt: use finalAttrs in mkDerivation
* wxmaxima: use finalAttrs in mkDerivation
* lammps: use finalAttrs in mkDerivation
* mlterm: use finalAttrs in mkDerivation
* video-trimmer: use finalAttrs in mkDerivation
* nerdfonts: use finalAttrs in mkDerivation
* gnomeExtensions.easyScreenCast: use finalAttrs in mkDerivation
* octave: use finalAttrs in mkDerivation; reformat
* comedilib: use finalAttrs in mkDerivation
* cpp-utilities: use finalAttrs in mkDerivation
* libsForQt5.kpeoplevcard: use finalAttrs in mkDerivation; reformat
* liberio: use finalAttrs in mkDerivation
* libqalculate: use finalAttrs in mkDerivation; reformat
* libwtk-sdl2: use finalAttrs in mkDerivation
* libsForQt5.pulseaudio-qt: use finalAttrs in mkDerivation; reformat
* qrupdate: use finalAttrs in mkDerivation; reformat
* libsForQt5.qtforkawesome: use finalAttrs in mkDerivation; reformat
* libsForQt5.qtutilities: use finalAttrs in mkDerivation; reformat
* sqlitecpp: use finalAttrs in mkDerivation; reformat
* tweeny: use finalAttrs in mkDerivation
* volk: use finalAttrs in mkDerivation
* wiringpi: use finalAttrs in mkDerivation
* snzip: use finalAttrs in mkDerivation; reformat
* bpm-tools: use finalAttrs in mkDerivation; reformat
* sacd: use finalAttrs in mkDerivation
* gtk-gnutella: use finalAttrs in mkDerivation; reformat
* sile: use finalAttrs in mkDerivation
* pplatex: use finalAttrs in mkDerivation; reformat
This continues where d8f7f6a5ce left off. Similarly
to that commit, this commit this also points `sourceRoot`s to `src.name` and similar
instead of keeping hardcoded names, and edits other derivation attrs do do the same,
where appropriate.
Also, similarly to d8f7f6a5ce some of expressions this
edits use `srcs` attribute with customly-named sources, so they have to be moved
into `let` blocks to keep evaluation efficient (the other, worse, way to do this
would to recurcively refer to `elemAt n finalAttrs.srcs` or, similarly, with `rec`).
Clang 16 makes implicit int and function declarations an error by
default in any mode except for C89. The configure script has two of
these that cause it to misdetect features when using Clang 16.
* Implicit `int main` in the errno check. This is fixed by adding the
missing `int`.
* Implicit definitions of `opendir` and `closedir`. These are fixed by
including the required headers.
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
libiconv is already defined per-platform. The actual libiconv library
won't be built on platforms like Linux where it doesn't need to be, so
there's no need to maintain a separate platform list here.
Required to build for FreeBSD.
Done with the help of https://github.com/Mindavi/nixpkgs-mark-broken
Tool is still WIP but this is one of the first results.
I manually audited the results and removed some results that were not valid.
Note that some of these packages maybe should have more constrained platforms set
instead of broken set, but I think not being perfectly correct is better than
just keep trying to build all these things and never succeeding.
Some observations:
- Some darwin builds require XCode tools
- aarch64-linux builds sometimes suffer from using gcc9
- gcc9 is getting older and misses some new libraries/features
- Sometimes tools try to do system detection or expect some explicit settings for
platforms that are not x86_64-linux
musl and darwin support UTF-8 locales without any extras. As a result
unzip can unpack UTF-8 filenames there as is. But on glibc without
locale archive presence files get mangled as:
deps/αβ -> deps/#U03b1#U03b2
This makes `fetchzip` fixed-output derivations unstable.
Tested this change to fail in `coq.src` which was generated in system
that mangles UTF-8 symbols:
$ nix build -f. coq.src --rebuild -L
source> trying https://github.com/coq/coq/archive/V8.15.2.zip
source> % Total % Received % Xferd Average Speed Time Time Time Current
source> Dload Upload Total Spent Left Speed
source> 0 0 0 0 0 0 0 0 --:--:-- 0:00:01 --:--:-- 0
source> 100 8945k 100 8945k 0 0 1513k 0 0:00:05 0:00:05 --:--:-- 1989k
source> unpacking source archive /build/V8.15.2.zip
error: hash mismatch in fixed-output derivation '/nix/store/hrnyykm7wgw8vxisgq7hc2bg5gr0y6s8-source.drv':
specified: sha256-h81nFqkuvZkMR7YLHy7laTq5yOhjMW+w6rYzncxvyD4=
got: sha256-DTspmwyD3Evl1CUmvUy2MonbLGUezvsHN3prmP9eK2I=
Note: it means that some of existing caches for fixed output
derivations become incorrect. It should not break already cached
tarballs on cache.nixos.org thus the impact should not be widespread.
`uasm` is x86 only.
It seems that in `aarch64-linux` at least, the optimizing build is done
without using any third-party tool (maybe using GCC's own assembly?).
Wimlib works just fine on darwin, but two adjustments need to be made:
- Tests need to be disabled, as they rely on glibc-isms (such as
lgetattr).
- cdrkit and syslinux dependencies are dropped, as those binaries are
linux-only.
* _7zz: correct license and remove p7zip dependency
The code under Compress/Rar* is licensed under a specific unRAR license
Also Compress/LzfseDecoder.cpp is covered by BSD3
The unRAR code is removed from the `.tar.xz` since the license posits you
agree or remove the code from your hard drive
This adds some complexity to updating 7zz so there is also an update
script
Meta has been updated and tweaked
Source is now downloaded from sourceforge in the `.tar.xz` version to
avoid depending on p7zip
* _7zz: add notice of the license updates and optional unRAR licenced code
The code under Compress/Rar* is licensed under a specific unRAR license
Also Compress/LzfseDecoder.cpp is covered by BSD3
The unRAR code is removed from the source drv since the license posits you
agree or remove the code from your hard drive
This adds some complexity to updating p7zip so there is also an update
script
Meta has been updated and tweaked
Use uasm to compile the optimized code instead of generic C code for
faster operations.
Before:
```
7zz x 10.83s user 0.40s system 98% cpu 11.439 total
```
After:
```
7zz x 6.87s user 0.40s system 98% cpu 7.395 total
```