Permalink
Browse files

Fix "use of undeclared identifier dNOOP" when building on OS X

1 parent 61f1e6d commit 22a8ae62028d6455e2ff56662c76c9c0157dca67 @farrainbow farrainbow committed Dec 1, 2016
Showing with 20 additions and 0 deletions.
  1. +3 −0 SConstruct
  2. +17 −0 src/auto/XSTools/darwin/include/perl.h
View
@@ -25,6 +25,9 @@ EXTRA_COMPILER_FLAGS = ['-Wall', '-O3', '-pipe']
DARWIN_INCLUDE_DIRECTORIES = ['/usr/local/opt/readline/include']
DARWIN_LIBRARY_DIRECTORIES = ['/usr/local/opt/readline/lib']
+# Fixes for OS X (src/auto/XSTools/darwin/include)
+DARWIN_INCLUDE_DIRECTORIES += ['darwin/include']
+
####################
import os
@@ -0,0 +1,17 @@
+/*
+Include the original file
+*/
+#include "../CORE/perl.h"
+
+/*
+Fixes error: use of undeclared identifier 'dNOOP'
+
+Read more:
+http://www.veripool.org/issues/732-Verilog-Perl-Not-able-to-install-on-Verilog-Language-Mac-10-9-2
+*/
+#ifdef PERL_DARWIN
+#ifdef dNOOP
+#undef dNOOP
+#define dNOOP
+#endif
+#endif

0 comments on commit 22a8ae6

Please sign in to comment.