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

fix: Nodetime arm64 for linux #874

Merged
merged 11 commits into from
Mar 17, 2021
3 changes: 3 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ builds:
goarch:
- amd64
- arm64
ignore:
- goos: darwin
goarch: arm64

brews:
- name: "starport"
Expand Down
6 changes: 1 addition & 5 deletions scripts/data/gen-nodetime/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion scripts/data/gen-nodetime/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"nodetime": "./nodetime"
},
"scripts": {
"build": "./node_modules/pkg/lib-es5/bin.js --debug -t node14-linux-x64,node14-macos-x64 -o nodetime ."
"build": "./node_modules/pkg/lib-es5/bin.js --debug -t node14-linux-x64,node14-macos-x64,node14-linux-arm64 -o nodetime ."
},
"dependencies": {
"@cosmjs/launchpad": "^0.23.2",
Expand Down
10 changes: 6 additions & 4 deletions scripts/gen-nodetime
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ cd ./scripts/data/gen-nodetime
npm i
npm run build

tar -czvf nodetime-linux.tar.gz nodetime-linux
tar -czvf nodetime-darwin.tar.gz nodetime-macos
tar -czvf nodetime-linux-arm64.tar.gz nodetime-linux-arm64
tar -czvf nodetime-linux-x64.tar.gz nodetime-linux-x64
tar -czvf nodetime-darwin-x64.tar.gz nodetime-macos-x64

cp nodetime-linux.tar.gz ../../../starport/pkg/nodetime/
cp nodetime-darwin.tar.gz ../../../starport/pkg/nodetime/
cp nodetime-linux-arm64.tar.gz ../../../starport/pkg/nodetime/
cp nodetime-linux-x64.tar.gz ../../../starport/pkg/nodetime/
cp nodetime-darwin-x64.tar.gz ../../../starport/pkg/nodetime/
8 changes: 8 additions & 0 deletions starport/pkg/nodetime/binary_darwin_amd64.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// +build darwin amd64

package nodetime

import _ "embed" // embed is required for binary embedding.

//go:embed nodetime-darwin-amd64.tar.gz
var binaryCompressed []byte
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// +build darwin
// +build linux amd64

package nodetime

import _ "embed" // embed is required for binary embedding.

//go:embed nodetime-darwin.tar.gz
//go:embed nodetime-linux-amd64.tar.gz
var binaryCompressed []byte
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
// +build linux
// +build linux arm64

package nodetime

import _ "embed" // embed is required for binary embedding.

//go:embed nodetime-linux.tar.gz
//go:embed nodetime-linux-arm64.tar.gz
var binaryCompressed []byte
Binary file added starport/pkg/nodetime/nodetime-linux-arm64.tar.gz
Binary file not shown.