build.ck 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. /*++
  2. Copyright (c) 2017 Minoca Corp.
  3. This file is licensed under the terms of the GNU General Public License
  4. version 3. Alternative licensing terms are available. Contact
  5. info@minocacorp.com for details. See the LICENSE file at the root of this
  6. project for complete licensing information.
  7. Module Name:
  8. santa
  9. Abstract:
  10. This executable implements the Minoca package manager.
  11. Author:
  12. Evan Green 29-Aug-2017
  13. Environment:
  14. User
  15. --*/
  16. from menv import application, mconfig;
  17. function build() {
  18. var app;
  19. var appName = "santa";
  20. var config;
  21. var entries;
  22. var sources;
  23. var tool;
  24. sources = [
  25. "mkbundle.ck",
  26. "santa.ck",
  27. "cmd/archive.ck",
  28. "cmd/build.ck",
  29. "cmd/config.ck",
  30. "cmd/convert_archive.ck",
  31. "cmd/del_realm.ck",
  32. "cmd/install.ck",
  33. "cmd/list_realms.ck",
  34. "cmd/new_realm.ck",
  35. "cmd/patch.ck",
  36. "cmd/uninstall.ck",
  37. "containment/chroot.ck",
  38. "containment/none.ck",
  39. "presentation/copy.ck",
  40. "presentation/move.ck",
  41. "santa/build.ck",
  42. "santa/config.ck",
  43. "santa/containment.ck",
  44. "santa/file.ck",
  45. "santa/modules.ck",
  46. "santa/presentation.ck",
  47. "santa/lib/archive.ck",
  48. "santa/lib/build.ck",
  49. "santa/lib/config.ck",
  50. "santa/lib/defaultbuild.ck",
  51. "santa/lib/diff.ck",
  52. "santa/lib/patch.ck",
  53. "santa/lib/patchman.ck",
  54. "santa/lib/pkg.ck",
  55. "santa/lib/pkgbuilder.ck",
  56. "santa/lib/pkgdb.ck",
  57. "santa/lib/pkgdepot.ck",
  58. "santa/lib/pkgman.ck",
  59. "santa/lib/realm.ck",
  60. "santa/lib/realmmanager.ck",
  61. "santa/lib/santaconfig.ck",
  62. ];
  63. if (mconfig.build_os == "Windows") {
  64. appName += ".exe";
  65. }
  66. config = {
  67. "CHALK_ARGS": "$IN $OUT"
  68. };
  69. app = {
  70. "type": "target",
  71. "label": "build_santa",
  72. "output": appName,
  73. "inputs": ["mkbundle.ck"],
  74. "implicit": sources + ["apps/ck:build_chalk"],
  75. "tool": "create_santa",
  76. "config": config
  77. };
  78. tool = {
  79. "type": "tool",
  80. "name": "create_santa",
  81. "command": "$O/../../tools/bin/chalk $in $out",
  82. "description": "Bundling santa - $OUT"
  83. };
  84. entries = [app, tool];
  85. return entries;
  86. }