#include STL_STRING
SG_USING_STD(string);
-
-#if ! defined( SG_HAVE_NATIVE_SGI_COMPILERS )
SG_USING_STD(ostream);
-#endif
/**
EXTRA_DIST = README
+include_HEADERS = \
+ cfloat \
+ csetjmp \
+ cstdio \
+ cwchar \
+ iostream \
+ strstream \
+ cassert \
+ climits \
+ csignal \
+ cstdlib \
+ cwctype \
+ istream \
+ cctype \
+ clocale \
+ cstdarg \
+ cstring \
+ fstream \
+ iterator \
+ cerrno \
+ cmath \
+ cstddef \
+ ctime \
+ iomanip \
+ streambuf
+includedir = @includedir@/compatibility
+
+EXTRA_DIST = README
+
include_HEADERS = \
cfloat \
csetjmp \
#define __SG_IOSTREAM 1
# include <iostream.h>
+# include <fstream.h>
#if defined(sgi) && !defined(__GNUC__)
using ::cout;
using ::cerr;
using ::clog;
+ using ::endl;
+
using ::ios_base;
+ using ::istream;
+ using ::ostream;
+
+ using ::ifstream;
+ using ::ofstream;
};
#endif
#ifndef __SG_ISTREAM
#define __SG_ISTREAM 1
+# include <iostream>
+
#if defined(sgi) && !defined(__GNUC__)
# include <stream.h>
-# include <iostream>
+# include <string>
+
+ using std::getline;
#endif
#ifndef __SG_STREAMBUF
#define __SG_STREAMBUF 1
-#if defined(sgi) && !defined(__GNUC__)
-
-# include <char_traits.h>
# include <iostream>
+# include <char_traits.h>
-# define pubsync sync
+//
+// Until we find a good way to rename the original streambuf class
+// and derive our own streambuf class from that, define this variable
+// for now so the code can inherit our streambuf class instead.
+//
+# define SG_NEED_STREAMBUF_HACK 1
- using std::char_traits;
+class __streambuf : virtual public streambuf {
+public:
- typedef char_traits<char> traits_type;
- typedef char_traits<char>::int_type int_type;
+ typedef std::char_traits<char> traits_type;
+ typedef std::char_traits<char>::int_type int_type;
typedef streampos pos_type;
typedef streamoff off_type;
+};
+
+
+#if defined(sgi) && !defined(__GNUC__)
+
+# define pubsync sync
namespace std {
using ::streambuf;
using ::streampos;
using ::streamoff;
};
-
#endif
#endif // !__SG_STREAMBUF
#include <simgear/compiler.h>
-// At least Irix needs this
-#ifdef SG_HAVE_NATIVE_SGI_COMPILERS
-#include <char_traits.h>
-#endif
-
#ifdef SG_HAVE_STD_INCLUDES
# include <streambuf>
# include <iostream>
#include <simgear/debug/debug_types.h>
-#ifndef SG_HAVE_NATIVE_SGI_COMPILERS
SG_USING_STD(streambuf);
SG_USING_STD(ostream);
SG_USING_STD(cout);
SG_USING_STD(cerr);
SG_USING_STD(endl);
-#else
-SG_USING_STD(char_traits);
-#endif
#ifdef __MWERKS__
SG_USING_STD(iostream);
* messages at runtime. Only messages with priority >= logbuf::logPriority
* and debugClass == logbuf::logClass are output.
*/
+#ifdef SG_NEED_STREAMBUF_HACK
+class logbuf : public __streambuf
+#else
class logbuf : public streambuf
+#endif
{
public:
#include "stardata.hxx"
-#if defined (_MSC_VER) || defined (SG_HAVE_NATIVE_SGI_COMPILERS)
+#if defined (_MSC_VER)
SG_USING_STD(getline);
#endif
#include <unistd.h>
#include STL_IOSTREAM
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
+#include "sg_binobj.hxx"
+
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
-
-#include "sg_binobj.hxx"
int main( int argc, char **argv ) {
#include STL_IOSTREAM
#include "lowlevel.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
-SG_USING_STD(cout);
-SG_USING_STD(endl);
-#endif
-
static const int sgEndianTest = 1;
#define sgIsLittleEndian (*((char *) &sgEndianTest ) != 0)
#define sgIsBigEndian (*((char *) &sgEndianTest ) == 0)
+SG_USING_STD(cout);
+SG_USING_STD(endl);
+
int main() {
cout << "This machine is ";
SG_USING_STD( string );
SG_USING_STD( vector );
-
-#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD( cout );
SG_USING_STD( endl );
-#endif
enum {
#include "sg_socket.hxx"
#include "lowlevel.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
-SG_USING_STD(cout);
-SG_USING_STD(endl);
-#endif
-
static const int sgEndianTest = 1;
#define sgIsLittleEndian (*((char *) &sgEndianTest ) != 0)
#define sgIsBigEndian (*((char *) &sgEndianTest ) == 0)
+SG_USING_STD(cout);
+SG_USING_STD(endl);
+
+
int main() {
if ( sgIsLittleEndian ) {
#include "sg_socket.hxx"
-#ifndef SG_HAVE_NATIVE_SGI_COMPILERS
-using std::cout;
-#endif
class TcpClient
{
#include "sg_socket.hxx"
-using std::string;
-#ifndef SG_HAVE_NATIVE_SGI_COMPILERS
-using std::cout;
-#endif
+SG_USING_STD(string);
+SG_USING_STD(cout);
class TcpServer
{
SG_USING_NAMESPACE(std);
#endif
-#ifndef SG_HAVE_NATIVE_SGI_COMPILERS
SG_USING_STD(ostream);
SG_USING_STD(istream);
-#endif
const double fgPoint3_Epsilon = 0.0000001;
#include "localconsts.hxx"
-#ifndef SG_HAVE_NATIVE_SGI_COMPILERS
SG_USING_STD(cout);
-#endif
#define DOMAIN_ERR_DEBUG 1
#include "MetarReport.h"
#include "Metar.h"
-#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(endl);
SG_USING_STD(ostream);
-#endif
CMetarReport::CMetarReport(
char *s ) :
#include "MetarStation.h"
#include <algorithm>
-#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(ostream);
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
double CMetarStation::decodeDMS( char *b )
#include STL_IOSTREAM
SG_USING_STD(string);
SG_USING_STD(vector);
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(istream);
SG_USING_STD(ostream);
-#endif
#endif
#include "props_io.hxx"
#include STL_IOSTREAM
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
-# include <fstream>
-#else
-# include <fstream.h>
-#endif
+#include STL_FSTREAM
#include STL_STRING
#include <vector>
#include <map>
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(istream);
SG_USING_STD(ifstream);
SG_USING_STD(ostream);
SG_USING_STD(ofstream);
-#endif
SG_USING_STD(string);
SG_USING_STD(vector);
SG_USING_STD(map);
SG_USING_STD(string);
SG_USING_STD(vector);
SG_USING_STD(map);
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(istream);
SG_USING_STD(ostream);
-#endif
/**
* Read properties from an XML input stream.
#include "props.hxx"
#include "props_io.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(cerr);
SG_USING_STD(endl);
-#endif
\f
#if defined( SG_HAVE_STD_INCLUDES )
# include <istream>
-#elif defined ( SG_HAVE_NATIVE_SGI_COMPILERS )
-# include <CC/stream.h>
#elif defined ( __BORLANDC__ )
# include <iostream>
#else
#include <simgear/misc/zfstream.hxx>
SG_USING_STD(string);
-
-#ifndef SG_HAVE_NATIVE_SGI_COMPILERS
SG_USING_STD(istream);
-#endif
/**
#include <zlib.h>
-// At least Irix needs this
-#ifdef SG_HAVE_NATIVE_SGI_COMPILERS
-#include <char_traits.h>
-SG_USING_STD(char_traits);
-#endif
-
#ifdef SG_HAVE_STD_INCLUDES
# include <streambuf>
#if defined(__GNUC__) && __GNUC_MINOR__ < 8
# define ios_binary ios::bin
-#elif defined( SG_HAVE_NATIVE_SGI_COMPILERS )
-# define ios_binary 0
#else
# define ios_binary ios::binary
#endif
/**
* A C++ I/O streams interface to the zlib gz* functions.
*/
+#ifdef SG_NEED_STREAMBUF_HACK
+class gzfilebuf : public __streambuf
+#else
class gzfilebuf : public streambuf
+#endif
{
public:
#include "route.hxx"
#include "waypoint.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
int main() {
SGRoute route;
#include "waypoint.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
-
int main() {
SGWayPoint a1(-93.216923, 44.880547, 0.0, SGWayPoint::WGS84, "KMSP");
#include <plib/sg.h>
#include <plib/ssg.h>
-#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
// return a sphere object as an ssgBranch
#include "stars.hxx"
-#if !defined (SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
// Set up star rendering call backs
#include "serial.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
-
FGSerialPort::FGSerialPort()
: dev_open(false)
#include "serial.hxx"
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(cout);
SG_USING_STD(endl);
-#endif
-
int main () {
FGSerialPort port;
#include STL_FSTREAM
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(ifstream);
-#endif
\f
#include STL_STRING
#include <vector>
-#if !defined(SG_HAVE_NATIVE_SGI_COMPILERS)
SG_USING_STD(istream);
-#endif
SG_USING_STD(string);
SG_USING_STD(vector);