Package.pp 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. //
  2. // Package.pp
  3. //
  4. // This file defines certain configuration variables that are to be
  5. // written into the various make scripts. It is processed by ppremake
  6. // (along with the Sources.pp files in each of the various
  7. // directories) to generate build scripts appropriate to each
  8. // environment.
  9. //
  10. // This is the package-specific file, which should be at the top of
  11. // every source hierarchy. It generally gets the ball rolling, and is
  12. // responsible for explicitly including all of the relevent Config.pp
  13. // files.
  14. // What is the name and version of this source tree?
  15. #if $[eq $[PACKAGE],]
  16. #define PACKAGE panda
  17. #define VERSION 0.80
  18. #endif
  19. // Where should we find the DTOOL source directory?
  20. #if $[DTOOL_SOURCE]
  21. #define DTOOL_SOURCE $[unixfilename $[DTOOL_SOURCE]]
  22. #elif $[or $[CTPROJS],$[DTOOL]]
  23. // If we are presently attached, use the environment variable.
  24. #define DTOOL_SOURCE $[unixfilename $[DTOOL]]
  25. #if $[eq $[DTOOL],]
  26. #error You seem to be attached to some trees, but not DTOOL!
  27. #endif
  28. #else
  29. // Otherwise, if we are not attached, we guess that the source is a
  30. // sibling directory to this source root.
  31. #define DTOOL_SOURCE $[standardize $[TOPDIR]/../dtool]
  32. #endif
  33. // Where should we install PANDA?
  34. #if $[PANDA_INSTALL]
  35. #define PANDA_INSTALL $[unixfilename $[PANDA_INSTALL]]
  36. #elif $[CTPROJS]
  37. #set PANDA $[unixfilename $[PANDA]]
  38. #define PANDA_INSTALL $[PANDA]/built
  39. #if $[eq $[PANDA],]
  40. #error You seem to be attached to some trees, but not PANDA!
  41. #endif
  42. #else
  43. #defer PANDA_INSTALL $[unixfilename $[INSTALL_DIR]]
  44. #endif
  45. // Also get the DTOOL Package file and everything that includes.
  46. #if $[not $[isfile $[DTOOL_SOURCE]/Package.pp]]
  47. #printvar DTOOL_SOURCE
  48. #error DTOOL source directory not found from panda! Are you attached properly?
  49. #endif
  50. #include $[DTOOL_SOURCE]/Package.pp
  51. // Define the inter-tree dependencies.
  52. #define NEEDS_TREES dtool $[NEEDS_TREES]
  53. #define DEPENDABLE_HEADER_DIRS $[DEPENDABLE_HEADER_DIRS] $[DTOOL_INSTALL]/include