You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
+ runs *post_install_php()* function if installation was successfull
73
+
+ builds pecl extensions
74
+
+ builds external extensions
72
75
73
76
# Custom configuration
74
77
@@ -110,19 +113,108 @@ Its default value is defined to "--disable-all".
110
113
111
114
The pre_\* and post_\* functions are called with the working directory set to the php source directory.
112
115
116
+
## Building extensions
117
+
118
+
Extensions are built and installed after php itself.
119
+
120
+
It is of your responsability to provide the loading and parameters of the extension to php, generally by creating an extension_name.ini file in the `${php_band_php_install_dir}/conf.d/` directory.
121
+
122
+
### Using pecl
123
+
124
+
You add some pecl extensions to build in your *configure-php.sh* file by using the function *php_band_pecl_add_package*.
125
+
It takes the package name as first parameter and eventually a string representing user inputs as second parameter.
126
+
The pecl package name must be a string accordingly to [pecl documentation](http://php.net/manual/en/install.pecl.pear.php).
127
+
For example to install the xdebug package, use either :
You may know some extensions defined in a lower config file are not compatible with a specific version (for example, xhprof does not work on 7.x).
146
+
You can remove the building extension request with the function *php_band_pecl_remove_package* :
147
+
148
+
```
149
+
php_band_pecl_remove_package 'xhprof'
150
+
```
151
+
152
+
### Building custom extensions
153
+
154
+
You can request building a custom extension with function *php_band_external_add*.
155
+
It takes a request identifer string as first parameter. Any other parameter will be passed to a callback function of your own named *extension_<identifier>*.
156
+
157
+
For example, let's build the extension xhprof. The pecl version builds untin php 5.99.
158
+
Our `config/configure-php.sh` may look like:
159
+
160
+
```bash
161
+
#!/bin/bash -e
162
+
163
+
php_band_pecl_add_package 'xhprof-stable'
164
+
```
165
+
166
+
In the `config/7/configure-php.sh` file we won't install pecl version but the git version from branch 'php7':
0 commit comments