mirror of https://github.com/YosysHQ/nextpnr.git
nix: minor improvements for the nix shell to modernize it (#1677)
This commit is contained in:
parent
a7c3bfe6e6
commit
77ccf518d5
22
shell.nix
22
shell.nix
|
|
@ -1,30 +1,40 @@
|
|||
{ pkgs ? import (fetchTarball https://github.com/NixOS/nixpkgs/archive/24.05.tar.gz) {} }:
|
||||
{ pkgs ? import (fetchTarball "https://github.com/NixOS/nixpkgs/archive/25.11.tar.gz") {} }:
|
||||
|
||||
let
|
||||
inherit (pkgs) stdenv lib;
|
||||
inherit (stdenv.hostPlatform) isDarwin;
|
||||
pythonPkgs = pkgs.python3Packages;
|
||||
boostPython = pkgs.boost.override { python = pythonPkgs.python; enablePython = true; };
|
||||
in pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
cmake
|
||||
ninja
|
||||
eigen
|
||||
boostPython
|
||||
pythonPkgs.python
|
||||
pythonPkgs.apycula
|
||||
pkgs.qt6.qtbase
|
||||
lld
|
||||
llvmPackages.openmp
|
||||
icestorm
|
||||
trellis
|
||||
mold
|
||||
yosys
|
||||
clang
|
||||
valgrind
|
||||
cling
|
||||
gdb
|
||||
];
|
||||
sccache
|
||||
] ++ lib.optional (!isDarwin) valgrind;
|
||||
|
||||
shellHook = ''
|
||||
export TRELLIS_INSTALL_PREFIX=${pkgs.trellis}
|
||||
export ICESTORM_INSTALL_PREFIX=${pkgs.icestorm}
|
||||
export QT_QPA_PLATFORM_PLUGIN_PATH="${pkgs.qt6.qtbase.bin}/lib/qt-${pkgs.qt6.qtbase.version}/plugins";
|
||||
export QT_QPA_PLATFORM_PLUGIN_PATH="${pkgs.qt6.qtbase}/${pkgs.qt6.qtbase.qtPluginPrefix}"
|
||||
|
||||
export CMAKE_C_COMPILER=clang
|
||||
export CMAKE_CXX_COMPILER=clang++
|
||||
export CMAKE_C_COMPILER_LAUNCHER=sccache
|
||||
export CMAKE_CXX_COMPILER_LAUNCHER=sccache
|
||||
export CMAKE_LINKER_TYPE=LLD
|
||||
export CMAKE_EXPORT_COMPILE_COMMANDS=ON
|
||||
export CMAKE_GENERATOR=Ninja
|
||||
'';
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue