cd /var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0_build/src/pyglue && /usr/bin/x86_64-pc-linux-gnu-g++ -DPYOCIO_NAME=PyOpenColorIO -DPyOpenColorIO_EXPORTS -DUSE_SSE -I/var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0/export -I/var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0_build/export -I/var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0_build/src/pyglue -I/usr/include/python3.6m -DNDEBUG -O2 -pipe -march=native -Wall -Wextra -Wshadow -Wconversion -Wcast-qual -Wformat=2 -msse2 -Wno-strict-aliasing -Wno-missing-field-initializers -Werror -fPIC -o CMakeFiles/PyOpenColorIO.dir/PyAllocationTransform.cpp.o -c /var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0/src/pyglue/PyAllocationTransform.cpp /var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0/src/pyglue/PyAllocationTransform.cpp:67:27: error: cast between incompatible function types from ‘PyObject* (*)(PyObject*)’ {aka ‘_object* (*)(_object*)’} to ‘PyCFunction’ {aka ‘_object* (*)(_object*, _object*)’} [-Werror=cast-function-type] (PyCFunction) PyOCIO_AllocationTransform_getAllocation, METH_NOARGS, ALLOCATIONTRANSFORM_GETALLOCATION__DOC__ }, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /var/tmp/portage/media-libs/opencolorio-1.1.0-r1/work/opencolorio-1.1.0/src/pyglue/PyAllocationTransform.cpp:71:27: error: cast between incompatible function types from ‘PyObject* (*)(PyObject*)’ {aka ‘_object* (*)(_object*)’} to ‘PyCFunction’ {aka ‘_object* (*)(_object*, _object*)’} [-Werror=cast-function-type] ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 17.0_20190205-121519 ------------------------------------------------------------------- gcc-config -l: [1] x86_64-pc-linux-gnu-7.3.1 [2] x86_64-pc-linux-gnu-8.2.0 * Available Python interpreters, in order of preference: [1] python3.7 [2] python3.6 [3] python2.7 (fallback) Available Ruby profiles: [1] ruby24 (with Rubygems) [2] ruby25 (with Rubygems) [3] ruby26 (with Rubygems) * Available Rust versions: [1] rust-1.32.0 * emerge -qpvO media-libs/opencolorio [ebuild N ] media-libs/opencolorio-1.1.0-r1 USE="python -doc -opengl -static-libs -test" CPU_FLAGS_X86="sse2" PYTHON_SINGLE_TARGET="python3_6 -python2_7 -python3_4 -python3_5" PYTHON_TARGETS="python2_7 python3_6 -python3_4 -python3_5"
Created attachment 564540 [details] emerge-info.txt
Created attachment 564542 [details] emerge-history.txt
Created attachment 564544 [details] environment
Created attachment 564546 [details] etc.portage.tbz2
Created attachment 564548 [details] logs.tbz2
Created attachment 564550 [details] media-libs:opencolorio-1.1.0-r1:20190210-120045.log
Created attachment 564552 [details] temp.tbz2
Seems to be a GCC 8 issue. Adding "-Wno-error=cast-function-type" to CXXFLAGS / CFLAGS makes it compile. (not verified function) source: https://github.com/swig/swig/issues/1259
Debian seems to have a patch for this https://salsa.debian.org/debian-phototools-team/opencolorio/blob/master/debian/patches/0004-Fix_build_with_GCC-8.patch
The src/pyglue/CMakeLists.txt file adds a global -Werror flag for unix systems. IIRC this is something, we don't want to have. Commenting this out let the compilation succeed. But the debian patch looks like the right approach for this issue, in addition to disabling -Werror.
Created attachment 571244 [details, diff] opencolorio-1.1.0-remove-Werror.patch Patch to disable global -Werror flag in src/pyglue/CMakeLists.txt
Additionally, I tried bumping EAPI and removing obsolete python-3.4 from PYTHON_COMPAT, which works for me.
Created attachment 571246 [details, diff] opencolorio-1.1.0.diff Diff between opencolorio-1.1.0-r1 and EAPI bumped opencolorio-1.1.0-r2
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=279e0179049fc08d5f304e23f1729a2c231a2f07 commit 279e0179049fc08d5f304e23f1729a2c231a2f07 Author: Sam James <sam@gentoo.org> AuthorDate: 2020-10-10 03:27:22 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2020-10-10 03:27:33 +0000 media-libs/opencolorio: bump to 1.1.1 Closes: https://bugs.gentoo.org/747409 Closes: https://bugs.gentoo.org/667986 Closes: https://bugs.gentoo.org/677642 Package-Manager: Portage-3.0.4, Repoman-3.0.1 Signed-off-by: Sam James <sam@gentoo.org> media-libs/opencolorio/Manifest | 1 + media-libs/opencolorio/opencolorio-1.1.1.ebuild | 92 +++++++++++++++++++++++++ 2 files changed, 93 insertions(+)