Merge pull request #199733 from wegank/kicad-darwin
kicad.base: expose binaries on darwin
This commit is contained in:
commit
14bfe4fa4f
1 changed files with 4 additions and 3 deletions
|
@ -15,7 +15,7 @@
|
|||
, pname ? "kicad"
|
||||
, stable ? true
|
||||
, withOCC ? true
|
||||
, withNgspice ? true
|
||||
, withNgspice ? !stdenv.isDarwin
|
||||
, libngspice
|
||||
, withScripting ? true
|
||||
, python3
|
||||
|
@ -170,6 +170,7 @@ stdenv.mkDerivation rec {
|
|||
# $out and $program_PYTHONPATH don't exist when makeWrapperArgs gets set?
|
||||
installPhase =
|
||||
let
|
||||
bin = if stdenv.isDarwin then "*.app/Contents/MacOS" else "bin";
|
||||
tools = [ "kicad" "pcbnew" "eeschema" "gerbview" "pcb_calculator" "pl_editor" "bitmap2component" ];
|
||||
utils = [ "dxf2idf" "idf2vrml" "idfcyl" "idfrect" "kicad2step" ];
|
||||
in
|
||||
|
@ -181,13 +182,13 @@ stdenv.mkDerivation rec {
|
|||
|
||||
# wrap each of the directly usable tools
|
||||
(map
|
||||
(tool: "makeWrapper ${base}/bin/${tool} $out/bin/${tool} $makeWrapperArgs"
|
||||
(tool: "makeWrapper ${base}/${bin}/${tool} $out/bin/${tool} $makeWrapperArgs"
|
||||
+ optionalString (withScripting) " --set PYTHONPATH \"$program_PYTHONPATH\""
|
||||
)
|
||||
tools)
|
||||
|
||||
# link in the CLI utils
|
||||
(map (util: "ln -s ${base}/bin/${util} $out/bin/${util}") utils)
|
||||
(map (util: "ln -s ${base}/${bin}/${util} $out/bin/${util}") utils)
|
||||
|
||||
"runHook postInstall"
|
||||
])
|
||||
|
|
Loading…
Reference in a new issue