Home Help Center

Ice3 compiling error with gcc 4.1.0

Hello, Ice developers,

I understand that gcc 4.x is not supported right now. I tried to fix the problem myself, but with no luck with my limited C++ experience. So I posted the error message here in the hope that you may come up with some quick fix or some suggestions.

I am using Fedora Core development branch. 'gcc -v' displays information as below:
Using built-in specs.
Target: i386-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --host=i386-redhat-linux
Thread model: posix
gcc version 4.1.0 20051214 (Red Hat 4.1.0-0.9)

The error message is:

making all in src
make[1]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src'
making all in IceUtil
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/IceUtil'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/IceUtil'
making all in icecpp
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/icecpp'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/icecpp'
making all in Slice
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/Slice'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/Slice'
making all in slice2cpp
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2cpp'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2cpp'
making all in slice2cs
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2cs'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2cs'
making all in slice2vb
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2vb'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2vb'
making all in slice2freeze
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2freeze'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2freeze'
making all in slice2freezej
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2freezej'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2freezej'
making all in slice2docbook
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2docbook'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2docbook'
making all in slice2java
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2java'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2java'
making all in slice2py
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/slice2py'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/slice2py'
making all in Ice
make[2]: Entering directory `/home/gyang/tmp/Ice-3.0.0/src/Ice'
c++ -c -I.. -I../../include -DICE_API_EXPORTS -ftemplate-depth-128 -Wall -D_REENTRANT -fPIC -g CommunicatorI.cpp
../../include/Ice/ProxyHandle.h: In destructor ‘IceInternal::ProxyHandle<T>::~ProxyHandle() [with T = IceProxy::Ice::Router]’:
CommunicatorI.cpp:198: instantiated from here
../../include/Ice/ProxyHandle.h:172: error: no matching function for call to ‘decRef(IceProxy::Ice::Router*&)’
../../include/Ice/DynamicLibraryF.h:20: note: candidates are: void IceInternal::decRef(IceInternal::DynamicLibrary*)
../../include/Ice/DynamicLibraryF.h:25: note: void IceInternal::decRef(IceInternal::DynamicLibraryList*)
../../include/Ice/LocalObjectF.h:26: note: void IceInternal::decRef(Ice::LocalObject*)
../../include/Ice/ProxyF.h:68: note: void IceInternal::decRef(IceProxy::Ice::Object*)
../../include/Ice/ProxyF.h:71: note: void IceInternal::decRef(IceDelegate::Ice::Object*)
../../include/Ice/ProxyF.h:74: note: void IceInternal::decRef(IceDelegateM::Ice::Object*)
../../include/Ice/ProxyF.h:77: note: void IceInternal::decRef(IceDelegateD::Ice::Object*)
../../include/Ice/ProxyHandle.h: In copy constructor ‘IceInternal::ProxyHandle<T>::ProxyHandle(const IceInternal::ProxyHandle<T>&) [with T = IceProxy::Ice::Router]’:
CommunicatorI.cpp:198: instantiated from here
../../include/Ice/ProxyHandle.h:164: error: no matching function for call to ‘incRef(IceProxy::Ice::Router*&)’
../../include/Ice/DynamicLibraryF.h:19: note: candidates are: void IceInternal::incRef(IceInternal::DynamicLibrary*)
../../include/Ice/DynamicLibraryF.h:24: note: void IceInternal::incRef(IceInternal::DynamicLibraryList*)
../../include/Ice/LocalObjectF.h:25: note: void IceInternal::incRef(Ice::LocalObject*)
../../include/Ice/ProxyF.h:67: note: void IceInternal::incRef(IceProxy::Ice::Object*)
../../include/Ice/ProxyF.h:70: note: void IceInternal::incRef(IceDelegate::Ice::Object*)
../../include/Ice/ProxyF.h:73: note: void IceInternal::incRef(IceDelegateM::Ice::Object*)
../../include/Ice/ProxyF.h:76: note: void IceInternal::incRef(IceDelegateD::Ice::Object*)
make[2]: *** [CommunicatorI.o] Error 1
make[2]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src/Ice'
make[1]: *** [all] Error 1
make[1]: Leaving directory `/home/gyang/tmp/Ice-3.0.0/src'
make: *** [all] Error 1

I found that there is a declaration of

IceInternal::decRef(IceProxy::Ice::Router*)

in Proxy.h.

But I can not understand why it is not found by the compiler. Is this a problem of Ice or a problem of the compiler?

Thanks,
Guo

Comments

  • umberumber Member
    And may I ask another basic question here about the "CommunicatorI.cpp"?

    I saw that there is a include statement at the beginning of the file
    #include <Ice/CommunicatorI.h>

    Since Communicator.h is at the same directory with CommunicatorI.cpp, not in the ../../include. As my understanding, usually it will be included as "CommunicatorI.h".

    Is there any specific reason it is included in the former form? Thanks.
  • marcmarc FloridaAdministrators, ZeroC Staff Marc LaukienOrganization: ZeroC, Inc.Project: The Internet Communications Engine ZeroC Staff
    I'm afraid we can't help with the GCC 4.1 problem. We have not tested Ice with GCC 4.1 yet (it is not yet a supported compiler). If you have a commercial need for using Ice with this compiler, please contact us at [email protected].

    We include all C++ header files prefixed with "Ice/", because this makes it easier to move files from private to public or vice versa, should the need arise. In any case, this is purely an internal coding style issue, and has no impact on applications that use Ice.
Sign In or Register to comment.