[ns] a probelm when compiling
Gautam - Chakrabarti
chakra10@msu.edu
Wed Apr 24 15:45:02 2002
yeah its me I guess who gave the earlier "solution". I found this
problem with gcc is kinda famous among users trying to install those
versions, i havent solved it myself, but u can try searching google with
something like "gcc installation problem" or "gcc streampos" or .... ,
actually it seemed to me earlier streampos was defined as "long long",
which they have changed later, so half of ur gcc is old, half is new.
Btw, I got this from google, searching it gives a patch that u can
install for gcc....
best wishes,
gautam
Zhikui Wang wrote:
>
> Hi, I have when compling a new .cc file as following, did anybody ever
> meet with it?
>
> c++ ...... fast.cc
> In file included from /usr/include/g++-3/iostream.h: 32, from
> tcp/fast.cc:51:
>
> /usr/include/g++-3/streambuf.h: In method 'streampos streambuf::pubseekoff
> (long long int, ios::seek_dir, int)":
> /usr/include/g++-3/streambuf.h: 362: conversion from '__off64_t' to
> non-scalar type 'streampos' requested
> /usr/include/g++-3/streambuf.h: In method 'streampos streambuf::pubseekpos
> (_G_fpos64_t, int)':
> /usr/include/g++-3/streambuf.h: 364: cannot convert 'streampos' to 'long
> long int' for argument '2' to '_IO_seekpos (_IO_FILE *, long long int,
> int)'
>
> make: *** [tcp/fast.o] Error 1.
>
> Actually, when I first instaled NS, there was another similar problems
> as following, and I used gcc 2.95.3. Somebody told me that it was caused
> by the lower version of gcc. Now I had gcc 2.96 installed. Problem still
> exists. Do you have any idea? Or is there any special configuration of
> gcc?
>
> BTW: linux redhat 7.0.
>
> thanks,
>
> zhikui
>
> > c++ ..... /src_rtg/classifier-sr.o src_rtg/classifier-sr.cc
> > In file included from
> > /usr/lib/gcc-lib/i386-redhat-linux/2.95.3/../../../../include/g++-3/iostream.h:31,
> > from src_rtg/classifier-sr.cc:38:
> > /usr/lib/gcc-lib/i386-redhat-linux/2.95.3/../../../../include/g++-3/streambuf.h:
> > In method 'struct streampos streambuf::pubseekoff(long long int,
> > ios::seek_dir, int=3)':
> > ....../streambuf.h:362: conversion from '__off64_t' to non-scalar type
> > 'streampos' requested
> > ....../streambuf.h: In method 'struct streampos
> > streambuf::pubseekpos(_G_fpos64_t,int=3)':
> > ....../streambuf.h: 364 'struct streampos' used where a 'long long int'
> > was expected
> > make: ***[src_rtg/calssifier-sr.0] Error 1
> >
--
***************************************************************
Gautam Chakrabarti
MS Student
Computer Sc. and Engg Department
Michigan State University
Email : chakra10@msu.edu
Home Page : http://www.cse.msu.edu/~chakra10
Why is there so much month left at the end of the money?
--- John Barrymore
***************************************************************