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

sync_diff_inspector: use statically build #785

Merged
merged 2 commits into from
Jun 11, 2024

Conversation

CharlesCheung96
Copy link
Contributor

@CharlesCheung96 CharlesCheung96 commented May 6, 2024

What problem does this PR solve?

Issue Number: ref #782

What is changed and how it works?

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Code changes

  • Has exported function/method change
  • Has exported variable/fields change
  • Has interface methods change
  • Has persistent data change

Side effects

  • Possible performance regression
  • Increased code complexity
  • Breaking backward compatibility

Related changes

  • Need to cherry-pick to the release branch
  • Need to update the documentation
  • Need to be included in the release note

@CharlesCheung96
Copy link
Contributor Author

/retest

@CharlesCheung96
Copy link
Contributor Author

/integration-test

@CharlesCheung96
Copy link
Contributor Author

/run-integration-test

@ti-chi-bot ti-chi-bot bot removed the lgtm label Jun 11, 2024
@ti-chi-bot ti-chi-bot bot added the lgtm label Jun 11, 2024
Copy link

ti-chi-bot bot commented Jun 11, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dveeden

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Copy link

ti-chi-bot bot commented Jun 11, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-05-23 08:41:20.817436421 +0000 UTC m=+2333834.574572038: ☑️ agreed by dveeden.
  • 2024-06-11 16:00:31.266725576 +0000 UTC m=+480385.320037501: ✖️🔁 reset by ti-chi-bot[bot].
  • 2024-06-11 18:08:00.167810818 +0000 UTC m=+488034.221122742: ☑️ agreed by dveeden.

@ti-chi-bot ti-chi-bot bot merged commit ee96064 into master Jun 11, 2024
4 checks passed
@ti-chi-bot ti-chi-bot bot deleted the disable-cgo-for-sync-diff branch June 11, 2024 18:09
@wuhuizuo
Copy link
Contributor

broken in buildings for mac targets.

@dveeden
Copy link
Contributor

dveeden commented Jun 12, 2024

I assume this is the issue?

$ GOOS=darwin GOARCH=arm64 CGO_ENABLED=0 make sync_diff_inspector 
GO111MODULE=on go build -ldflags '-X "github.com/pingcap/tidb-tools/pkg/utils.Version=v8.1.0-8-g2c9fecb" -X "github.com/pingcap/tidb-tools/pkg/utils.BuildTS=2024-06-12 05:56:32" -X "github.com/pingcap/tidb-tools/pkg/utils.GitHash=2c9fecb17c2f014b469bd1f0e36393dae1842773" -X "github.com/pingcap/tidb-tools/pkg/utils.GitBranch=master"' -o bin/sync_diff_inspector ./sync_diff_inspector
# github.com/cloudfoundry/gosigar
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:20:12: cpuUsage.Get undefined (type Cpu has no field or method Get)
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:30:14: cpuUsage.Get undefined (type Cpu has no field or method Get)
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:49:11: l.Get undefined (type LoadAverage has no field or method Get)
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:55:11: m.Get undefined (type Mem has no field or method Get)
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:61:11: m.GetIgnoringCGroups undefined (type Mem has no field or method GetIgnoringCGroups)
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:67:11: s.Get undefined (type Swap has no field or method Get)
../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/sigar_shared.go:12:21: procTime.Get undefined (type *ProcTime has no field or method Get)
make: *** [Makefile:60: sync_diff_inspector] Error 1

@wuhuizuo
Copy link
Contributor

../../../go/pkg/mod/github.com/cloudfoundry/gosigar@v1.3.6/concrete_sigar.go:20:12: cpuUsage.Get undefined (type Cpu has no field or method Get)

Yes

@dveeden
Copy link
Contributor

dveeden commented Jun 12, 2024

https://github.com/cloudfoundry/gosigar/blob/master/sigar_darwin.go heavily relies on C so that explains that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants