Question

Installing Pthreads with LAMP on a blank droplet

Posted February 2, 2014 8.1k views
I'm having a lot of trouble installing Pthreads on a blank droplet (tried Ubuntu, Centos & Debian). I just can't get it to install. Could somebody link me to a guide on how to this from the start? OS doesn't matter. Thanks!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
5 answers
Does installing php5-dev, cloning https://github.com/krakjoe/pthreads and running phpize in the root directory of the repo work?
(Try that out on an Ubuntu droplet)
class 'Thread' not found :/
Which means it's not installed yet :(
How are you running the file? Trhough the CLI or apache?

It also seems like you can install it from PECL which should be easier. Try running the following commands:
sudo apt-get install php-pear

sudo pecl install pthreads
sudo service apache2 restart
Submit an Answer