Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

Commit 9e43336

Browse files
authored
[SYCL] Add SYCL lib path to sycl_options after afaefb6 (#957)
This change fixes the following problem: `/usr/bin/ld: cannot find -lsycl`
1 parent edb565a commit 9e43336

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

SYCL/lit.cfg.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@
145145
config.substitutions.append( ('%opencl_include_dir', config.opencl_include_dir) )
146146

147147
if cl_options:
148-
config.substitutions.append( ('%sycl_options', ' sycl.lib /I' +
148+
config.substitutions.append( ('%sycl_options', ' ' + config.sycl_libs_dir + '/../lib/sycl.lib /I' +
149149
config.sycl_include + ' /I' + os.path.join(config.sycl_include, 'sycl')) )
150150
config.substitutions.append( ('%include_option', '/FI' ) )
151151
config.substitutions.append( ('%debug_option', '/DEBUG' ) )
@@ -154,7 +154,8 @@
154154
config.substitutions.append( ('%shared_lib', '/LD') )
155155
else:
156156
config.substitutions.append( ('%sycl_options', ' -lsycl -I' +
157-
config.sycl_include + ' -I' + os.path.join(config.sycl_include, 'sycl')) )
157+
config.sycl_include + ' -I' + os.path.join(config.sycl_include, 'sycl') +
158+
' -L' + config.sycl_libs_dir) )
158159
config.substitutions.append( ('%include_option', '-include' ) )
159160
config.substitutions.append( ('%debug_option', '-g' ) )
160161
config.substitutions.append( ('%cxx_std_option', '-std=' ) )

0 commit comments

Comments
 (0)