Last active
June 3, 2019 14:24
-
-
Save tvlooy/0e28e59178be86a5c12096abde6f4bb3 to your computer and use it in GitHub Desktop.
Use OpenBSD's pledge and unveil syscalls in PHP
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Note that this is for people that want to build it from source, using pecl | |
# This code is in official OpenBSD ports now https://marc.info/?l=openbsd-ports-cvs&m=154270973708561 | |
pkg_add php-7.2.10 | |
ln -s /usr/local/bin/php-7.2 /usr/local/bin/php | |
ln -s /usr/local/bin/phpize-7.2 /usr/local/bin/phpize | |
ln -s /usr/local/bin/php-config-7.2 /usr/local/bin/php-config | |
pkg_add autoconf-2.69p2 | |
export AUTOCONF_VERSION=2.69 | |
pkg_add pear | |
pecl download pledge | |
tar xzvf pledge-2.0.2.tgz | |
cd pledge-2.0.2 | |
phpize | |
./configure | |
make install | |
php -dextension=pledge -m | grep pledge |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment