Bernd Schoeller wrote:
> I have successfully compiled Gobo (including gec) under OpenBSD. As a
> result, gec is now the first Eiffel compiler that has been ported to
> OpenBSD.
Wow, you're too fast ;-) I'm still ironing a few things and
writing the embryo of the doc (listing what is not implemented
yet) before asking people to try to compile Gobo with gec
on their computer with their C compiler.
> The 'security enhanced' gcc compiler of OpenBSD issues a couple of
> warnings about the use of 'sprintf' and 'strcpy' (which OpenBSD
> requires be replaced by their safe counterparts):
>
> /tmp//ccIg2494.o(.text+0x173068): In function `file_creatable':
> : warning: strcpy() is almost always misused, please use strlcpy()
> /tmp//ccIg2494.o(.text+0x17348b): In function `file_owner':
> : warning: sprintf() is often misused, please use snprintf()
OK, I'll have a look at that, but I don't care that much because
it is to implement some features from FreeELKS's file classes
but these classes really owe to reduce their interface with C.
> Normally, OpenBSD is a challenge to any c-producing compiler, as it
> uses lots of enhanced techniques to defend against buffer-overflows
> (pro-police stack guard, mmap instead of brk for malloc, randomized
> heap locations). Gobo seems to be clean with respect to these issues.
Good.
> The bootstrapping works as expected: create the 'gec.c' and 'gec.h'
> files under Linux, copy them to OpenBSD, compile a 'gec'-binary
> manually, add it to the path, do '$GOBO/work/bootstrap/bootstrap.sh'.
I wanted to wait before adding gec.[ch] to the bootstrap. I
first want to get feedback from people trying to compile
Gobo with gec with different C compilers on different
platforms. But as I said above, I'm not quite ready yet.
Almost...
> I have some problems to compile 'gexslt':
All Eiffel compilers have problems compiling gexslt!
> First I had a ulimit for processes at 512MB, which made 'gec' produce
> a segmentation violation, caused by an 'out-of-memory' call to
> gealloc. A nicer error message would be appreciated here.
Yes, but you're too fast again ;-) gec does not support exceptions
yet. Therefore you don't get a No-more-memory exception yet.
> Then, compiling gexslt required too much memory for the first host
> (that machine had 512MB of RAM). I stopped at 814M, but then swapping
> locked down the OS.
>
> On a second host (1500MB of RAM under VMWare), I managed to generate
> the C code. Then I had to add '#include <sys/timeb.h>' to the .h-file
> for the C compilation to start.
Do you know what requires this include file? Is it something
part of the generated C code, or something in one of the C
files in $GOBO/misc/gec/runtime/c?
> In the end, gcc terminates with:
>
> cc1: out of memory allocating 18296555516 bytes after a total of 0 bytes
I didn't have time to let gec be able to generate several
smaller C files instead of a huge one. When that will be
implemented perhaps this will help things a bit.
--
Eric Bezault
mailto:
[hidden email]
http://www.gobosoft.com-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642_______________________________________________
gobo-eiffel-develop mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gobo-eiffel-develop