From 9f5a015f42d1ec5d3c3107abcf0c54579c39a719 Mon Sep 17 00:00:00 2001 From: Ainar Garipov Date: Tue, 15 Jun 2021 19:42:41 +0300 Subject: [PATCH] Pull request: all: imp build tags Updates #2419. Squashed commit of the following: commit e57e6ce56c59d4ef42b1716247fe48a86404179e Author: Ainar Garipov Date: Tue Jun 15 19:37:15 2021 +0300 all: imp build tags --- internal/aghnet/net_darwin.go | 3 +-- internal/aghnet/net_linux.go | 3 +-- internal/aghnet/net_linux_test.go | 3 +-- internal/aghnet/net_others.go | 3 +-- internal/aghnet/systemresolvers_others.go | 3 +-- internal/aghnet/systemresolvers_others_test.go | 3 +-- internal/aghnet/systemresolvers_windows.go | 3 +-- internal/aghnet/systemresolvers_windows_test.go | 3 +-- internal/aghos/endian_big.go | 3 +-- internal/aghos/endian_little.go | 3 +-- internal/aghos/os_bsd.go | 3 +-- internal/aghos/os_freebsd.go | 3 +-- internal/aghos/os_linux.go | 3 +-- internal/aghos/os_windows.go | 3 +-- internal/aghos/syslog_others.go | 3 +-- internal/aghos/syslog_windows.go | 3 +-- internal/aghos/user_unix.go | 3 +-- internal/aghos/user_windows.go | 3 +-- internal/dhcpd/checkother.go | 3 +-- internal/dhcpd/checkother_windows.go | 3 +-- internal/dhcpd/dhcpd_test.go | 3 +-- internal/dhcpd/os_windows.go | 3 +-- internal/dhcpd/v4.go | 3 +-- internal/dhcpd/v46_windows.go | 3 +-- internal/dhcpd/v4_test.go | 3 +-- internal/dhcpd/v6.go | 3 +-- internal/dhcpd/v6_test.go | 3 +-- internal/dnsforward/ipset_linux.go | 3 +-- internal/dnsforward/ipset_others.go | 3 +-- internal/filtering/blocked_test.go | 3 +-- internal/tools/tools.go | 3 +-- internal/version/norace.go | 3 +-- internal/version/race.go | 3 +-- 33 files changed, 33 insertions(+), 66 deletions(-) diff --git a/internal/aghnet/net_darwin.go b/internal/aghnet/net_darwin.go index 8e68e719..ee30657c 100644 --- a/internal/aghnet/net_darwin.go +++ b/internal/aghnet/net_darwin.go @@ -1,6 +1,5 @@ -// +build darwin - //go:build darwin +// +build darwin package aghnet diff --git a/internal/aghnet/net_linux.go b/internal/aghnet/net_linux.go index d0d01f7c..b4adced6 100644 --- a/internal/aghnet/net_linux.go +++ b/internal/aghnet/net_linux.go @@ -1,6 +1,5 @@ -// +build linux - //go:build linux +// +build linux package aghnet diff --git a/internal/aghnet/net_linux_test.go b/internal/aghnet/net_linux_test.go index 30e54fdd..77e7c9c8 100644 --- a/internal/aghnet/net_linux_test.go +++ b/internal/aghnet/net_linux_test.go @@ -1,6 +1,5 @@ -// +build linux - //go:build linux +// +build linux package aghnet diff --git a/internal/aghnet/net_others.go b/internal/aghnet/net_others.go index 560af917..7ee8e964 100644 --- a/internal/aghnet/net_others.go +++ b/internal/aghnet/net_others.go @@ -1,6 +1,5 @@ -// +build !linux,!darwin - //go:build !(linux || darwin) +// +build !linux,!darwin package aghnet diff --git a/internal/aghnet/systemresolvers_others.go b/internal/aghnet/systemresolvers_others.go index dd44fa0b..dae8a8dc 100644 --- a/internal/aghnet/systemresolvers_others.go +++ b/internal/aghnet/systemresolvers_others.go @@ -1,6 +1,5 @@ -// +build !windows - //go:build !windows +// +build !windows package aghnet diff --git a/internal/aghnet/systemresolvers_others_test.go b/internal/aghnet/systemresolvers_others_test.go index 7e0399ca..f614c960 100644 --- a/internal/aghnet/systemresolvers_others_test.go +++ b/internal/aghnet/systemresolvers_others_test.go @@ -1,6 +1,5 @@ -// +build !windows - //go:build !windows +// +build !windows package aghnet diff --git a/internal/aghnet/systemresolvers_windows.go b/internal/aghnet/systemresolvers_windows.go index 7dfec410..584b3636 100644 --- a/internal/aghnet/systemresolvers_windows.go +++ b/internal/aghnet/systemresolvers_windows.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package aghnet diff --git a/internal/aghnet/systemresolvers_windows_test.go b/internal/aghnet/systemresolvers_windows_test.go index 6058195f..d8c38396 100644 --- a/internal/aghnet/systemresolvers_windows_test.go +++ b/internal/aghnet/systemresolvers_windows_test.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package aghnet diff --git a/internal/aghos/endian_big.go b/internal/aghos/endian_big.go index bd37cc1a..8e6c0b99 100644 --- a/internal/aghos/endian_big.go +++ b/internal/aghos/endian_big.go @@ -1,6 +1,5 @@ -// +build mips mips64 - //go:build mips || mips64 +// +build mips mips64 // This file is an adapted version of github.com/josharian/native. diff --git a/internal/aghos/endian_little.go b/internal/aghos/endian_little.go index 30242bf6..56a4e3ce 100644 --- a/internal/aghos/endian_little.go +++ b/internal/aghos/endian_little.go @@ -1,6 +1,5 @@ -// +build amd64 386 arm arm64 mipsle mips64le ppc64le - //go:build amd64 || 386 || arm || arm64 || mipsle || mips64le || ppc64le +// +build amd64 386 arm arm64 mipsle mips64le ppc64le // This file is an adapted version of github.com/josharian/native. diff --git a/internal/aghos/os_bsd.go b/internal/aghos/os_bsd.go index 07febc93..8e726737 100644 --- a/internal/aghos/os_bsd.go +++ b/internal/aghos/os_bsd.go @@ -1,6 +1,5 @@ -// +build darwin netbsd openbsd - //go:build darwin || netbsd || openbsd +// +build darwin netbsd openbsd package aghos diff --git a/internal/aghos/os_freebsd.go b/internal/aghos/os_freebsd.go index 3c8b1e65..d1f4083c 100644 --- a/internal/aghos/os_freebsd.go +++ b/internal/aghos/os_freebsd.go @@ -1,6 +1,5 @@ -// +build freebsd - //go:build freebsd +// +build freebsd package aghos diff --git a/internal/aghos/os_linux.go b/internal/aghos/os_linux.go index 0850a5bf..d185daf3 100644 --- a/internal/aghos/os_linux.go +++ b/internal/aghos/os_linux.go @@ -1,6 +1,5 @@ -// +build linux - //go:build linux +// +build linux package aghos diff --git a/internal/aghos/os_windows.go b/internal/aghos/os_windows.go index 026665e3..aa95d9a7 100644 --- a/internal/aghos/os_windows.go +++ b/internal/aghos/os_windows.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package aghos diff --git a/internal/aghos/syslog_others.go b/internal/aghos/syslog_others.go index e321e943..8399bae0 100644 --- a/internal/aghos/syslog_others.go +++ b/internal/aghos/syslog_others.go @@ -1,6 +1,5 @@ -// +build !windows,!plan9 - //go:build !(windows || plan9) +// +build !windows,!plan9 package aghos diff --git a/internal/aghos/syslog_windows.go b/internal/aghos/syslog_windows.go index 53da1f5b..f562168e 100644 --- a/internal/aghos/syslog_windows.go +++ b/internal/aghos/syslog_windows.go @@ -1,6 +1,5 @@ -// +build windows plan9 - //go:build windows || plan9 +// +build windows plan9 package aghos diff --git a/internal/aghos/user_unix.go b/internal/aghos/user_unix.go index f8d228f7..3ccb6eb9 100644 --- a/internal/aghos/user_unix.go +++ b/internal/aghos/user_unix.go @@ -1,6 +1,5 @@ -// +build darwin freebsd linux netbsd openbsd - //go:build darwin || freebsd || linux || netbsd || openbsd +// +build darwin freebsd linux netbsd openbsd package aghos diff --git a/internal/aghos/user_windows.go b/internal/aghos/user_windows.go index bb39caab..4fac90e1 100644 --- a/internal/aghos/user_windows.go +++ b/internal/aghos/user_windows.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package aghos diff --git a/internal/dhcpd/checkother.go b/internal/dhcpd/checkother.go index 8406e836..07320c8d 100644 --- a/internal/dhcpd/checkother.go +++ b/internal/dhcpd/checkother.go @@ -1,6 +1,5 @@ -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris - //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris +// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris package dhcpd diff --git a/internal/dhcpd/checkother_windows.go b/internal/dhcpd/checkother_windows.go index c57a28c6..c417f643 100644 --- a/internal/dhcpd/checkother_windows.go +++ b/internal/dhcpd/checkother_windows.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package dhcpd diff --git a/internal/dhcpd/dhcpd_test.go b/internal/dhcpd/dhcpd_test.go index 5bc8e71e..8cbc8787 100644 --- a/internal/dhcpd/dhcpd_test.go +++ b/internal/dhcpd/dhcpd_test.go @@ -1,6 +1,5 @@ -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris - //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris +// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris package dhcpd diff --git a/internal/dhcpd/os_windows.go b/internal/dhcpd/os_windows.go index 33606537..33e5592b 100644 --- a/internal/dhcpd/os_windows.go +++ b/internal/dhcpd/os_windows.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package dhcpd diff --git a/internal/dhcpd/v4.go b/internal/dhcpd/v4.go index 21345153..7c915d67 100644 --- a/internal/dhcpd/v4.go +++ b/internal/dhcpd/v4.go @@ -1,6 +1,5 @@ -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris - //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris +// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris package dhcpd diff --git a/internal/dhcpd/v46_windows.go b/internal/dhcpd/v46_windows.go index 93afa34a..66511515 100644 --- a/internal/dhcpd/v46_windows.go +++ b/internal/dhcpd/v46_windows.go @@ -1,6 +1,5 @@ -// +build windows - //go:build windows +// +build windows package dhcpd diff --git a/internal/dhcpd/v4_test.go b/internal/dhcpd/v4_test.go index 8d24ae9f..b9a1defb 100644 --- a/internal/dhcpd/v4_test.go +++ b/internal/dhcpd/v4_test.go @@ -1,6 +1,5 @@ -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris - //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris +// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris package dhcpd diff --git a/internal/dhcpd/v6.go b/internal/dhcpd/v6.go index 9ccfbda7..6d7d6a96 100644 --- a/internal/dhcpd/v6.go +++ b/internal/dhcpd/v6.go @@ -1,6 +1,5 @@ -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris - //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris +// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris package dhcpd diff --git a/internal/dhcpd/v6_test.go b/internal/dhcpd/v6_test.go index 06284ace..1467909f 100644 --- a/internal/dhcpd/v6_test.go +++ b/internal/dhcpd/v6_test.go @@ -1,6 +1,5 @@ -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris - //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris +// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris package dhcpd diff --git a/internal/dnsforward/ipset_linux.go b/internal/dnsforward/ipset_linux.go index 4f02b634..e94c87c2 100644 --- a/internal/dnsforward/ipset_linux.go +++ b/internal/dnsforward/ipset_linux.go @@ -1,6 +1,5 @@ -// +build linux - //go:build linux +// +build linux package dnsforward diff --git a/internal/dnsforward/ipset_others.go b/internal/dnsforward/ipset_others.go index c15120f1..fad0b341 100644 --- a/internal/dnsforward/ipset_others.go +++ b/internal/dnsforward/ipset_others.go @@ -1,6 +1,5 @@ -// +build !linux - //go:build !linux +// +build !linux package dnsforward diff --git a/internal/filtering/blocked_test.go b/internal/filtering/blocked_test.go index 188bc9a0..575f75cc 100644 --- a/internal/filtering/blocked_test.go +++ b/internal/filtering/blocked_test.go @@ -1,6 +1,5 @@ -// +build ignore - //go:build ignore +// +build ignore package filtering diff --git a/internal/tools/tools.go b/internal/tools/tools.go index 2a247f21..7d875da1 100644 --- a/internal/tools/tools.go +++ b/internal/tools/tools.go @@ -1,6 +1,5 @@ -// +build tools - //go:build tools +// +build tools package tools diff --git a/internal/version/norace.go b/internal/version/norace.go index 0ad8ee0a..38dec06f 100644 --- a/internal/version/norace.go +++ b/internal/version/norace.go @@ -1,6 +1,5 @@ -// +build !race - //go:build !race +// +build !race package version diff --git a/internal/version/race.go b/internal/version/race.go index 15c00a4b..eb1c73a5 100644 --- a/internal/version/race.go +++ b/internal/version/race.go @@ -1,6 +1,5 @@ -// +build race - //go:build race +// +build race package version