Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

metrics: fix compilation for GOOS=js #23449

Merged
merged 1 commit into from
Aug 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion metrics/cpu_disabled.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.

// +build ios
// +build ios js

package metrics

Expand Down
2 changes: 1 addition & 1 deletion metrics/cpu_enabled.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.

// +build !ios
// +build !ios,!js

package metrics

Expand Down
2 changes: 2 additions & 0 deletions metrics/cpu_windows.go → metrics/cputime_nop.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.

// +build windows js

package metrics

// getProcessCPUTime returns 0 on Windows as there is no system call to resolve
Expand Down
2 changes: 1 addition & 1 deletion metrics/cpu_syscall.go → metrics/cputime_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.

// +build !windows
// +build !windows,!js

package metrics

Expand Down
3 changes: 1 addition & 2 deletions metrics/runtime_cgo.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
// +build cgo
// +build !appengine
// +build cgo,!appengine,!js

package metrics

Expand Down
2 changes: 1 addition & 1 deletion metrics/runtime_no_cgo.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !cgo appengine
// +build !cgo appengine js

package metrics

Expand Down