Bug 218703 - graphics/blender doesn't build with CYCLES options
Summary: graphics/blender doesn't build with CYCLES options
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-17 14:09 UTC by Grzegorz Junka
Modified: 2018-03-13 20:58 UTC (History)
7 users (show)

See Also:


Attachments
Poudriere log for the failed build (24.18 KB, application/x-xz-compressed-tar)
2017-04-17 14:09 UTC, Grzegorz Junka
no flags Details
fix compile error (1.26 KB, patch)
2017-04-29 15:20 UTC, Christian Gusenbauer
no flags Details | Diff
fix package list (2.45 KB, patch)
2017-04-29 15:22 UTC, Christian Gusenbauer
no flags Details | Diff
svn-diff_cycles_blender (70.10 KB, patch)
2017-06-01 10:10 UTC, Walter Schwarzenfeld
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Grzegorz Junka 2017-04-17 14:09:30 UTC
Created attachment 181843 [details]
Poudriere log for the failed build

In blender set

OPTIONS_FILE_SET+=CYCLES
OPTIONS_FILE_SET+=CYCLESOSL

e.g. using:

  poudriere options -c -j 11rel0amd64 -p local -z blender1 graphics/blender

Any other options in any package leave set to the default value. Then try to build, e.g.:

  /usr/bin/nice -n 20 poudriere bulk -j 11rel0amd64 -p local -z blender1 graphics/blender

It will fail. See attached log.
Comment 1 Anonymized Account freebsd_committer freebsd_triage 2017-04-20 17:17:59 UTC
Confirmed.
Comment 2 Christian Gusenbauer 2017-04-29 15:20:03 UTC
Created attachment 182176 [details]
fix compile error

this patch fixes the compile-time error
Comment 3 Christian Gusenbauer 2017-04-29 15:22:01 UTC
Created attachment 182177 [details]
fix package list

fix the pkg-plist file which contains different include files
Comment 4 Christian Gusenbauer 2017-04-29 15:25:07 UTC
I've attached two patches; the first fixes the compile time error, the second one fixes the package list, which contains a different set of include files.

Using those two patches blender runs with cycles without any problems here (FreeBSD 10.3-STABLE, ports from 2017Q2).
Comment 5 Grzegorz Junka 2017-04-30 07:08:01 UTC
Thanks. Is this an action on me or I should wait until it's merged into SVN?
Comment 6 Walter Schwarzenfeld 2017-05-23 16:07:57 UTC
The two patches are working. Why it is not committed yet?
Comment 7 Erik Nordstrøm 2017-05-31 00:48:06 UTC
I had this problem too trying to build Blender 2.78c with Cycles enabled on FreeBSD 11.0.

Applying the patches allows the build to succeed.

According to https://www.freshports.org/graphics/blender/ there is no maintainer for this port currently.

I have sent an e-mail to ports@FreeBSD.org to notify them that this bug has patches that fixes the problem.
Comment 8 Kurt Jaeger freebsd_committer freebsd_triage 2017-05-31 20:27:50 UTC
testbuilds@work
Comment 9 Kurt Jaeger freebsd_committer freebsd_triage 2017-06-01 03:21:37 UTC
Two issues:

Error: /usr/local/bin/blender is linked to /usr/local/lib/libXrender.so.1 from x11/libXrender but it is not declared as a dependency
Warning: you need USE_XORG+=xrender

and: pkg-plist has issues ? See

http://people.freebsd.org/~pi/logs/graphics__blender-11a-1496262421.txt
Comment 10 Walter Schwarzenfeld 2017-06-01 10:10:14 UTC
Created attachment 183122 [details]
svn-diff_cycles_blender
Comment 11 Kurt Jaeger freebsd_committer freebsd_triage 2017-06-02 05:20:16 UTC
testbuilds@work
Comment 12 Kurt Jaeger freebsd_committer freebsd_triage 2017-06-02 05:29:54 UTC
Ignoring previously applied (or reversed) patch.
2 out of 2 hunks ignored--saving rejects to intern/cycles/bvh/bvh_build.cpp.rej
Ignoring previously applied (or reversed) patch.
2 out of 2 hunks ignored--saving rejects to intern/cycles/bvh/bvh_build.cpp.rej
=> FreeBSD patch patch-cycles failed to apply cleanly.
Comment 13 Walter Schwarzenfeld 2017-06-02 08:50:31 UTC
Why this? The patches applies fine on my system....
Comment 14 Kurt Jaeger freebsd_committer freebsd_triage 2017-06-11 12:37:00 UTC
I don't know why, sorry.
Comment 15 Christian Gusenbauer 2017-06-18 12:51:52 UTC
It looks like the svn-diff_cycles_blender patch already contains my two patches. So I'd suggest to apply only the svn-diff_cylces_blender patch and try to build again.
Comment 16 Walter Schwarzenfeld 2017-06-18 19:15:37 UTC
Yes, I only pack your patches in a svn-diff.
Comment 17 valery 2017-10-14 04:38:31 UTC
Blender 2.78c_9 compile fine with cycles + osl
- - - - - - - - - - - - - - - - - - - - - - - -
1. I patched with: 
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=182176&action=diff
https://bugs.freebsd.org/bugzilla/attachment.cgi?id=182177&action=diff

2. then I changed LLVM version in Makefile from 3.4 to 4.0 (openshadinglanguage use 4.0 now)

3. then make : Ok
4. Intensive use during 2 days : no troubles ; must be confirmed next weeks.

X. Info / Env.:
- FreeBSD 11.1-RELEASE-p1
-  pkg info -d blender
blender-2.78c_9:
        libXxf86vm-1.1.4_1
        libXi-1.7.9,1
        libXext-1.3.3_1,1
        libX11-1.6.5,1
        pango-1.40.6
        libXmu-1.1.2_3,1
        libxml2-2.9.4
        freetype2-2.8
        ffmpeg-3.3.4,1
        fftw3-3.3.6.p2_2
        python35-3.5.4
        tiff-4.0.8
        png-1.6.32
        opensubdiv-3.0.5_5
        openshadinglanguage-1.8.10_3
        openjpeg15-1.5.2_1
        openimageio-1.7.17_3
        opencollada-1.6.47
        mesa-libs-17.1.8
        libGLU-9.0.0_3
        jpeg-turbo-1.5.2
        ilmbase-2.2.0
        gtk-update-icon-cache-2.24.29
        glew-1.13.0_1
        gdk-pixbuf2-2.36.9
        OpenEXR-2.2.0_8
        sdl2-2.0.6
        pcre-8.40_1
        llvm40-4.0.1_1
        glib-2.50.2_6,1
        gettext-runtime-0.19.8.1_1
        desktop-file-utils-0.23
        boost-libs-1.65.1
        openal-soft-1.18.1
        libsndfile-1.0.28
        jackit-0.125.0_2
        freealut-1.1.0_4
        atk-2.24.0

_OPTIONS_READ=blender-2.78c_9
_FILE_COMPLETE_OPTIONS_LIST=AVI BULLET CAMERATRACK CINEON COLLADA COMPOSITOR CYCLES CYCLESOSL DDS FFMPEG FFTW3 FRAMESERVER FREESTYLE GAMEENGINE HDR HEADLESS INPUT_NDOF JACK LIBMV LZMA LZO MENU MOD_BOOLEAN MOD_FLUID MOD_OCEANSIM MOD_REMESH MOD_SMOKE NLS OPENAL OPENCOLORIO OPENEXR OPENIMAGEIO OPENJPEG OPENSUBDIV PLAYER RAYOPTIMIZATION REDCODE SDL SNDFILE TIFF XF86VMODE XINPUT
OPTIONS_FILE_SET+=AVI
OPTIONS_FILE_SET+=BULLET
OPTIONS_FILE_UNSET+=CAMERATRACK
OPTIONS_FILE_SET+=CINEON
OPTIONS_FILE_SET+=COLLADA
OPTIONS_FILE_SET+=COMPOSITOR
OPTIONS_FILE_SET+=CYCLES
OPTIONS_FILE_SET+=CYCLESOSL
OPTIONS_FILE_SET+=DDS
OPTIONS_FILE_SET+=FFMPEG
OPTIONS_FILE_SET+=FFTW3
OPTIONS_FILE_SET+=FRAMESERVER
OPTIONS_FILE_SET+=FREESTYLE
OPTIONS_FILE_SET+=GAMEENGINE
OPTIONS_FILE_SET+=HDR
OPTIONS_FILE_UNSET+=HEADLESS
OPTIONS_FILE_SET+=INPUT_NDOF
OPTIONS_FILE_SET+=JACK
OPTIONS_FILE_SET+=LIBMV
OPTIONS_FILE_SET+=LZMA
OPTIONS_FILE_SET+=LZO
OPTIONS_FILE_SET+=MENU
OPTIONS_FILE_SET+=MOD_BOOLEAN
OPTIONS_FILE_SET+=MOD_FLUID
OPTIONS_FILE_SET+=MOD_OCEANSIM
OPTIONS_FILE_SET+=MOD_REMESH
OPTIONS_FILE_SET+=MOD_SMOKE
OPTIONS_FILE_UNSET+=NLS
OPTIONS_FILE_SET+=OPENAL
OPTIONS_FILE_UNSET+=OPENCOLORIO
OPTIONS_FILE_SET+=OPENEXR
OPTIONS_FILE_SET+=OPENIMAGEIO
OPTIONS_FILE_SET+=OPENJPEG
OPTIONS_FILE_SET+=OPENSUBDIV
OPTIONS_FILE_SET+=PLAYER
OPTIONS_FILE_UNSET+=RAYOPTIMIZATION
OPTIONS_FILE_UNSET+=REDCODE
OPTIONS_FILE_SET+=SDL
OPTIONS_FILE_SET+=SNDFILE
OPTIONS_FILE_SET+=TIFF
OPTIONS_FILE_SET+=XF86VMODE
OPTIONS_FILE_SET+=XINPUT
Comment 18 Shane 2017-10-15 04:26:37 UTC
bug #222303 updates blender to 2.79 and should resolve this issue.

Note that the CYCLES option can be enabled without CYCLESOSL, if you don't specifically plan to use osl scripts then you don't need to enable the CYCLESOSL option.

The first patch here would still be needed with blender 2.78 to enable CYCLES without CYCLESOSL
Comment 19 Shane 2017-10-21 07:13:00 UTC
The blender port has now been updated to 2.79

This issue should be resolved, can you check if you still have any trouble building with CYCLES and CYCLESOSL.
Comment 20 Grzegorz Junka 2018-01-13 13:02:38 UTC
Sorry for late response. Please give me some time. I can't test it right now as I am upgrading my server. Will come back once I verified.
Comment 21 Grzegorz Junka 2018-03-13 20:53:00 UTC
I've verified that it compiles now. The defect can be closed. Many thanks for your support.