diff --git a/metrics/cputime_nop.go b/metrics/cputime_nop.go
index 465d88c4d2..a6285ec10a 100644
--- a/metrics/cputime_nop.go
+++ b/metrics/cputime_nop.go
@@ -14,8 +14,8 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see .
-//go:build windows || js
-// +build windows js
+//go:build windows || js || tinygo
+// +build windows js tinygo
package metrics
diff --git a/metrics/cputime_unix.go b/metrics/cputime_unix.go
index a44bf80876..5db38b16a2 100644
--- a/metrics/cputime_unix.go
+++ b/metrics/cputime_unix.go
@@ -14,8 +14,8 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see .
-//go:build !windows && !js && !wasip1
-// +build !windows,!js,!wasip1
+//go:build !windows && !js && !wasip1 && !tinygo
+// +build !windows,!js,!wasip1,!tinygo
package metrics