From a8a66c147edaa8fa724d2c84add899c030719c75 Mon Sep 17 00:00:00 2001 From: Schrijvers Luc Date: Thu, 20 Sep 2018 06:59:48 +0000 Subject: [PATCH] verilator, bump version (#2745) * verilator, bump version * verilator, use PATCH function, remove fixPkgconfig --- .../patches/verilator-3.924.patchset | 56 +++++++++++++ .../verilator/verilator-3.924.recipe | 79 +++++++++++++++++++ 2 files changed, 135 insertions(+) create mode 100644 sci-electronics/verilator/patches/verilator-3.924.patchset create mode 100644 sci-electronics/verilator/verilator-3.924.recipe diff --git a/sci-electronics/verilator/patches/verilator-3.924.patchset b/sci-electronics/verilator/patches/verilator-3.924.patchset new file mode 100644 index 000000000..dd086ee69 --- /dev/null +++ b/sci-electronics/verilator/patches/verilator-3.924.patchset @@ -0,0 +1,56 @@ +From 5efa36f87b22bd52e34a78c02b85123cc493bcd0 Mon Sep 17 00:00:00 2001 +From: Alexander von Gluck IV +Date: Thu, 23 Oct 2014 18:35:32 +0000 +Subject: Haiku: Add strings.h for strcasecmp + + +diff --git a/src/V3Error.cpp b/src/V3Error.cpp +index b12f5b8..4c0c090 100644 +--- a/src/V3Error.cpp ++++ b/src/V3Error.cpp +@@ -21,6 +21,7 @@ + #include + #include + #include ++#include + #include + #include "V3Error.h" + #ifndef _V3ERROR_NO_GLOBAL_ +diff --git a/src/V3Options.cpp b/src/V3Options.cpp +index 11dc0a9..8de652f 100644 +--- a/src/V3Options.cpp ++++ b/src/V3Options.cpp +@@ -29,6 +29,7 @@ + #include + #include + #include ++#include + #include + #include + #include +-- +2.16.4 + + +From 473b5567b0202da9d4c72766a6dfa66c25273aa5 Mon Sep 17 00:00:00 2001 +From: begasus +Date: Sat, 7 Jul 2018 17:45:04 +0200 +Subject: fix path for pkg-config + + +diff --git a/verilator.pc.in b/verilator.pc.in +index 2b3ba70..c8aef2b 100644 +--- a/verilator.pc.in ++++ b/verilator.pc.in +@@ -2,7 +2,7 @@ prefix=@prefix@ + exec_prefix=@exec_prefix@ + libdir=@libdir@ + datarootdir=@datarootdir@ +-includedir=@pkgdatadir@/include ++includedir=@includedir@ + + Name: verilator + Description: fast free Verilog simulator +-- +2.16.4 + diff --git a/sci-electronics/verilator/verilator-3.924.recipe b/sci-electronics/verilator/verilator-3.924.recipe new file mode 100644 index 000000000..9ec5614e1 --- /dev/null +++ b/sci-electronics/verilator/verilator-3.924.recipe @@ -0,0 +1,79 @@ +SUMMARY="A fast C++ Verilog simulator" +DESCRIPTION="Verilator is the fastest free Verilog HDL simulator, and \ +beats most commercial simulators. It compiles synthesizable Verilog (not \ +test-bench code!), plus some PSL, SystemVerilog and Synthesis assertions \ +into C++ or SystemC code. It is designed for large projects where fast \ +simulation performance is of primary concern, and is especially well suited \ +to generate executable models of CPUs for embedded software design teams." +HOMEPAGE="https://www.veripool.org/" +COPYRIGHT="2006-2018 Wilson Snyder" +LICENSE="GNU GPL v3" +REVISION="1" +SOURCE_URI="https://www.veripool.org/ftp/verilator-$portVersion.tgz" +CHECKSUM_SHA256="7dcb19711b8630ada59f0d3d7409faa9649e37bf4c53a0bbfcad32afb28b5975" +PATCHES="verilator-$portVersion.patchset" + +ARCHITECTURES="!x86_gcc2 x86 x86_64" +SECONDARY_ARCHITECTURES="x86" + +commandSuffix=$secondaryArchSuffix +commandBinDir=$binDir +if [ "$targetArchitecture" = x86_gcc2 ]; then + commandSuffix= + commandBinDir=$prefix/bin +fi + +PROVIDES=" + verilator$secondaryArchSuffix = $portVersion + cmd:verilator$commandSuffix = $portVersion + cmd:verilator_bin$commandSuffix = $portVersion + cmd:verilator_bin_dbg$commandSuffix = $portVersion + cmd:verilator_coverage$commandSuffix = $portVersion + cmd:verilator_coverage_bin_dbg$commandSuffix = $portVersion + cmd:verilator_profcfunc$commandSuffix = $portVersion + " +REQUIRES=" + haiku$secondaryArchSuffix + " + +BUILD_REQUIRES=" + haiku${secondaryArchSuffix}_devel + " +BUILD_PREREQUIRES=" + cmd:awk + cmd:bison + cmd:flex + cmd:gcc$secondaryArchSuffix + cmd:make + cmd:perl + " + +PATCH() +{ + sed -i 's,/usr/bin/perl,/usr/bin/env perl,g' test_regress/*.pl + sed -i 's,/usr/bin/perl,/usr/bin/env perl,g' test_regress/t/*.pl + chmod +x test_regress/*.pl + chmod +x test_regress/t/*.pl +} + +BUILD() +{ + runConfigure --omit-dirs "binDir" ./configure \ + --bindir="$commandBinDir" + make $jobArgs +} + +INSTALL() +{ + make install + + mkdir -p $developLibDir/pkgconfig $includeDir + mv $dataDir/pkgconfig/* $developLibDir/pkgconfig/ + mv $dataDir/verilator/include/* $includeDir + rmdir $dataDir/{pkgconfig,verilator/include} +} + +TEST() +{ + make test +}