Thread overview
How to bundle a GtkD application for Windows
Nov 29, 2020
adnan449
Nov 29, 2020
adnan449
Nov 29, 2020
Jack
Dec 01, 2020
Ferhat Kurtulmuş
November 29, 2020
Hello, I would be greatly thankful if I was given an easy guide on how to produce windows executables for GtkD applications. I do not have an access to a windows machine but I need to be able to produce installers/exe files for the windows users.

Users should not have to install any dependency manually to be able to install my program.
Thank you.
November 29, 2020
On Sunday, 29 November 2020 at 20:08:33 UTC, adnan449 wrote:
> Hello, I would be greatly thankful if I was given an easy guide on how to produce windows executables for GtkD applications. I do not have an access to a windows machine but I need to be able to produce installers/exe files for the windows users.
>
> Users should not have to install any dependency manually to be able to install my program.
> Thank you.

To be more clear, my development platform is x86-linux-gnu and my app depends on libgtk-3-dev and sqlite3.
November 29, 2020
On Sunday, 29 November 2020 at 20:08:33 UTC, adnan449 wrote:
> Hello, I would be greatly thankful if I was given an easy guide on how to produce windows executables for GtkD applications. I do not have an access to a windows machine but I need to be able to produce installers/exe files for the windows users.
>
> Users should not have to install any dependency manually to be able to install my program.
> Thank you.

To produce such executable on windows check out this[1]. To make a installer, you need to find the dll files that the executable depend on,I'm trying to do excactly this[2], in order to deploy an application without the user need to install the Gtk+ runtime. I believe just copying those dlls to application's folder will work. It seems for themes and stuff you need something more but I'm not there yet.

[1]: https://github.com/gtkd-developers/GtkD/wiki/Installing-on-Windows
[2]: https://forum.dlang.org/post/vhmwtetoqtstgmlcvsga@forum.dlang.org
December 01, 2020
On Sunday, 29 November 2020 at 20:08:33 UTC, adnan449 wrote:
> Hello, I would be greatly thankful if I was given an easy guide on how to produce windows executables for GtkD applications. I do not have an access to a windows machine but I need to be able to produce installers/exe files for the windows users.
>
> Users should not have to install any dependency manually to be able to install my program.
> Thank you.

A useful tip.

Assuming one has a list of dependent dlls.

https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer

The subfolder gtk-nsis-pack contains a required folder structure if you want to use theme support etc. Simply put your gtkd exe in the bin folder. You can remove redundant dlls from the bin folder to obtain a minimal bundle for your program. The NSIS project structure may also help to create an installer for your program.