SGI: Development

Dillo3 - Page 1

I thought it might be a good idea to use our new gcc 4.7 and give dillo3.0.2 a try. fltk1.3 builds fine and test/demo runs without errors. dillo compiles fine also and it starts with the correct displayed startup screen (about:splash). I can open files but there is a strange 32 byte limit. I can open file:/tmp/12345678901234567890123.jpg but file:/tmp/123456789012345678901234.jpg return a 404 error. Websites don't open at all. Same behavior compiled with gcc3. Any idea?
:Tezro: :Fuel: :Octane2: :Octane: :Onyx2: :O2+: :O2: :Indy: :Indigo: :Cube:
I got a good start on compiling dillo using MIPSPro 7.4.3 last fall, the big stumbling block is the authors use of variadic macros, I'll take another look at it tonight with the newer Dillo and we can compare notes. I'm subscribed to the Dillo development list, which is very active, you might want to point these issues out there...
Project:
Temporarily lost at sea...
Plan:
World domination! Or something...
vishnu wrote: I got a good start on compiling dillo using MIPSPro 7.4.3 last fall, the big stumbling block is the authors use of variadic macros, I'll take another look at it tonight with the newer Dillo and we can compare notes. I'm subscribed to the Dillo development list, which is very active, you might want to point these issues out there...
Yes, I did this already and we ended up in:
corevid wrote: Well, I'm out of ideas for the moment. This is the point where I'd have to throw gdb at it or put in lots of MSG()s
I probably will do that, but there is a chance that this is a known problem other developers had solved in the past. And of course you are welcome to compare notes.
:Tezro: :Fuel: :Octane2: :Octane: :Onyx2: :O2+: :O2: :Indy: :Indigo: :Cube:
corevid wrote: Well, I'm out of ideas for the moment. This is the point where I'd have to throw gdb at it or put in lots of MSG()s
So corevid was trying it with gcc as well? I usually use the ProDev Workshop debugger (cvd) for stuff I've compiled with MIPSPro...
Project:
Temporarily lost at sea...
Plan:
World domination! Or something...
vishnu wrote: I got a good start on compiling dillo using MIPSPro 7.4.3 last fall, the big stumbling block is the authors use of variadic macros, I'll take another look at it tonight with the newer Dillo and we can compare notes.

hey vish :

man cc wrote: * The gcc compiler allows variadic macros; the MIPSpro 7.4 compilers
support these macros in c99 mode. If you have code that uses
ellipses (...) as part of a macro definition and you are not
compiling with c99, you will need to rewrite the macro. Two possible
approaches are to replace the macro with a new variadic function, or
to create a family of macros, each taking different (fixed) numbers
of arguments.

Worth a try with c99 ?
hamei wrote:
man cc wrote: * The gcc compiler allows variadic macros; the MIPSpro 7.4 compilers
support these macros in c99 mode. If you have code that uses
ellipses (...) as part of a macro definition and you are not
compiling with c99, you will need to rewrite the macro. Two possible
approaches are to replace the macro with a new variadic function, or
to create a family of macros, each taking different (fixed) numbers
of arguments.

Worth a try with c99 ?

I did that and some other difficulty arose that can't remember just now. Anyway, I diddled with it some more last night and managed to get a bunch of it to compile[1] but ran into a show stopper in dialog.cc:

Code: Select all

cc-1028 CC: ERROR File = dialog.cc, Line = 180
The expression used must have a constant value.

memset(pm, '\0', sizeof(Fl_Menu_Item[n_it+1]));
^


Which I have emailed the development list about.

[1] for the curious, here's what I've been able to compile so far: auth.o, bitvec.o, bookmark.o, bw.o, cache.o, capi.o, chain.o, colors.o, cookies.o, css.o, decode.o, dicache.o, digest.o, dillo.o, dns.o, dpiapi.o, gif.o, history.o, jpeg.o, keys.o, klist.o, md5.o, misc.o, paths.o, png.o, prefs.o, prefsparser.o, timeout.o, ui.o, uicmd.o, url.o, utf8.o
Project:
Temporarily lost at sea...
Plan:
World domination! Or something...
vishnu wrote: I did that and some other difficulty arose that can't remember just now.

I'm prob'ly teaching grandma to suck eggs here, but did you know that < man cc > has a ton of stuff about gcc-isms and how to get around them ? Even more than the helpful page at freeware used to have ?

This was a bit interesting ... at least we aren't the only people in the world with some unusual desires ...
http://stackoverflow.com/questions/1250 ... pplication
No replies, tho :(
hamei wrote: I'm prob'ly teaching grandma to suck eggs here, but did you know that < man cc > has a ton of stuff about gcc-isms and how to get around them?
True but what I've compiled so far has not been a problem for MIPSPro in CC (not c99) mode. The show stopper in dialog.cc is just plain bad code, and I think it's a bug that gcc doesn't see that...

hamei wrote: This was a bit interesting ... at least we aren't the only people in the world with some unusual desires ...
http://stackoverflow.com/questions/1250 ... pplication
No replies, tho :(
No replies because, with regard to what he's asking about doing, well to put it quite simply "you can't get there from here..." ;)
Project:
Temporarily lost at sea...
Plan:
World domination! Or something...
So now I'm trying to compile it in c99 mode and I'm wondering if my compiler installation is borked, could someone kindly cd into dillo's dw directory and post the output from doing this:

Code: Select all

c99 -c -w findtext.cc -o findtext.o


I get seven errors all having to do with the variadic macros, which MIPSPro 7.4's c99 is supposed to understand. :cry:

So if any of you kind people can get it to compile I'll know it's a bad compiler installation on my end.
Project:
Temporarily lost at sea...
Plan:
World domination! Or something...
Hi there,

like the OP I tried to compile Dillo3 almost a year ago, but with the same result: Build was OK, but problems with loading pages... I used gcc3 back then.

@vishnu: I tried it, and this is what I got:

Code: Select all

thoweh@species8472 $>uname -a
IRIX64 species8472 6.5 07202013 IP27
thoweh@species8472 $>c99 -version
MIPSpro Compilers: Version 7.4.4m
thoweh@species8472 $>ls
dillo-3.0.2      dillo-3.0.2.tar
thoweh@species8472 $>cd dillo-3.0.2
thoweh@species8472 $>ls
aclocal.m4         config.h.in        doc                d_size.h           Makefile.in
AUTHORS            config.sub         Doxyfile           INSTALL            missing
ChangeLog          COPYING            dpi                install-dpi-local  NEWS
configure          depcomp            dpid               install-sh         README
configure.in       dillorc            dpip               lout               src
config.guess       dlib               dw                 Makefile.am        test
thoweh@species8472 $>cd dw
thoweh@species8472 $>c99 -c -w findtext.cc -o findtext.o
cc-1040 c99: ERROR File = ../lout/msg.h, Line = 14
An identifier is expected.

#define _MSG(...)
^

cc-1040 c99: ERROR File = ../lout/msg.h, Line = 15
An identifier is expected.

#define _MSG_WARN(...)
^

cc-1040 c99: ERROR File = ../lout/msg.h, Line = 16
An identifier is expected.

#define _MSG_ERR(...)
^

cc-1040 c99: ERROR File = ../lout/msg.h, Line = 19
An identifier is expected.

#define MSG(...)                                   \
^

cc-1040 c99: ERROR File = ../lout/msg.h, Line = 27
An identifier is expected.

#define MSG_WARN(...)                              \
^

cc-1040 c99: ERROR File = ../lout/msg.h, Line = 33
An identifier is expected.

#define MSG_ERR(...)                               \
^

cc-1055 c99: ERROR File = findtext.cc, Line = 231
A macro invocation has too many arguments.

_MSG("Having to do.");
^

7 errors detected in the compilation of "findtext.cc".
thoweh@species8472 $>


Not better what you got, I suppose :(

The compiler installation is OK I think, it was done by jan-jaap before I got the machine (O2k)
:A3502L: :O2000: :O200: = :O200: - :O200: :O200: :Octane: :Octane: :320: :O2: :Indigo2IMP: :Indy:
+ | d | i | g | i | t | a | l | +apple +[...] ;)
vishnu wrote: I get seven errors all having to do with the variadic macros, which MIPSPro 7.4's c99 is supposed to understand. :cry:
So if any of you kind people can get it to compile I'll know it's a bad compiler installation on my end.

Code: Select all

Making all in dw
gmake[2]: Entering directory `/usr/people/lgeorge/downtemp/dillo-3.0.2/dw'
source='findtext.cc' object='findtext.o' libtool=no \
DEPDIR=.deps depmode=sgi /bin/ksh ../depcomp \
CC -DHAVE_CONFIG_H -I. -I..  -I.. -I/usr/local/include  -mips4 -O3 -c99 -I/usr/nekowar
e/include -I/usr/include -c -o findtext.o findtext.cc
cc-1234 CC: WARNING File = ../lout/object.hh, Line = 66
Access control is not specified ("private" by default).

class Integer: public Object, misc::Comparable
^

cc-1234 CC: WARNING File = ../lout/object.hh, Line = 85
Access control is not specified ("private" by default).

class ConstString: public Object, misc::Comparable
^

cc-1035 CC: WARNING File = /usr/include/stdint.h, Line = 5
#error directive:  This header file is to be used only for c99 mode
compilations

#error This header file is to be used only for c99 mode compilations
^

cc-1040 CC: ERROR File = ../lout/msg.h, Line = 14
An identifier is expected.

#define _MSG(...)
^

cc-1040 CC: ERROR File = ../lout/msg.h, Line = 15
An identifier is expected.

#define _MSG_WARN(...)
^

cc-1040 CC: ERROR File = ../lout/msg.h, Line = 16
An identifier is expected.

#define _MSG_ERR(...)
^

cc-1040 CC: ERROR File = ../lout/msg.h, Line = 19
An identifier is expected.

#define MSG(...)                                   \
^

cc-1040 CC: ERROR File = ../lout/msg.h, Line = 27
An identifier is expected.

#define MSG_WARN(...)                              \
^

cc-1040 CC: ERROR File = ../lout/msg.h, Line = 33
An identifier is expected.

#define MSG_ERR(...)                               \
^

cc-1055 CC: ERROR File = findtext.cc, Line = 231
A macro invocation has too many arguments.

_MSG("Having to do.");
^

7 errors detected in the compilation of "findtext.cc".
gmake[2]: *** [findtext.o] Error 2
gmake[2]: Leaving directory `/usr/people/george/downtemp/dillo-3.0.2/dw'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/people/george/downtemp/dillo-3.0.2'
gmake: *** [all] Error 2

Code: Select all

urchin 18% printenv
...
CC=c99
CXX=CC
F77=f77
CFLAGS=-mips4 -O3 -c99 -I/usr/nekoware/include -I/usr/include
CXXFLAGS=-mips4 -O3 -c99 -I/usr/nekoware/include -I/usr/include
LDFLAGS=-mips4 -L/usr/nekoware/lib -L/usr/lib32 -Wl,-rpath -Wl,/usr/nekoware/lib
LD_LIBRARY_PATH=/usr/nekoware/lib /usr/lib32
LD_LIBRARYN32_PATH=/usr/nekoware/lib:/usr/lib32
MAKE=gmake
GNUMAKE=gmake

Notice the third warning down though ? Something odd going on ?
The MIPSpro C++ compiler isn't c99 compliant, the C compiler however can be if you want (by calling it as c99 or with -c99), but that'll not help you with C++ source files. You'll have to supply a family of replacement macros with a fixed number of parameters, e.g. _MSG1(x), _MSG2(x,y) etc.
hamei wrote: Notice the third warning down though ? Something odd going on ?
I think that's a bug in the header file, a couple of the others have it too: grep "ifndef __c99" /usr/include/*.h . . . How much does sgi charge for a MIPSPro license again? :roll:
canavan wrote: The MIPSpro C++ compiler isn't c99 compliant...
Yep, I think that's the "other difficulty" I was talking about above... :lol:
Project:
Temporarily lost at sea...
Plan:
World domination! Or something...
Even if you make the code compile with mips pro you will run into the same problem of the gcc build. There is probably a problem in the IO part. Socket connections don't work at all and opening files has a strange 32byte limit in path length. I am sure this is not a problem of the gcc build.
:Tezro: :Fuel: :Octane2: :Octane: :Onyx2: :O2+: :O2: :Indy: :Indigo: :Cube:
diegel wrote: There is probably a problem in the IO part. Socket connections don't work at all and opening files has a strange 32byte limit in path length. I am sure this is not a problem of the gcc build.

A thousand eyes, a thousand hands ... and Larry, Moe and Curly in charge :P
hamei wrote:
A thousand eyes, a thousand hands ...
I'm pretty sure the Dillo team isn't that big... ;)
hamei wrote:
...and Larry, Moe and Curly in charge :P
Or that Stoogey... :lol:
Well I fixed the variadic macros enough to get it to try to compile findtext.cc, but now it's puking on dillo's use of namespaces. This might not be worth it... :x
So okay, the dillo guys are declaring three namespaces across two header files and one implementation file (findtext.cc, findtext.hh, and core.hh), MIPSPro seems to get through the header files okay but then pukes on the first namespace declaration in the implementation file. I've mimicked what I think they're doing in three much simpler test files, but MIPSPro turns those into an executable with no complaint. Perhaps the problem is with the dillo classes; my test harness just has functions not classes. Drear. I thought computers were supposed to free us from this kind of drudgery not enmesh us in it... :oops: :P
vishnu wrote:
This might not be worth it... :x

Did I forget to mention that Shep was in charge of development ?
hamei wrote:
Did I forget to mention that She m p was in charge of development ?

There, fixed that for you. ;)

_________________
Then? :IRIS3130: ... Now? :O3x02L: :1600SW: +MLA :Fuel: :Octane2: :Octane: :Indigo2IMP: ... Other: DEC :BA213: :BA123: Sun , DG AViiON , NeXT :Cube: