cad/iverilog: Fix build with -fno-common

Fix the build with -fno-common, which is the default in llvm 11 (and gcc10).

MFH:		2020Q3
This commit is contained in:
Niclas Zeising 2020-08-18 17:41:24 +00:00
parent 9ba6e2af06
commit ef7b401e4e
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=545237
3 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,10 @@
--- driver/cflexor.lex.orig 2020-08-18 17:06:30 UTC
+++ driver/cflexor.lex
@@ -30,6 +30,7 @@
static int comment_enter;
static char* trim_trailing_white(char*txt, int trim);
+char *current_file;
/*
* Mostly copied from the flex manual. Do not make this arbitrary
* depth without checking for looping files.

View File

@ -0,0 +1,10 @@
--- driver/cfparse_misc.h.orig 2020-08-18 17:06:43 UTC
+++ driver/cfparse_misc.h
@@ -39,6 +39,6 @@ int cferror(const char *);
int cfparse(void);
void switch_to_command_file(const char *);
void destroy_lexor(void);
-char *current_file;
+extern char *current_file;
#endif /* IVL_cfparse_misc_H */

View File

@ -0,0 +1,12 @@
--- libveriuser/priv.h.orig 2020-08-18 15:47:00 UTC
+++ libveriuser/priv.h
@@ -30,7 +30,8 @@ extern char* __acc_newstring(const char*txt);
/*
* Trace file for logging ACC and TF calls.
+ * Defined in libveriuser/priv.c
*/
-FILE* pli_trace;
+extern FILE* pli_trace;
#endif /* IVL_priv_H */