1. EuGTK: Distributing Programs
- Posted by euphoric (admin) Apr 09, 2015
- 1743 views
irv, do you have any docs on what is needed to distribute a EuGTK program? Does the end-user need to install the GTK libs, or can they be packaged with my program?
2. Re: EuGTK: Distributing Programs
- Posted by ghaberek (admin) Apr 09, 2015
- 1768 views
irv, do you have any docs on what is needed to distribute a EuGTK program? Does the end-user need to install the GTK libs, or can they be packaged with my program?
I would advise against packaging the GTK binaries with your own. You're better off advising the end user which packages to install using the relevant package manager (e.g. apt-get install gtk+-2.0).
If you create a Debian package or an RPM package then you can specify the Depends (deb) or Requires (rpm) fields for the required GTK packages.
Taking that a step further, you could create your own Debian or Yum repository to host your packages. Then advise end users to add your repo and install your app via apt-get or yum.
The best part about a custom repo is that your end users will get updates automatically when you push them (assuming they run updates).
-Greg
3. Re: EuGTK: Distributing Programs
- Posted by euphoric (admin) Apr 09, 2015
- 1711 views
irv, do you have any docs on what is needed to distribute a EuGTK program? Does the end-user need to install the GTK libs, or can they be packaged with my program?
I would advise against packaging the GTK binaries with your own. You're better off advising the end user which packages to install using the relevant package manager (e.g. apt-get install gtk+-2.0).
Thanks for the info! I should have specified my users are primarily working in Windows. Same idea? Make the end-user install GTK? I don't like that option. As it is, I'm currently distributing my wxEuphoria program with the requisite DLLs all included. Seems easiest and most efficient.
4. Re: EuGTK: Distributing Programs
- Posted by ghaberek (admin) Apr 09, 2015
- 1754 views
I should have specified my users are primarily working in Windows.
Well shucks no. That changes the game entirely. Have a look here: Embedding GTK+.
Basically, your installer can contain and silently install the GTK+ package on its own.
If you're using Inno Setup, you can use the custom Run command.
I forget how to do this with NSIS but I'm sure it supports the same feature.
-Greg
5. Re: EuGTK: Distributing Programs
- Posted by andi49 Apr 09, 2015
- 1672 views
Thanks for the info! I should have specified my users are primarily working in Windows. Same idea? Make the end-user install GTK? I don't like that option. As it is, I'm currently distributing my wxEuphoria program with the requisite DLLs all included. Seems easiest and most efficient.
Hi
For Windows, using GTK is the worst thing you can do. Even Projects like 'The Gimp' or 'Geany' come with there own set off GTK dll's on Windows.
Maybe, it is okay for a big project like 'Gimp' or 'Geany' but not for small or medium sized project.
You will be doomed to provide a working set of GTK dll's with your project. GTK changes much too fast.
Just my point of view
Andreas
6. Re: EuGTK: Distributing Programs
- Posted by irv Apr 09, 2015
- 1688 views
The Embedded GTK site has GTK2 packages for Windows. GTK.org, on their downloads page, has GTK3, which is what EuGTK needs.
The GTK for Windows packages are pretty large, but installing them isn't too difficult, just unzip into C:/gtk, and then switch to the C:/gtk/bin directory and run 4 setup programs. All that could be done with a batch file.
EuGTK (better get the latest version) will find the dll's there.
If you want to package the entire set together with your program, you can weed out more than 90% of the GTK package, and include only the necessary dlls and the needed setup programs.
Edit: That said, although I've had pretty good luck running EuGTK on Windows, I wouldn't choose it for anything important just yet.
7. Re: EuGTK: Distributing Programs
- Posted by irv Apr 10, 2015
- 1695 views
I've updated EuGTK 4.9.4, it now has a 'plug-in' which allows you to use the GtkSourceView widget, which automatically detects source code languages (C, HTML, python, etc.. .and Euphoria!), colorizes them, etc.
Might be handy, since it only takes two or 3 lines of code to include this widget in your program.
8. Re: EuGTK: Distributing Programs
- Posted by irv Apr 11, 2015
- 1627 views
Just finishing up an accounting program built with EuGTK and Glade. The whole thing only needed about 600 lines of code, and was much easier to do than a similar job I did a few years ago with Visual Basic. - Which, if I recall, required more like thousands of lines of code.
Here's a screenshot: http://sites.google.com/site/euphoriagtk/acctg.png
Edit: this is, of course, running on Linux :)
Edit 2: interestingly enough, it runs fine on Windows, too!
9. Re: EuGTK: Distributing Programs
- Posted by petelomax Apr 11, 2015
- 1602 views
According to http://www.gtk.org/download/win32_contentlist.php it seems you will need 22 dlls and two directories.
(For some reason that link only works when you click on the "http" part.)
Fixed that for you. -Greg
10. Re: EuGTK: Distributing Programs
- Posted by irv Apr 11, 2015
- 1599 views
According to http://www.gtk.org/download/win32_contentlist.php it seems you will need 22 dlls and two directories.
(For some reason that link only works when you click on the "http" part.)
And here is a batch script for running the setup which locates fonts, image handlers, etc on Windows;
pkg-config --cflags gtk+-3.0 pango-querymodules > c:\gtk\etc\pango\pango.modules gdk-pixbuf-query-loaders > c:\gtk\lib\gdk-pixbuf-2.0\2.10.0\loaders.cache gtk-query-immodules-3.0 > c:\gtk\lib\gtk-3.0\3.0.0\immodules.cacheNote this assumes you've unpacked stuff into C:\gtk