0
$\begingroup$

I have been following the instructions here from Hugo Desrosiers.

(Instructions pasted below)

• Install Nvidia CUDA toolkit 10.2 as per Bruno Wego's method.

  wget 'https://developer.download.nvidia.com/compute/cuda/10.2/Prod/local_installers/cuda_10.2.89_mac.dmg' && \
  hdiutil attach cuda_10.2.89_mac.dmg \
      -nobrowse \
      -mountpoint \
      /Volumes/CUDAMacOSXInstaller

  open /Volumes/CUDAMacOSXInstaller/CUDAMacOSXInstaller.app

  hdiutil detach /Volumes/CUDAMacOSXInstaller && rm ./cuda_10.2.89_mac.dmg
  

Prepare for a build on mac os x as per Blender instructions, quick setup. Do the

make update
make

to test the ability to build the CPU version first (and fix whatever is missing until the build works). Fix file blender/intern/cycles/device/cuda/device_cuda_impl.cpp, in function CUDADevice::compile_kernel_get_common_cflags. Add the string "-std=c++14 " as first argument of the string_printf (don't omit the trailing space!). It should look like this:

     string cflags = string_printf(
            "-std=c++14 "
            "-m%d "
            "--ptxas-options=\"-v\" "
            "--use_fast_math "
            "-DNVCC "
            "-I\"%s\"",
            machine,
            include_path.c_str());
  

Modify the file lib/darwin/nanovdb/include/nanovdb/NanoVDB.h (that's obtained during the make update), fixing all the static_assert calls for which the 1st param is a C++ templatised value that have an extra comma by simply putting the expression in parenthesis, so the non-C++14 compiler don't get confused. This is the diff I got after the fix:

      887c887
      <     static_assert(is_same<int, typename CoordT::ValueType>::value, "Expected \"int\" coordinate type");
      ---
      >     static_assert((is_same<int, typename CoordT::ValueType>::value), "Expected \"int\" coordinate type");
      1515,1516c1515,1516
      <     static_assert(is_same<NodeType<0>, LeafNodeType>::value, "NodeType<0> error");
      <     static_assert(is_same<NodeType<3>, RootType>::value, "NodeType<3> error");
      ---
      >     static_assert((is_same<NodeType<0>, LeafNodeType>::value), "NodeType<0> error");
      >     static_assert((is_same<NodeType<3>, RootType>::value), "NodeType<3> error");
      1594c1594
      <     static_assert(is_same<NodeType<NodeT::LEVEL>, NodeT>::value, "Tree::getNode: unvalid node type");
      ---
      >     static_assert((is_same<NodeType<NodeT::LEVEL>, NodeT>::value), "Tree::getNode: unvalid node type");
      1611c1611
      <     static_assert(is_same<NodeType<NodeT::LEVEL>, NodeT>::value, "Tree::getNode: unvalid node type");
      ---
      >     static_assert((is_same<NodeType<NodeT::LEVEL>, NodeT>::value), "Tree::getNode: unvalid node type");
      2425c2425
      <         static_assert(is_same<T, NodeT>::value, "ReadAccessor::getNode: Invalid node type");
      ---
      >         static_assert((is_same<T, NodeT>::value), "ReadAccessor::getNode: Invalid node type");
  

Build blender with GPU support for cycles (replace sm_61 by the CUDA Compute level your card supports):

  make WITH_CYCLES_CUDA_BINARIES=ON DCYCLES_CUDA_BINARIES_ARCH=sm_61

(Instructions end)

I have got Blender to compile as far as 95%. Looking back in the terminal it seems that there is one fatal error:

blender-git/blender/extern/audaspace/plugins/jack/JackDevice.h:36:10: fatal error: 'jack/jack.h' file not found



  
$\endgroup$
4
  • $\begingroup$ The error you are getting implies that blender is trying to use Jack, an audio package, and that the part of Jack needed to compile with it is not installed on your computer. You need to check your package manager and see if there are jack components you are missing. $\endgroup$ Jul 28, 2021 at 17:32
  • $\begingroup$ I have jack on my computer, and I have uninstalled and re-installed it, it makes no difference. $\endgroup$
    – jkagli
    Jul 30, 2021 at 7:09
  • $\begingroup$ I re-installed Jack and restarted, deleted my blender-git folder and started all over again. I now get to 61% and have the message: "make[1]: *** [all] Error 2 make: *** [all] Error 2" $\endgroup$
    – jkagli
    Jul 30, 2021 at 7:45
  • $\begingroup$ it seems this is documented as a bug developer.blender.org/T79261. But copying the files over from the Library to a /jack subfolder (as suggested) does not seem to fix it. $\endgroup$
    – jkagli
    Jul 30, 2021 at 10:22

2 Answers 2

1
$\begingroup$

The build is looking for the folders in a subfolder called jack so I managed to fix this by copying the contents of

~Library/Frameworks/Jackmp.framework/Versions/A/Headers

into a sub folder within itself called /jack (I kept the originals in place).

I then copied this /jack folder into

~Library/Frameworks/Jackmp.framework/Headers and ~blender-git/blender/jack/

so that in the folder called jack there is a subfolder called jack.

$\endgroup$
0
$\begingroup$

Also hit this problem while compiling Blender for MacOs... Now its "/headers/jack" folder thats need to be created // So steps are:

  1. Download "universal install" for Jack and run it, it will create /Library/Frameworks/Jackmp.framework/
  2. sudo mkdir /Library/Frameworks/Jackmp.framework/headers/jack
  3. sudo cp -R /Library/Frameworks/Jackmp.framework/Versions/A/Headers/ /Library/Frameworks/Jackmp.framework/headers/jack
$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .