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

Make release-linux architectures via environments. #14184

Merged
merged 1 commit into from
Feb 22, 2021

Conversation

lunny
Copy link
Member

@lunny lunny commented Dec 29, 2020

Then we can just only release one architecture.

LINUX_ARCHS=linux/amd64 TAGS=bindata make release-linux

@lunny lunny added the topic/build PR changes how Gitea is built, i.e. regarding Docker or the Makefile label Dec 29, 2020
@lunny
Copy link
Member Author

lunny commented Dec 29, 2020

It seems xgo don't care about -targets.

$ LINUX_ARCHS=linux/amd64 TAGS=bindata make release-linux
CGO_CFLAGS="-g -O2 -I/Users/lunny/gopath/src/github.com/ibmdb/go_ibm_db/installer/clidriver/include" GO111MODULE=off xgo -go go-1.15.x -dest dist/binaries -tags 'netgo osusergo bindata' -ldflags '-linkmode external -extldflags "-static"  -X "main.MakeVersion=GNU Make 3.81" -X "main.Version=1.14.0+dev-482-ga19bded87" -X "main.Tags=bindata"' -targets 'linux/amd64' -out gitea-master .
Checking docker installation...
Client: Docker Engine - Community
 Version:           18.09.2
 API version:       1.39
 Go version:        go1.10.8
 Git commit:        6247962
 Built:             Sun Feb 10 04:12:39 2019
 OS/Arch:           darwin/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          18.09.2
  API version:      1.39 (minimum version 1.12)
  Go version:       go1.10.6
  Git commit:       6247962
  Built:            Sun Feb 10 04:13:06 2019
  OS/Arch:          linux/amd64
  Experimental:     true

Checking for required docker image techknowlogick/xgo:go-1.15.x... found.
Cross compiling ....
Enabled Go module support
Using vendored Go module dependencies
Building /source/go.mod...
Compiling for linux/amd64...
# code.gitea.io/gitea
loadinternal: cannot find runtime/cgo
Bootstrapping linux/arm-5...
# code.gitea.io/gitea
loadinternal: cannot find runtime/cgo
Bootstrapping linux/arm-5...
Compiling for linux/arm-5...
Compiling for linux/arm-5...
# code.gitea.io/gitea
loadinternal: cannot find runtime/cgo
Cleaning up build environment...

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Dec 29, 2020
@codecov-io
Copy link

Codecov Report

Merging #14184 (a19bded) into master (9a4050f) will increase coverage by 0.00%.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master   #14184   +/-   ##
=======================================
  Coverage   42.02%   42.03%           
=======================================
  Files         733      733           
  Lines       78704    78704           
=======================================
+ Hits        33074    33081    +7     
+ Misses      40199    40194    -5     
+ Partials     5431     5429    -2     
Impacted Files Coverage Δ
modules/util/timer.go 42.85% <0.00%> (-42.86%) ⬇️
models/unit.go 46.57% <0.00%> (-2.74%) ⬇️
routers/repo/view.go 37.60% <0.00%> (-0.65%) ⬇️
services/pull/pull.go 42.35% <0.00%> (-0.51%) ⬇️
models/gpg_key.go 53.90% <0.00%> (+0.57%) ⬆️
modules/git/command.go 89.42% <0.00%> (+1.92%) ⬆️
services/gitdiff/gitdiff.go 70.93% <0.00%> (+1.93%) ⬆️
modules/charset/charset.go 70.78% <0.00%> (+2.24%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cfc3916...a19bded. Read the comment docs.

@lunny
Copy link
Member Author

lunny commented Feb 22, 2021

It seems xgo don't care about -targets.

$ LINUX_ARCHS=linux/amd64 TAGS=bindata make release-linux
CGO_CFLAGS="-g -O2 -I/Users/lunny/gopath/src/github.com/ibmdb/go_ibm_db/installer/clidriver/include" GO111MODULE=off xgo -go go-1.15.x -dest dist/binaries -tags 'netgo osusergo bindata' -ldflags '-linkmode external -extldflags "-static"  -X "main.MakeVersion=GNU Make 3.81" -X "main.Version=1.14.0+dev-482-ga19bded87" -X "main.Tags=bindata"' -targets 'linux/amd64' -out gitea-master .
Checking docker installation...
Client: Docker Engine - Community
 Version:           18.09.2
 API version:       1.39
 Go version:        go1.10.8
 Git commit:        6247962
 Built:             Sun Feb 10 04:12:39 2019
 OS/Arch:           darwin/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
  Version:          18.09.2
  API version:      1.39 (minimum version 1.12)
  Go version:       go1.10.6
  Git commit:       6247962
  Built:            Sun Feb 10 04:13:06 2019
  OS/Arch:          linux/amd64
  Experimental:     true

Checking for required docker image techknowlogick/xgo:go-1.15.x... found.
Cross compiling ....
Enabled Go module support
Using vendored Go module dependencies
Building /source/go.mod...
Compiling for linux/amd64...
# code.gitea.io/gitea
loadinternal: cannot find runtime/cgo
Bootstrapping linux/arm-5...
# code.gitea.io/gitea
loadinternal: cannot find runtime/cgo
Bootstrapping linux/arm-5...
Compiling for linux/arm-5...
Compiling for linux/arm-5...
# code.gitea.io/gitea
loadinternal: cannot find runtime/cgo
Cleaning up build environment...

Resolved so that this is ready to review.

@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Feb 22, 2021
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Feb 22, 2021
@lafriks lafriks merged commit 00fffdf into go-gitea:master Feb 22, 2021
@lunny lunny deleted the lunny/make_linux branch February 22, 2021 07:02
@go-gitea go-gitea locked and limited conversation to collaborators May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. topic/build PR changes how Gitea is built, i.e. regarding Docker or the Makefile
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants