1<div align="center"> 2 <a href="https://php.net"> 3 <img 4 alt="PHP" 5 src="https://www.php.net/images/logos/new-php-logo.svg" 6 width="150"> 7 </a> 8</div> 9 10# The PHP Interpreter 11 12PHP is a popular general-purpose scripting language that is especially suited to 13web development. Fast, flexible and pragmatic, PHP powers everything from your 14blog to the most popular websites in the world. PHP is distributed under the 15[PHP License v3.01](LICENSE). 16 17[![Push](https://github.com/php/php-src/actions/workflows/push.yml/badge.svg)](https://github.com/php/php-src/actions/workflows/push.yml) 18[![Build status](https://travis-ci.com/php/php-src.svg?branch=master)](https://travis-ci.com/github/php/php-src) 19[![Build Status](https://dev.azure.com/phpazuredevops/php/_apis/build/status/php.php-src?branchName=master)](https://dev.azure.com/phpazuredevops/php/_build/latest?definitionId=1&branchName=master) 20[![Fuzzing Status](https://oss-fuzz-build-logs.storage.googleapis.com/badges/php.svg)](https://bugs.chromium.org/p/oss-fuzz/issues/list?sort=-opened&can=1&q=proj:php) 21 22## Documentation 23 24The PHP manual is available at [php.net/docs](https://php.net/docs). 25 26## Installation 27 28### Prebuilt packages and binaries 29 30Prebuilt packages and binaries can be used to get up and running fast with PHP. 31 32For Windows, the PHP binaries can be obtained from 33[windows.php.net](https://windows.php.net). After extracting the archive the 34`*.exe` files are ready to use. 35 36For other systems, see the [installation chapter](https://php.net/install). 37 38### Building PHP source code 39 40*For Windows, see [Build your own PHP on Windows](https://wiki.php.net/internals/windows/stepbystepbuild_sdk_2).* 41 42For a minimal PHP build from Git, you will need autoconf, bison, and re2c. For 43a default build, you will additionally need libxml2 and libsqlite3. 44 45On Ubuntu, you can install these using: 46 47 sudo apt install -y pkg-config build-essential autoconf bison re2c \ 48 libxml2-dev libsqlite3-dev 49 50On Fedora, you can install these using: 51 52 sudo dnf install re2c bison autoconf make libtool ccache libxml2-devel sqlite-devel 53 54Generate configure: 55 56 ./buildconf 57 58Configure your build. `--enable-debug` is recommended for development, see 59`./configure --help` for a full list of options. 60 61 # For development 62 ./configure --enable-debug 63 # For production 64 ./configure 65 66Build PHP. To speed up the build, specify the maximum number of jobs using `-j`: 67 68 make -j4 69 70The number of jobs should usually match the number of available cores, which 71can be determined using `nproc`. 72 73## Testing PHP source code 74 75PHP ships with an extensive test suite, the command `make test` is used after 76successful compilation of the sources to run this test suite. 77 78It is possible to run tests using multiple cores by setting `-jN` in 79`TEST_PHP_ARGS`: 80 81 make TEST_PHP_ARGS=-j4 test 82 83Shall run `make test` with a maximum of 4 concurrent jobs: Generally the maximum 84number of jobs should not exceed the number of cores available. 85 86The [qa.php.net](https://qa.php.net) site provides more detailed info about 87testing and quality assurance. 88 89## Installing PHP built from source 90 91After a successful build (and test), PHP may be installed with: 92 93 make install 94 95Depending on your permissions and prefix, `make install` may need super user 96permissions. 97 98## PHP extensions 99 100Extensions provide additional functionality on top of PHP. PHP consists of many 101essential bundled extensions. Additional extensions can be found in the PHP 102Extension Community Library - [PECL](https://pecl.php.net). 103 104## Contributing 105 106The PHP source code is located in the Git repository at 107[github.com/php/php-src](https://github.com/php/php-src). Contributions are most 108welcome by forking the repository and sending a pull request. 109 110Discussions are done on GitHub, but depending on the topic can also be relayed 111to the official PHP developer mailing list internals@lists.php.net. 112 113New features require an RFC and must be accepted by the developers. See 114[Request for comments - RFC](https://wiki.php.net/rfc) and 115[Voting on PHP features](https://wiki.php.net/rfc/voting) for more information 116on the process. 117 118Bug fixes don't require an RFC. If the bug has a GitHub issue, reference it in 119the commit message using `GH-NNNNNN`. Use `#NNNNNN` for tickets in the old 120[bugs.php.net](https://bugs.php.net) bug tracker. 121 122 Fix GH-7815: php_uname doesn't recognise latest Windows versions 123 Fix #55371: get_magic_quotes_gpc() throws deprecation warning 124 125See [Git workflow](https://wiki.php.net/vcs/gitworkflow) for details on how pull 126requests are merged. 127 128### Guidelines for contributors 129 130See further documents in the repository for more information on how to 131contribute: 132 133- [Contributing to PHP](/CONTRIBUTING.md) 134- [PHP coding standards](/CODING_STANDARDS.md) 135- [Mailing list rules](/docs/mailinglist-rules.md) 136- [PHP release process](/docs/release-process.md) 137 138## Credits 139 140For the list of people who've put work into PHP, please see the 141[PHP credits page](https://php.net/credits.php). 142