WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Unable to build darwin on darwin - flag provided but not defined #329

@pztrn

Description

@pztrn

Describe the bug:

When trying to build app using fyne-cross it whines about unknown flag.

To Reproduce:

Steps to reproduce the behaviour:

  1. Make a hello world app (error is application-agnostic).
  2. Run fyne-cross darwin -app-id=com.dummy.app -app-version="0.1.0" -app-build="1" -icon=Icon.png -arch=arm64 -name="Dummy App" -pull on macos.
  3. See error:
...
[✓] go.mod found
[i] Packaging app...
Incorrect Usage: flag provided but not defined: -appBuild

Windows and Linux versions compiles fine. Removing -app-build flag from command line makes no difference, because it will be always appended here: https://github.com/fyne-io/fyne-cross/blob/master/internal/command/command.go#L181

Example code:

Device and debug info (please complete the following information):

Device info
  • OS: macOS
  • Version: 15.6.1
  • Go version: 1.25.1 with 1.24.1 in Fyne's cross images.
  • fyne-cross version: v1.6.1
  • Fyne version: 2.6.3
Debug info
task: [client:client:build-darwin-amd64] fyne-cross darwin -app-id=com.dummy.app -app-version="0.1.0" -app-build="1" -icon=client/Icon.png -arch=amd64 -category=6007 -name="Dummy App" -pull -no-cache -debug client/cmd/client
[i] Target: darwin/amd64
&command.localContainerImage{baseContainerImage:command.baseContainerImage{arch:"amd64", os:"darwin", id:"darwin-amd64", env:map[string]string{"CC":"zig cc -v -target x86_64-macos.10.12 -isysroot /sdk -iwithsysroot /usr/include -iframeworkwithsysroot /System/Library/Frameworks", "CGO_LDFLAGS":"--sysroot /sdk -F/System/Library/Frameworks -L/usr/lib", "CXX":"zig c++ -v -target x86_64-macos.10.12 -isysroot /sdk -iwithsysroot /usr/include -iframeworkwithsysroot /System/Library/Frameworks", "GOARCH":"amd64", "GOOS":"darwin"}, tags:[]string(nil), mount:[]command.containerMountPoint{command.containerMountPoint{name:"project", localHost:"/Users/pztrn/projects/my/dummy", inContainer:"/app"}}, DockerImage:"docker.io/fyneio/fyne-cross-images:darwin"}, runner:(*command.localContainerEngine)(0x14000216000)}
[i] Checking for a newer version of the docker image: docker.io/fyneio/fyne-cross-images:darwin
/opt/homebrew/bin/docker pull docker.io/fyneio/fyne-cross-images:darwin
darwin: Pulling from fyneio/fyne-cross-images
Digest: sha256:e686758e615c6397eecb9809a502299cc85b895defd0604a961b0502eb143e9d
Status: Image is up to date for fyneio/fyne-cross-images:darwin
docker.io/fyneio/fyne-cross-images:darwin
[✓] Image is up to date
[i] Cleaning target directories...
[✓] "temp" dir cleaned: /Users/pztrn/projects/my/dummy/fyne-cross/tmp/darwin-amd64
[✓] "bin" dir cleaned: /Users/pztrn/projects/my/dummy/fyne-cross/bin/darwin-amd64
[✓] "dist" dir cleaned: /Users/pztrn/projects/my/dummy/fyne-cross/dist/darwin-amd64
[i] Checking for go.mod: /Users/pztrn/projects/my/dummy/go.mod
[✓] go.mod found
[i] Packaging app...
fyne cli version: v1.6.1
fyne library version: v2.6.3
/Users/pztrn/go/bin/fyne package -os darwin -name Dummy App -icon /Users/pztrn/projects/my/dummy/fyne-cross/tmp/darwin-amd64/Icon.png -appBuild 1 -appVersion 0.1.0 -appID com.dummy.app -src client/cmd/client
Incorrect Usage: flag provided but not defined: -appBuild

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions