Cygwin build fixes.

This commit is contained in:
Robert Osfield
2002-04-25 22:07:48 +00:00
parent 62dc8f7cda
commit a1a1876875
2 changed files with 5 additions and 11 deletions

View File

@@ -142,8 +142,10 @@
#if defined(WIN32) && !defined(__CYGWIN__)
#define vsnprintf _vsnprintf
#define snprintf _snprintf
#endif
namespace dx {
//----------------------------------------------------------------------------
@@ -525,7 +527,7 @@ inline int WARNING( char fmt[], ... )
//----------------------------------------------------------------------------
void GetParms( int argc, char *argv[],
char infile [ PATH_MAX ], WriterParms &parms )
char infile [ DX_PATH_MAX ], WriterParms &parms )
{
WriterParms defaults;
@@ -581,7 +583,7 @@ void GetParms( int argc, char *argv[],
}
infile[0] = parms.outfile[0] = '\0';
strncat( infile , argv[ i ], PATH_MAX-1 );
strncat( infile , argv[ i ], DX_PATH_MAX-1 );
strncat( parms.outfile, argv[i+1], sizeof(parms.outfile)-1 );
}
@@ -2279,10 +2281,6 @@ void DXWriter::CollectUnhandledModesAndAttrs( osg::StateSet *sset )
//----------------------------------------------------------------------------
#ifdef WIN32
#define snprintf _snprintf
#endif
void DXWriter::ReportUnhandledModesAndAttrs()
{
char msg[1024];

View File

@@ -21,11 +21,7 @@
#include <osg/Vec4>
#include <osg/Node>
#ifdef WIN32
// windows only defines PATH_MAX on _POSIX_
#define PATH_MAX 512
#endif
const int DX_PATH_MAX = 512;
namespace dx {