~ruther/nix-fpga

ref: a9e4e49ebb7a14bc5d564f96c181d7d01a00a950 nix-fpga/pkgs/xilinx/vivado/fhs.nix -rw-r--r-- 413 bytes
a9e4e49e — Rutherther feat: add usb-driver to ISE 1 year, 9 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{ pkgs, myLib, requireInstallDir ? false, ... }:

pkgs.buildFHSEnv {
  targetPkgs = (import ../common.nix).targetPkgs;

  name = "vivado";

  runScript = ''
    ${myLib.runScriptPrefix "vivado" requireInstallDir}
    if [[ ! -z $INSTALL_DIR ]]; then
      source $INSTALL_DIR/settings64.sh $INSTALL_DIR
    fi
    export LD_LIBRARY_PATH=/lib:$LD_LIBRARY_PATH
    exec "$@"
  '';

  meta.mainProgram = "vivado";
}