From 3bfe47823ae3b5632657e8f2c5d63f5a8887fc20 Mon Sep 17 00:00:00 2001 From: David Rose Date: Tue, 15 May 2001 01:12:07 +0000 Subject: [PATCH] *** empty log message *** --- dtool/Config.pp | 12 ++++++++++-- dtool/LocalSetup.pp | 3 +++ dtool/pptempl/Global.pp | 13 +++++++++---- dtool/src/dconfig/symbolEnt.h | 4 ++++ dtool/src/dtoolbase/dtoolbase.h | 2 ++ dtool/src/dtoolutil/vector_string.h | 4 ++++ dtool/src/interrogatedb/vector_int.h | 4 ++++ dtool/src/parser-inc/Sources.pp | 2 +- dtool/src/parser-inc/algorithm | 15 +++++++++++++++ 9 files changed, 52 insertions(+), 7 deletions(-) create mode 100644 dtool/src/parser-inc/algorithm diff --git a/dtool/Config.pp b/dtool/Config.pp index 15d06177de..58988d31a3 100644 --- a/dtool/Config.pp +++ b/dtool/Config.pp @@ -158,6 +158,15 @@ #define NSPR_LIBS nspr4 #defer HAVE_NSPR $[libtest $[NSPR_LPATH],$[NSPR_LIBS]] +// Is a third-party STL library installed, and where? This is only +// necessary if the default include and link lines that come with the +// compiler don't provide adequate STL support. At least some form of +// STL is absolutely required in order to build Panda. +#define STL_IPATH +#define STL_LPATH +#define STL_CFLAGS +#define STL_LIBS + // Is Crypto++ installed, and where? #define CRYPTO_IPATH /usr/include/crypto++ #define CRYPTO_LPATH /usr/lib @@ -376,8 +385,7 @@ // In general, it is safe to define these to be the same. However, // don't define these to be '.', or you will be very sad the next time // you run 'make clean'. -#defer BC_VARIANT $[if $[USE_BOUNDSCHECKER],-bc] -#defer ODIR Opt$[OPTIMIZE]$[BC_VARIANT]-$[PLATFORM] +#defer ODIR Opt$[OPTIMIZE]-$[PLATFORM]$[USE_COMPILER] #defer ODIR_SHARED $[ODIR] #defer ODIR_STATIC $[ODIR] diff --git a/dtool/LocalSetup.pp b/dtool/LocalSetup.pp index 8a769d66fc..ea59499593 100644 --- a/dtool/LocalSetup.pp +++ b/dtool/LocalSetup.pp @@ -25,6 +25,9 @@ $[cdefine HAVE_NAMESPACE] /* Define if the C++ iostream library supports ios::binary. */ $[cdefine HAVE_IOS_BINARY] +/* Define if we have Dinkumware STL installed. */ +$[cdefine HAVE_DINKUM] + /* Define if we have Python installed. */ $[cdefine HAVE_PYTHON] diff --git a/dtool/pptempl/Global.pp b/dtool/pptempl/Global.pp index 6158ab89f9..0103688d60 100644 --- a/dtool/pptempl/Global.pp +++ b/dtool/pptempl/Global.pp @@ -70,6 +70,11 @@ #set INTERROGATE_PYTHON_INTERFACE $[and $[HAVE_PYTHON],$[INTERROGATE_PYTHON_INTERFACE]] #define run_interrogate $[or $[INTERROGATE_C_INTERFACE],$[INTERROGATE_PYTHON_INTERFACE]] +#define stl_ipath $[wildcard $[STL_IPATH]] +#define stl_lpath $[wildcard $[STL_LPATH]] +#define stl_cflags $[STL_CFLAGS] +#define stl_libs $[STL_LIBS] + #if $[HAVE_PYTHON] #define python_ipath $[wildcard $[PYTHON_IPATH]] #define python_lpath $[wildcard $[PYTHON_LPATH]] @@ -344,7 +349,7 @@ // on the various external packages this particular target claims to // require. #defun get_cflags - #define alt_cflags $[nspr_cflags] $[python_cflags] + #define alt_cflags $[stl_cflags] $[nspr_cflags] $[python_cflags] #if $[ne $[USE_CRYPTO] $[components $[USE_CRYPTO],$[active_component_libs]],] #set alt_cflags $[alt_cflags] $[crypto_cflags] @@ -409,7 +414,7 @@ // claims to require. This returns a space-separated set of directory // names only; the -I switch is not included here. #defun get_ipath - #define alt_ipath $[nspr_ipath] $[python_ipath] + #define alt_ipath $[stl_ipath] $[nspr_ipath] $[python_ipath] #if $[ne $[USE_CRYPTO] $[components $[USE_CRYPTO],$[active_component_libs]],] #set alt_ipath $[alt_ipath] $[crypto_ipath] @@ -474,7 +479,7 @@ // target claims to require. This returns a space-separated set of // directory names only; the -L switch is not included here. #defun get_lpath - #define alt_lpath $[nspr_lpath] $[python_lpath] + #define alt_lpath $[stl_lpath] $[nspr_lpath] $[python_lpath] #if $[ne $[USE_CRYPTO] $[components $[USE_CRYPTO],$[active_component_libs] $[transitive_link]],] #set alt_lpath $[alt_lpath] $[crypto_lpath] @@ -540,7 +545,7 @@ // space-separated set of library names only; the -l switch is not // included here. #defun get_libs - #define alt_libs $[nspr_libs] $[python_libs] + #define alt_libs $[stl_libs] $[nspr_libs] $[python_libs] #if $[ne $[USE_CRYPTO] $[components $[USE_CRYPTO],$[active_component_libs] $[transitive_link]],] #set alt_libs $[alt_libs] $[crypto_libs] diff --git a/dtool/src/dconfig/symbolEnt.h b/dtool/src/dconfig/symbolEnt.h index 188dbb44e4..6f47cdcea2 100644 --- a/dtool/src/dconfig/symbolEnt.h +++ b/dtool/src/dconfig/symbolEnt.h @@ -46,6 +46,10 @@ class EXPCL_DTOOLCONFIG SymbolEnt { } // close Config namespace +#ifdef HAVE_DINKUM +#define VV_SYMBOLENT std::_Vector_val > +EXPORT_TEMPLATE_CLASS(EXPCL_DTOOL, EXPTP_DTOOL, VV_SYMBOLENT) +#endif EXPORT_TEMPLATE_CLASS(EXPCL_DTOOLCONFIG, EXPTP_DTOOLCONFIG, std::vector); namespace Config { diff --git a/dtool/src/dtoolbase/dtoolbase.h b/dtool/src/dtoolbase/dtoolbase.h index ae492247fa..cbdcab609f 100644 --- a/dtool/src/dtoolbase/dtoolbase.h +++ b/dtool/src/dtoolbase/dtoolbase.h @@ -33,6 +33,8 @@ #pragma warning (disable : 4250) /* C4355: 'this' : used in base member initializer list */ #pragma warning (disable : 4355) +/* C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data */ +#pragma warning (disable : 4244) #endif /* WIN32_VC */ diff --git a/dtool/src/dtoolutil/vector_string.h b/dtool/src/dtoolutil/vector_string.h index c119121cbf..48fab760c2 100644 --- a/dtool/src/dtoolutil/vector_string.h +++ b/dtool/src/dtoolutil/vector_string.h @@ -19,6 +19,10 @@ // rather than defining the vector again. //////////////////////////////////////////////////////////////////// +#ifdef HAVE_DINKUM +#define VV_STRING std::_Vector_val > +EXPORT_TEMPLATE_CLASS(EXPCL_DTOOL, EXPTP_DTOOL, VV_STRING) +#endif EXPORT_TEMPLATE_CLASS(EXPCL_DTOOL, EXPTP_DTOOL, std::vector) typedef vector vector_string; diff --git a/dtool/src/interrogatedb/vector_int.h b/dtool/src/interrogatedb/vector_int.h index 491e419a31..10746fd946 100644 --- a/dtool/src/interrogatedb/vector_int.h +++ b/dtool/src/interrogatedb/vector_int.h @@ -19,6 +19,10 @@ // rather than defining the vector again. //////////////////////////////////////////////////////////////////// +#ifdef HAVE_DINKUM +#define VV_INT std::_Vector_val > +EXPORT_TEMPLATE_CLASS(EXPCL_DTOOL, EXPTP_DTOOL, VV_INT) +#endif EXPORT_TEMPLATE_CLASS(EXPCL_DTOOLCONFIG, EXPTP_DTOOLCONFIG, std::vector) typedef vector vector_int; diff --git a/dtool/src/parser-inc/Sources.pp b/dtool/src/parser-inc/Sources.pp index 246eac2b57..9b6b53b468 100644 --- a/dtool/src/parser-inc/Sources.pp +++ b/dtool/src/parser-inc/Sources.pp @@ -1,4 +1,4 @@ #define INSTALL_PARSER_INC \ - deque iostream list map pair queue set stack stdtypedefs.h \ + algorithm deque iostream list map pair queue set stack stdtypedefs.h \ string vector windows.h zlib.h md5.h files.h hex.h \ nurbs.hh diff --git a/dtool/src/parser-inc/algorithm b/dtool/src/parser-inc/algorithm new file mode 100644 index 0000000000..c9328a14e7 --- /dev/null +++ b/dtool/src/parser-inc/algorithm @@ -0,0 +1,15 @@ +// Filename: algorithm +// Created by: drose (12May00) +// +//////////////////////////////////////////////////////////////////// + +// This file, and all the other files in this directory, aren't +// intended to be compiled--they're just parsed by CPPParser (and +// interrogate) in lieu of the actual system headers, to generate the +// interrogate database. + +#ifndef ALGORITHM_H +#define ALGORITHM_H + +#endif +