epfl-lara / ScalaZ3

DSL in Scala for Constraint Solving with Z3 SMT Solver
Apache License 2.0
123 stars 34 forks source link

GCC 5 uses the GNU11 standard, which breaks how inline functions are used. #48

Closed koksal closed 9 years ago

koksal commented 9 years ago

I'm on OS X, and the C compilation fails when GCC 5 is used. I tracked down the cause to the change of standard from GNU89 to GNU11, affecting the semantics of inline functions.

A quick "fix" is to pass the flag -std=gnu89 to GCC. I assume the alternative is to rename inline functions to "extern inline" ones, which should be equivalent to the old "inline" functions in C99 semantics that are used now by default (according to this document).

colder commented 9 years ago

For now I added -std=gnu89.

If somebody has some time of their hands, feel free to revisit this and fix the code to work on gnu11.

Best,