Bug 228531 - graphics/blender: fails to link with CYCLES
Summary: graphics/blender: fails to link with CYCLES
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Steve Wills
URL:
Keywords:
Depends on:
Blocks: 214864
  Show dependency treegraph
 
Reported: 2018-05-27 04:48 UTC by Charlie Li
Modified: 2018-06-15 18:59 UTC (History)
2 users (show)

See Also:
bugzilla: maintainer-feedback? (FreeBSD)


Attachments
build fix workaround for graphics/blender (553 bytes, patch)
2018-05-29 05:45 UTC, Shane
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Charlie Li freebsd_committer freebsd_triage 2018-05-27 04:48:57 UTC
When lld is the system linker via WITH_LLD_IS_LD, and with the port's CYCLES option enabled, the very end of the build fails with linker errors:

[3096/3099] /usr/local/libexec/ccache/c++  -DBOOST_ALL_NO_LIB -DCCL_NAMESPACE_BEGIN="namespace ccl {" -DCCL_NAMESPACE_END=} -DCYCLES_GFLAGS_NAMESPACE=gflags -DCYCLES_STD_UNORDERED_MAP -DGOOGLE_GLOG_DLL_DECL="" -DNDEBUG -DOSL_STATIC_LIBRARY -DWITH_BLENDER_GUARDEDALLOC -DWITH_CYCLES_LOGGING -DWITH_GLU -DWITH_GL_PROFILE_COMPAT -DWITH_KERNEL_AVX -DWITH_KERNEL_AVX2 -DWITH_KERNEL_SSE2 -DWITH_KERNEL_SSE3 -DWITH_KERNEL_SSE41 -DWITH_OSL -DWITH_SYSTEM_PUGIXML -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D__LITTLE_ENDIAN__ -D__MMX__ -D__SSE2__ -D__SSE__ -isystem /usr/local/include -isystem /wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/extern/glog/src -isystem /wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/extern/gflags/src -isystem /usr/local/include/OpenImageIO -isystem /usr/local/include/OpenEXR -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/intern/cycles/../atomic -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/intern/cycles -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/intern/glew-mx -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/intern/guardedalloc -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/intern/mikktspace -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/source/blender/makesdna -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/source/blender/makesrna -I/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/source/blender/blenlib -Isource/blender/makesrna/intern -isystem /usr/local/include/python3.6m -Wall -Wno-tautological-compare -Wno-unknown-pragmas -Wno-char-subscripts -Wno-overloaded-virtual -Wno-sign-compare -Wno-invalid-offsetof -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing -std=c++11   -msse -pipe -fPIC -funsigned-char -fno-strict-aliasing -msse2 -ffast-math -fno-finite-math-only -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing -MD -MT intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_texture.cpp.o -MF intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_texture.cpp.o.d -o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_texture.cpp.o -c /wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/intern/cycles/blender/blender_texture.cpp
[3097/3099] : && /usr/local/bin/cmake -E remove lib/libbf_intern_cycles.a && /usr/bin/ar qc lib/libbf_intern_cycles.a  intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_camera.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_mesh.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_object.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_object_cull.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_particles.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_curves.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_logging.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_python.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_session.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_shader.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_sync.cpp.o intern/cycles/blender/CMakeFiles/bf_intern_cycles.dir/blender_texture.cpp.o && /usr/bin/ranlib lib/libbf_intern_cycles.a && :
[3098/3099] : && /usr/local/libexec/ccache/c++  -Wall -Wno-tautological-compare -Wno-unknown-pragmas -Wno-char-subscripts -Wno-overloaded-virtual -Wno-sign-compare -Wno-invalid-offsetof -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing -std=c++11   -msse -pipe -fPIC -funsigned-char -fno-strict-aliasing -msse2 -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing  -fstack-protector  -Wl,--version-script='/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/source/creator/blender.map' source/blenderplayer/CMakeFiles/blenderplayer.dir/bad_level_call_stubs/stubs.c.o  -o bin/blenderplayer -L/usr/local/lib  -L/usr/local/llvm60/lib -Wl,-rpath,/usr/local/lib:/usr/local/llvm60/lib:/usr/local/lib/opencollada: lib/libge_player_ghost.a lib/libge_player_common.a lib/libbf_intern_string.a lib/libbf_intern_ghost.a lib/libbf_rna.a lib/libbf_blenkernel.a lib/libbf_depsgraph.a lib/libbf_physics.a lib/libbf_intern_rigidbody.a lib/libbf_blenloader.a lib/libge_blen_routines.a lib/libbf_editor_datafiles.a lib/libge_converter.a lib/libge_logic_ketsji.a lib/libge_phys_bullet.a lib/libge_phys_dummy.a lib/libge_logic.a lib/libge_rasterizer.a lib/libge_oglrasterizer.a lib/libge_logic_expressions.a lib/libge_scenegraph.a lib/libbf_ikplugin.a lib/libbf_intern_itasc.a lib/libbf_intern_iksolver.a lib/libbf_intern_smoke.a lib/libbf_modifiers.a lib/libbf_intern_moto.a lib/libbf_nodes.a lib/libbf_gpu.a lib/libbf_imbuf.a lib/libbf_avi.a lib/libge_logic_network.a lib/libge_logic_ngnetwork.a lib/libge_logic_loopbacknetwork.a lib/libextern_bullet.a lib/libbf_intern_guardedalloc.a lib/libbf_intern_memutil.a lib/libbf_python_ext.a lib/libbf_python_mathutils.a lib/libbf_python_bmesh.a lib/libbf_imbuf_cineon.a lib/libbf_imbuf_openexr.a lib/libbf_imbuf_openimageio.a lib/libbf_imbuf_dds.a lib/libbf_dna.a lib/libge_videotex.a lib/libbf_blenfont.a lib/libbf_blentranslation.a lib/libbf_intern_audaspace.a lib/libblenkernel_blc.a lib/libbf_bmesh.a lib/libbf_blenlib.a lib/libextern_minilzo.a lib/libbf_intern_ghost.a lib/libbf_blenkernel.a lib/libbf_intern_mikktspace.a lib/libextern_recastnavigation.a lib/libbf_intern_opencolorio.a lib/libbf_intern_glew_mx.a lib/libbf_intern_eigen.a lib/libextern_rangetree.a lib/libextern_wcwidth.a lib/libbf_intern_libmv.a lib/libextern_glog.a lib/libextern_gflags.a lib/libextern_lzma.a lib/libextern_ceres.a lib/libextern_carve.a lib/libextern_xdnd.a lib/libbf_intern_locale.a lib/libbf_intern_decklink.a lib/libbf_intern_opensubdiv.a lib/libbf_alembic.a /usr/local/lib/libpng.so -lz /usr/local/lib/libfreetype.so -Xlinker -export-dynamic /usr/local/lib/libpython3.6m.so /usr/local/lib/libGLEW.so /usr/local/lib/libfftw3.so /usr/local/lib/libsndfile.so /usr/local/lib/libSDL2.so /usr/local/lib/libtiff.so /usr/local/lib/libOpenImageIO.so /usr/local/lib/libpng.so -lz /usr/local/lib/libjpeg.so -lz /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libtiff.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libosdGPU.so /usr/local/lib/libosdCPU.so /usr/local/lib/liboslcomp.so /usr/local/lib/liboslexec.so /usr/local/lib/liboslquery.so /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libjpeg.so /usr/local/lib/libAlembic.so /usr/local/lib/libhdf5.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libopenjpeg.so -lavformat -lavcodec -lavutil -lavdevice -lswscale /usr/local/lib/opencollada/libOpenCOLLADAStreamWriter.so /usr/local/lib/opencollada/libOpenCOLLADASaxFrameworkLoader.so /usr/local/lib/opencollada/libOpenCOLLADAFramework.so /usr/local/lib/opencollada/libOpenCOLLADABaseUtils.so /usr/local/lib/opencollada/libGeneratedSaxParser.so /usr/local/lib/opencollada/libMathMLSolver.so /usr/local/lib/opencollada/libbuffer.so /usr/local/lib/opencollada/libftoa.so /usr/local/lib/opencollada/libUTF.so /usr/local/lib/libpcre.so /usr/local/lib/libxml2.so /usr/local/llvm60/lib/libLLVM-6.0.0.so lib/libextern_clew.a lib/libextern_cuew.a -lz /usr/local/lib/libGLU.so /usr/local/lib/libGL.so /usr/local/lib/libX11.so /usr/local/lib/libXi.so /usr/local/lib/libXxf86vm.so /usr/local/lib/libXfixes.so /usr/local/lib/libXrender.so -lutil -lc -lm -pthread lib/libextern_clew.a lib/libextern_cuew.a /usr/local/lib/libpng.so /usr/local/lib/libfreetype.so /usr/local/lib/libpython3.6m.so /usr/local/lib/libGLEW.so /usr/local/lib/libfftw3.so /usr/local/lib/libsndfile.so /usr/local/lib/libSDL2.so /usr/local/lib/libtiff.so /usr/local/lib/libOpenImageIO.so /usr/local/lib/libjpeg.so /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libosdGPU.so /usr/local/lib/libosdCPU.so /usr/local/lib/liboslcomp.so /usr/local/lib/liboslexec.so /usr/local/lib/liboslquery.so /usr/local/lib/libAlembic.so /usr/local/lib/libhdf5.so /usr/local/lib/libopenjpeg.so -lavformat -lavcodec -lavutil -lavdevice -lswscale /usr/local/lib/opencollada/libOpenCOLLADAStreamWriter.so /usr/local/lib/opencollada/libOpenCOLLADASaxFrameworkLoader.so /usr/local/lib/opencollada/libOpenCOLLADAFramework.so /usr/local/lib/opencollada/libOpenCOLLADABaseUtils.so /usr/local/lib/opencollada/libGeneratedSaxParser.so /usr/local/lib/opencollada/libMathMLSolver.so /usr/local/lib/opencollada/libbuffer.so /usr/local/lib/opencollada/libftoa.so /usr/local/lib/opencollada/libUTF.so /usr/local/lib/libpcre.so /usr/local/lib/libxml2.so /usr/local/llvm60/lib/libLLVM-6.0.0.so /usr/local/lib/libGLU.so /usr/local/lib/libGL.so /usr/local/lib/libX11.so /usr/local/lib/libXi.so /usr/local/lib/libXxf86vm.so /usr/local/lib/libXfixes.so /usr/local/lib/libXrender.so -lutil -lc -lm && :
[3099/3099] : && /usr/local/libexec/ccache/c++  -Wall -Wno-tautological-compare -Wno-unknown-pragmas -Wno-char-subscripts -Wno-overloaded-virtual -Wno-sign-compare -Wno-invalid-offsetof -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing -std=c++11   -msse -pipe -fPIC -funsigned-char -fno-strict-aliasing -msse2 -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing  -fstack-protector  -Wl,--version-script='/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/source/creator/blender.map' source/creator/CMakeFiles/blender.dir/creator.c.o source/creator/CMakeFiles/blender.dir/creator_args.c.o source/creator/CMakeFiles/blender.dir/creator_signals.c.o  -o bin/blender -L/usr/local/lib  -L/usr/local/llvm60/lib -Wl,-rpath,/usr/local/lib:/usr/local/llvm60/lib:/usr/local/lib/opencollada: lib/libbf_windowmanager.a lib/libbf_editor_space_api.a lib/libbf_editor_space_action.a lib/libbf_editor_space_buttons.a lib/libbf_editor_space_console.a lib/libbf_editor_space_file.a lib/libbf_editor_space_graph.a lib/libbf_editor_space_image.a lib/libbf_editor_space_info.a lib/libbf_editor_space_logic.a lib/libbf_editor_space_nla.a lib/libbf_editor_space_node.a lib/libbf_editor_space_outliner.a lib/libbf_editor_space_script.a lib/libbf_editor_space_sequencer.a lib/libbf_editor_space_text.a lib/libbf_editor_space_time.a lib/libbf_editor_space_userpref.a lib/libbf_editor_space_view3d.a lib/libbf_editor_space_clip.a lib/libbf_editor_transform.a lib/libbf_editor_util.a lib/libbf_editor_uvedit.a lib/libbf_editor_curve.a lib/libbf_editor_gpencil.a lib/libbf_editor_interface.a lib/libbf_editor_mesh.a lib/libbf_editor_metaball.a lib/libbf_editor_object.a lib/libbf_editor_armature.a lib/libbf_editor_physics.a lib/libbf_editor_render.a lib/libbf_editor_screen.a lib/libbf_editor_sculpt_paint.a lib/libbf_editor_sound.a lib/libbf_editor_animation.a lib/libbf_editor_datafiles.a lib/libbf_editor_mask.a lib/libbf_editor_io.a lib/libbf_render.a lib/libbf_python.a lib/libbf_python_ext.a lib/libbf_python_mathutils.a lib/libbf_python_bmesh.a lib/libbf_freestyle.a lib/libbf_ikplugin.a lib/libbf_modifiers.a lib/libbf_alembic.a lib/libbf_bmesh.a lib/libbf_gpu.a lib/libbf_blenloader.a lib/libbf_compositor.a lib/libbf_blenkernel.a lib/libbf_intern_rigidbody.a lib/libbf_physics.a lib/libbf_nodes.a lib/libbf_rna.a lib/libbf_imbuf.a lib/libbf_blenlib.a lib/libbf_depsgraph.a lib/libbf_intern_ghost.a lib/libbf_intern_string.a lib/libbf_avi.a lib/libbf_imbuf_cineon.a lib/libbf_imbuf_openexr.a lib/libbf_imbuf_openimageio.a lib/libbf_imbuf_dds.a lib/libbf_collada.a lib/libbf_intern_elbeem.a lib/libbf_intern_iksolver.a lib/libbf_intern_memutil.a lib/libbf_intern_guardedalloc.a lib/libge_blen_routines.a lib/libge_converter.a lib/libge_phys_dummy.a lib/libge_phys_bullet.a lib/libbf_intern_smoke.a lib/libextern_lzma.a lib/libextern_curve_fit_nd.a lib/libge_logic_ketsji.a lib/libextern_recastnavigation.a lib/libge_logic.a lib/libge_rasterizer.a lib/libge_oglrasterizer.a lib/libge_logic_expressions.a lib/libge_scenegraph.a lib/libge_logic_network.a lib/libge_logic_ngnetwork.a lib/libextern_bullet.a lib/libge_logic_loopbacknetwork.a lib/libbf_intern_moto.a lib/libge_videotex.a lib/libbf_dna.a lib/libbf_blenfont.a lib/libbf_blentranslation.a lib/libbf_intern_audaspace.a lib/libbf_intern_mikktspace.a lib/libbf_intern_dualcon.a lib/libbf_intern_cycles.a lib/libcycles_render.a lib/libcycles_graph.a lib/libcycles_bvh.a lib/libcycles_device.a lib/libcycles_kernel.a lib/libcycles_kernel_osl.a lib/libcycles_util.a lib/libcycles_subd.a lib/libbf_intern_opencolorio.a lib/libbf_intern_eigen.a lib/libextern_rangetree.a lib/libextern_wcwidth.a lib/libbf_intern_libmv.a lib/libbf_intern_glew_mx.a lib/libextern_glog.a lib/libextern_gflags.a lib/libextern_ceres.a lib/libextern_minilzo.a lib/libbf_intern_itasc.a lib/libextern_carve.a lib/libextern_xdnd.a lib/libbf_intern_locale.a lib/libbf_intern_decklink.a lib/libbf_intern_opensubdiv.a /usr/local/lib/libpng.so -lz /usr/local/lib/libfreetype.so -Xlinker -export-dynamic /usr/local/lib/libpython3.6m.so /usr/local/lib/libGLEW.so /usr/local/lib/libfftw3.so /usr/local/lib/libsndfile.so /usr/local/lib/libSDL2.so /usr/local/lib/libtiff.so /usr/local/lib/libOpenImageIO.so /usr/local/lib/libpng.so -lz /usr/local/lib/libjpeg.so -lz /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libtiff.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libosdGPU.so /usr/local/lib/libosdCPU.so /usr/local/lib/liboslcomp.so /usr/local/lib/liboslexec.so /usr/local/lib/liboslquery.so /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libjpeg.so /usr/local/lib/libAlembic.so /usr/local/lib/libhdf5.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libopenjpeg.so -lavformat -lavcodec -lavutil -lavdevice -lswscale /usr/local/lib/opencollada/libOpenCOLLADAStreamWriter.so /usr/local/lib/opencollada/libOpenCOLLADASaxFrameworkLoader.so /usr/local/lib/opencollada/libOpenCOLLADAFramework.so /usr/local/lib/opencollada/libOpenCOLLADABaseUtils.so /usr/local/lib/opencollada/libGeneratedSaxParser.so /usr/local/lib/opencollada/libMathMLSolver.so /usr/local/lib/opencollada/libbuffer.so /usr/local/lib/opencollada/libftoa.so /usr/local/lib/opencollada/libUTF.so /usr/local/lib/libpcre.so /usr/local/lib/libxml2.so /usr/local/llvm60/lib/libLLVM-6.0.0.so lib/libextern_clew.a lib/libextern_cuew.a -lz /usr/local/lib/libGLU.so /usr/local/lib/libGL.so /usr/local/lib/libX11.so /usr/local/lib/libXi.so /usr/local/lib/libXxf86vm.so /usr/local/lib/libXfixes.so /usr/local/lib/libXrender.so -lutil -lc -lm -pthread /usr/local/lib/libpng.so /usr/local/lib/libfreetype.so /usr/local/lib/libpython3.6m.so /usr/local/lib/libGLEW.so /usr/local/lib/libfftw3.so /usr/local/lib/libsndfile.so /usr/local/lib/libSDL2.so /usr/local/lib/libtiff.so /usr/local/lib/libOpenImageIO.so /usr/local/lib/libjpeg.so /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libosdGPU.so /usr/local/lib/libosdCPU.so /usr/local/lib/liboslcomp.so /usr/local/lib/liboslexec.so /usr/local/lib/liboslquery.so /usr/local/lib/libAlembic.so /usr/local/lib/libhdf5.so /usr/local/lib/libopenjpeg.so -lavformat -lavcodec -lavutil -lavdevice -lswscale /usr/local/lib/opencollada/libOpenCOLLADAStreamWriter.so /usr/local/lib/opencollada/libOpenCOLLADASaxFrameworkLoader.so /usr/local/lib/opencollada/libOpenCOLLADAFramework.so /usr/local/lib/opencollada/libOpenCOLLADABaseUtils.so /usr/local/lib/opencollada/libGeneratedSaxParser.so /usr/local/lib/opencollada/libMathMLSolver.so /usr/local/lib/opencollada/libbuffer.so /usr/local/lib/opencollada/libftoa.so /usr/local/lib/opencollada/libUTF.so /usr/local/lib/libpcre.so /usr/local/lib/libxml2.so /usr/local/llvm60/lib/libLLVM-6.0.0.so /usr/local/lib/libGLU.so /usr/local/lib/libGL.so /usr/local/lib/libX11.so /usr/local/lib/libXi.so /usr/local/lib/libXxf86vm.so /usr/local/lib/libXfixes.so /usr/local/lib/libXrender.so -lutil -lc -lm && :
FAILED: bin/blender 
: && /usr/local/libexec/ccache/c++  -Wall -Wno-tautological-compare -Wno-unknown-pragmas -Wno-char-subscripts -Wno-overloaded-virtual -Wno-sign-compare -Wno-invalid-offsetof -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing -std=c++11   -msse -pipe -fPIC -funsigned-char -fno-strict-aliasing -msse2 -O2 -pipe -march=broadwell -fstack-protector -fno-strict-aliasing  -fstack-protector  -Wl,--version-script='/wrkdirs/usr/ports/graphics/blender/work/blender-2.79b/source/creator/blender.map' source/creator/CMakeFiles/blender.dir/creator.c.o source/creator/CMakeFiles/blender.dir/creator_args.c.o source/creator/CMakeFiles/blender.dir/creator_signals.c.o  -o bin/blender -L/usr/local/lib  -L/usr/local/llvm60/lib -Wl,-rpath,/usr/local/lib:/usr/local/llvm60/lib:/usr/local/lib/opencollada: lib/libbf_windowmanager.a lib/libbf_editor_space_api.a lib/libbf_editor_space_action.a lib/libbf_editor_space_buttons.a lib/libbf_editor_space_console.a lib/libbf_editor_space_file.a lib/libbf_editor_space_graph.a lib/libbf_editor_space_image.a lib/libbf_editor_space_info.a lib/libbf_editor_space_logic.a lib/libbf_editor_space_nla.a lib/libbf_editor_space_node.a lib/libbf_editor_space_outliner.a lib/libbf_editor_space_script.a lib/libbf_editor_space_sequencer.a lib/libbf_editor_space_text.a lib/libbf_editor_space_time.a lib/libbf_editor_space_userpref.a lib/libbf_editor_space_view3d.a lib/libbf_editor_space_clip.a lib/libbf_editor_transform.a lib/libbf_editor_util.a lib/libbf_editor_uvedit.a lib/libbf_editor_curve.a lib/libbf_editor_gpencil.a lib/libbf_editor_interface.a lib/libbf_editor_mesh.a lib/libbf_editor_metaball.a lib/libbf_editor_object.a lib/libbf_editor_armature.a lib/libbf_editor_physics.a lib/libbf_editor_render.a lib/libbf_editor_screen.a lib/libbf_editor_sculpt_paint.a lib/libbf_editor_sound.a lib/libbf_editor_animation.a lib/libbf_editor_datafiles.a lib/libbf_editor_mask.a lib/libbf_editor_io.a lib/libbf_render.a lib/libbf_python.a lib/libbf_python_ext.a lib/libbf_python_mathutils.a lib/libbf_python_bmesh.a lib/libbf_freestyle.a lib/libbf_ikplugin.a lib/libbf_modifiers.a lib/libbf_alembic.a lib/libbf_bmesh.a lib/libbf_gpu.a lib/libbf_blenloader.a lib/libbf_compositor.a lib/libbf_blenkernel.a lib/libbf_intern_rigidbody.a lib/libbf_physics.a lib/libbf_nodes.a lib/libbf_rna.a lib/libbf_imbuf.a lib/libbf_blenlib.a lib/libbf_depsgraph.a lib/libbf_intern_ghost.a lib/libbf_intern_string.a lib/libbf_avi.a lib/libbf_imbuf_cineon.a lib/libbf_imbuf_openexr.a lib/libbf_imbuf_openimageio.a lib/libbf_imbuf_dds.a lib/libbf_collada.a lib/libbf_intern_elbeem.a lib/libbf_intern_iksolver.a lib/libbf_intern_memutil.a lib/libbf_intern_guardedalloc.a lib/libge_blen_routines.a lib/libge_converter.a lib/libge_phys_dummy.a lib/libge_phys_bullet.a lib/libbf_intern_smoke.a lib/libextern_lzma.a lib/libextern_curve_fit_nd.a lib/libge_logic_ketsji.a lib/libextern_recastnavigation.a lib/libge_logic.a lib/libge_rasterizer.a lib/libge_oglrasterizer.a lib/libge_logic_expressions.a lib/libge_scenegraph.a lib/libge_logic_network.a lib/libge_logic_ngnetwork.a lib/libextern_bullet.a lib/libge_logic_loopbacknetwork.a lib/libbf_intern_moto.a lib/libge_videotex.a lib/libbf_dna.a lib/libbf_blenfont.a lib/libbf_blentranslation.a lib/libbf_intern_audaspace.a lib/libbf_intern_mikktspace.a lib/libbf_intern_dualcon.a lib/libbf_intern_cycles.a lib/libcycles_render.a lib/libcycles_graph.a lib/libcycles_bvh.a lib/libcycles_device.a lib/libcycles_kernel.a lib/libcycles_kernel_osl.a lib/libcycles_util.a lib/libcycles_subd.a lib/libbf_intern_opencolorio.a lib/libbf_intern_eigen.a lib/libextern_rangetree.a lib/libextern_wcwidth.a lib/libbf_intern_libmv.a lib/libbf_intern_glew_mx.a lib/libextern_glog.a lib/libextern_gflags.a lib/libextern_ceres.a lib/libextern_minilzo.a lib/libbf_intern_itasc.a lib/libextern_carve.a lib/libextern_xdnd.a lib/libbf_intern_locale.a lib/libbf_intern_decklink.a lib/libbf_intern_opensubdiv.a /usr/local/lib/libpng.so -lz /usr/local/lib/libfreetype.so -Xlinker -export-dynamic /usr/local/lib/libpython3.6m.so /usr/local/lib/libGLEW.so /usr/local/lib/libfftw3.so /usr/local/lib/libsndfile.so /usr/local/lib/libSDL2.so /usr/local/lib/libtiff.so /usr/local/lib/libOpenImageIO.so /usr/local/lib/libpng.so -lz /usr/local/lib/libjpeg.so -lz /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libtiff.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libosdGPU.so /usr/local/lib/libosdCPU.so /usr/local/lib/liboslcomp.so /usr/local/lib/liboslexec.so /usr/local/lib/liboslquery.so /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libjpeg.so /usr/local/lib/libAlembic.so /usr/local/lib/libhdf5.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libopenjpeg.so -lavformat -lavcodec -lavutil -lavdevice -lswscale /usr/local/lib/opencollada/libOpenCOLLADAStreamWriter.so /usr/local/lib/opencollada/libOpenCOLLADASaxFrameworkLoader.so /usr/local/lib/opencollada/libOpenCOLLADAFramework.so /usr/local/lib/opencollada/libOpenCOLLADABaseUtils.so /usr/local/lib/opencollada/libGeneratedSaxParser.so /usr/local/lib/opencollada/libMathMLSolver.so /usr/local/lib/opencollada/libbuffer.so /usr/local/lib/opencollada/libftoa.so /usr/local/lib/opencollada/libUTF.so /usr/local/lib/libpcre.so /usr/local/lib/libxml2.so /usr/local/llvm60/lib/libLLVM-6.0.0.so lib/libextern_clew.a lib/libextern_cuew.a -lz /usr/local/lib/libGLU.so /usr/local/lib/libGL.so /usr/local/lib/libX11.so /usr/local/lib/libXi.so /usr/local/lib/libXxf86vm.so /usr/local/lib/libXfixes.so /usr/local/lib/libXrender.so -lutil -lc -lm -pthread /usr/local/lib/libpng.so /usr/local/lib/libfreetype.so /usr/local/lib/libpython3.6m.so /usr/local/lib/libGLEW.so /usr/local/lib/libfftw3.so /usr/local/lib/libsndfile.so /usr/local/lib/libSDL2.so /usr/local/lib/libtiff.so /usr/local/lib/libOpenImageIO.so /usr/local/lib/libjpeg.so /usr/local/lib/libboost_filesystem.so /usr/local/lib/libboost_regex.so /usr/local/lib/libboost_thread.so /usr/local/lib/libboost_date_time.so /usr/local/lib/libboost_wave.so /usr/local/lib/libboost_locale.so /usr/local/lib/libboost_system.so /usr/local/lib/libboost_chrono.so /usr/local/lib/libboost_atomic.so /usr/local/lib/libboost_serialization.so /usr/local/lib/libHalf.so /usr/local/lib/libIex-2_2.so /usr/local/lib/libIlmImf.so /usr/local/lib/libIlmThread-2_2.so /usr/local/lib/libImath-2_2.so /usr/local/lib/libosdGPU.so /usr/local/lib/libosdCPU.so /usr/local/lib/liboslcomp.so /usr/local/lib/liboslexec.so /usr/local/lib/liboslquery.so /usr/local/lib/libAlembic.so /usr/local/lib/libhdf5.so /usr/local/lib/libopenjpeg.so -lavformat -lavcodec -lavutil -lavdevice -lswscale /usr/local/lib/opencollada/libOpenCOLLADAStreamWriter.so /usr/local/lib/opencollada/libOpenCOLLADASaxFrameworkLoader.so /usr/local/lib/opencollada/libOpenCOLLADAFramework.so /usr/local/lib/opencollada/libOpenCOLLADABaseUtils.so /usr/local/lib/opencollada/libGeneratedSaxParser.so /usr/local/lib/opencollada/libMathMLSolver.so /usr/local/lib/opencollada/libbuffer.so /usr/local/lib/opencollada/libftoa.so /usr/local/lib/opencollada/libUTF.so /usr/local/lib/libpcre.so /usr/local/lib/libxml2.so /usr/local/llvm60/lib/libLLVM-6.0.0.so /usr/local/lib/libGLU.so /usr/local/lib/libGL.so /usr/local/lib/libX11.so /usr/local/lib/libXi.so /usr/local/lib/libXxf86vm.so /usr/local/lib/libXfixes.so /usr/local/lib/libXrender.so -lutil -lc -lm && :
/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_init(char const*)) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_init(char const*)) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_init(char const*)) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_init(char const*)) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_start()) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_start()) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_start()) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_start()) in archive lib/libcycles_util.a

/usr/bin/ld: error: undefined symbol: gflags::SetCommandLineOption(char const*, char const*)
>>> referenced by util_logging.cpp
>>>               util_logging.cpp.o:(ccl::util_logging_verbosity_set(int)) in archive lib/libcycles_util.a
c++: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.

This probably needs referred upstream but I'm also reporting here as bug 214864 is still relevant.
Comment 1 Ed Maste freebsd_committer freebsd_triage 2018-05-29 00:04:48 UTC
Does it work if you set LLD_UNSAFE=yes in the port's Makefile?
Comment 2 Charlie Li freebsd_committer freebsd_triage 2018-05-29 02:45:35 UTC
(In reply to Ed Maste from comment #1)
bfd fails with the same error:

lib/libcycles_util.a(util_logging.cpp.o): In function `ccl::util_logging_init(char const*)':
util_logging.cpp:(.text+0x59): undefined reference to `gflags::SetCommandLineOption(char const*, char const*)'
util_logging.cpp:(.text+0x88): undefined reference to `gflags::SetCommandLineOption(char const*, char const*)'
util_logging.cpp:(.text+0xae): undefined reference to `gflags::SetCommandLineOption(char const*, char const*)'
util_logging.cpp:(.text+0xd1): undefined reference to `gflags::SetCommandLineOption(char const*, char const*)'
lib/libcycles_util.a(util_logging.cpp.o): In function `ccl::util_logging_start()':
util_logging.cpp:(.text+0x11b): undefined reference to `gflags::SetCommandLineOption(char const*, char const*)'
lib/libcycles_util.a(util_logging.cpp.o):util_logging.cpp:(.text+0x141): more undefined references to `gflags::SetCommandLineOption(char const*, char const*)' follow
c++: error: linker command failed with exit code 1 (use -v to see invocation)
ninja: build stopped: subcommand failed.
Comment 3 Shane 2018-05-29 05:45:32 UTC
Created attachment 193808 [details]
build fix workaround for graphics/blender

Adding LLD_UNSAFE=yes does not fix this. The quick workaround is to add WITH_CYCLES_LOGGING to CMAKE_OFF. When enabled this allows blender to be started with extra debugging output while rendering, unless gathering info for a bug report disabling this makes no difference to the user.

For a proper fix I'm not sure why this is happening. The conflict only happens if devel/gflags is installed when building blender, which includes its own copy of gflags source in extern/gflags.

devel/gflags is now being installed via graphics/opencv.

Both the port installed and blender included files have
SetCommandLineOption(const char* name, const char* value)

but lld is giving an error looking for 
gflags::SetCommandLineOption(char const*, char const*)

Both sources use "const char*" but lld is looking for "char const*" - but only when gflags is installed from ports.

Matching code to use SetCommandLineOption is also used in blenders intern/libmv which doesn't get this error - libmv logging is always enabled and builds if CYCLES_LOGGING is disabled per the patch.

The two blender sources using SetCommandLineOption are
intern/libmv/intern/logging.cc  -- this builds
intern/cycles/util/util_logging.cpp  -- this fails if gflags port is installed
Comment 4 Shane 2018-05-29 07:00:04 UTC
Just to clarify - this is NOT an LLD issue. On 11-stable using gnu ld the same error appears - when the gflags port is installed.
Comment 5 Ed Maste freebsd_committer freebsd_triage 2018-05-29 16:40:28 UTC
(In reply to Shane from comment #4)
Thanks for investigating/updating.
Comment 6 commit-hook freebsd_committer freebsd_triage 2018-06-15 18:58:59 UTC
A commit references this bug:

Author: swills
Date: Fri Jun 15 18:58:41 UTC 2018
New revision: 472484
URL: https://svnweb.freebsd.org/changeset/ports/472484

Log:
  graphics/blender: fails to link with CYCLES

  PR:		228531
  Submitted by:	Shane <FreeBSD@ShaneWare.Biz> (maintainer)
  Reported by:	Charlie Li <ml+freebsd@vishwin.info>

Changes:
  head/graphics/blender/Makefile
Comment 7 Steve Wills freebsd_committer freebsd_triage 2018-06-15 18:59:39 UTC
Committed, thanks!