Apache OpenOffice (AOO) Bugzilla – Issue 30346
astdump.cxx does not compile under Solaris/x86
Last modified: 2005-02-15 15:27:56 UTC
While trying to build ooo20040620 I'm getting the following: Making: ../unxsoli4.pro/obj/astdump.obj CC -c -temp=/tmp -I. -I. -I../inc -I../inc -I../unx/inc -I../unxsoli4.pro/inc -I. -I/home/doehrm/oocvs/solver/680/unxsoli4.pro/inc/stl -I/ home/doehrm/oocvs/solver/680/unxsoli4.pro/inc/external -I/home/doehrm/oocvs/solver/680/unxsoli4.pro/inc -I/home/doehrm/oocvs/solenv/unxsoli4 /inc -I/home/doehrm/oocvs/solenv/inc -I/home/doehrm/oocvs/res -I/home/doehrm/oocvs/solver/680/unxsoli4.pro/inc/stl/SC5 -I/include -I/home/d oehrm/oocvs/solenv/inc/Xp31 -I/usr/java/include -I/usr/java/include/solaris -I/usr/java/include/native_threads/include -I. -I../res -I. -O -features=no%altspell,no%localfor -instances=static -KPIC -DSOLARIS -DUNX -DVCL -DC52 -DC52 -DINTEL -DCVER=C52 -D_USE_NAMESPACE -D_PT HREADS -DSYSV -DSUN -DSUN4 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -DSTLPORT_VERSION=400 -D_PTHREADS -D__DMAKE -DUNIX -DCPPU_ENV=sunpro5 -DS UPD=680 -DPRODUCT -DNDEBUG -DPRODUCT_FULL -DOSL_DEBUG_LEVEL=0 -DOPTIMIZE -DEXCEPTIONS_ON -DCUI -DSOLAR_JAVA -DSRC680 -DMULTITHREAD -o .. /unxsoli4.pro/obj/astdump.o /home/doehrm/oocvs/idlc/source/astdump.cxx "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 257: Error: Cannot cast away const or volatile. "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 304: Error: Cannot cast away const or volatile. "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 309: Error: Cannot cast away const or volatile. "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 315: Error: Cannot cast away const or volatile. "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 329: Error: Cannot cast away const or volatile. "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 342: Error: Cannot cast away const or volatile. "/home/doehrm/oocvs/idlc/source/astdump.cxx", line 354: Error: Cannot cast away const or volatile. 7 Error(s) detected. dmake: Error code 7, while making '../unxsoli4.pro/obj/astdump.obj' This is > uname -a SunOS plonk 5.9 Generic_112234-12 i86pc i386 i86pc > CC -V CC: Sun WorkShop 6 update 2 C++ 5.3 Patch 111686-20 2004/03/19 There was some time ago a discussion on the dev list with sander (AFAIR) that this compiler should be supported.
Juergen, please take care of this.
I got the info that this compiler is not supported. So if you have a patch i will check it and will integrate it if possible. Otherwise i will take a look on it when i have time and when i found an appropraite compler.
set target
So which compiler should be used on Solaris 9/x86? Studio 8 does not work either (other error earlier - if necessary I can find out)
reopening. I'm at this one now too. I will try to propose solution for this.
BTW: I'm on Solaris/SPARC with CC: Sun WorkShop 6 update 2 C++ 5.3 Patch 111685-10 2002/09/16
The attached patch fixes the whole idlc issue for me.
Created attachment 16468 [details] Replace static_casts with classic casts
jsc: back to you. See hr's comments in http://www.openoffice.org/issues/show_bug.cgi?id=26098 about those staic_casts.
Fixes the error for me too - thanx a lot for this fix! :-)
The same issue is in vcl: diff -ur ooo_cws_src680_ooo20040704_src.orig/vcl/unx/source/app/saldisp.cxx ooo_cws_src680_ooo20040704_src/vcl/unx/source/app/saldisp.cxx --- ooo_cws_src680_ooo20040704_src.orig/vcl/unx/source/app/saldisp.cxx 2004-07-17 08:40:35.000000000 +0200 +++ ooo_cws_src680_ooo20040704_src/vcl/unx/source/app/saldisp.cxx 2004-07-17 08:41:16.000000000 +0200 @@ -2436,7 +2436,7 @@ std::list< SalFrame* >::const_iterator it; for( it = m_aFrames.begin(); it != m_aFrames.end(); ++it ) { - X11SalFrame* pFrame = static_cast< X11SalFrame* >(*it); + X11SalFrame* pFrame = (X11SalFrame*)(*it); if( pFrame->GetWindow() == aWindow || pFrame->GetShellWindow() == aWindow ) { aWindow = pFrame->GetWindow(); @@ -2500,7 +2500,7 @@ std::list< SalFrame* >::const_iterator it; for( it = m_aFrames.begin(); it != m_aFrames.end(); ++it ) { - X11SalFrame* pFrame = static_cast< X11SalFrame* >(*it); + X11SalFrame* pFrame = (X11SalFrame*)(*it); XLIB_Window aDispatchWindow = pEvent->xany.window; if( pFrame->GetWindow() == aDispatchWindow || pFrame->GetShellWindow() == aDispatchWindow doehrm: can you confirm this too?
i will integrate this patch asap but again this is not a supported compiler and you will probably run into problems again and again.
Again my question as already posted: Which compiler is supported on Solaris/x86? The configure scripts checks for WS6U2 and the next supported Version is Studio 8 IMHO.
jsc: I'd suggest consulting with C++ experts inside Sun. I do not know C++ very well. I'll attach complete vcl patch (more places there need fixes). My Solaris/SPARC build is currently at sd project.
Created attachment 16581 [details] VCL static casts fix
please submit a seperate issue for the VCL patch. It's a different project and i won't patch it. Thanks
jsc: done - see #i31733#.
The compiler which is currently used is CC: Sun C++ 5.5 Patch 113817-03 2003/10/14 Some older compilers are supported as well but the Workshop 6 update 2 was to bad. The compiler has a bad quality and works only with some patches reasonable. The compiler is accepted but not officially supported, we give no guarantee and we recommend to use a newer one.
Yes, this is true for SPARC but this compiler is not available for Intel...
The forte 7 compiler was not available for Intel but this is Forte 8 and that is exactly the reason why we have switched for Sparc to this compiler as well. We want use the same compiler for both platforms.
fixed -> patch integrated on cws sdksample
integrate patch
checked on master m78