the usual steps and following wiki instructions,
git clone https://github.com/SpiderLabs/ModSecurity.git && cd ModSecurity && ./build.sh && git submodule init && git submodule update && ./configure && make && sudo make install
in the past few days and till yesterday night it worked just fine with no issues.
Just today after doing some tests on a newly created server running Ubuntu 18.04.3
after cloning the repo and reaching make it simply stops and shows the error below
Logs and dumps
/bin/bash ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I. -std=c++11 -I.. -g -I../others -fPIC -O3 -I../headers -DWITH_GEOIP -I/usr/include/ -DWITH_YAJL -I/usr/include/yajl -I/usr/local/include -DPCRE_HAVE_JIT -DWITH_MAXMIND -I/usr/include/x86_64-linux-gnu -I/usr/include/libxml2 -DWITH_LIBXML2 -g -O2 -MT parser/libmodsecurity_la-seclang-parser.lo -MD -MP -MF parser/.deps/libmodsecurity_la-seclang-parser.Tpo -c -o parser/libmodsecurity_la-seclang-parser.lo `test -f 'parser/seclang-parser.cc' || echo './'`parser/seclang-parser.cc
libtool: compile: g++ -DHAVE_CONFIG_H -I. -std=c++11 -I.. -g -I../others -fPIC -O3 -I../headers -DWITH_GEOIP -I/usr/include/ -DWITH_YAJL -I/usr/include/yajl -I/usr/local/include -DPCRE_HAVE_JIT -DWITH_MAXMIND -I/usr/include/x86_64-linux-gnu -I/usr/include/libxml2 -DWITH_LIBXML2 -g -O2 -MT parser/libmodsecurity_la-seclang-parser.lo -MD -MP -MF parser/.deps/libmodsecurity_la-seclang-parser.Tpo -c parser/seclang-parser.cc -fPIC -DPIC -o parser/.libs/libmodsecurity_la-seclang-parser.o
In file included from ../src/rule_script.h:21:0,
from seclang-parser.yy:20,
from parser/seclang-parser.cc:40:
../headers/modsecurity/rules_set.h: In constructor ‘modsecurity::RulesSet::RulesSet()’:
../headers/modsecurity/rules_set.h:51:9: error: expected identifier before ‘,’ token
,m_secmarker_skipped(0)
^
Makefile:1851: recipe for target 'parser/libmodsecurity_la-seclang-parser.lo' failed
make[3]: *** [parser/libmodsecurity_la-seclang-parser.lo] Error 1
Expected behavior
Compile with no issues
Confirmed by going back to the last commit on the 4th of Feb: Commit
git checkout -b v3/old-commit
git reset --hard f7e4c1d9f5c96429334a28561fd2dd8cc4b53d30
I tried to compile and it went through with no issues.
This commit broke the compilation: Commit
the older commits work just fine.
Hope this helps
Well spoted @M034B5,
Working on the fix
fix is on the build bots.
worked like charm thanks @zimmerle !