Skip to content

Commit

Permalink
Fix DALI TF plugin source compilation during installation
Browse files Browse the repository at this point in the history
- removes unnecessary escape characters from compilation commands
  for the DALI TF plugin stub and binary issues when the
  plugin is built from the source during installation. Before
  this change rpatch was incorrectly set to '$ORIGIN' instead
  of just $ORIGIN

Signed-off-by: Janusz Lisiecki <jlisiecki@nvidia.com>
  • Loading branch information
JanuszL committed Apr 29, 2024
1 parent 8298353 commit e70f593
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
6 changes: 3 additions & 3 deletions dali_tf_plugin/dali_tf_plugin_install_tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ def build(self):
dali_lflags = "-L" + tmpdir + " -ldali"
dali_cflags = "-I" + os.path.join(self.src_path, "include")

cmd = [compiler, "-Wl,-R,'$ORIGIN/..'", "-std=c++14", "-DNDEBUG", "-shared"]
cmd = [compiler, "-Wl,-R,$ORIGIN/..", "-std=c++14", "-DNDEBUG", "-shared"]
cmd += dali_stub_src.split()
cmd += ["-o"]
cmd += dali_stub_lib.split()
Expand Down Expand Up @@ -374,8 +374,8 @@ def build(self):
root_include = "-I" + os.getenv("PREFIX", default="/usr") + "/include"
cmd = [
compiler,
"-Wl,-R,'$ORIGIN/..'",
"-Wl,-rpath,'$ORIGIN'",
"-Wl,-R,$ORIGIN/..",
"-Wl,-rpath,$ORIGIN",
cpp_ver,
"-DNDEBUG",
"-shared",
Expand Down
4 changes: 4 additions & 0 deletions qa/TL0_tensorflow_plugin/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ test_body() {
pip install ../../../nvidia-dali-tf-plugin*.tar.gz
${python_invoke_test} test_dali_tf_plugin.py:TestDaliTfPluginLoadOk

# Installing "current" dali tf (built against installed TF) - force rebuild
pip install ../../../nvidia-dali-tf-plugin*.tar.gz
DALI_TF_ALWAYS_BUILD=1 ${python_invoke_test} test_dali_tf_plugin.py:TestDaliTfPluginLoadOk

# DALI TF run
${python_invoke_test} test_dali_tf_plugin_run.py

Expand Down

0 comments on commit e70f593

Please sign in to comment.