souffle-lang / souffle

Soufflé is a variant of Datalog for tool designers crafting analyses in Horn clauses. Soufflé synthesizes a native parallel C++ program from a logic specification.
http://souffle-lang.github.io/
Universal Permissive License v1.0
913 stars 206 forks source link

Build error on Fedora 40 for Souffle 2.2 #2490

Closed tchoutri closed 3 months ago

tchoutri commented 4 months ago

It doesn't seem possible to build Souffle 2.2 on Fedora 40 at the moment:

/home/tchoutri/Vrac/souffle-2.2/src/tests/disjoint_set_property_test.cpp:143:12: error: use of deleted function ‘souffle::PiggyList<T>::PiggyList(souffle::PiggyList<T>&&) [with T = long unsigned int]’
  143 |     return nodes;
      |            ^~~~~

I already had to pass -Wno-error=deprecated-declarations in src/CMakeLists.txt but I don't have a good workaround for this.

quentin commented 4 months ago

Version 2.2 is quite old, not surprising that recent compilers may complain. I would recommend building 2.4.1 if you can.

quentin commented 4 months ago

The latest version of the line is return souffle::PiggyList<parent_t>{nodes};. That might be enough to fix?

tchoutri commented 4 months ago

The latest version of the line is return souffle::PiggyList<parent_t>{nodes};. That might be enough to fix?

Ok! Thank you!

quentin commented 4 months ago

New versions of compilers tend to implement more and more warnings. You may consider removing at least -Werror here to disable "warnings into errors" behavior:

https://github.com/souffle-lang/souffle/blob/ea4ebd45b56619f9362d5db9bb6b7783b4bbb24c/src/CMakeLists.txt#L198-L199

tchoutri commented 4 months ago

I have done this, but it doesn't seem to effect the error. Is there any command to build the binary and not the tests?

quentin commented 4 months ago

You should be able to disable the build of tests with cmake -DSOUFFLE_ENABLE_TESTING=OFF ...

quentin commented 4 months ago

This branch builds with tests on my fedora 40: https://github.com/quentin/souffle/tree/v2.2

https://github.com/souffle-lang/souffle/compare/2.2...quentin:souffle:v2.2

quentin commented 3 months ago

I'm closing this question. Feel free to re-open if needed.