Joined: Jun 07, 2003 Posts: 234 Location: near Cologne, Germany
Posted: Fri Oct 10, 2003 8:42 am Post subject:
Ed,
I've another compiling issue with stlport:
=============
Building project stlport
=============
/neooffice/stlport
-------------
mkdir ./unxmacxp.pro/misc/build/STLport-4.5/src
mkdir: ./unxmacxp.pro/misc/build/STLport-4.5/src: File exists
cd ./unxmacxp.pro/misc/build/STLport-4.5/src && make -f gcc-3.0-macosx.mak -j1 && touch so_built_so_stlport
g++ -I../stlport -D_REENTRANT -D_PTHREADS -ftemplate-depth-32 -malign-natural -no-cpp-precomp -fexceptions -Wall -W -Wno-sign-compare -Wno-unused -Wno-uninitialized -Wno-long-double -O2 -fPIC dll_main.cpp -c -o ../lib/obj/GCC/ReleaseD/dll_main.o
In file included from stlport_prefix.h:28,
from dll_main.cpp:34:
../stlport/ctime:32: error: `size_t' not declared
../stlport/ctime:33: error: `clock_t' not declared
../stlport/ctime:34: error: `time_t' not declared
../stlport/ctime:35: error: `tm' not declared
../stlport/ctime:37: error: `clock' not declared
../stlport/ctime:38: error: `asctime' not declared
../stlport/ctime:39: error: `ctime' not declared
../stlport/ctime:40: error: `gmtime' not declared
../stlport/ctime:41: error: `difftime' not declared
../stlport/ctime:42: error: `mktime' not declared
../stlport/ctime:43: error: `localtime' not declared
../stlport/ctime:44: error: `strftime' not declared
../stlport/ctime:45: error: `time' not declared
In file included from dll_main.cpp:34:
stlport_prefix.h:30: error: `time_t' not declared
In file included from ../stlport/stl/debug/_debug.c:160,
from ../stlport/stl/debug/_debug.h:418,
from ../stlport/utility:36,
from dll_main.cpp:36:
../stlport/cstdlib:42: error: `div_t' not declared
../stlport/cstdlib:43: error: `ldiv_t' not declared
../stlport/cstdlib:44: error: `size_t' not declared
../stlport/cstdlib:47: error: `abort' not declared
../stlport/cstdlib:48: error: `atexit' not declared
../stlport/cstdlib:49: error: `exit' not declared
../stlport/cstdlib:50: error: `getenv' not declared
../stlport/cstdlib:51: error: `calloc' not declared
../stlport/cstdlib:52: error: `free' not declared
../stlport/cstdlib:53: error: `malloc' not declared
../stlport/cstdlib:54: error: `realloc' not declared
../stlport/cstdlib:55: error: `atof' not declared
../stlport/cstdlib:56: error: `atoi' not declared
../stlport/cstdlib:57: error: `atol' not declared
../stlport/cstdlib:58: error: `mblen' not declared
../stlport/cstdlib:59: error: `mbstowcs' not declared
../stlport/cstdlib:60: error: `mbtowc' not declared
../stlport/cstdlib:61: error: `strtod' not declared
../stlport/cstdlib:62: error: `strtol' not declared
../stlport/cstdlib:63: error: `strtoul' not declared
../stlport/cstdlib:64: error: `system' not declared
../stlport/cstdlib:70: error: `bsearch' not declared
../stlport/cstdlib:71: error: `qsort' not declared
../stlport/cstdlib:74: error: `abs' not declared
../stlport/cstdlib:76: error: `div' not declared
../stlport/cstdlib:77: error: `labs' not declared
../stlport/cstdlib:78: error: `ldiv' not declared
../stlport/cstdlib:79: error: `rand' not declared
../stlport/cstdlib:80: error: `srand' not declared
In file included from ../stlport/stl/debug/_debug.c:236,
from ../stlport/stl/debug/_debug.h:418,
from ../stlport/utility:36,
from dll_main.cpp:36:
../stlport/cstdarg:32: error: `va_list' not declared
In file included from ../stlport/stl/debug/_debug.c:237,
from ../stlport/stl/debug/_debug.h:418,
from ../stlport/utility:36,
from dll_main.cpp:36:
../stlport/cstdio:51: error: `FILE' not declared
../stlport/cstdio:52: error: `fpos_t' not declared
../stlport/cstdio:53: error: `size_t' not declared
../stlport/cstdio:64: error: `clearerr' not declared
../stlport/cstdio:65: error: `fclose' not declared
../stlport/cstdio:66: error: `feof' not declared
../stlport/cstdio:67: error: `ferror' not declared
../stlport/cstdio:68: error: `fflush' not declared
../stlport/cstdio:69: error: `fgetc' not declared
../stlport/cstdio:70: error: `fgetpos' not declared
../stlport/cstdio:71: error: `fgets' not declared
../stlport/cstdio:72: error: `fopen' not declared
../stlport/cstdio:73: error: `fprintf' not declared
../stlport/cstdio:74: error: `fputc' not declared
../stlport/cstdio:75: error: `fputs' not declared
../stlport/cstdio:76: error: `fread' not declared
../stlport/cstdio:77: error: `freopen' not declared
../stlport/cstdio:78: error: `fscanf' not declared
../stlport/cstdio:79: error: `fseek' not declared
../stlport/cstdio:80: error: `fsetpos' not declared
../stlport/cstdio:81: error: `ftell' not declared
../stlport/cstdio:82: error: `fwrite' not declared
../stlport/cstdio:85: error: `getc' not declared
../stlport/cstdio:86: error: `getchar' not declared
../stlport/cstdio:87: error: `putc' not declared
../stlport/cstdio:88: error: `putchar' not declared
../stlport/cstdio:91: error: `gets' not declared
../stlport/cstdio:92: error: `perror' not declared
../stlport/cstdio:93: error: `printf' not declared
../stlport/cstdio:94: error: `puts' not declared
../stlport/cstdio:95: error: `remove' not declared
../stlport/cstdio:96: error: `rename' not declared
../stlport/cstdio:97: error: `rewind' not declared
../stlport/cstdio:98: error: `scanf' not declared
../stlport/cstdio:99: error: `setbuf' not declared
../stlport/cstdio:100: error: `setvbuf' not declared
../stlport/cstdio:101: error: `sprintf' not declared
../stlport/cstdio:102: error: `sscanf' not declared
../stlport/cstdio:103: error: `tmpfile' not declared
../stlport/cstdio:104: error: `tmpnam' not declared
../stlport/cstdio:105: error: `ungetc' not declared
../stlport/cstdio:106: error: `vfprintf' not declared
../stlport/cstdio:107: error: `vprintf' not declared
../stlport/cstdio:108: error: `vsprintf' not declared
In file included from ../stlport/stl/debug/_debug.h:418,
from ../stlport/utility:36,
from dll_main.cpp:36:
../stlport/stl/debug/_debug.c: In static member function `static void
_STL::__stl_debug_engine<_Dummy>::_Message(const char*, ...)':
../stlport/stl/debug/_debug.c:245: error: parse error before `;' token
In file included from ../stlport/stl/_alloc.h:31,
from ../stlport/memory:28,
from dll_main.cpp:38:
../stlport/cstddef: At global scope:
../stlport/cstddef:42: error: `ptrdiff_t' not declared
../stlport/cstddef:43: error: `size_t' not declared
In file included from ../stlport/cstring:32,
from ../stlport/stl/_alloc.h:42,
from ../stlport/memory:28,
from dll_main.cpp:38:
../stlport/using/cstring:1: error: `size_t' not declared
../stlport/using/cstring:17: error: `memmove' not declared
../stlport/using/cstring:18: error: `memcpy' not declared
../stlport/using/cstring:23: error: `memchr' not declared
../stlport/using/cstring:24: error: `strchr' not declared
../stlport/using/cstring:25: error: `strpbrk' not declared
../stlport/using/cstring:26: error: `strrchr' not declared
../stlport/using/cstring:27: error: `strstr' not declared
../stlport/using/cstring:30: error: `memcmp' not declared
../stlport/using/cstring:31: error: `memset' not declared
../stlport/using/cstring:33: error: `strcat' not declared
../stlport/using/cstring:36: error: `strcmp' not declared
../stlport/using/cstring:39: error: `strcoll' not declared
../stlport/using/cstring:41: error: `strcpy' not declared
../stlport/using/cstring:43: error: `strcspn' not declared
../stlport/using/cstring:44: error: `strerror' not declared
../stlport/using/cstring:45: error: `strlen' not declared
../stlport/using/cstring:46: error: `strncat' not declared
../stlport/using/cstring:47: error: `strncmp' not declared
../stlport/using/cstring:49: error: `strncpy' not declared
../stlport/using/cstring:50: error: `strspn' not declared
../stlport/using/cstring:52: error: `strtok' not declared
../stlport/using/cstring:53: error: `strxfrm' not declared
In file included from ../stlport/stl/_alloc.h:64,
from ../stlport/memory:28,
from dll_main.cpp:38:
../stlport/stl/_threads.h: In member function `void
_STL::_STLP_mutex_indirect::_M_initialize()':
../stlport/stl/_threads.h:340: error: `calloc' undeclared in namespace `std'
In file included from ../stlport/stl/_threads.h:552,
from ../stlport/stl/_alloc.h:64,
from ../stlport/memory:28,
from dll_main.cpp:38:
../stlport/stl/_threads.c: At global scope:
../stlport/stl/_threads.c:36: error: `time_t' not declared
In file included from ../stlport/cwchar:27,
from ../stlport/stl/_limits.h:36,
from ../stlport/limits:28,
from dll_main.cpp:44:
../stlport/stl/_cwchar.h:168: error: `size_t' not declared
In file included from ../stlport/stl/_string.h:27,
from ../stlport/string:42,
from dll_main.cpp:45:
../stlport/cctype:52: error: `isalnum' not declared
../stlport/cctype:53: error: `isalpha' not declared
../stlport/cctype:54: error: `iscntrl' not declared
../stlport/cctype:55: error: `isdigit' not declared
../stlport/cctype:56: error: `isgraph' not declared
../stlport/cctype:57: error: `islower' not declared
../stlport/cctype:58: error: `isprint' not declared
../stlport/cctype:59: error: `ispunct' not declared
../stlport/cctype:60: error: `isspace' not declared
../stlport/cctype:61: error: `isupper' not declared
../stlport/cctype:62: error: `isxdigit' not declared
../stlport/cctype:63: error: `tolower' not declared
../stlport/cctype:64: error: `toupper' not declared
../stlport/stl/debug/_debug.c: In static member function `static void
_STL::__stl_debug_engine<_Dummy>::_Message(const char*, ...) [with _Dummy =
bool]':
dll_main.cpp:147: instantiated from here
../stlport/stl/debug/_debug.c:246: error: `__args' undeclared (first use this
function)
../stlport/stl/debug/_debug.c:246: error: (Each undeclared identifier is
reported only once for each function it appears in.)
../stlport/stl/debug/_debug.c:263: error: `vfprintf' undeclared in namespace `
std'
make: *** [../lib/obj/GCC/ReleaseD/dll_main.o] Error 1
dmake: Error code 2, while making './unxmacxp.pro/misc/build/so_built_so_stlport'
---* TG_SLO.MK *---
ERROR: Error 65280 occurred while making /neooffice/stlport
dmake: Error code 1, while making 'build_all'
---* TG_SLO.MK *---
Joined: May 25, 2003 Posts: 4752 Location: Santa Barbara, CA
Posted: Fri Oct 10, 2003 10:08 am Post subject:
Hrm, yeah, I didn't see any problems with stlport at all. Let's check compiler version:
Code:
[vishnu:~] peterlin% gcc --version
gcc (GCC) 3.3 20030304 (Apple Computer, Inc. build 1435)
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
There are a couple of different gcc 3.3 builds out there. I'm thinking of rerunning the August 2003 gcc 3.3 updater to make sure I've got the latest version. I remember hearing of some stuff that didn't work in the June (?) one but did work in the update to it.
Joined: Jun 07, 2003 Posts: 234 Location: near Cologne, Germany
Posted: Fri Oct 10, 2003 10:21 am Post subject:
Ed,
you're right, we have indeed different versions of gcc:
Code:
[SchlesisPowerbook:~] thomas% gcc --version
gcc (GCC) 3.3 20030304 (Apple Computer, Inc. build 1493)
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
FWIW guys, there are _two_ versions of gcc 3.3 floating around, like you've noticed. There are:
June WWDC: released at WWDC, termed "Gold Master" gcc 3.3 release
August G5: updated with optimizations and support for G5 processors
I personally still have the June WWDC version, because you _cannot_ apply the August update over a June update, you have to re-install the December 2002 Developer Tools CD and then apply the August G5 update. That's just dumb in my opinion.
Thanks for getting the errors ironed out Ed, I was kicking myself in the head last night because sablot was being so stupid. I surmised it was a preprocessor issue, but never would have guessed the sizeof() thing. Perhaps its time to start submitting bugs to Apple?
Before this all starts to get out of hand, I'm going to remove the global -ObjC++ and enable ObjectiveC++ _only_ for sal and vcl modules. I don't think the ABI is any different between the two, so we'll see how it goes. If any other modules need ObjC++ then we can enable it for those modules.
Joined: May 25, 2003 Posts: 4752 Location: Santa Barbara, CA
Posted: Fri Oct 10, 2003 10:16 pm Post subject:
Yeah Dan, I think you may have the right solution in turning off that global ObjC++ flag, especially since this seems to be another damn preprocessing error ObjC++ and C++ should have the same ABI on principle as they're being emitted by the same compiler. There's never any "cross-pollination" in ObjC++. The C++ declarations and method invocations must be explicitly separated from the ObjC method invocations, and similarly for the classes.
I would be all for trying to submit bug reports to Apple, but I tried simple test cases and didn't find the failures. From our past experiences, if the test case isn't whittled down to the bare minimum I don't think it'd get addressed. Not to mention the Neo codebase may be (or, well, may have been) one of the largest to use ObjC++.
I think the Mozilla project experienced similar issues with the C++ side of things as well, that their code built differnetly on different compiler versions. That's really creepy, though, that stlport would work on an older compiler version (mine) and not work on a newer one (yours). Apparently that August update did more then just add in G5 compatibility.
schlesi wrote:
May be we'll run into more problems when upgrading gcc in future?
Blech. Probably most certainly. I had hoped we would have put these behind us with the advent of gcc 3.3, but apparently not
Joined: May 25, 2003 Posts: 4752 Location: Santa Barbara, CA
Posted: Fri Oct 10, 2003 11:05 pm Post subject:
Yes, Dan, I confirmed removing the global ObjC++ flag removes my latest compile error in cppuhelper dealing with XProxyFacory.hdl as well.
I know how to turn ObjC++ off globally, but I'm busy looking for a better way of enabling it for an entire module instead of just adding it to every makefile.mk in the module. AFAIK vcl requires it...do we have any ObjC inlines in sal yet? Grepping didn't yield any #import statements...
Joined: May 25, 2003 Posts: 4752 Location: Santa Barbara, CA
Posted: Sat Oct 11, 2003 1:02 am Post subject: Committed removal of ObjC++
OK, I committed the removal of the global -ObjC++ flag throwing. Affected modules:
solenv
vcl
Within VCL, I added the ObjC++ flag to all of the subdirectories of vcl/aqua as well as vcl/source/window, vcl/source/control, and vcl/source/app. Off the top of my head that seemed like the most evident subset of code that used ObjC inlined code and didn't have files with an explicit .m or .mm extension.
I recompiled sal without the ObjC++ flag and had no compiler errors (June gcc 3.3...that's the one I'm using apparently in my default environment)
I just committed changes to enable ObjC++ module-wide for sal and vcl in unxmacxp.mk, and removed the per-makefile options from vcl as well.
Still dies in ilstbox though
I also committed some changes to a few other things. Ripped from the commit log:
1) Remove per-makefile ObjC++ flags, move to per-modules ones specified
in solenv/inc/unxmacxp.mk
2) Convert aqua/source/app/salsys.cxx to 1.1 version from Unix side (I assume
some members changed and therefore the 1.1 Unix one was more correct)
3) Don't allow salinst.cxx to specify bit-depth of VirtualDevices since they
should all be 32-bit anyway.
4) Remove cruft code from salmain.cxx
5) Random things to salbmp (don't set color mask, add debug printf)
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You cannot download files in this forum