You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Author Name: Marek Rouchal
Original Redmine Issue: 169 from https://www.veripool.org
Original Date: 2009-10-23
Original Assignee: Wilson Snyder (@wsnyder)
When builing Verilog-Perl 3.220 on Linux (RedHat Enterprise Linux 3.0) with gcc-4.1.2, I saw this problem:
g++ -c -m32 -fno-strict-aliasing -pipe -I/opt/perl_5.8.8/ext/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -I../Preproc -O2 -march=pentium4 -DVERSION="3.220" -DXS_VERSION="3.220" -fpic "-I/opt/perl_5.8.8/lib/CORE" VPreproc.cpp
VPreproc.cpp:126: error: expected identifier before '__null'
VPreproc.cpp:126: error: expected ',' or '...' before '__null'
VPreproc.cpp: In member function 'virtual std::string VPreproc::getline()':
VPreproc.cpp:164: error: no matching function for call to 'VPreprocImp::dcgettext(NULL, bool, )'
Seems that this is related to gettext(), which seems to be #define'd to something else on Linux - and the preprocessor garbles the VPreproc.cpp code. This rough patch corrects the problem and all tests run fine on Linux:
-string VPreprocImp::gettext(bool stop_at_eol) {
+string VPreprocImp::mYgettext(bool stop_at_eol) {
// Get a single line from the parse stream. Buffer unreturned text until the newline.
if (isEof()) return "";
while (1) {
The text was updated successfully, but these errors were encountered:
Author Name: Marek Rouchal
Original Redmine Issue: 169 from https://www.veripool.org
Original Date: 2009-10-23
Original Assignee: Wilson Snyder (@wsnyder)
When builing Verilog-Perl 3.220 on Linux (RedHat Enterprise Linux 3.0) with gcc-4.1.2, I saw this problem:
g++ -c -m32 -fno-strict-aliasing -pipe -I/opt/perl_5.8.8/ext/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -I../Preproc -O2 -march=pentium4 -DVERSION="3.220" -DXS_VERSION="3.220" -fpic "-I/opt/perl_5.8.8/lib/CORE" VPreproc.cpp
VPreproc.cpp:126: error: expected identifier before '__null'
VPreproc.cpp:126: error: expected ',' or '...' before '__null'
VPreproc.cpp: In member function 'virtual std::string VPreproc::getline()':
VPreproc.cpp:164: error: no matching function for call to 'VPreprocImp::dcgettext(NULL, bool, )'
Seems that this is related to gettext(), which seems to be #define'd to something else on Linux - and the preprocessor garbles the VPreproc.cpp code. This rough patch corrects the problem and all tests run fine on Linux:
diff -ruN Verilog-Perl-3.220/Preproc/VPreproc.cpp Verilog-Perl-3.220p1/Preproc/VPreproc.cpp
--- Verilog-Perl-3.220/Preproc/VPreproc.cpp 2009-09-27 13:34:49.000000000 +0200
+++ Verilog-Perl-3.220p1/Preproc/VPreproc.cpp 2009-10-23 11:42:38.000000000 +0200
@@ -123,7 +123,7 @@
int getToken();
void parseTop();
void parseUndef();
bool isEof() const { return (m_lexp==NULL); }
void open(string filename, VFileLine* filelinep);
void insertUnreadback(const string& text) { m_lineCmt += text; }
@@ -161,11 +161,11 @@
}
string VPreproc::getline() {
VPreprocImp* idatap = static_cast<VPreprocImp*>(m_opaquep);
}
string VPreproc::getall() {
VPreprocImp* idatap = static_cast<VPreprocImp*>(m_opaquep);
}
void VPreproc::debug(int level) {
VPreprocImp* idatap = static_cast<VPreprocImp*>(m_opaquep);
@@ -871,7 +871,7 @@
}
}
-string VPreprocImp::gettext(bool stop_at_eol) {
+string VPreprocImp::mYgettext(bool stop_at_eol) {
// Get a single line from the parse stream. Buffer unreturned text until the newline.
if (isEof()) return "";
while (1) {
The text was updated successfully, but these errors were encountered: