3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-06-19 20:33:39 +00:00

Add "#ifdef __FreeBSD__"

(Re-commit e3575a8 with corrected author field)
This commit is contained in:
Christian Krämer 2018-05-05 13:02:44 +02:00 committed by Clifford Wolf
parent 1167538d26
commit c1ecb1b2f1
5 changed files with 52 additions and 9 deletions

View file

@ -25,7 +25,7 @@
# include <sys/time.h>
#endif
#ifdef __linux__
#if defined(__linux__) || defined(__FreeBSD__)
# include <dlfcn.h>
#endif
@ -392,7 +392,7 @@ void log_pop()
log_flush();
}
#if defined(__linux__) && defined(YOSYS_ENABLE_PLUGINS)
#if (defined(__linux__) || defined(__FreeBSD__)) && defined(YOSYS_ENABLE_PLUGINS)
void log_backtrace(const char *prefix, int levels)
{
if (levels <= 0) return;
@ -587,7 +587,7 @@ void log_wire(RTLIL::Wire *wire, std::string indent)
// ---------------------------------------------------
// This is the magic behind the code coverage counters
// ---------------------------------------------------
#if defined(YOSYS_ENABLE_COVER) && defined(__linux__)
#if defined(YOSYS_ENABLE_COVER) && (defined(__linux__) || defined(__FreeBSD__))
dict<std::string, std::pair<std::string, int>> extra_coverage_data;