2019-01-08 22:56:16 +00:00
|
|
|
{ stdenv, fetchFromGitHub
|
|
|
|
, python3, boost
|
|
|
|
, cmake
|
|
|
|
}:
|
2018-08-02 09:18:47 +01:00
|
|
|
|
|
|
|
let
|
2019-01-08 22:56:16 +00:00
|
|
|
boostWithPython3 = boost.override { python = python3; enablePython = true; };
|
2018-08-02 09:18:47 +01:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "trellis-${version}";
|
2019-04-22 18:20:25 +01:00
|
|
|
version = "2019.04.22";
|
2018-08-02 09:18:47 +01:00
|
|
|
|
2019-01-08 22:56:16 +00:00
|
|
|
srcs = [
|
|
|
|
(fetchFromGitHub {
|
|
|
|
owner = "symbiflow";
|
|
|
|
repo = "prjtrellis";
|
2019-04-22 18:20:25 +01:00
|
|
|
rev = "5eb0ad870f30422b95d090ac9a476343809c62b9";
|
|
|
|
sha256 = "10jkjfhqdr2bff41mh3w8a7kszf2whqqgk5s1z5z07mlh6zfdjlg";
|
2019-01-08 22:56:16 +00:00
|
|
|
name = "trellis";
|
|
|
|
})
|
|
|
|
(fetchFromGitHub {
|
|
|
|
owner = "symbiflow";
|
|
|
|
repo = "prjtrellis-db";
|
2019-02-23 17:05:19 +00:00
|
|
|
rev = "d0b219af41ae3da6150645fbc5cc5613b530603f";
|
|
|
|
sha256 = "1mnzvrqrcbfypvbagwyf6arv3kmj6q7n27gcmyk6ap2xnavkx4bq";
|
2019-01-08 22:56:16 +00:00
|
|
|
name = "database";
|
|
|
|
})
|
2018-08-02 09:18:47 +01:00
|
|
|
];
|
2019-01-08 22:56:16 +00:00
|
|
|
sourceRoot = "trellis";
|
2018-08-02 09:18:47 +01:00
|
|
|
|
2019-01-08 22:56:16 +00:00
|
|
|
buildInputs = [ boostWithPython3 ];
|
|
|
|
nativeBuildInputs = [ cmake python3 ];
|
2018-08-02 09:18:47 +01:00
|
|
|
|
2019-01-08 22:56:16 +00:00
|
|
|
preConfigure = with builtins; ''
|
|
|
|
rmdir database && ln -sfv ${elemAt srcs 1} ./database
|
2018-08-02 09:18:47 +01:00
|
|
|
|
|
|
|
source environment.sh
|
|
|
|
cd libtrellis
|
|
|
|
'';
|
|
|
|
|
2019-01-08 22:56:16 +00:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Documentation and bitstream tools for Lattice ECP5 FPGAs";
|
2018-08-02 09:18:47 +01:00
|
|
|
longDescription = ''
|
|
|
|
Project Trellis documents the Lattice ECP5 architecture
|
|
|
|
to enable development of open-source tools. Its goal is
|
|
|
|
to provide sufficient information to develop a free and
|
|
|
|
open Verilog to bitstream toolchain for these devices.
|
|
|
|
'';
|
2019-01-08 22:56:16 +00:00
|
|
|
homepage = https://github.com/symbiflow/prjtrellis;
|
|
|
|
license = stdenv.lib.licenses.isc;
|
|
|
|
maintainers = with maintainers; [ q3k thoughtpolice ];
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
2018-08-02 09:18:47 +01:00
|
|
|
};
|
|
|
|
}
|