···11{ stdenv
22, fetchgit
33, lib
44-, fetchpatch
54, meson
65, ninja
76, pkg-config
···3332 hash = "sha256-x0Im9m9MoACJhQKorMI34YQ+/bd62NdAPc2nWwaJAvM=";
3433 };
35343636- outputs = [ "out" "dev" "doc" ];
3535+ outputs = [ "out" "dev" ];
37363837 postPatch = ''
3938 patchShebangs utils/
3939+ '';
4040+4141+ # libcamera signs the IPA module libraries at install time, but they are then
4242+ # modified by stripping and RPATH fixup. Therefore, we need to generate the
4343+ # signatures again ourselves. For reproducibility, we use a static private key.
4444+ #
4545+ # If this is not done, libcamera will still try to load them, but it will
4646+ # isolate them in separate processes, which can cause crashes for IPA modules
4747+ # that are not designed for this (notably ipa_rpi.so).
4848+ preBuild = ''
4949+ ninja src/ipa-priv-key.pem
5050+ install -D ${./ipa-priv-key.pem} src/ipa-priv-key.pem
4051 '';
41524253 strictDeps = true;
···8697 # Avoid blanket -Werror to evade build failures on less
8798 # tested compilers.
8899 "-Dwerror=false"
100100+ # Documentation breaks binary compatibility.
101101+ # Given that upstream also provides public documentation,
102102+ # we can disable it here.
103103+ "-Ddocumentation=disabled"
89104 ];
9010591106 # Fixes error on a deprecated declaration
···9310894109 # Silence fontconfig warnings about missing config
95110 FONTCONFIG_FILE = makeFontsConf { fontDirectories = [ ]; };
9696-9797- # libcamera signs the IPA module libraries at install time, but they are then
9898- # modified by stripping and RPATH fixup. Therefore, we need to generate the
9999- # signatures again ourselves.
100100- #
101101- # If this is not done, libcamera will still try to load them, but it will
102102- # isolate them in separate processes, which can cause crashes for IPA modules
103103- # that are not designed for this (notably ipa_rpi.so).
104104- postFixup = ''
105105- ../src/ipa/ipa-sign-install.sh src/ipa-priv-key.pem $out/lib/libcamera/ipa_*.so
106106- '';
107111108112 meta = with lib; {
109113 description = "An open source camera stack and framework for Linux, Android, and ChromeOS";