RenderKit / ospray

An Open, Scalable, Portable, Ray Tracing Based Rendering Engine for High-Fidelity Visualization
http://ospray.org
Apache License 2.0
1.02k stars 186 forks source link

ISPC v1.11.0 compile issues #322

Closed sriravic closed 5 years ago

sriravic commented 5 years ago

When trying to compile the latest pulled code on a Ubuntu 18.04 system with clang-8 and the latest ispc1.11, build fails with the following error.

/usr/bin/ld: local__common/OSPCommon.dev_sse4.o: relocation R_X86_64_PC32 against symbol `stdout@@GLIBC_2.2.5' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value

I checked the ispc flags and they are indeed built with --pic flags. I'm not sure what else is going wrong here.

jeffamstutz commented 5 years ago

Yes, this is a known new issue with the latest ISPC (v1.11.0) and OSPRay. I've done some initial explorations and haven't been able to get it working locally.

The current workaround is to use ISPC v1.10.0 until we can figure out these PIC related problems.

sriravic commented 5 years ago

Thank you. That fixed the problem. Should I close this issue or keep it open for tracking purposes?

jeffamstutz commented 5 years ago

Let’s leave this open until the ISPC issues are ironed out, so this gets tracked in a public place.

Thanks for reporting this, though!

dbabokin commented 5 years ago

CCing @aneshlya

johguenther commented 5 years ago

Just out of curiosity: did you manually enforce usage of ispc v1.11? Because we have

set(ISPC_VERSION_WORKING "1.10.0" "1.9.2" "1.9.1")

in ospcommon/cmake/ispc.cmake, thus that version should not have been picked up automatically by CMake configure.

sriravic commented 5 years ago

I didn't enforce it directly but rather my setup just had version 1.11 in the path to search for the ispc executable. I'm not sure why CMake didn't report this.

dbabokin commented 5 years ago

This is ISPC problem. We have a fix for it.

dbabokin commented 5 years ago

The issue is fixed in ISPC master. It will be available in the next ISPC release.

jeffamstutz commented 5 years ago

Fantastic, thanks @dbabokin!

jeffamstutz commented 5 years ago

We now detect if an incompatible ISPC is being used during CMake build configuration in v2.0.0-alpha.

dbabokin commented 5 years ago

I see that you have list of compatible versions here: https://github.com/ospray/ospray/blob/master/components/ospcommon/cmake/ispc.cmake#L18

What about adding 1.12.0 to it?