hwinfo: split lib from bin output

bin currently depends on perl, which is a big dependency for
`nixos-facter`
This commit is contained in:
Jörg Thalheim 2024-12-03 22:26:55 +01:00
parent 3b6172a234
commit 58e0732fb3

View File

@ -69,6 +69,13 @@ stdenv.mkDerivation (finalAttrs: {
patchShebangs src/ids/convert_hd
'';
outputs = [
"bin"
"dev"
"lib"
"out"
];
# The pci/usb ids in hwinfo are ancient. We can get a more up-to-date list simply by copying from systemd
preBuild = ''
# since we don't have .git, we cannot run this.
@ -94,6 +101,13 @@ stdenv.mkDerivation (finalAttrs: {
];
installFlags = [ "DESTDIR=$(out)" ];
enableParallelBuilding = false; # broken parallel dependencies
postInstall = ''
moveToOutput bin "$bin"
moveToOutput lib "$lib"
'';
passthru = {
tests = {
version = testers.testVersion { package = finalAttrs.finalPackage; };