Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

phpbrew 5.3.10 build error: dereferencing pointer to incomplete type

Tags:

c++

php

ubuntu

I am trying to compile an old version of php for testing using phpbrew but I am encountering the following build error:

/home/ubuntu/.phpbrew/build/php-5.3.10/ext/dom/node.c:1900:40: error: 
dereferencing pointer to incomplete type
 RETVAL_STRINGL((char *) buf->buffer->content, ret, 1);

I have included all the libraries that phpbrew has indicated should be included, however I don't understand how to fix this build error or what it even means.

like image 901
user1658296 Avatar asked Sep 10 '26 06:09

user1658296


1 Answers

I had the similar problem and it was because of my installed libxml2 version was newer than 2.9.0. So as explained here you can fix it by applying the following patch: Go to your php source folder:

$ cd ~/.phpbrew/build/php-{version}/

Then download and apply the following patch:

$ curl -s https://mail.gnome.org/archives/xml/2012-August/txtbgxGXAvz4N.txt | patch -p0

Now try to compile and everything should be fine.

like image 152
NEO Avatar answered Sep 12 '26 20:09

NEO



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!