Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Update build script to use GOFLAGS and CGO_LDFLAGS#460

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Closed

Conversation

@max-baz
Copy link
Contributor

This change makes use of GOFLAGS to simplify compiling with PIE, respecting LDFLAGS and trimming local paths to support reproducible builds.

Relevant:https://lists.archlinux.org/pipermail/arch-dev-public/2020-March/029898.html

Since you are already providing a source tarball that includes vendor dependencies (👍), all dependency-related items in the email do not apply to you:

  • -mod=vendor is used by default in Go 1.14
  • -modcacherw is only needed if our build system was fetching vendor dependencies itself

Tested by applying this patch on top of 1.7.1 release archive that contains vendor folder.

This change makes use of GOFLAGS to simplify compiling with PIE, respecting LDFLAGS and trimming local paths to support reproducible builds.Relevant:https://lists.archlinux.org/pipermail/arch-dev-public/2020-March/029898.htmlSince you are already providing a source tarball that includes vendor dependencies (👍), all dependency-related items in the email do not apply to you:* -mod=vendor is used by default in Go 1.14* -modcacherw is only needed if our build system was fetching vendor dependencies itselfTested by applying this patch on top of 1.7.1 release archive that contains vendor folder.
@max-baz
Copy link
ContributorAuthor

Oh it seems your travis checks for older Go versions... Let me know how you want to proceed, maybe it's time to remove older Go versions? 😜

rfjakob added a commit that referenced this pull requestApr 13, 2020
@rfjakob
Copy link
Owner

-buildmode=pie causes problems with static builds:

# github.com/rfjakob/gocryptfsloadinternal: cannot find runtime/cgo# github.com/rfjakob/gocryptfs/gocryptfs-xrayloadinternal: cannot find runtime/cgo# github.com/rfjakob/gocryptfs/contrib/statfsloadinternal: cannot find runtime/cgo

@max-baz
Copy link
ContributorAuthor

Hmm I didn't see this, do you do something special to reproduce?

@rfjakob
Copy link
Owner

$ ./build-without-openssl.bash # github.com/rfjakob/gocryptfsloadinternal: cannot find runtime/cgo# github.com/rfjakob/gocryptfs/gocryptfs-xrayloadinternal: cannot find runtime/cgo# github.com/rfjakob/gocryptfs/contrib/statfsloadinternal: cannot find runtime/cgogocryptfs v1.7.1-48-gf6b1c68 without_openssl; go-fuse v1.0.1-0.20190319092520-161a16484456; 2020-04-18 go1.13.6 linux/amd64

@rfjakob
Copy link
Owner

Fixed via5da5e9f . build.bash now uses both -buildmode=pie and -trimpath when possible.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@max-baz@rfjakob

[8]ページ先頭

©2009-2025 Movatter.jp