Errors on al builds
brancomat opened this issue · 3 comments
I assume porting to GEOS C API for #291 is still ongoing, but there are a couple of side effects worth a report:
On CentOS 7 (https://simc.arpae.it/moncic-ci/arkimet/last/master/centos7/build.log):
/bin/sh ../libtool --tag=CXX --mode=compile g++ -DHAVE_CONFIG_H -I.. -I.. -I/root/rpmbuild/BUILD/arkimet/embedded/sqlite/ -DCONF_DIR=\"/etc/arkimet\" -DPOSTPROC_DIR=\"/usr/lib64/arkimet\" -I/usr/include -I/usr/lib64/pkgconfig/../../include -I/usr/include/mysql -Werror -Wall -Wextra -Wno-unused-parameter -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -std=c++11 -c -o utils/libarkimet_la-geos.lo `test -f 'utils/geos.cc' || echo './'`utils/geos.cc
2022-09-12 18:23:45 INFO system.centos7 stdout: libtool: compile: g++ -DHAVE_CONFIG_H -I.. -I.. -I/root/rpmbuild/BUILD/arkimet/embedded/sqlite/ -DCONF_DIR=\"/etc/arkimet\" -DPOSTPROC_DIR=\"/usr/lib64/arkimet\" -I/usr/include -I/usr/lib64/pkgconfig/../../include -I/usr/include/mysql -Werror -Wall -Wextra -Wno-unused-parameter -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -std=c++11 -c utils/geos.cc -fPIC -DPIC -o utils/.libs/libarkimet_la-geos.o
utils/geos.cc: In constructor 'arki::utils::geos::Context::Context()':
utils/geos.cc:52:23: error: 'GEOS_init_r' was not declared in this scope
: ctx(GEOS_init_r())
^
utils/geos.cc: In destructor 'arki::utils::geos::Context::~Context()':
utils/geos.cc:60:22: error: 'GEOS_finish_r' was not declared in this scope
GEOS_finish_r(ctx);
^
utils/geos.cc: In member function 'void arki::utils::geos::CoordinateSequence::setxy(unsigned int, double, double)':
utils/geos.cc:127:59: error: 'GEOSCoordSeq_setXY_r' was not declared in this scope
int res = GEOSCoordSeq_setXY_r(context, ptr, idx, x, y);
On CentOS8 the error is similar but mentions only GEOSCoordSeq_setXY_r
On all fedora builds, the installation of man pages now fails (from https://simc.arpae.it/moncic-ci/arkimet/last/master/fedora34/build.log):
/usr/bin/install -c -m 644 ./arki-dump.1 ./arki-query.1 ./arki-check.1 ./arki-mergeconf.1 ./arki-scan.1 ./arki-server.1 arki-testtar.1 ./arki-xargs.1 ./arki-bufr-prepare.1 '/root/rpmbuild/BUILDROOT/arkimet-1.44-1.x86_64/usr/share/man/man1'
system.fedora34 stderr: /usr/bin/install: cannot stat './arki-dump.1': No such file or directory
system.fedora34 stderr: /usr/bin/install: cannot stat './arki-query.1': No such file or directory
(...)
In a previous working build the syntax was different (from https://simc.arpae.it/moncic-ci/arkimet/202209021231/master/fedora34/build.log):
/usr/bin/install -c -m 644 arki-dump.1 arki-query.1 arki-check.1 arki-mergeconf.1 arki-scan.1 arki-server.1 arki-testtar.1 arki-xargs.1 arki-bufr-prepare.1 '/root/rpmbuild/BUILDROOT/arkimet-1.44-1.x86_64/usr/share/man/man1'
Right, so the C API is stable, but the part of the C API that I'm using (the thread safe part) did not exist in Centos7. Fun 😞
Is there a newer version of GEOS available for Centos7 somehow?
For the lack of GEOSCoordSeq_setXY_r
I think it's possible to find an easy workaround
I have found that the names of the init functions in GEOS 3.4 were different than in GEOS 3.5+, and I've now added precompiler statements to use one or the other.
They keep compatibility in the C API, but it doesn't mean that they don't change function names over time, keeping the deprecated ones around
Arkimet is now greed on all required builds