Use the --app:gui option, the compiler error ld.exe: cannot find -lgdi32..-lcomdlg32
Fortunately, now resolved to get a positive reply --app:gui is very important.
Thank you very much
import iup
echo "imported iup"
var openRes = open(nil,nil)
echo("openRes=",openRes)
var lbl = label("Hello, World")
show(dialog(lbl))
mainLoop()
close()
compiled on an Ubunutu 14.04.3 LTS via the command:
nim c xyz.nim
where the iup library was /usr/lib/libiup.so and was obtained starting at:
it was version 3.15 which is kinda old now.
I was pleasantly surprised at how easy this was to do.
At some point I will need to do a static library link - anyone have an example of that? In go it required a fairly long specification of Linux libraries - something like:
/usr/lib/libiup.a -lgtk-3 -lgdk-3 -lglib-2.0 -lpangocairo-1.0 -lcairo -lgdk_pixbuf-2.0 -lpango-1.0 -lgobject-2.0 -lX11 -lc
yes, I know it is 2021 now as for "static library link", here ( https://github.com/nim-lang/iup/issues/5 ) is the answer: to use "--dynlibOverride:iup"
btw. it is strange why iup is not considered as an official gui lib for nim? I think iup has been time-proven since there are some applications are written by using iup; on the other hand https://github.com/andlabs/libui, which is the base of "ui, Beginnings of what might become Nim's official UI library", seems to be far from maturity.
btw. it is strange why iup is not considered as an official gui lib for nim?
It is not that strange as we have currently at least 20 GUI libs for Nim, so calling one the "official" is arbitrary.