Minimal fix for relative base path.

In some cases when calculating the relative path of an artifact from the
same directory returns "." which is not allowed in path manipulation
from recipes.

Bug: https://github.com/flutter/flutter/issues/81855
Change-Id: I1aa35971e1fb7a4c183162fdda3e97e23a8e205a
Reviewed-on: https://flutter-review.googlesource.com/c/recipes/+/27400
Reviewed-by: Keyong Han <keyonghan@google.com>
Commit-Queue: Godofredo Contreras <godofredoc@google.com>
diff --git a/recipes/engine_v2/builder.py b/recipes/engine_v2/builder.py
index f2c789c..28840d0 100644
--- a/recipes/engine_v2/builder.py
+++ b/recipes/engine_v2/builder.py
@@ -124,6 +124,7 @@
       dir_name = api.path.dirname(full_include_path)
       full_base_path = api.path.abspath(checkout.join(archive_config.get('base_path','')))
       rel_path = api.path.relpath(dir_name, full_base_path)
+      rel_path = '' if rel_path == '.' else rel_path
       base_name = api.path.basename(full_include_path)
       api.file.ensure_directory('Ensuring %s' % archive_dir.join(rel_path), archive_dir.join(rel_path))
       api.file.copy('Copy %s' % include_path, full_include_path, archive_dir.join(rel_path, base_name))