diff options
author | Tom Stellard <thomas.stellard@amd.com> | 2012-10-02 20:58:46 +0000 |
---|---|---|
committer | Tom Stellard <thomas.stellard@amd.com> | 2012-10-16 17:14:59 +0000 |
commit | 327f78fd8474eb5e0bd13aaba6c9c4dcc9cd1f1d (patch) | |
tree | 4ba6d106a0bac15ed328e42d2ec1bc98a7d4ee65 /configure.py | |
parent | c6fad48798dac1544a90e415dacffda4bd4eca8f (diff) |
configure: Allow targets to override generic cl implementations with LLVM IR
Diffstat (limited to 'configure.py')
-rwxr-xr-x | configure.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/configure.py b/configure.py index 83a9375..2084178 100755 --- a/configure.py +++ b/configure.py @@ -112,8 +112,12 @@ for target in targets: manifest_deps.add(subdir_list_file) for src in open(subdir_list_file).readlines(): src = src.rstrip() - if src not in sources_seen: - sources_seen.add(src) + # Only add the base filename (e.g. Add get_global_id instead of + # get_global_id.cl) to sources_seen. + # This allows targets to overide generic .cl sources with .ll sources. + src_base = os.path.splitext(src)[0] + if src_base not in sources_seen: + sources_seen.add(src_base) obj = os.path.join(target, 'lib', src + '.bc') objects.append(obj) src_file = os.path.join(libdir, src) |