From: Mattia B. <mb...@ds...> - 2002-04-17 16:44:00
|
> Has any one been succesful with building wxPerl on SGI? I get hundreds > of compilation errors: > > CC -c -I../.. -I/usr/local/lib/wx/include/gtk-2.2 -I/usr/local/include > -I. -O3 -DVERSION=\"0.01\" -DXS_VERSION=\"0.01\" > -I/usr/freeware/lib/perl5/5.6.1/irix-n32/CORE -DWXPL_EXT > -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_REENTRANT Grid.c > cc-1367 CC: ERROR File = ../../cpp/helpers.h, Line = 272 > A pointer to an incomplete class type is not allowed. > > SvREFCNT_inc( m_self ); > ^ > > cc-1367 CC: ERROR File = Grid.c, Line = 184 > A pointer to an incomplete class type is not allowed. > > bool show = (int)SvIV(ST(1)); Some questions: * Is CC it the same compiler that was used for wxGTK ( it should )? * Is it a C or C++ compiler ( or both )? * If it is both, and uses the .c or .cpp ( or .cxx, or whatever ) to discriminate between C and C++, is there a way to force it to compile a .c file as C++? * if you do ( from the top level directory ) $ make Wx.c $ cp Wx.c Wx.cpp ( or .cxx or .cc ... ) $ make Wx.o CC ..... Wx.c ^C # stop it just after it outputs the command $ CC .... Wx.cpp # the line compiling the file with Wx.c => Wx.cpp/.cxx/.cc ... does it compile or not? Regards Mattia |
From: Mattia B. <mb...@ds...> - 2002-04-18 18:31:40
|
> Hi Mattia, > > Thanks for replying to my message: (see below) You're welcome! > Mattia Barbon wrote: > > > > > Has any one been succesful with building wxPerl on SGI? I get hundreds > > > of compilation errors: <snip> > > > SvREFCNT_inc( m_self ); > > > ^ > > > > > > cc-1367 CC: ERROR File = Grid.c, Line = 184 > > > A pointer to an incomplete class type is not allowed. > > > > > > bool show = (int)SvIV(ST(1)); <snip> > > * Is it a C or C++ compiler ( or both )? > > It is a C++ compiler (that can also handle C). > > > * If it is both, and uses the .c or .cpp ( or .cxx, or whatever ) to > > discriminate between C and C++, is there a way to force it to compile > > a .c file as C++? > > I am certain that it is treating the file as C++. When I tried "cc" > (instead of CC) it gave bunch of errors such as: > > cc-1020 cc: ERROR File = /usr/local/include/wx/defs.h, Line = 456 > The identifier "class" is undefined. > > class WXDLLEXPORT wxObject; > ^ Sigh, one easy solution gone > This is clearly a c verses c++ issue. However, when I use CC, then I > get bunch of errors that all seems to be related to SvREFCNT_inc, SvOK, > SvUV, SvPV_nolen, etc. In fact the first 40 errors all include the > mentioned names, all with the same message: > > A pointer to an incomplete class type is not allowed. > > > > > * if you do ( from the top level directory ) > > $ make Wx.c > > $ cp Wx.c Wx.cpp ( or .cxx or .cc ... ) > > $ make Wx.o > > CC ..... Wx.c > > I did, with no effect. Any other suggestions? I'm running short of suggestions :-( I think CC has a "preprocess to standard output" mode ( like gcc -E ) could you do $ CC --switch-to-preprocess-to-stdout ..options.. Wx.cpp > Wx.i and send Wx.i to me, ( better if gzipped )? Also: do a "make 2>&1 > make.log" and send the log to me. Another idea ( after you created the Wx.i and make.log ): in Wx.xs try replacing WXPL_EXTERN_C_START with extern "C" { WXPL_EXTERN_C_END with } and see what make Wx.o says Thanks Mattia |
From: Farzin S. <ac...@ac...> - 2002-04-18 01:25:49
|
Hi Mattia, Thanks for replying to my message: (see below) Mattia Barbon wrote: > > > Has any one been succesful with building wxPerl on SGI? I get hundreds > > of compilation errors: > > > > CC -c -I../.. -I/usr/local/lib/wx/include/gtk-2.2 -I/usr/local/include > > -I. -O3 -DVERSION=\"0.01\" -DXS_VERSION=\"0.01\" > > -I/usr/freeware/lib/perl5/5.6.1/irix-n32/CORE -DWXPL_EXT > > -DGTK_NO_CHECK_CASTS -D__WXGTK__ -D_REENTRANT Grid.c > > cc-1367 CC: ERROR File = ../../cpp/helpers.h, Line = 272 > > A pointer to an incomplete class type is not allowed. > > > > SvREFCNT_inc( m_self ); > > ^ > > > > cc-1367 CC: ERROR File = Grid.c, Line = 184 > > A pointer to an incomplete class type is not allowed. > > > > bool show = (int)SvIV(ST(1)); > Some questions: > > * Is CC it the same compiler that was used for wxGTK ( it should )? I am not certain what was used for wxGTK, since I downloaded it from http://freeware.sgi.com/index-by-alpha.html. This is pre-packaged installable distribution. I would imagine that it was compiled with CC. SGI has three compilers cc, CC and c89. > * Is it a C or C++ compiler ( or both )? It is a C++ compiler (that can also handle C). > * If it is both, and uses the .c or .cpp ( or .cxx, or whatever ) to > discriminate between C and C++, is there a way to force it to compile > a .c file as C++? I am certain that it is treating the file as C++. When I tried "cc" (instead of CC) it gave bunch of errors such as: cc-1020 cc: ERROR File = /usr/local/include/wx/defs.h, Line = 456 The identifier "class" is undefined. class WXDLLEXPORT wxObject; ^ This is clearly a c verses c++ issue. However, when I use CC, then I get bunch of errors that all seems to be related to SvREFCNT_inc, SvOK, SvUV, SvPV_nolen, etc. In fact the first 40 errors all include the mentioned names, all with the same message: A pointer to an incomplete class type is not allowed. > > * if you do ( from the top level directory ) > $ make Wx.c > $ cp Wx.c Wx.cpp ( or .cxx or .cc ... ) > $ make Wx.o > CC ..... Wx.c I did, with no effect. Any other suggestions? > ^C # stop it just after it outputs the command > $ CC .... Wx.cpp # the line compiling the file with Wx.c => Wx.cpp/.cxx/.cc ... > does it compile or not? > > Regards > Mattia Thanks again. Farzin |