I can't do cross compile to ARM since vfsgen was added #3438

Closed
opened 2025-11-02 05:12:58 -06:00 by GiteaMirror · 4 comments
Owner

Originally created by @esfraner on GitHub (Jun 7, 2019).

  • Gitea version (or commit ref): latest from master
  • Git version: 2.11.0
  • Operating system: Linux debian
  • Database:
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant
  • Log gist:

Description

I can't do cross compile to ARM from x86_64 since vfsgen was added in #7080. If I use the previous commit (using go-bindata) there isn't any problem 😢

I realized that the error comes from //go:generate go run -mod=vendor main.go lines

I'm running this command: GOOS=linux GOARCH=arm GOARM=7 TAGS="bindata" make generate build

Screenshots

image

Originally created by @esfraner on GitHub (Jun 7, 2019). <!-- NOTE: If your issue is a security concern, please send an email to security@gitea.io instead of opening a public issue --> <!-- 1. Please speak English, this is the language all maintainers can speak and write. 2. Please ask questions or configuration/deploy problems on our Discord server (https://discord.gg/gitea) or forum (https://discourse.gitea.io). 3. Please take a moment to check that your issue doesn't already exist. 4. Please give all relevant information below for bug reports, because incomplete details will be handled as an invalid report. --> - Gitea version (or commit ref): latest from master - Git version: 2.11.0 - Operating system: Linux debian - Database: - [ ] PostgreSQL - [ ] MySQL - [ ] MSSQL - [ ] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [ ] No - [x] Not relevant - Log gist: ## Description I can't do cross compile to ARM from x86_64 since vfsgen was added in #7080. If I use the [previous commit](https://github.com/go-gitea/gitea/commit/8eba27c79257c6bc68cefbdffbb36d3596e6d3ee) (using go-bindata) there isn't any problem :cry: I realized that the error comes from [`//go:generate go run -mod=vendor main.go`](https://github.com/go-gitea/gitea/blob/master/modules/options/options.go#L7) lines I'm running this command: `GOOS=linux GOARCH=arm GOARM=7 TAGS="bindata" make generate build` ## Screenshots ![image](https://user-images.githubusercontent.com/22304628/59073887-55c09800-88c9-11e9-921f-0d44d3a3b98a.png) <!-- **If this issue involves the Web Interface, please include a screenshot** -->
Author
Owner

@sapk commented on GitHub (Jun 7, 2019):

What version of go do you use ?

@sapk commented on GitHub (Jun 7, 2019): What version of go do you use ?
Author
Owner

@esfraner commented on GitHub (Jun 7, 2019):

What version of go do you use ?

I am using 1.11.10

@esfraner commented on GitHub (Jun 7, 2019): > What version of go do you use ? I am using 1.11.10
Author
Owner

@sapk commented on GitHub (Jun 7, 2019):

Ok, I think it failed because it try to run the generation via vfsgen for arm.
Can you try this order of commands ? (generate without the cross flags)

make generate
GOOS=linux GOARCH=arm GOARM=7 TAGS="bindata" make build
@sapk commented on GitHub (Jun 7, 2019): Ok, I think it failed because it try to run the generation via vfsgen for arm. Can you try this order of commands ? (generate without the cross flags) ``` make generate GOOS=linux GOARCH=arm GOARM=7 TAGS="bindata" make build ```
Author
Owner

@esfraner commented on GitHub (Jun 7, 2019):

@sapk, thank you It was the problem 😄

@esfraner commented on GitHub (Jun 7, 2019): @sapk, thank you It was the problem :smile:
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#3438