anchor.diff:  
     makeFlags = optionals (debug) [ "CFLAGS+=-Og" "CFLAGS+=-ggdb" ];
   
  -  cmakeFlags = optionals (withScripting) [
  +  cmakeFlags = optionals (stable && withScripting) [
       "-DKICAD_SCRIPTING=ON"
       "-DKICAD_SCRIPTING_MODULES=ON"
       "-DKICAD_SCRIPTING_PYTHON3=ON"
       "-DKICAD_SCRIPTING_WXPYTHON_PHOENIX=ON"
     ]
  -  ++ optional (!withScripting)
  +  ++ optionals (!withScripting) [
       "-DKICAD_SCRIPTING=OFF"
  +    "-DKICAD_SCRIPTING_WXPYTHON=OFF"
  +  ]
     ++ optional (withNgspice) "-DKICAD_SPICE=ON"
     ++ optional (!withOCE) "-DKICAD_USE_OCE=OFF"
     ++ optional (!withOCC) "-DKICAD_USE_OCC=OFF"
  
positive.code:   "Only kicad-unstable(-small) supports address/thread sanitation";
  assert lib.assertMsg (!(sanitizeAddress && sanitizeThreads))
    "'sanitizeAddress' and 'sanitizeThreads' are mutually exclusive, use one.";
  let
    inherit (lib) optional optionals;
  in
  
negative.code:     openssl
      boost
    ]
    # unstable requires swig and python
    # wxPython still optional
    ++ optionals (withScripting || (!stable)) [ swig python ]
    ++ optional (withScripting) wxPython
    ++ optional (withNgspice) libngspice
    ++ optional (withOCE) opencascade
    ++ optional (withOCC) opencascade-occt
  