Skip to content

Release builds #156

Closed
Closed
@arcticfox1919

Description

@arcticfox1919

I use the hover build command to generate a Windows executable, but there is a black console, how to publish a real program without a console.

Activity

GeertJohan

GeertJohan commented on Jun 9, 2019

@GeertJohan
Member

We don't have support for releases yet. For now, hover only builds a debug version of the app with a console to track logs. I'll keep this issue open to track support for release builds.

GeertJohan

GeertJohan commented on Jun 10, 2019

@GeertJohan
Member

Things that --release should do:

  • Build binary without console (windows: -ldflags -H=windowsgui).
    Building flutter bundle as --release.
    Setting the right VM arguments.
    Reduce the size of the share-lib from 88M to 28M by running strip -s ./libflutter_engine.so.
changed the title [-]How to release my app?[/-] [+]Hover build release[/+] on Jun 10, 2019
pinned this issue on Jun 10, 2019
changed the title [-]Hover build release[/-] [+]Release builds[/+] on Jun 10, 2019
erickzanardo

erickzanardo commented on Jun 21, 2019

@erickzanardo

I am really looking forward to this as well.

chengxuncc

chengxuncc commented on Jun 26, 2019

@chengxuncc

Can't wait to play with it.

alexelisenko

alexelisenko commented on Jun 26, 2019

@alexelisenko

@GeertJohan Any updates or ETA on this? If not, would you be able to provide any documentation on how to go about removing the console window manually for now? It would be greatly appreciated.

Thanks.

pchampio

pchampio commented on Jun 26, 2019

@pchampio
Member

Once my final exams are over, I'll like to take a look at release builds, (if it's not done by then).
For now, #135 provides enough information for you to hack this through.

$ # export CGO_LDFLAGS="-L$HOME/.cache/hover/engine/windows/" # Not working!
$ # set CGO_LDFLAGS="-L%HOMEPATH%/.cache/hover/engine/windows/" # also not working the dll isn't found
$ cd ./desktop/cmd
$ go build -ldflags="-L%HOMEPATH%/.cache/hover/engine/windows/" -H=windowsgui
$ mv cmd ../build/outputs/windows
$ ../build/outputs/windows/cmd # to start the app
alexelisenko

alexelisenko commented on Jun 26, 2019

@alexelisenko

@Drakirus Thanks for that. Im assuming its supposed to be set vs export for windows?

pchampio

pchampio commented on Jun 26, 2019

@pchampio
Member

Yup

alexelisenko

alexelisenko commented on Jun 26, 2019

@alexelisenko

Im getting the following error:

PS C:\Users\User\development\desktop-apps\flutter_project> set CGO_LDFLAGS="-L%HOMEPATH%/.cache/hover/engine/windows/"
PS C:\Users\User\development\desktop-apps\flutter_project> cd ./desktop/cmd
PS C:\Users\User\development\desktop-apps\flutter_project\desktop\cmd> go build -ldflags -H=windowsgui
# github.com/go-flutter-desktop/go-flutter/embedder
C:/Program Files/mingw-w64/x86_64-8.1.0-posix-seh-rt_v6-rev0/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/8.1.0/../../../../x86_64-w64-mingw32/bin/ld.exe: cannot find -lflutter_engine
collect2.exe: error: ld returned 1 exit status

34 remaining items

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @GeertJohan@erickzanardo@Tokenyet@pchampio@monkeyWie

        Issue actions

          Release builds · Issue #156 · go-flutter-desktop/go-flutter