| | 89 | BUILD CONFIGURATION CONSOLIDATION VIA config.yml |
| | 90 | ------------------------------------------------ |
| | 91 | |
| | 92 | To keep the multitude of configuration options and mechanisms under |
| | 93 | control for the build, we're moving over some of the above to a |
| | 94 | centralized file, "config.yml" under the build root. This file is in |
| | 95 | YAML format[1]; if it does not exist, one with defaults will be created |
| | 96 | for you. |
| | 97 | |
| | 98 | The options you can control there include: |
| | 99 | |
| | 100 | - optimization level: whether `make` means `make optimized` or |
| | 101 | `make unoptimized` by default. |
| | 102 | |
| | 103 | - precompilation options: by default, pugs is built with the Standard Prelude |
| | 104 | compiled into it. This makes many Perl 6 builtins available to pugs, and |
| | 105 | loads fast. You can specify additional modules to inline a precompiled |
| | 106 | version of into the executable: Test.pm is a good choice if running the |
| | 107 | test suite. The cost of this is a longer build process which requires much |
| | 108 | more RAM. |
| | 109 | |
| | 110 | - GHC heap size: if precompiling modules other than Prelude.pm into pugs, you |
| | 111 | will probably need to increase the amount of RAM GHC permits itself to use, |
| | 112 | otherwise it will abort the build. And if your machine is low on RAM, and |
| | 113 | itself runs out of memory while building pugs, you can set this to a low |
| | 114 | value (but turn off optimization and precompilation too). |
| | 115 | |
| | 116 | You can override values set in this file temporarily via the single |
| | 117 | PUGS_BUILD_OPTS environment variable. For example, if you normally do |
| | 118 | precompile Prelude.pm but want a faster build just this once: |
| | 119 | |
| | 120 | env PUGS_BUILD_OPTS=precompile_prelude=false make |
| | 121 | |
| | 122 | See `util/config-template.yml` for more information. |
| | 123 | |
| | 124 | [1] See <http://yaml.org/>. Only a subset of the YAML syntax is permitted |
| | 125 | at the moment, to avoid a dependency on the full parser. |
| | 126 | |