Remove reference to $relative_target_output_dir

`$relative_target_output_dir` was a variable at one point but no longer.
Update the `depfile` docs example to remove the last reference to
`$relative_target_output_dir` and instead suggest what most Chrome
gni files seem to do which is "${target_gen_dir}/${target_name}.d" +
rebase_path.

Change-Id: Ie6be45f9f5be704b4c8fe1cde4d3c2551461c4f8
Reviewed-on: https://gn-review.googlesource.com/c/gn/+/15020
Commit-Queue: Brett Wilson <brettw@chromium.org>
Reviewed-by: Brett Wilson <brettw@chromium.org>
Reviewed-by: David Turner <digit@google.com>
diff --git a/docs/reference.md b/docs/reference.md
index 9fb18db..76ef2a9 100644
--- a/docs/reference.md
+++ b/docs/reference.md
@@ -5589,10 +5589,10 @@
 
     # Locate the depfile in the output directory named like the
     # inputs but with a ".d" appended.
-    depfile = "$relative_target_output_dir/{{source_name}}.d"
+    depfile = "$target_gen_dir/{{source_name_part}}.d"
 
     # Say our script uses "-o <d file>" to indicate the depfile.
-    args = [ "{{source}}", "-o", depfile ]
+    args = [ "{{source}}", "-o", rebase_path(depfile, root_build_dir)]
   }
 ```
 ### <a name="var_deps"></a>**deps**: Private linked dependencies.
diff --git a/src/gn/variables.cc b/src/gn/variables.cc
index d61a363..28f174d 100644
--- a/src/gn/variables.cc
+++ b/src/gn/variables.cc
@@ -1112,10 +1112,10 @@
 
     # Locate the depfile in the output directory named like the
     # inputs but with a ".d" appended.
-    depfile = "$relative_target_output_dir/{{source_name}}.d"
+    depfile = "$target_gen_dir/{{source_name_part}}.d"
 
     # Say our script uses "-o <d file>" to indicate the depfile.
-    args = [ "{{source}}", "-o", depfile ]
+    args = [ "{{source}}", "-o", rebase_path(depfile, root_build_dir)]
   }
 )";