ccid: strip shared object to reduce closure size

The ccid derivation provides a pcsclite plugin to access CCID devices.
This shared object is written to a non-standard path "$out/pcsc", which
causes it not to get stripped by default. The consequence is that the
result is an unstripped binary that still contains references to gcc and
glibc-dev in its debug symbols, which unnecessarily inflates the closure
size from ~80MB to ~400MB.

Explicitly add the directory to the stripped paths to fix this issue.
This commit is contained in:
Patrick Steinhardt 2023-10-24 22:10:17 +02:00
parent 3a8616d039
commit 5fb0f38f2c

View File

@ -21,6 +21,10 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ pkg-config perl ];
buildInputs = [ pcsclite libusb1 ];
# The resulting shared object ends up outside of the default paths which are
# usually getting stripped.
stripDebugList = ["pcsc"];
meta = with lib; {
description = "ccid drivers for pcsclite";
homepage = "https://ccid.apdu.fr/";