Compiling enblend with gnu g++

97 views
Skip to first unread message

Kornel Benko

unread,
Nov 21, 2019, 6:58:04 PM11/21/19
to hugi...@googlegroups.com
Hi,
the recent version of enblend sources (from repo) is
not compilable with the gnu compiler.

Using it I get
In file included from /usr/src/enblend/enblend-code/src/enblend.cc:85:
/usr/src/enblend/enblend-code/src/optional_transitional.hpp:40:51: error: 'experimental'
in namespace 'std' does not name a type 40 | template <typename t> using optional
= ::std::experimental::optional<t>; |
^~~~~~~~~~~~ /usr/src/enblend/enblend-code/src/optional_transitional.hpp:41:11: error:
'experimental' has not been declared 41 | using experimental::nullopt;
| ^~~~~~~~~~~~
/usr/src/enblend/enblend-code/src/enblend.cc:118:6: error: 'optional' in namespace 'std'
does not name a template type 118 | std::optional<std::string> OutputMaskFileName;
| ^~~~~~~~
/usr/src/enblend/enblend-code/src/enblend.cc:118:1: note: 'std::optional' is only
available from C++17 onwards
...................................................................

Patching the CMakeLists.txt to use the required --std=c++17, the error
compiling src/enblend.cc is:
In file included from /usr/include/vigra/stdconvolution.hxx:43,
from /usr/include/vigra/convolution.hxx:41,
from /usr/src/enblend/enblend-code/src/openmp_vigra.h:32,
from /usr/src/enblend/enblend-code/src/enblend.h:41,
from /usr/src/enblend/enblend-code/src/enblend.cc:197:
/usr/include/vigra/separableconvolution.hxx:1413:13: error: ISO C++17 does not allow
dynamic exception specifications 1413 | throw(PreconditionViolation)
| ^~~~~
.....................................................

This is the same with the recent g++9.2 compiler.

Kornel

Gunter Königsmann

unread,
Nov 22, 2019, 12:42:34 AM11/22/19
to hugi...@googlegroups.com, Kornel Benko
I believe if you add -std=c++1z to the compiler flags it works.

Kind regards,

Gunter.
--
Diese Nachricht wurde von meinem Android-Gerät mit K-9 Mail gesendet.

Kornel Benko

unread,
Nov 22, 2019, 5:36:19 AM11/22/19
to hugi...@googlegroups.com
Am Fri, 22 Nov 2019 06:42:24 +0100
schrieb Gunter Königsmann <gunter.ko...@gmail.com>:

> I believe if you add -std=c++1z to the compiler flags it works.
>
> Kind regards,
>
> Gunter.

Unfortunately this does not help. The resulting error is the same as with -std=c++17.
Reply all
Reply to author
Forward
0 new messages