v1.1.0 compile problem with g++ 7.3.0

211 views
Skip to first unread message

jdb.w...@gmail.com

unread,
Jun 14, 2018, 12:23:01 PM6/14/18
to OpenColorIO Developers
Hi,

I tried to compile OCIO version 1.1.0 on a Debian based distro using g++ 7.3.0:

$ cat /etc/debian_version
buster/sid
$ g++ --version
g++ (Debian 7.3.0-11) 7.3.0

I get error messages related to "-Werror=deprecated-declarations".

Here is the first one:

$ cmake -D CMAKE_INSTALL_PREFIX=/usr/local/ocio ~/git/github/OpenColorIO
-- The C compiler identification is GNU 7.3.0
-- The CXX compiler identification is GNU 7.3.0
...
/home/jan/git/github/OpenColorIO/ociobuild/ext/dist/include/yaml-cpp/parser.h:46:8: error: ‘template<class> class std::auto_ptr’ is deprecated [-Werror=deprecated-declarations]
   std::auto_ptr<Scanner> m_pScanner;
        ^~~~~~~~
In file included from /usr/include/c++/7/memory:80:0,
                 from /usr/include/c++/7/tr1/memory:39,
                 from /home/jan/git/github/OpenColorIO/ociobuild/export/OpenColorABI.h:63,
                 from /home/jan/git/github/OpenColorIO/export/OpenColorIO/OpenColorIO.h:38,
                 from /home/jan/git/github/OpenColorIO/src/core/OCIOYaml.cpp:31:
/usr/include/c++/7/bits/unique_ptr.h:51:28: note: declared here
   template<typename> class auto_ptr;
                            ^~~~~~~~
In file included from /home/jan/git/github/OpenColorIO/ociobuild/ext/dist/include/yaml-cpp/yaml.h:8:0,
                 from /home/jan/git/github/OpenColorIO/src/core/OCIOYaml.cpp:75:

Any ideas how to make this work?

Thanks,

Jan

Patrick Hodoul

unread,
Jun 15, 2018, 9:30:41 AM6/15/18
to OpenColorIO Developers
Hi Jan,

According to the gcc documentation (Warning-Options), you could disable the warning with -Wno-deprecated-declarations

Patrick.

Patrick Hodoul

unread,
Jun 15, 2018, 9:59:48 AM6/15/18
to OpenColorIO Developers
Another option could be to use the installed yaml (instead of the OCIO one) with  USE_EXTERNAL_YAML
Reply all
Reply to author
Forward
0 new messages