Commit f3e4aa1a authored by Nirbheek Chauhan's avatar Nirbheek Chauhan 🐜 Committed by Nirbheek Chauhan

openexr: Fix check for when to pass -std=c++98

commit 6adfb120 added this flag to fix
builds with `-Werror`, and afterwards it was changed to use a version
check when newer versions of openexr moved over to C++11.

However, some distros have backported patches to older openexr
versions which make it require C++11, which makes the version check
incorrect and causes an error because we passed `-Werror -std=c++98`.

Instead, directly check when usage of the header requires `-std=c++98`
with `-Werror` and override the `cpp_std` setting on the target.

Fixes #1117
parent d29012a7
Pipeline #84430 failed with stages
in 84 minutes and 26 seconds