Please help, I can't solve this

Hello,

I'm trying to evaluate OpenCascade in linux64 Fedora Core6. It is becoming impossible.
As it doens't come with precompiled binaries for 64 bits I have to compile it.

Its own libtool script returns the following problem when building:
libtool: unrecognized option `--tag=CXX'

It is made by the ./configure coming with OCC sources, so it should work... but it doesn't

Then I tried with a script that removes that tag, and passes the rest to the this libtool one.
Then I get this error:

********
../../../drv/Dico/Dico_DictionaryOfInteger_0.cxx: In function 'Handle_Standard_Type& Dico_DictionaryOfInteger_Type_()':
../../../drv/Dico/Dico_DictionaryOfInteger_0.cxx:51: error: 'Standard_Transient_Type_' was not declared in this scope
********

I would like to test this software a bit before thinking on some support, so please, help me because I'm lost currently.

Thank you very much.

Alvaro's picture

It works now:

I should have checked another thread where a similar problem was solved. If you have that problem, solve it this way:

export CXXFLAGS="-m64 -D_OCC64 -ffriend-injection"
export CFLAGS="-m64 -D_OCC64 -ffriend-injection"

./configure

make

It turns out that the new gcc compiler needs the -ffriend flag in order to compile properly. The others are just for the 64 bits platform.

Alvaro's picture

WELL, A new compilation problem:

../../../inc/Standard_ErrorHandlerCallback.hxx:64: error: extra qualification 'Standard_ErrorHandlerCallback::' on member 'Standard_ErrorHandlerCallback'

what is this??

Alvaro's picture

This seems to be a speech for myself.

I solved that issue with the compiler flag "-fpermissive"

It turns out that both "-ffriend-injection" and "-fpermissive" are workarounds for nonconforming code. The fact is that OpenCascade has been programmed using some currently gcc deprecated C++ syntax. This is an issue with other programs/libraries as well that have to either update their code or use some of these flags.

I would ask the OpenCascade team to do something at this respect. As a potential client, I would see this as an important point for an underlaying library of these dimensions.