examples
examples copied to clipboard
how to include new_repository headers
how to include ONEAPI_HEADERS in BUILD file ?
my bazel source file as follow:
ref.bzl
ONEAPI_HEADERS = glob([ "include/**",])
ONEAPI_LIBRARY = glob([ "lib/*",])
cc_import(
name = "oneAPI",
hdrs = ONEAPI_HEADERS,
shared_library = "lib/libsycl.so",
visibility = ["//visibility:public"],)
BUILD.
cc_binary(
name = "starter",
srcs = [
"getting_started.cpp",
"example_utils.hpp"
],
deps = [
"@oneDNN//:oneDNN",
"@oneAPI//:oneAPI"
],
copts = [
"-I/home/wzy/sycl_workspace/oneDNN-cuda-debug/include",
"-I/home/wzy/sycl_workspace/build-cuda/include",
"-I/home/wzy/sycl_workspace/build-cuda/include/sycl", ],
linkstatic = 0)