ppremake.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. /*
  2. // Filename: ppremake.h
  3. // Created by: drose (25Sep00)
  4. //
  5. ////////////////////////////////////////////////////////////////////
  6. */
  7. #ifndef PPREMAKE_H
  8. #define PPREMAKE_H
  9. #ifdef _MSC_VER
  10. /* For Visual C, include the special config.h file. */
  11. #include "config_msvc.h"
  12. #else
  13. /* Otherwise, include the normal automatically-generated file. */
  14. #include "config.h"
  15. #endif
  16. #ifdef __cplusplus
  17. #ifdef HAVE_IOSTREAM
  18. #include <iostream>
  19. #include <fstream>
  20. #ifdef HAVE_SSTREAM
  21. #include <sstream>
  22. #else // HAVE_SSTREAM
  23. #include <strstream>
  24. #endif // HAVE_SSTREAM
  25. #else // HAVE_IOSTREAM
  26. #include <iostream.h>
  27. #include <fstream.h>
  28. #include <strstream.h>
  29. #endif // HAVE_IOSTREAM
  30. #if defined(HAVE_CYGWIN) || defined(WIN32_VC)
  31. // Either Cygwin or Visual C++ is a Win32 environment.
  32. #define WIN32
  33. #endif
  34. #include <string>
  35. #ifdef HAVE_NAMESPACE
  36. using namespace std;
  37. #endif
  38. #endif /* __cplusplus */
  39. #ifndef HAVE_ALLOCA_H
  40. /* If we don't have alloca.h, use malloc() to implement gnu_regex. */
  41. #define REGEX_MALLOC 1
  42. #endif
  43. #define PACKAGE_FILENAME "Package.pp"
  44. #define SOURCE_FILENAME "Sources.pp"
  45. #define COMMAND_PREFIX '#'
  46. #define VARIABLE_PREFIX '$'
  47. #define VARIABLE_OPEN_BRACE '['
  48. #define VARIABLE_CLOSE_BRACE ']'
  49. #define PATTERN_WILDCARD '%'
  50. #define BEGIN_COMMENT "//"
  51. #define FUNCTION_PARAMETER_SEPARATOR ','
  52. #define VARIABLE_OPEN_NESTED '('
  53. #define VARIABLE_CLOSE_NESTED ')'
  54. #define VARIABLE_PATSUBST ":"
  55. #define VARIABLE_PATSUBST_DELIM "="
  56. #define SCOPE_DIRNAME_SEPARATOR '/'
  57. #define SCOPE_DIRNAME_WILDCARD "*"
  58. #define SCOPE_DIRNAME_CURRENT "."
  59. #ifdef __cplusplus
  60. /* These are set from the similarly-named variables defined in
  61. System.pp. */
  62. extern bool unix_platform;
  63. extern bool windows_platform;
  64. /* This is a command-line global parameter. */
  65. extern bool dry_run;
  66. extern bool verbose_dry_run;
  67. #endif
  68. /* These are defined so that we may build Filename, DSearchPath, and
  69. GlobPattern, which are copied from dtool and panda. We have to
  70. copy these files in since ppremake must be built first, and stands
  71. outside of Panda; but we want to minimize the changes we must make
  72. to these files so that we can easily recopy them at need.
  73. These symbols just make the build environment a bit more
  74. Panda-like. */
  75. #define PUBLISHED public
  76. #define INLINE inline
  77. #define EXPCL_DTOOL
  78. #define EXPCL_PANDA
  79. #endif