diff --git a/bazel/BUILD b/bazel/BUILD index 664318348..c701790b0 100644 --- a/bazel/BUILD +++ b/bazel/BUILD @@ -150,3 +150,34 @@ tf_cc_binary( linkstatic=True, visibility = ["//visibility:public"], ) + +tf_cc_binary( + name = 'infer_multi', + srcs = [ + "examples/cpp/infer_multiple_networks/main.cc", + "examples/cpp/infer_multiple_networks/inference_engine.h", + "examples/cpp/infer_multiple_networks/inference_engine.cc", + "examples/cpp/tf_label_image_utils.cc", + ], + deps = [ + "@org_tensorflow//tensorflow/cc:cc_ops", + "@org_tensorflow//tensorflow/cc:client_session", + "@org_tensorflow//tensorflow/core:tensorflow", + ":ngraph_bridge_lib", + "@ngraph//:cpu_backend", + ], + copts = [ + "-pthread", + "-std=c++11", + "-D_FORTIFY_SOURCE=2", + "-Wformat", + "-Wformat-security", + "-Wformat", + "-fstack-protector-all", + "-I ngraph_bridge", + "-I external/ngraph/src", + "-I logging", + ] + CXX_ABI, + linkstatic=False, + visibility = ["//visibility:public"], +) diff --git a/examples/cpp/infer_multiple_networks/BUILD b/examples/cpp/infer_multiple_networks/BUILD deleted file mode 100644 index 8ddf49dc8..000000000 --- a/examples/cpp/infer_multiple_networks/BUILD +++ /dev/null @@ -1,33 +0,0 @@ -load("//:cxx_abi_option.bzl", "CXX_ABI") -load("@org_tensorflow//tensorflow:tensorflow.bzl", "tf_cc_binary") - -tf_cc_binary( - name = 'infer_multi', - srcs = [ - "main.cc", - "inference_engine.h", - "inference_engine.cc", - "tf_label_image_utils.cc" - ], - deps = [ - "@org_tensorflow//tensorflow/cc:cc_ops", - "@org_tensorflow//tensorflow/cc:client_session", - "@org_tensorflow//tensorflow/core:tensorflow", - "//:ngraph_bridge_lib", - "@ngraph//:cpu_backend", - ], - copts = [ - "-pthread", - "-std=c++11", - "-D_FORTIFY_SOURCE=2", - "-Wformat", - "-Wformat-security", - "-Wformat", - "-fstack-protector-all", - "-I ngraph_bridge", - "-I external/ngraph/src", - "-I logging", - ] + CXX_ABI, - linkstatic=False, - visibility = ["//visibility:public"], -) \ No newline at end of file diff --git a/tools/test_utils.py b/tools/test_utils.py index d7bafc493..a640c9e5c 100755 --- a/tools/test_utils.py +++ b/tools/test_utils.py @@ -599,9 +599,7 @@ def run_bazel_build_test(venv_dir, build_dir): command_executor(['bazel-bin/hello_tf']) # Now built the bigger app - command_executor([ - 'bazel', 'build', '//examples/cpp/infer_multiple_networks:infer_multi' - ]) + command_executor(['bazel', 'build', 'infer_multi']) # Return to the original directory os.chdir(root_pwd) @@ -620,5 +618,8 @@ def run_bazel_build(): # Run the cpp app - hello_tf command_executor(['bazel-bin/hello_tf']) + # Now built the bigger app + command_executor(['bazel', 'build', 'infer_multi']) + # Return to the original directory os.chdir(root_pwd)