RTTI support in devel/llvm40 (and maybe other llvm ports)

Shane Ambler FreeBSD at ShaneWare.Biz
Sun Nov 12 03:36:53 UTC 2017


On 10/11/2017 17:37, Alexey Dokuchaev wrote:
> Hi Brooks,
> 
> I've just found out that our `devel/llvm40' port comes without
> -DLLVM_ENABLE_RTTI=ON on the CMAKE_ARGS.  This is a regression
> from e.g. 3.4 times when it was enabled by default.
> 
> The problem is that RTTI support is required by some consumers,
> e.g. `graphics/openshadinglanguage' and `graphics/appleseed'
> (cf. https://github.com/appleseedhq/appleseed/issues/1625),
> but I cannot enable RTTI in those ports unless I enable it in
> LLVM port(s) first.
> 

It is probably more a case of llvm sets rtti off by default even though
the llvm ports < v3.8 have enabled it.

Previous versions of osl had rtti enabled to match the llvm setting.
I disabled rtti in osl when switching to llvm40 only to get it to work.
No changes to graphics/blender were needed.

While I know appleseed fails when rtti is disabled directly in CXXFLAGS,
maybe cmake can detect the use of rtti in llvm (or offer an option) and
adjust to suit, or just add -fno-rtti only for the osl files.

-- 
FreeBSD - the place to B...Software Developing

Shane Ambler



More information about the freebsd-ports mailing list