Skip to content

add clang to tools if necessary

Sven M. Hallberg requested to merge pesco/hammer:scons-clang into master

clang appears to require -fPIC for shared objects on most platforms. the 'clang' tool adds the flag when appropriate. however, scons never selects the clang tool automatically!

so add the tool ourselves if CC=clang is set or generally on Darwin. also tries to detect if cc itself happens to be clang (this fixes the build on OpenBSD).

can anyone test on Darwin? and Windows?

Edited by Sven M. Hallberg

Merge request reports