• Status New
  • Percent Complete
    0%
  • Task Type Bug Report
  • Category Packages
  • Assigned To No-one
  • Operating System pentium4
  • Severity Low
  • Priority Medium
  • Reported Version
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Arch Linux 32
Opened by Andreas Baumann - 02.04.2022
Last edited by Andreas Baumann - 10.04.2022

FS#246 - [blender] doesn't work (and doesn't build)

blender 2.93 has dependencies on wrong versions of
- llvm (via openshadinglanguage)
- boost (via openimageio)

Could NOT find PythonLibsUnix (missing: PYTHON_LIBRARY PYTHON_LIBPATH PYTHON_INCLUDE_DIR PYTHON_INCLUDE_CONFIG_DIR)’

blender 3.0.1:
Haru not found, disabling WITH_HARU’ and ‘Cycles OSL requires WITH_LLVM, the library may not have been found. Configure LLVM or disable WITH_CYCLES_OSL

Let’s tackle one issue after the other. :-)

Admin
Andreas Baumann commented on 02.04.2022 07:07

lddtree shows:

...
    liboslexec.so.1.11 => /usr/lib/liboslexec.so.1.11
        libboost_thread.so.1.76.0 => None
    liboslcomp.so.1.11 => /usr/lib/liboslcomp.so.1.11
        libclang-cpp.so.12 => None
        libLLVM-12.so => None
...
    libOpenImageIO.so.2.2 => /usr/lib/libOpenImageIO.so.2.2
        libboost_filesystem.so.1.76.0 => None
...
    libboost_locale.so.1.76.0 => None
Admin
Andreas Baumann commented on 02.04.2022 09:38

OpenColorio:

-- Performing Test HAVE_SSE2
-- Performing Test HAVE_SSE2 - Success

This is hard-coded for being tested on the host, so this fails when
cross-compiling or building in a chroot.

Admin
Andreas Baumann commented on 03.04.2022 06:58

openshadinglanguage fails with:

CMake Error at /usr/share/cmake/Modules/FindBISON.cmake:113 (message):
  Command "/usr/bin/bison --version" failed with output:

  /usr/bin/bison: error while loading shared libraries: libtextstyle.so.0:
  cannot open shared object file: No such file or directory

lddtree shows libtextstyle.so.0 comes from gettext which is stuck in a failing
test (which I will now simply ignore). The error is in gnulib, which is a library
fetched at build time in source form to various GNU project (as if shared libraries would
not exist). This makes patching them hard..

We have to force rebuilding of bison (why didn't it happen?)

Admin
Andreas Baumann commented on 03.04.2022 11:12

So, gettext and bison are ready, so are the open* libraries.

Now we get into unported 32-bit problem territory:

/build/blender/src/blender/source/blender/blenkernel/intern/idprop_create.cc:122:40:   required from here
/build/blender/src/blender/source/blender/blenkernel/intern/idprop_create.cc:94:98: error: static assertion failed: Allowed values for PrimitiveType are int32_t, float and double.
   94 |   static_assert(std::is_same_v<PrimitiveType, int32_t> || std::is_same_v<PrimitiveType, float_t> ||
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~
   95 |                     std::is_same_v<PrimitiveType, double>,
      |                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~                                         

So, adding float as a primitive helps (as float_t is something beatifuly
different on 32-bit).

Admin
Andreas Baumann commented on 03.04.2022 13:44

So, now I get tons of errors here:

/build/blender/src/blender/build/bin/blender: error while loading shared libraries: libtbb.so.2: cannot open shared object file: No such file or directory

This is weird, as this means that the new blender being built is still linked
somehow againt an old TBB library.

Admin
Andreas Baumann commented on 03.04.2022 13:46
    libembree3.so.3 => /usr/lib/libembree3.so.3
        libtbb.so.2 => None

aha, so we have to rebuilt embree.. :-)

Admin
Andreas Baumann commented on 03.04.2022 13:58
-- Found Intel SPMD Compiler (ISPC): /usr/bin/ispc
/usr/bin/ispc: error while loading shared libraries: libclang-cpp.so.10: cannot open shared object file: No such file or directory

Nice, this points to ispc, either we rebuild that against newer llvm or we use a
llvm10-libs shim.

Admin
Andreas Baumann commented on 03.04.2022 14:02

ispc: I have a bad feeling about this:

In file included from /usr/include/features.h:514:
/usr/include/gnu/stubs.h:10:11: fatal error: 'gnu/stubs-64.h' file not found
# include <gnu/stubs-64.h>
          ^~~~~~~~~~~~~~~~
Admin
Andreas Baumann commented on 03.04.2022 14:03

We would need a clang10 (we don't have one), just to make the old ispc work again.
Let's see if we can drop embree from blender.. (though I have the feeling blender
could require with a ray tracer..):

-- Found OpenColorIO: /usr/lib/libOpenColorIO.so;/usr/lib/libyaml-cpp.so;/usr/lib/libexpat.so;/usr/lib/libpystring.so (found suitable version "2.1.1", minimum required is "2.0.0") 
CMake Error at /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find Embree (missing: _embree_LIBRARIES EMBREE_INCLUDE_DIR)
  (Required is at least version "3.8.0")
Call Stack (most recent call first):
  /usr/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
  build_files/cmake/Modules/FindEmbree.cmake:82 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  build_files/cmake/platform/platform_unix.cmake:427 (find_package)
  CMakeLists.txt:1001 (include)

bingo.

Admin
Andreas Baumann commented on 03.04.2022 14:05

So, reactivating blender will be hard I'm afraid..

Killer Wasp commented on 03.04.2022 15:52

From mi side.

Blender 2.93:
Break llvm, clang and boost-libs dependences. I tried decompress this 3 packages in a new directory and tried run with LD_LIBRARY_PATH= with a segfault result (i maybe need test with a restart)
packages that need:
- llvm-libs-12.0.1-5.1-pentium4.pkg.tar.zst (or "llvm12" from the system)
- clang-12.0.1-1.2-pentium4.pkg.tar.zst
- boost-libs-1.76.0-2.1-pentium4.pkg.tar.zst

Blender 3.0.1:
Give a error from cmake: (tested with LD_LIBRARY_PATH=, llvm13, and llvm12, and python 3.9)
- "Haru not found, disabling WITH_HARU"
- "Cycles OSL requires WITH_LLVM, the library may not have been found. Configure LLVM or disable WITH_CYCLES_OSL"
- disable with -DWITH_CYCLES_OSL=Off , and now show a bunch of errors with Boost.

Blender 3.1.2:
Give a error from cmake:
- "Could NOT find PythonLibsUnix (missing: PYTHON_LIBRARY PYTHON_LIBPATH PYTHON_INCLUDE_DIR PYTHON_INCLUDE_CONFIG_DIR)"

It seems that the one that works best is 3.0.1, at least close to it. The cmake line used is:
cmake .. -DCMAKE_BUILD_TYPE=Release -DWITH_CYCLES_DEVICE_OPTIX=OFF -DWITH_CYCLES_OSL=Off -DWITH_PYTHON_INSTALL=OFF -DWITH_INSTALL_PORTABLE=OFF -DPYTHON_VERSION=3.9 -DPYTHON_LIBPATH=/usr/lib -DPYTHON_LIBRARY=python3.9 -DPYTHON_INCLUDE_DIRS=/usr/include/python3.9 -DCMAKE_CXX_FLAGS="-I /usr/include/python3.9" -DWITH_CYCLES_CUDA_BINARIES=OFF -DWITH_CYCLES_DEVICE_CUDA=OFF -DWITH_RAYOPTIMIZATION=OFF -DBOOST_LIBPATH=/opt/DWN-T/SYS3/usr/lib -DBoost_INCLUDE_DIR=/opt/DWN-T/SYS3/usr/include/ -DWITH_HARU=OFF

(/opt/DWN-T/SYS3/ have old packages for llvm-12.0.1, boost-libs 1.76, and clang-12.0.1)

Admin
Andreas Baumann commented on 05.04.2022 17:52

ispc probes for a AMD64 host and then does:

set(X86_HOST FALSE)
#if (${CMAKE_HOST_SYSTEM_PROCESSOR} MATCHES "AMD64|86")
#    set(X86_HOST TRUE)
#endif()

Fixing that gets me stuck in ispc (required by embree) with:

/build/ispc/src/ispc-1.16.1/src/func.cpp:490:44: error: no member named 'Reserved_0' in 'llvm::genx::KernelMDOp'
            mdArgs[llvm::genx::KernelMDOp::Reserved_0] =
                   ~~~~~~~~~~~~~~~~~~~~~~~~^
1 error generated.
make[2]: *** [CMakeFiles/ispc.dir/build.make:594: CMakeFiles/ispc.dir/src/func.cpp.o] Error 1

This could be a too old version of llvm..

Admin
Andreas Baumann commented on 05.04.2022 17:54

@Killer Wasp: We could try to let blender alive as a library zombie by providing
shim libraries for boost, llvm, icu, etc. But then it goes the firefox way of the
dodo..

Admin
Andreas Baumann commented on 05.04.2022 17:55
llvm 13.0.1-2.0
llvm-libs 13.0.1-2.0

seems up to date (in staging).

Admin
Andreas Baumann commented on 06.04.2022 18:27

Do we need genx at all? I try to disable that..

Admin
Andreas Baumann commented on 07.04.2022 07:46

Good sign, the patch file is now longer than the PKGBUILD :-) removing testing and GENX seems to produce a ispc binary (all we care for now)..

Admin
Andreas Baumann commented on 07.04.2022 13:39

Rebuilding embree now..

Admin
Andreas Baumann commented on 07.04.2022 16:22

Rebuilding blender now..

Admin
Andreas Baumann commented on 07.04.2022 18:44

In principle it build, but now I have huge dependency issues around openimageio,
boost and friends to solve..

Admin
Andreas Baumann commented on 08.04.2022 06:32

In stable we get now the same problem as with many other software:

  libpython3.10.so.1.0 => None

I see no other uption but to
a) stick forever to python 3.9
b) push python 3.10 from testing to stable and clean up everything which is not

 working afterwards.
Admin
Andreas Baumann commented on 08.04.2022 15:32

Now with the python issue out of the way I'm left with this:

blender: symbol lookup error: blender: undefined symbol: _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_replaceEjjPKcj, version LLVM_13

which is:

std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_M_replace(unsigned int, unsigned int, char const*, unsigned int)

could just be we have to push llvm too, but not before having a shim..

Admin
Andreas Baumann commented on 09.04.2022 08:11

Disappeared and after a yaml-cpp push to stable, things work now (at least on pentium4)

Admin
Andreas Baumann commented on 09.04.2022 08:18

Running on real hardware, pentium4 looks fine, i686 not:

Thread 1 "blender" received signal SIGILL, Illegal instruction.
0xb7323952 in ?? () from /usr/lib/libembree3.so.3
=> 0xb7323952:  66 0f d6 44 24 08       movq   %xmm0,0x8(%esp)

This is some SSE optimization in embree.

Admin
Andreas Baumann commented on 10.04.2022 08:29

I don't see how I can build embree on i686..

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing