From 7eb2d308830003432601f9b40ba5ccf7382b6157 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Sat, 1 May 2021 15:37:44 +0200 Subject: [PATCH] syscall: add //go:build lines to files generated with with mksyscall_libc.pl Change-Id: I2e02d02d9208fc2dbf01c0cea4a67c288967cd07 Reviewed-on: https://go-review.googlesource.com/c/go/+/315276 Trust: Tobias Klauser Run-TryBot: Tobias Klauser TryBot-Result: Go Bot Reviewed-by: Ian Lance Taylor --- src/syscall/mksyscall_libc.pl | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/syscall/mksyscall_libc.pl b/src/syscall/mksyscall_libc.pl index 5ceedc812a..631a07c819 100755 --- a/src/syscall/mksyscall_libc.pl +++ b/src/syscall/mksyscall_libc.pl @@ -23,6 +23,7 @@ my $cmdline = "mksyscall_libc.pl " . join(' ', @ARGV); my $errors = 0; my $_32bit = ""; my $tags = ""; # build tags +my $newtags = ""; # new style build tags my $aix = 0; my $solaris = 0; @@ -300,10 +301,14 @@ if($errors) { exit 1; } +# TODO: this assumes tags are just simply comma separated. For now this is all the uses. +$newtags = $tags =~ s/,/ && /r; + print <