Skip to content

windows-msi build error with docker, linux-deb build not working even though should be possible #546

Closed
go-flutter-desktop/hover
#184
@sidevesh

Description

@sidevesh

Looks like with the recent updates to hover, its not possible to compile for a platform from different host platform even with the --docker option.
Is that the case really ? I am trying to compile ubuntu and windows packages from macOS with the --docker option and I am getting the following output:

For linux-deb:

swapn@Swapnils-MacBook-Pro tomatoroapp % hover build linux-deb --docker
hover: AOT builds currently only work on their host OS

Also I changed the checks in code to allow running linux-deb packaging with docker option,
and on trying to build it, got the following error:

swapn@Swapnils-MacBook-Pro tomatoroapp % hover build linux-deb --docker
hover: Downloading engine for platform linux-release at version 5babba6c4d25fa237bbf755ab85c9a0c50b3c6ec...
Download completed in 45.03s
hover: Failed to strip /Users/swapn/Library/Caches/hover/engine/linux-release/libflutter_engine.so: exit status 1

For windows-msi:

swapn@Swapnils-MacBook-Pro tomatoroapp % hover build windows-msi --docker
hover: Using engine from cache
hover: Building using docker container
Running this docker command: /usr/local/bin/docker run --rm --mount type=bind,source=/Users/swapn/Documents/Projects/Tomatoro/tomatoroapp,target=/app --mount type=bind,source=/Users/swapn/Library/Caches/hover/engine,target=/root/.cache/hover/engine --mount type=bind,source=/Users/swapn/Library/Caches/hover/docker-go-cache,target=/go-cache --env GOCACHE=/go-cache --env HOVER_SAFE_CHOWN_UID=501 --env HOVER_SAFE_CHOWN_GID=20 --env GOPROXY=https://proxy.golang.org,direct
 --env GOPRIVATE=
 goflutter/hover:latest hover-safe.sh build windows-msi --skip-engine-download --version-number 1.0.20+24
docker container: docker: Error response from daemon: invalid mount config for type "bind": bind source path does not exist: /host_mnt/Users/swapn/Library/Caches/hover/engine.
docker container: See 'docker run --help'.
hover: Docker run failed: exit status 125

Building for linux from docker with macOS shhould be possible since docker on macOS runs inside linux VM.
Not sure why the error for windows-msi happens.

hover doctor output:

hover: Hover version (devel) running on darwin
hover: Sharing packaging tools
hover: darwin-bundle is supported
hover: darwin-dmg is supported
hover: darwin-pkg is supported
hover: Packaging linux-appimage is not supported on darwin
hover: To still package linux-appimage on darwin you need to run hover with the `--docker` flag.
hover: Packaging linux-deb is not supported on darwin
hover: To still package linux-deb on darwin you need to run hover with the `--docker` flag.
hover: Packaging linux-pkg is not supported on darwin
hover: To still package linux-pkg on darwin you need to run hover with the `--docker` flag.
hover: Packaging linux-rpm is not supported on darwin
hover: To still package linux-rpm on darwin you need to run hover with the `--docker` flag.
hover: Packaging linux-snap is not supported on darwin
hover: To still package linux-snap on darwin you need to run hover with the `--docker` flag.
hover: Packaging windows-msi is not supported on darwin
hover: To still package windows-msi on darwin you need to run hover with the `--docker` flag.
hover: 
hover: Sharing flutter version
Flutter 1.22.0 • channel unknown • unknown source
Framework • revision d408d302e2 (3 months ago) • 2020-09-29 11:49:17 -0700
Engine • revision 5babba6c4d
Tools • Dart 2.10.0
hover: Flutter engine commit: https://github.com/flutter/engine/commit/5babba6c4d25fa237bbf755ab85c9a0c50b3c6ec
hover: ⚠ The go-flutter project tries to stay compatible with the beta channel of Flutter.
hover: ⚠     It's advised to use the beta channel: `flutter channel beta`
hover: Finding out the C compiler version
Apple clang version 12.0.0 (clang-1200.0.32.2)
Target: x86_64-apple-darwin20.1.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
hover: Sharing the content of go.mod
module tomatoro/go

go 1.13

require (
        github.com/BestBurning/platform_device_id/go v0.1.1
        github.com/deckarep/gosx-notifier v0.0.0-20180201035817-e127226297fb // indirect
        github.com/go-flutter-desktop/go-flutter v0.42.0
        github.com/go-flutter-desktop/plugins/package_info v0.0.0-20200415181852-215d9c007301
        github.com/go-flutter-desktop/plugins/path_provider v0.3.3
        github.com/go-flutter-desktop/plugins/shared_preferences v0.4.3
        github.com/go-flutter-desktop/plugins/url_launcher v0.1.2
        github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1
        github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200707082815-5321531c36a2
        github.com/martinlindhe/notify v0.0.0-20181008203735-20632c9a275a
        github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d // indirect
        github.com/pkg/errors v0.9.1
        github.com/sidevesh/go-flutter-plugin-sqflite v0.0.0-20200718224941-b1ba30c6bdda
        gopkg.in/toast.v1 v1.0.0-20180812000517-0a84660828b2 // indirect
)
hover: Sharing the content of hover.yaml
application-name: Tomatoro
executable-name: ""
package-name: ""
license: UNLICENSED
target: lib/main_desktop.dart
branch: ""
cache-path: ""
opengl: ""
engine-version: ""
hover: Sharing the content of go/cmd
go/cmd/desktop_local_notifications.go   go/cmd/main.go  go/cmd/options.go       go/cmd/transparent_title_bar_darwin.go  go/cmd/transparent_title_bar_unsupported.go

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