Page MenuHomeFreeBSD

devel/libclc: Update to 11.1.0
Needs ReviewPublic

Authored by manu on Jul 23 2021, 6:42 PM.

Details

Reviewers
jbeich
Group Reviewers
x11
Summary
  • Use llvm releases of libclc
  • Force llvm12 as it is what's used for mesa/clover

Moving to libclc from llvm12 needs llvm-spirv so for now just update
to latest llvm11 sources.

Test Plan

Not tested

Diff Detail

Lint
Lint Skipped
Unit
Unit Tests Skipped

Event Timeline

manu requested review of this revision.Jul 23 2021, 6:42 PM
manu created this revision.

Moving to libclc from llvm12 needs llvm-spirv ...

llvm-spirv dependency can be dropped:

post-patch:
# Exclude targets depending on llvm-spirv
	@${REINPLACE_CMD} -e '/^[[:space:]]*spirv.*mesa/d' \
		${WRKSRC}/CMakeLists.txt

or after 9b3e3e4b33ca fixed with:

BUILD_DEPENDS+=	llvm-spirv:devel/spirv-llvm-translator
# Can be a relative path e.g., -DLLVM_SPIRV:FILEPATH=llvm-spirv
CMAKE_ARGS+=	-DLLVM_SPIRV:FILEPATH="${LOCALBASE}/bin/llvm-spirv"

Caveat: spirv-llvm-translator currently uses llvm11 because intel-graphics-compiler upstream keeps reverting llvm12 support.

I don't use this port, so not interested in thoroughly reviewing.

devel/libclc/Makefile
24

Either qualify type by adding :FILEPATH then quote the path or use relative path e.g., -DLLVM_CONFIG=llvm-config12. Such style appears to be preferred by devel/cmake maintainer.

After c638dc3a4dc4 libclc >= 12.* will automatically find llvm-spirv without adjusting CMAKE_ARGS if the dependency is installed for the desired LLVM version.