Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 821193 - media-libs/openimageio-2.3.8.0: Build fails - Imath/ImathColor.h: No such file or directory
Summary: media-libs/openimageio-2.3.8.0: Build fails - Imath/ImathColor.h: No such fil...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Aisha Tammy
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-01 10:55 UTC by Ian Pickworth
Modified: 2022-02-12 03:55 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Full Build log (media-libs:openimageio-2.3.8.0:20211101-093845.log,55.55 KB, text/plain)
2021-11-01 10:58 UTC, Ian Pickworth
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ian Pickworth 2021-11-01 10:55:10 UTC
Extract from build log (will attach full log):
...
[17/158] /usr/bin/x86_64-pc-linux-gnu-g++ -DOpenImageIO_EXPORTS -DOpenImageIO_Util_EXPORTS -DUSE_EXTERNAL_PUGIXML=1 -DUSE_FREETYPE=1 -DUSE_JPEG_TURBO=1 -DUSE_OCIO=1 -DUSE_OPENCOLORIO=1 -DUSE_TBB=1 -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -Iinclude/OpenImageIO -Iinclude -Isrc/include -I/var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/include -isystem /usr/include/Imath-3  -O2 -pipe -fPIC -Wall -Wno-unused-local-typedefs -Wno-unused-result -Wno-aligned-new -Wno-noexcept-type -fno-math-errno -msse2 -std=c++14 -MD -MT src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o -MF src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o.d -o src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o -c /var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/libutil/strutil.cpp
FAILED: src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o 
/usr/bin/x86_64-pc-linux-gnu-g++ -DOpenImageIO_EXPORTS -DOpenImageIO_Util_EXPORTS -DUSE_EXTERNAL_PUGIXML=1 -DUSE_FREETYPE=1 -DUSE_JPEG_TURBO=1 -DUSE_OCIO=1 -DUSE_OPENCOLORIO=1 -DUSE_TBB=1 -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -Iinclude/OpenImageIO -Iinclude -Isrc/include -I/var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/include -isystem /usr/include/Imath-3  -O2 -pipe -fPIC -Wall -Wno-unused-local-typedefs -Wno-unused-result -Wno-aligned-new -Wno-noexcept-type -fno-math-errno -msse2 -std=c++14 -MD -MT src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o -MF src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o.d -o src/libutil/CMakeFiles/OpenImageIO_Util.dir/strutil.cpp.o -c /var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/libutil/strutil.cpp
In file included from /var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/include/OpenImageIO/fmath.h:40,
                 from /var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/include/OpenImageIO/hash.h:31,
                 from /var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/include/OpenImageIO/strutil.h:24,
                 from /var/tmp/portage/media-libs/openimageio-2.3.8.0/work/oiio-2.3.8.0/src/libutil/strutil.cpp:27:
include/OpenImageIO/Imath.h:16:13: fatal error: Imath/ImathColor.h: No such file or directory
   16 | #   include <Imath/ImathColor.h>
      |             ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
ninja: build stopped: subcommand failed.

...
Comment 1 Ian Pickworth 2021-11-01 10:58:54 UTC
Created attachment 747801 [details]
Full Build log

Full Build log
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-11-01 11:00:51 UTC
Thanks for the report. This Imath pain doesn't seem to stop!
Comment 3 Ian Pickworth 2021-11-01 11:01:52 UTC
Do you need more information (emerge -pqv, environment files)?
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-11-01 11:21:33 UTC
(In reply to Ian Pickworth from comment #3)
> Do you need more information (emerge -pqv, environment files)?

Is there any chance you're comfortable briefly editing the ebuild?

Putting the 'sed' bit back at the top of src_prepare: https://gitweb.gentoo.org/repo/gentoo.git/commit/media-libs/openimageio?id=c694e446bc9a0e73dd9cc0586c82c05c2a5c2734 (no - lines in front though).
Comment 5 Ian Pickworth 2021-11-01 11:41:25 UTC
I'll have a go - give me a few hours...
Comment 6 Ian Pickworth 2021-11-01 12:10:29 UTC
I copied openimageio-2.3.8.0.ebuild to openimageio-2.3.8.0-r1.ebuild and made this change:

ian2 ~ # diff -crB /usr/portage/media-libs/openimageio/openimageio-2.3.8.0.ebuild /usr/portage/media-libs/openimageio/openimageio-2.3.8.0-r1.ebuild
*** /usr/portage/media-libs/openimageio/openimageio-2.3.8.0.ebuild	2021-10-31 09:10:00.000000000 +0000
--- /usr/portage/media-libs/openimageio/openimageio-2.3.8.0-r1.ebuild	2021-11-01 12:00:10.000000000 +0000
***************
*** 103,108 ****
--- 103,112 ----
  }
  
  src_prepare() {
+ 	sed -i \
+ 			-e 's/find_package(OpenEXR CONFIG)/find_package(OpenEXR-3 CONFIG)/' \
+ 			src/cmake/modules/FindOpenEXR.cmake || die
+ 
  	cmake_src_prepare
  	cmake_comment_add_subdirectory src/fonts
  
ian2 ~ # 

After updating the manifest, emerging openimageio-2.3.8.0-r1 worked, so that appears to fix the Imath issue.
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-11-01 12:34:27 UTC
Thanks a bunch! I think I'd assumed I added it when it was obsolete and dropped it without thinking. My apologies and again appreciated for the testing.

Fixing now...
Comment 8 Larry the Git Cow gentoo-dev 2021-11-01 12:37:12 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1d79435986200507cccba60dd4bcf2cf168f5a0c

commit 1d79435986200507cccba60dd4bcf2cf168f5a0c
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2021-11-01 12:35:54 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2021-11-01 12:36:49 +0000

    media-libs/openimageio: fix building against OpenEXR 2
    
    Closes: https://bugs.gentoo.org/821193
    Signed-off-by: Sam James <sam@gentoo.org>

 ...{openimageio-2.3.8.0.ebuild => openimageio-2.3.8.0-r1.ebuild} | 9 +++++++++
 1 file changed, 9 insertions(+)
Comment 9 Sebastian Parborg 2021-11-01 15:12:45 UTC
It seems like older openimageio versions also needs this work around to build.
I tested 2.2.18.0-r1 and 2.2.15.0-r1
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-11-01 15:17:28 UTC
(In reply to Sebastian Parborg from comment #9)
> It seems like older openimageio versions also needs this work around to
> build.
> I tested 2.2.18.0-r1 and 2.2.15.0-r1

May need a slightly different hack there to ensure we definitely build against the older slot. You able to look at it? I can try if _really_ needed but got other bits on list too
Comment 11 Larry the Git Cow gentoo-dev 2022-02-12 03:55:50 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=42905a79164d67fea0dcc8f5138a78b8553d5996

commit 42905a79164d67fea0dcc8f5138a78b8553d5996
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-02-12 02:01:26 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-02-12 03:55:31 +0000

    media-libs/openimageio: flip over to OpenEXR 3
    
    Things are getting complicated with trying to keep Blender
    on OpenEXR 2. Blender needs to switch as a result, but
    so do its dependencies.
    
    Bug: https://bugs.gentoo.org/831357
    Bug: https://bugs.gentoo.org/832862
    Bug: https://bugs.gentoo.org/821193
    Signed-off-by: Sam James <sam@gentoo.org>

 .../openimageio-2.3.11.0-imath-openexr-3.patch     | 302 +++++++++++++++++++++
 .../openimageio/openimageio-2.3.11.0-r1.ebuild     | 190 +++++++++++++
 2 files changed, 492 insertions(+)