Compilation error: unknown type name 'rd_kafka_error_t'
brmn opened this issue · 2 comments
brmn commented
- PHP version: PHP 8.0.3 (cli) (built: Mar 5 2021 07:54:13) ( NTS )
- librdkafka version: librdkafka-dev/focal,now 1.2.1-1ubuntu1 amd64 [installed], librdkafka1/focal,now 1.2.1-1ubuntu1 amd64 [installed,automatic]
- simple-kafka-client version: latest PECL
- kafka version: --
Add debug logs, by adjusting your configuration:
# pecl install simple_kafka_client
...
running: make
/bin/bash /tmp/pear/temp/pear-build-defaultuserVyI2pr/simple_kafka_client-0.1.4/libtool --mode=compile cc -I. -I/tmp/pear/temp/simple_kafka_client -I/tmp/pear/temp/pear-build-defaultuserVyI2pr/simple_kafka_client-0.1.4/include -I/tmp/pear/temp/pear-build-defaultuserVyI2pr/simple_kafka_client-0.1.4/main -I/tmp/pear/temp/simple_kafka_client -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /tmp/pear/temp/simple_kafka_client/simple_kafka_client.c -o simple_kafka_client.lo
libtool: compile: cc -I. -I/tmp/pear/temp/simple_kafka_client -I/tmp/pear/temp/pear-build-defaultuserVyI2pr/simple_kafka_client-0.1.4/include -I/tmp/pear/temp/pear-build-defaultuserVyI2pr/simple_kafka_client-0.1.4/main -I/tmp/pear/temp/simple_kafka_client -I/usr/include/php/20200930 -I/usr/include/php/20200930/main -I/usr/include/php/20200930/TSRM -I/usr/include/php/20200930/Zend -I/usr/include/php/20200930/ext -I/usr/include/php/20200930/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /tmp/pear/temp/simple_kafka_client/simple_kafka_client.c -fPIC -DPIC -o .libs/simple_kafka_client.o
In file included from /tmp/pear/temp/simple_kafka_client/simple_kafka_client.c:43:
/tmp/pear/temp/simple_kafka_client/php_simple_kafka_client_int.h:192:51: error: unknown type name 'rd_kafka_error_t'
192 | void create_kafka_error(zval *return_value, const rd_kafka_error_t *error);
| ^~~~~~~~~~~~~~~~
make: *** [Makefile:209: simple_kafka_client.lo] Error 1
ERROR: `make' failed
root@d367a21c3dab:/var/www/html#
nick-zh commented
@brmn thx i'll have a look on the weekend, if you figure out the cause before me, feel free to open a PR ✌️
nick-zh commented
Ah sry, i overlooked that you are using librdkafka-1.2.x
which is not supported, you need to have at least librdkafka-1.6.x