Closed someson closed 1 year ago
This is already fixed with the latest parsertl14 (I switched to int8_t and uint8_t a couple of months ago).
You can fetch the new files from https://github.com/BenHanson/parsertl14/tree/master/include/parsertl
@remicollet Are you able to merge in the latest parsertl14 Remi? Anatol seems to have gone very quiet.
I have forked parle and updated to the latest libraries: https://github.com/BenHanson/parle
I followed the instructions at: https://pear.php.net/manual/en/pyrus.commands.build.php to build, so it should all be OK (some interfaces had changed slightly)
Let me know if this builds OK for you now.
Let me know if this builds OK for you now.
Thank you! I was struggling to build it myself (even installed CLion) and got lost in errors. I'm not a CPP dev. However, there's an error in your build:
#0 3.724 In file included from /var/www/html/parle/lib/lexertl14/lexertl/parser/tokeniser/re_tokeniser.hpp:14,
#0 3.724 from /var/www/html/parle/lib/lexertl14/lexertl/parser/parser.hpp:15,
#0 3.724 from /var/www/html/parle/lib/lexertl14/lexertl/generator.hpp:15,
#0 3.724 from /var/www/html/parle/parle.cpp:39:
#0 3.724 /var/www/html/parle/lib/lexertl14/lexertl/parser/tokeniser/re_tokeniser_helper.hpp:243:10: fatal error: fold2.inc: No such file or directory
#0 3.724 243 | #include "fold2.inc"
#0 3.724 | ^~~~~~~~~~~
#0 3.724 compilation terminated.
#0 3.728 make: *** [Makefile:209: parle.lo] Error 1
trying to build in docker:
FROM php:8.1-fpm
RUN apt-get update && apt-get install -y --no-install-recommends \
sudo git curl gcc libtool libicu-dev libonig-dev libpng-dev libxml2-dev libxslt1-dev libzip-dev zip unzip gnupg wget
RUN git clone https://github.com/BenHanson/parle.git && cd parle && phpize && ./configure && make
# ...
I have added the missing files.
I think there are now some #include
path mismatches:
#0 3.602 g++ -I. -I/var/www/html/parle -I/var/www/html/parle/include -I/var/www/html/parle/main -I/var/www/html/parle -I/usr/local/include/php -I/usr/local/include/php/main -I/usr/local/include/php/TSRM -I/usr/local/include/php/Zend -I/usr/local/include/php/ext -I/usr/local/include/php/ext/date/lib -I/var/www/html/parle/lib/lexertl14 -I/var/www/html/parle/lib/parsertl14 -I/var/www/html/parle/lib/parle -I/var/www/html/parle/lib -DHAVE_CONFIG_H -g -O2 -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1 -std=c++14 -DZEND_COMPILE_DL_EXT=1 -c /var/www/html/parle/parle.cpp -MMD -MF parle.dep -MT parle.lo -fPIC -DPIC -o .libs/parle.o
#0 3.657 In file included from /var/www/html/parle/lib/parsertl14/parsertl/generator.hpp:12,
#0 3.657 from /var/www/html/parle/parle.cpp:46:
#0 3.657 /var/www/html/parle/lib/parsertl14/parsertl/rules.hpp:12:10: fatal error: ../../../lexertl14/include/lexertl/generator.hpp: No such file or directory
#0 3.657 12 | #include "../../../lexertl14/include/lexertl/generator.hpp"
#0 3.657 | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#0 3.657 compilation terminated.
#0 3.661 make: *** [Makefile:209: parle.lo] Error 1
------
failed to solve: executor failed running [/bin/sh -c git clone https://github.com/BenHanson/parle.git && cd parle && phpize --clean && phpize && ./configure && make]: exit code: 2
i think it should be
#include "../../lexertl14/lexertl/generator.hpp"
instead of
#include "../../../lexertl14/include/lexertl/generator.hpp"
3 files affected:
lib/parsertl14/parsertl/rules.hpp
lib/parsertl14/parsertl/match.hpp
lib/parsertl14/parsertl/search.hpp
i had this start already from path fixinig as i tried to do it myself :D
Aha, yes the relative paths have changed.
Anatol has given me push access to the main repository, so I have merged in the latest fixes.
I'm also planning to address at least some of the other issues.
it is nice to see that the package will be moving forward, thank you!
OS: Debian (docker php:8.1-fpm)
pecl or from source resulting the same: