[Slackbuilds-users] openimageio with pybind11 issues

Tim Dickson dickson.tim at googlemail.com
Wed Mar 24 14:30:57 UTC 2021


On 24/03/2021 11:42, Christoph Willing wrote:
> On 24/3/21 6:55 pm, Tim Dickson via SlackBuilds-users wrote:
>>
>> On 24/03/2021 07:48, Christoph Willing wrote:
>>> On 23/3/21 5:44 pm, Tim Dickson via SlackBuilds-users wrote:
>>>> has anyone had success building openimageio with the new pybind11  ? it
>>>> is failing for me. it seems to be looking for pybind11 files in
>>>> /usr/include/python2.7/pybind11  when the pybind11 package has the files
>>>> in /usr/include/pybind11
>>>>
>>> I've held pybind11 at version at 2.5.0 - the latest that enables
>>> building of openimageio - however not for want of finding include files.
>>> With latest pybind11-2.6.2 configuration output says:
>>>       -- pybind11 2.6.2, include dir: /usr/include
>>>
>>> i.e. include files are found OK.
>>>
>>> The error I see is after 92% has compiled:
>>>       /var/tmp/SBo/oiio-Release-2.0.13/src/python/py_oiio.h:303:47: error:
>>> no matching function for call to 'cast(OpenImageIO_v2_0::span<const
>>> OpenImageIO_v2_0::TypeDesc, -1l>::element_type&)'
>>>
>>> I'm assuming this is due to new definitions in pybind11 which newer
>>> versions of openimageio will deal with. However newer versions of
>>> openimageio don't build in 14.2 so we're stuck with openimageio-2.0.13
>>> and (therefore) pybind11-2.5.0.
>>>
>>> chris
>>>
>> hmm. i'm using pybind11 2.5.0 all on slackware 14.2 (64bit) the errors i
>> get with openimageio are....
>>
>> -- robin-map include dir: /usr/include
>> CMake Error at src/cmake/externalpackages.cmake:568 (file):
>>    file STRINGS file "/usr/include/python2.7/pybind11/common.h" cannot be
>>    read.
>> Call Stack (most recent call first):
>>    CMakeLists.txt:206 (find_or_download_pybind11)
>>
>> CMake Error at src/cmake/externalpackages.cmake:570 (file):
>>    file STRINGS file "/usr/include/python2.7/pybind11/common.h" cannot be
>>    read.
>> Call Stack (most recent call first):
>>    CMakeLists.txt:206 (find_or_download_pybind11)
>>
>> CMake Error at src/cmake/externalpackages.cmake:572 (file):
>>    file STRINGS file "/usr/include/python2.7/pybind11/common.h" cannot be
>>    read.
>> Call Stack (most recent call first):
>>    CMakeLists.txt:206 (find_or_download_pybind11)
>>
>> -- pybind11 366.366.366, include dir: /usr/include/python2.7
>> CMake Error at
>> /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:148
>> (message):
>>    Could NOT find PythonInterp: Found unsuitable version "2.7.17", but
>>    required is at least "3.7.2" (found /usr/bin/python2.7)
>> Call Stack (most recent call first):
>> /usr/share/cmake-3.5/Modules/FindPackageHandleStandardArgs.cmake:386
>> (_FPHSA_FAILURE_MESSAGE)
>>    /usr/share/cmake-3.5/Modules/FindPythonInterp.cmake:163
>> (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
>>    src/python/CMakeLists.txt:4 (find_package)
>>
>> -- Configuring incomplete, errors occurred!
>> See also "/tmp/SBo/oiio-Release-2.0.13/build/CMakeFiles/CMakeOutput.log".
>> See also "/tmp/SBo/oiio-Release-2.0.13/build/CMakeFiles/CMakeError.log".
>>
>> looking at the CMakeEerror.log the complaint is that pthread_create does
>> not exist.
> I don't think that's a problem - I see the same pthread problem  in
> CMakeError.log of a successful build.
>
> How old is your pybind11 build? In February I updated the SLackBuilkd
> for pybind11, the main change being to use CMake instead of Python as
> the build instrument; also to use python3 exclusively instead of
> python2. I suggest you rebuild/install this latest pybind11, then try
> openimageio again.
>
> chris
> _______________________________________________
>
I did have the latest pybind11 installed (I reinstalled it again, just 
in case). But your info about the change got me thinking, and i've got 
it going now. (after running rm -r /tmp/SBo/*  ). It looks like previous 
build artefacts in openimageio messed up the build attempt. thanks for 
the pointer.

 From looking at the openimageio.Slackbuild, it tries to remove the 
wrong temporary directory before extracting the files, thus leaving 
stale stuff from previous package creation. Because the PRGNAM is 
"openimageio" but the extracted source is in "oiio-Release" the script 
never cleans up (removes) any previous contents of oiio-Release
A fix for this in the slackbuild is to replace
rm -rf PRGNAM-$VERSION

with

rm -rf $SRCNAM-$VERSION

Regards, Tim (and thanks for the slackbuild :-)   )

-- 
This email has been checked for viruses by AVG.
https://www.avg.com



More information about the SlackBuilds-users mailing list