From a4fd9bb2e0a550a7525136c0b0442f1ae9e5875e Mon Sep 17 00:00:00 2001 From: Jacob Janzen Date: Fri, 1 Mar 2024 16:21:15 -0600 Subject: [PATCH] build: fix target processing when a parent directory contains "scratch" --- ns3 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ns3 b/ns3 index 801d10db9..21252c9f3 100755 --- a/ns3 +++ b/ns3 @@ -1225,7 +1225,7 @@ def get_target_to_build(program_path, ns3_version, build_profile): print("Target to build does not exist: %s" % program_path) exit(1) - if "scratch" in program_path: + if "scratch" in os.path.relpath(program_path, ns3_path): # Get the path to the program and replace slashes with underlines # to get unique targets for CMake, preventing collisions with modules examples return program_name.replace(out_dir, "").replace("/", "_")[1:]