-
-
Notifications
You must be signed in to change notification settings - Fork 51
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
Propagate tags when building with fyne cross #200
Comments
I am not certain we support |
I did: |
Also I tried : But the app still does not work |
I guess we should apologize for being French :-) More seriously, the devel version returned indicate you did build maybe not from the master branch. Would you mind pulling the latest version of fyne-cross and checking if the error is still there? |
I built a new fyne-cross as follows: after that I did: and got: error building application: exit status 1 |
This issue is related to: fyne-io/fyne#3795 |
me tooo , I have this problen |
Describe the bug:
I am trying to cross package from ubuntu an windows fyne app that uses the following torrent library:
github.com/anacrolix/torrent
Yet after and running it the app stops.
Even though normaly --tags=disable_libutp should have fixed the torrent library "github.com/anacrolix/torrent" it does not. This means that fyne cross do not propagate tags when cross building.
Note this bug is similar to the one discribed here;
fyne-io/fyne#3641
To Reproduce:
create a new go mod
go mod init fynetorrentguiapp
go get fyne.io/fyne/v2
go get github.com/anacrolix/torrent
touch main.go
add the example code include below
package the app with fyne cross as follow:
sudo ./fc windows -arch=* -app-id=fynetorrentapp.app.testapp -icon=./Icon.png --tags=disable_libutp
run it on windows.
Example code:
'''go
package main
import (
"log"
"fyne.io/fyne/v2"
"fyne.io/fyne/v2/app"
"fyne.io/fyne/v2/widget"
"fyne.io/fyne/v2/container"
"fyne.io/fyne/v2/data/binding"
"fyne.io/fyne/v2/canvas"
"image/color"
"time"
"fmt"
"github.com/anacrolix/torrent"
)
var mainapp fyne.App
var AppLocation string
var MainTorrent string//magnet
var MainFile string//filepath
var AppIsClosing bool
func main() {
mainapp= app.New()
AppIsClosing=false
AppLocation=mainapp.Storage().RootURI().String()
fmt.Println("AppLocation :",AppLocation)
mainwin := mainapp.NewWindow("wetorrent")
mainwin.Resize(fyne.NewSize(400, 710))
go initmainclient()
tabs := container.NewAppTabs(
container.NewTabItem("Home", homeScreen(mainwin)),
)
tabs.SetTabLocation(container.TabLocationTop)
mainwin.SetContent(tabs)
mainwin.ShowAndRun()
AppIsClosing=true
}
func homeScreen(win fyne.Window) fyne.CanvasObject {
data := binding.BindStringList(
//&[]string{"Item 1", "Item 2", "Item 3"},
&[]string{},
)
list := widget.NewListWithData(data,
func() fyne.CanvasObject {
return widget.NewLabel("template")
},
func(i binding.DataItem, o fyne.CanvasObject) {
o.(*widget.Label).Bind(i.(binding.String))
})
text := canvas.NewText("Text Object"+AppLocation, color.Black)
add := widget.NewButton("Open New Webapp Tab", func() {
//val := fmt.Sprintf("Item %d", data.Length()+1)
//data.Append(val)
fmt.Println("coool")
})
return container.NewBorder( text,add, nil, nil, list)
}
var mainclient * torrent.Client
func initmainclient() {
cfg := torrent.NewDefaultClientConfig()
//cfg.Seed = true
cfg.DataDir=AppLocation//
//cfg.NoDHT = true
//cfg.DisableTCP = true
//cfg.DisableUTP = true
//cfg.DisableAggressiveUpload = false
//cfg.DisableWebtorrent = false
//cfg.DisableWebseeds = false
var err error
mainclient, err = torrent.NewClient(cfg)
if err != nil {
log.Print("new torrent client: %w", err)
return //fmt.Errorf("new torrent client: %w", err)
}
log.Print("new torrent client INITIATED")
defer mainclient.Close()
for {
if AppIsClosing {
log.Print("closing mainclient")
break
}
time.Sleep(1 * time.Second)
}
//
}
''''
Device and debug info (please complete the following information):
Fyne version
v2.3.0
Go compiler version
go1.20 linux/amd64
Operating system
Linux
Operating system version
Ubuntu 18.04.6 LTS (Bionic Beaver)
Additional Information
Go module info
cli_version="(devel)"
go_mod="true"
go_path="false"
imported="true"
path="***********"
version="v2.3.0"
Go version info
version="go1.20 linux/amd64"
Go environment info
CGO_ENABLED="1"
GO111MODULE=""
GOARCH="amd64"
GOOS="linux"
OS info
architecture="x86_64"
home_url="https://www.ubuntu.com/"
kernel="Linux 5.4.0-137-generic #154~18.04.1-Ubuntu SMP Tue Jan 10 16:58:20 UTC 2023"
name="Ubuntu"
version="18.04.6 LTS (Bionic Beaver)"
The text was updated successfully, but these errors were encountered: