-php-build
- -php-build builds multiple PHP versions from source, and this fully automatic.
- --Who uses this?
- --
-
- Travis CI -
- Maybe you? -
-Install
- -% git clone git://github.com/php-build/php-build
-% cd php-build
-% sudo ./install.sh
-
-
--Usage
+ + +PHP from source
+Every version of PHP, built and run side by side.
+php-build compiles PHP from source and installs versions in parallel, standalone or as a phpenv plugin. Fully automatic.
+Parallel versions
Install 5.6 through 8.x at once and pin a version per project. No system-wide clobbering.
From source
Compiles each release from source with your own configure options and build environment.
phpenv native
Drops in as a phpenv plugin so phpenv install just works, or run it fully standalone.
Definition driven
Version recipes live as definitions. List, extend, or add your own build targets.
-Synopsis
+Install
+Two ways in
+1. As a phpenv plugin — the installer wires up phpenv and php-build together:
+$ curl -L https://raw.githubusercontent.com/phpenv/phpenv-installer/master/bin/phpenv-installer | bash
+ 2. Standalone — clone and install to a prefix you control:
+$ git clone https://github.com/php-build/php-build.git
+$ cd php-build
+$ PREFIX=$HOME/local ./install.sh
+ php-build --help
+
+ Usage
+ Build a version
+
+
+ php-build --help
php-build --definitions
-php-build [-i <environment_or_inifile>] <definition> <prefix>
-
-
-Before you can build PHP you will need all necessary build dependencies.
-
-If you use Ubuntu:
-% sudo apt-get install libmcrypt-dev libreadline-dev
-
-% sudo apt-get build-dep php5-cli
-
-
-If you use macOS:
-
- Install Homebrew
- -
-
Install Hombrew packages:
- % brew install pkg-config autoconf openssl icu4c re2c bison libzip mcrypt
-
- -
-
Specify the Homebrew library places in configure options:
- env "PATH=/usr/local/opt/bison/bin:$PATH" "PHP_BUILD_CONFIGURE_OPTS=--with-openssl=$(brew --prefix openssl) --with-libzip" phpenv install 7.0.30
-
-
-
-
-Then run this to install PHP 5.5.9 in development configuration:
-
-% php-build -i development 5.5.9 ~/local/php/5.5.9
-
-
-To get a list of all supported PHP versions pass the --definitions flag:
-
-% php-build --definitions
-
+php-build [-i <environment_or_inifile>] <definition> <prefix>
+
+ Build 8.3.0 in development configuration into a chosen prefix:
+
+
+ $ php-build -i development 8.3.0 ~/local/php/8.3.0
+
+
-
-Meet the core team
+
+ Before your first build
+ Build dependencies
+
+
+ Debian / Ubuntu
+
+
+ $ sudo apt-get install -y \
+ autoconf bison re2c pkg-config \
+ libxml2-dev libssl-dev libcurl4-openssl-dev \
+ libreadline-dev libzip-dev libsqlite3-dev
+
+
+
+ macOS (Homebrew)
+
+
+ $ brew install pkg-config autoconf \
+ openssl icu4c re2c bison libzip
+
+
+
+
-
-License
+
+ Maintainers
+ Core team
+
+
-The MIT License
+
+ Legal
+ License
+ php-build is released under the MIT License. Copyright © 2011–2015 Christoph Hochstrasser.
+
+ Read the full license
+ The MIT License (MIT)
-Copyright (c) 2011-2015 Christoph Hochstrasser
+Copyright (c) 2011-2015 Christoph Hochstrasser
-Permission is hereby granted, free of charge, to any person obtaining a copy
+Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
+furnished to do so, subject to the following conditions:
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
+THE SOFTWARE.
+
-