[Insight-users] gcc-2.95.2 compile error? : Nope, No compile
error.
Luis Ibanez
luis . ibanez at kitware . com
Tue, 30 Sep 2003 17:51:24 -0400
Hi Feng,
ITK builds fine with gcc-2.95.
I just submitted an experimental build to the Dashboard.
http://www . itk . org/Testing/Dashboard/20030930-0500-Nightly/Dashboard . html
Please look at "starsend.kitware" in the Experimental builds.
http://www . itk . org/Testing/Sites/starsend . kitware/Linux-gcc-295/20030930-2110-Experimental/BuildError . html
Your compilation problem may originate from:
A) a compiler installation problem.
since you are using both gcc 2.95 and gcc 3.3
OR
B) a CMake configuration problem.
A typical first suspect is the pair of environment
variables "CC" and "CXX".
Please make sure that CC is set to gcc-2.95 and
CXX is set to g++-2.95, before you run "ccmake".
You may have to start from a clean new binary
directory, since it is possible that your previous
configurations were inconsistent.
---
If the legacy code compiled with gcc-2.95 is C++ code,
you may have to build ITK using the *same* compiler.
Unless the classes in the legacy code are completely
encapsulated and are not visible from your application.
(which is unlikely).
Regards,
Luis
----------------
Feng Ma wrote:
> Hi,
>
> I am linking ITK together with some legacy code which was compiled with
> gcc-2.95.2. When I tried to compile ITK with gcc-2.95.2, I got the
> following error:
>
> /r2net/r2/fma/ITK2.95.2/Utilities/MetaIO: building default_target
> Building object file metaBlob.o...
> In file included from
> /opt/gcc-2.95.2/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../include/g++-3/iostream.h:31,
>
> from
> /opt/gcc-2.95.2/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../include/g++-3/iostream:6,
>
> from
> /r2net/space_fma2/Devel/InsightToolkit-1.4.0/Utilities/MetaIO/metaBlob.cxx:3:
>
> /opt/gcc-2.95.2/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../include/g++-3/streambuf.h:
> In method `struct streampos streambuf::pubseekoff(long long int,
> ios::seek_dir, int = 3)':
> /opt/gcc-2.95.2/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../include/g++-3/streambuf.h:362:
> conversion from `__off64_t' to non-scalar type `streampos' requested
> /opt/gcc-2.95.2/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../include/g++-3/streambuf.h:
> In method `struct streampos streambuf::pubseekpos(_G_fpos64_t, int = 3)':
> /opt/gcc-2.95.2/lib/gcc-lib/i686-pc-linux-gnu/2.95.2/../../../../include/g++-3/streambuf.h:364:
> `struct streampos' used where a `long long int' was expected
> make[5]: *** [metaBlob.o] Error 1
>
>
> I am wondering if anyone encountered similiar problem before. I did the
> search on mailist and didn't find answers.
>
> The other question is: could I link gcc-3.3.1 compiled ITK libraries
> with other libraries compiled using gcc-2.95.2?
>
> Thanks a lot.
>
> -Feng
>
> _________________________________________________________________
> Get MSN 8 Dial-up Internet Service FREE for one month. Limited time
> offer-- sign up now! http://join . msn . com/?page=dept/dialup
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk . org
> http://www . itk . org/mailman/listinfo/insight-users
>