Skip to content

Commit 81106b6

Browse files
committed
Add script name that generated headers.
1 parent 5247933 commit 81106b6

File tree

3 files changed

+4
-6
lines changed

3 files changed

+4
-6
lines changed

analytics/generate_windows_stubs.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,7 @@ def generate_function_pointers(header_file_path, output_h_path, output_c_path):
116116
header_guard = f"{HEADER_GUARD_PREFIX}{os.path.basename(output_h_path).upper().replace('.', '_')}_"
117117
with open(output_h_path, 'w', encoding='utf-8') as f:
118118
f.write(f"{COPYRIGHT_NOTICE}")
119-
f.write(f"// Generated from {os.path.basename(header_file_path)}\n")
120-
f.write(f"// This is a self-contained header file.\n\n")
119+
f.write(f"// Generated from {os.path.basename(header_file_path)} by {os.path.basename(sys.argv[0])}\n\n")
121120
f.write(f"#ifndef {header_guard}\n")
122121
f.write(f"#define {header_guard}\n\n")
123122

@@ -150,7 +149,7 @@ def generate_function_pointers(header_file_path, output_h_path, output_c_path):
150149
# --- Write the Source File (.c) ---
151150
with open(output_c_path, 'w', encoding='utf-8') as f:
152151
f.write(f"{COPYRIGHT_NOTICE}")
153-
f.write(f"// Generated from {os.path.basename(header_file_path)}\n\n")
152+
f.write(f"// Generated from {os.path.basename(header_file_path)} by {os.path.basename(sys.argv[0])}\n\n")
154153
f.write(f'#include "{INCLUDE_PREFIX}{os.path.basename(output_h_path)}"\n')
155154
f.write('#include <stddef.h> // For NULL\n\n')
156155
f.write("// --- Stub Function Definitions ---\n")

analytics/src/windows/analytics_dynamic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15-
// Generated from analytics.h
15+
// Generated from analytics.h by generate_windows_stubs.py
1616

1717
#include "analytics/src/windows/analytics_dynamic.h"
1818

analytics/src/windows/analytics_dynamic.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212
// See the License for the specific language governing permissions and
1313
// limitations under the License.
1414

15-
// Generated from analytics.h
16-
// This is a self-contained header file.
15+
// Generated from analytics.h by generate_windows_stubs.py
1716

1817
#ifndef FIREBASE_ANALYTICS_SRC_WINDOWS_ANALYTICS_DYNAMIC_H_
1918
#define FIREBASE_ANALYTICS_SRC_WINDOWS_ANALYTICS_DYNAMIC_H_

0 commit comments

Comments
 (0)