|
1 | | -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 1 | +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
2 | 2 | ; static-php-cli (spc) env configuration |
3 | 3 | ; |
4 | 4 | ; This file is used to set default env vars for static-php-cli build. |
5 | 5 | ; As dynamic build process, some of these vars can be overwritten by CLI options. |
6 | 6 | ; And you can also overwrite these vars by setting them in your shell environment. |
| 7 | +; The value should be changed only if you know what you are doing. Otherwise, please leave them as default. |
7 | 8 | ; |
8 | 9 | ; We need to use some pre-defined internal env vars, like `BUILD_ROOT_PATH`, `DOWNLOAD_PATH`, etc. |
9 | | -; Please note that these vars cannot be defined in this file, they are only be defined before static-php-cli running. |
| 10 | +; Please note that these vars cannot be defined in this file, they should only be defined before static-php-cli running. |
10 | 11 | ; |
11 | | -; Here's a list of env vars, these value cannot be changed anywhere: |
| 12 | +; Here's a list of env vars, these variables will be defined if not defined: |
12 | 13 | ; |
13 | | -; SPC_VERSION: the version of static-php-cli. |
14 | | -; WORKING_DIR: the working directory of the build process. (default: `$(pwd)`) |
15 | | -; ROOT_DIR: the root directory of static-php-cli. (default: `/path/to/static-php-cli`, when running in phar or micro mode: `phar://path/to/spc.phar`) |
16 | 14 | ; BUILD_ROOT_PATH: the root path of the build process. (default: `$(pwd)/buildroot`) |
17 | 15 | ; BUILD_INCLUDE_PATH: the path of the include files. (default: `$BUILD_ROOT_PATH/include`) |
18 | 16 | ; BUILD_LIB_PATH: the path of the lib files. (default: `$BUILD_ROOT_PATH/lib`) |
19 | 17 | ; BUILD_BIN_PATH: the path of the bin files. (default: `$BUILD_ROOT_PATH/bin`) |
20 | | -; PKG_ROOT_PATH: the root path of the package files. (default: `$(pwd)/pkgroot`) |
| 18 | +; BUILD_MODULES_PATH: the path of the php modules (shared extensions) files. (default: `$BUILD_ROOT_PATH/modules`) |
| 19 | +; PKG_ROOT_PATH: the root path of the package files. (default: `$(pwd)/pkgroot/$GNU_ARCH-{darwin|linux|windows}`) |
21 | 20 | ; SOURCE_PATH: the path of the source files. (default: `$(pwd)/source`) |
22 | 21 | ; DOWNLOAD_PATH: the path of the download files. (default: `$(pwd)/downloads`) |
23 | | -; CPU_COUNT: the count of the CPU cores. (default: `$(nproc)`) |
24 | | -; SPC_ARCH: the arch of the current system, for some libraries needed `--host=XXX` args. (default: `$(uname -m)`, e.g. `x86_64`, `aarch64`, `arm64`) |
25 | | -; GNU_ARCH: the GNU arch of the current system. (default: `$(uname -m)`, e.g. `x86_64`, `aarch64`) |
26 | | -; MAC_ARCH: the MAC arch of the current system. (default: `$(uname -m)`, e.g. `x86_64`, `arm64`) |
| 22 | +; PATH: (*nix only) static-php-cli will add `$BUILD_BIN_PATH` to PATH. |
| 23 | +; PKG_CONFIG_PATH: (*nix only) static-php-cli will set `$BUILD_LIB_PATH/pkgconfig` to PKG_CONFIG_PATH. |
27 | 24 | ; |
28 | | -; * These vars are only be defined in Unix (macOS, Linux, FreeBSD)Builder and cannot be changed anywhere: |
29 | | -; PATH: static-php-cli will add `$BUILD_BIN_PATH` to PATH. |
30 | | -; PKG_CONFIG: static-php-cli will set `$BUILD_BIN_PATH/pkg-config` to PKG_CONFIG. |
31 | | -; PKG_CONFIG_PATH: static-php-cli will set `$BUILD_LIB_PATH/pkgconfig` to PKG_CONFIG_PATH. |
| 25 | +; Here's a list of env vars, these variables is defined in SPC and cannot be changed anywhere: |
32 | 26 | ; |
33 | | -; * These vars are only be defined in LinuxBuilder and cannot be changed anywhere: |
34 | | -; SPC_LINUX_DEFAULT_CC: the default compiler for linux. (For alpine linux: `gcc`, default: `$GNU_ARCH-linux-musl-gcc`) |
35 | | -; SPC_LINUX_DEFAULT_CXX: the default c++ compiler for linux. (For alpine linux: `g++`, default: `$GNU_ARCH-linux-musl-g++`) |
36 | | -; SPC_LINUX_DEFAULT_AR: the default archiver for linux. (For alpine linux: `ar`, default: `$GNU_ARCH-linux-musl-ar`) |
37 | | -; SPC_EXTRA_PHP_VARS: the extra vars for building php, used in `configure` and `make` command. |
| 27 | +; SPC_VERSION: the version of static-php-cli. |
| 28 | +; WORKING_DIR: the working directory of the build process. (default: `$(pwd)`) |
| 29 | +; ROOT_DIR: the root directory of static-php-cli. (default: `/path/to/static-php-cli`, when running in phar or micro mode: `phar://path/to/spc.phar`) |
| 30 | +; CPU_COUNT: the count of the CPU cores. (default: `$(nproc)`) |
| 31 | +; SPC_ARCH: the arch of the current system, for some libraries needed `--host=XXX` args. (default: `$(uname -m)`, e.g. `x86_64`, `aarch64`, `arm64`) |
| 32 | +; GNU_ARCH: the GNU arch of the current system. (default: `$(uname -m)`, e.g. `x86_64`, `aarch64`) |
| 33 | +; MAC_ARCH: the MAC arch of the current system. (default: `$(uname -m)`, e.g. `x86_64`, `arm64`) |
| 34 | +; PKG_CONFIG: (*nix only) static-php-cli will set `$BUILD_BIN_PATH/pkg-config` to PKG_CONFIG. |
| 35 | +; SPC_LINUX_DEFAULT_CC: (linux only) the default compiler for linux. (For alpine linux: `gcc`, default: `$GNU_ARCH-linux-musl-gcc`) |
| 36 | +; SPC_LINUX_DEFAULT_CXX: (linux only) the default c++ compiler for linux. (For alpine linux: `g++`, default: `$GNU_ARCH-linux-musl-g++`) |
| 37 | +; SPC_LINUX_DEFAULT_AR: (linux only) the default archiver for linux. (For alpine linux: `ar`, default: `$GNU_ARCH-linux-musl-ar`) |
| 38 | +; SPC_EXTRA_PHP_VARS: (linux only) the extra vars for building php, used in `configure` and `make` command. |
38 | 39 |
|
39 | 40 | [global] |
40 | 41 | ; Build concurrency for make -jN, default is CPU_COUNT, this value are used in every libs. |
|
0 commit comments