comp.lang.ada
 help / color / mirror / Atom feed
* openglada build problem.
@ 2014-07-26 22:23 pincerfae
  2014-07-27  7:16 ` Dmitry A. Kazakov
  0 siblings, 1 reply; 12+ messages in thread
From: pincerfae @ 2014-07-26 22:23 UTC (permalink / raw)


I hate to be a bother, but I'm having issues with the openglada bindings.

I do everything right via the gprbuild option, as instructed in the readme.

The problem I have is when I try to build and run the included examples.

gnatmake -d -PC:\openglada\glfw_test.gpr -XGLFW_Version=2 -XLIBRARY_TYPE=static -XAuto_Exceptions=enabled -XMode=debug -XWindowing_System=windows
gnatbind -x C:\openglada\obj\glfw_test-display.ali
gnatlink C:\openglada\obj\glfw_test-display.ali -g C:\openglada\lib\libGlfwAda.a C:\openglada\lib\libOpenGLAda.a -lglfw -lwinmm -lgdi32 -lOpenGL32 -lGdi32 -o C:\openglada\bin\glfw_test-display.exe
c:/gnat/2014/bin/../libexec/gcc/i686-pc-mingw32/4.7.4/ld.exe: cannot find -lglfw
collect2.exe: error: ld returned 1 exit status
gnatlink: error when calling C:\GNAT\2014\bin\gcc.exe
gnatmake: *** link failed.

this is run within GNAT GPS..
what am I doing wrong?

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-26 22:23 openglada build problem pincerfae
@ 2014-07-27  7:16 ` Dmitry A. Kazakov
  2014-07-27 21:12   ` pincerfae
  0 siblings, 1 reply; 12+ messages in thread
From: Dmitry A. Kazakov @ 2014-07-27  7:16 UTC (permalink / raw)


On Sat, 26 Jul 2014 15:23:09 -0700 (PDT), pincerfae@gmail.com wrote:

> I hate to be a bother, but I'm having issues with the openglada bindings.
> 
> I do everything right via the gprbuild option, as instructed in the readme.
> 
> The problem I have is when I try to build and run the included examples.
[...]
> gnatlink C:\openglada\obj\glfw_test-display.ali -g C:\openglada\lib\libGlfwAda.a C:\openglada\lib\libOpenGLAda.a -lglfw
> c:/gnat/2014/bin/../libexec/gcc/i686-pc-mingw32/4.7.4/ld.exe: cannot find -lglfw

libglfw.a missing?

> this is run within GNAT GPS..
> what am I doing wrong?

GLFW is not standard Windows GL, AFAIK. You must install it and its 
libraries first.

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-27  7:16 ` Dmitry A. Kazakov
@ 2014-07-27 21:12   ` pincerfae
  2014-07-27 21:20     ` Nasser M. Abbasi
                       ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: pincerfae @ 2014-07-27 21:12 UTC (permalink / raw)


On Sunday, July 27, 2014 12:16:34 AM UTC-7, Dmitry A. Kazakov wrote:
> On Sat, 26 Jul 2014 15:23:09 -0700 (PDT), pincerfae@gmail.com wrote:
> 
> 
> 
> > I hate to be a bother, but I'm having issues with the openglada bindings.
> 
> > 
> 
> > I do everything right via the gprbuild option, as instructed in the readme.
> 
> > 
> 
> > The problem I have is when I try to build and run the included examples.
> 
> [...]
> 
> > gnatlink C:\openglada\obj\glfw_test-display.ali -g C:\openglada\lib\libGlfwAda.a C:\openglada\lib\libOpenGLAda.a -lglfw
> 
> > c:/gnat/2014/bin/../libexec/gcc/i686-pc-mingw32/4.7.4/ld.exe: cannot find -lglfw
> 
> 
> 
> libglfw.a missing?
> 
> 
> 
> > this is run within GNAT GPS..
> 
> > what am I doing wrong?
> 
> 
> 
> GLFW is not standard Windows GL, AFAIK. You must install it and its 
> 
> libraries first.
> 
> 
> 
> -- 
> 
> Regards,
> 
> Dmitry A. Kazakov
> 
> http://www.dmitry-kazakov.de

and just how do I go about doing that?
I've all but given up on trying to get gl-ANYTHING to work with ada.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-27 21:12   ` pincerfae
@ 2014-07-27 21:20     ` Nasser M. Abbasi
  2014-07-27 22:13     ` Simon Wright
  2014-07-28  3:46     ` Luke A. Guest
  2 siblings, 0 replies; 12+ messages in thread
From: Nasser M. Abbasi @ 2014-07-27 21:20 UTC (permalink / raw)


On 7/27/2014 4:12 PM, pincerfae@gmail.com wrote:

>
> and just how do I go about doing that?
> I've all but given up on trying to get gl-ANYTHING to work with ada.
>

I've not tried openGL with Ada. But if you can't get it to build,
and want to try Fortran instead, then I have detailed instructions
how to build fortran with openGL and examples build statically that
you can download and run on linux as is. It took one 10 days of
full-time work to figure how to build Fortran with open-GL. It
is not easy, since openGL comes with many libraries and many dependencies.

This was all on Linux. On windows, no way I will even try this. Linux
is much easier to build software on.

--Nasser


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-27 21:12   ` pincerfae
  2014-07-27 21:20     ` Nasser M. Abbasi
@ 2014-07-27 22:13     ` Simon Wright
  2014-07-27 22:36       ` Nasser M. Abbasi
  2014-07-28  3:46     ` Luke A. Guest
  2 siblings, 1 reply; 12+ messages in thread
From: Simon Wright @ 2014-07-27 22:13 UTC (permalink / raw)


pincerfae@gmail.com writes:

> On Sunday, July 27, 2014 12:16:34 AM UTC-7, Dmitry A. Kazakov wrote:
>> GLFW is not standard Windows GL, AFAIK. You must install it and its 
>> libraries first.
>
> and just how do I go about doing that?
> I've all but given up on trying to get gl-ANYTHING to work with ada.

It is a shame that the openglada demo programs depend on other
libraries.

http://flyx.github.io/OpenGLAda/ (just above the "Getting the Code"
heading) has links to GLFW, SOIL snd FTGL.At least
http://www.glfw.org/download.html contains links to Windows binaries.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-27 22:13     ` Simon Wright
@ 2014-07-27 22:36       ` Nasser M. Abbasi
  2014-07-28  2:48         ` pincerfae
  0 siblings, 1 reply; 12+ messages in thread
From: Nasser M. Abbasi @ 2014-07-27 22:36 UTC (permalink / raw)


On 7/27/2014 5:13 PM, Simon Wright wrote:

> It is a shame that the openglada demo programs depend on other
> libraries.
>
> http://flyx.github.io/OpenGLAda/ (just above the "Getting the Code"
> heading) has links to GLFW, SOIL snd FTGL.At least
> http://www.glfw.org/download.html contains links to Windows binaries.
>

A static build version could be provided, so user do not have to install
many other things to make the demo program even run. This is what I did with
the Fortran openGL. Yes, the demos are much larger in size now, but
it is only one file. Download and run. It includes inside it all
the libraries needed linked in statically.

Having to download many other libraries just to see a demo program,
will discourage people from even trying it.

--Nasser


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-27 22:36       ` Nasser M. Abbasi
@ 2014-07-28  2:48         ` pincerfae
  0 siblings, 0 replies; 12+ messages in thread
From: pincerfae @ 2014-07-28  2:48 UTC (permalink / raw)


On Sunday, July 27, 2014 3:36:18 PM UTC-7, Nasser M. Abbasi wrote:
> On 7/27/2014 5:13 PM, Simon Wright wrote:
> 
> 
> 
> > It is a shame that the openglada demo programs depend on other
> 
> > libraries.
> 
> >
> 
> > http://flyx.github.io/OpenGLAda/ (just above the "Getting the Code"
> 
> > heading) has links to GLFW, SOIL snd FTGL.At least
> 
> > http://www.glfw.org/download.html contains links to Windows binaries.
> 
> >
> 
> 
> 
> A static build version could be provided, so user do not have to install
> 
> many other things to make the demo program even run. This is what I did with
> 
> the Fortran openGL. Yes, the demos are much larger in size now, but
> 
> it is only one file. Download and run. It includes inside it all
> 
> the libraries needed linked in statically.
> 
> 
> 
> Having to download many other libraries just to see a demo program,
> 
> will discourage people from even trying it.
> 
> 
> 
> --Nasser

well said, nasser.
I like learning ada, a lot. but this whole patchwork of getting anything to work is very discouraging.
delphi/pascal and opengl isn't much better, as I've found.


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-27 21:12   ` pincerfae
  2014-07-27 21:20     ` Nasser M. Abbasi
  2014-07-27 22:13     ` Simon Wright
@ 2014-07-28  3:46     ` Luke A. Guest
  2014-07-28 17:58       ` pincerfae
                         ` (2 more replies)
  2 siblings, 3 replies; 12+ messages in thread
From: Luke A. Guest @ 2014-07-28  3:46 UTC (permalink / raw)


<
> and just how do I go about doing that?
> I've all but given up on trying to get gl-ANYTHING to work with ada.

I'm sorry but it's seriously not difficult if you know how to use the
tools. You need to look at he gnat options. This is not m$'s c++ IDE where
everything is done for you.

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-28  3:46     ` Luke A. Guest
@ 2014-07-28 17:58       ` pincerfae
  2014-07-28 18:30       ` pincerfae
  2014-07-29  1:05       ` pincerfae
  2 siblings, 0 replies; 12+ messages in thread
From: pincerfae @ 2014-07-28 17:58 UTC (permalink / raw)


On Sunday, July 27, 2014 8:46:14 PM UTC-7, Luke A. Guest wrote:
> <
> 
> > and just how do I go about doing that?
> 
> > I've all but given up on trying to get gl-ANYTHING to work with ada.
> 
> 
> 
> I'm sorry but it's seriously not difficult if you know how to use the
> 
> tools. You need to look at he gnat options. This is not m$'s c++ IDE where
> 
> everything is done for you.

and WHERE did I mention anything about C/C++? Oh wait, I didn't, did I?
lose the goddamned attitude. 



I downloaded the glfw, with no clue on where to install the files, because there's NO INSTRUCTIONS on where to put them.
This has been my problem. I view the readme for every opengl binding I've downloaded (as there are only three), and I still get error messages about 'missing -lgfw'. WHEN I AM ACTUALLY USING THE GNAT COMPILER...

The main issue I am seeing (and have been seeing for quite a while), is that a lot of these so-called bindings seem to be written and packaged for people running *nix systems, and not windows (WHICH IS WHAT I'M USING).






^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-28  3:46     ` Luke A. Guest
  2014-07-28 17:58       ` pincerfae
@ 2014-07-28 18:30       ` pincerfae
  2014-07-29  1:05       ` pincerfae
  2 siblings, 0 replies; 12+ messages in thread
From: pincerfae @ 2014-07-28 18:30 UTC (permalink / raw)



> I'm sorry but it's seriously not difficult if you know how to use the
> 
> tools. You need to look at he gnat options. This is not m$'s c++ IDE where
> 
> everything is done for you.


until you can say something that'll actually help me towards resolving this problem, refrain from saying anything further.


I downloaded glfw after receiving the -lglfw not found message when trying to gprbuild in msys.
nothing from the examples will build (which obviously includes using GNAT/GPS(DUH!), because it's missing glfw.

The problem is there lacks any specifics on where to put the contents of glfw or where to add it as a reference to solve this problem.

it was mentioned before, that Ada seems to favour anything that's NOT a Windows OS.

There should be a disclaimer. You can use Ada with OpenGL as long as it's not using a Windows OS.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-28  3:46     ` Luke A. Guest
  2014-07-28 17:58       ` pincerfae
  2014-07-28 18:30       ` pincerfae
@ 2014-07-29  1:05       ` pincerfae
  2014-07-29  8:12         ` Dmitry A. Kazakov
  2 siblings, 1 reply; 12+ messages in thread
From: pincerfae @ 2014-07-29  1:05 UTC (permalink / raw)


On Sunday, July 27, 2014 8:46:14 PM UTC-7, Luke A. Guest wrote:
> <
> 
> > and just how do I go about doing that?
> 
> > I've all but given up on trying to get gl-ANYTHING to work with ada.
> 
> 
> 
> I'm sorry but it's seriously not difficult if you know how to use the
> 
> tools. You need to look at he gnat options. This is not m$'s c++ IDE where
> 
> everything is done for you.

If you have nothing helpful to offer, MOVE ON...


I am fed up of seeing this meessage every time I want to see ANY examples in felix krause's opengl binding.

gnatmake -d -PC:\openglada\glfw_test.gpr -XGLFW_Version=2 -XLIBRARY_TYPE=static -XAuto_Exceptions=enabled -XMode=debug -XWindowing_System=windows glfw_test-display.adb -j2
gnatbind -x C:\openglada\obj\glfw_test-display.ali
gnatlink C:\openglada\obj\glfw_test-display.ali -g C:\openglada\lib\libGlfwAda.a C:\openglada\lib\libOpenGLAda.a -lglfw -lwinmm -lgdi32 -lOpenGL32 -lGdi32 -o C:\openglada\bin\glfw_test-display.exe
c:/gnat/2014/bin/../libexec/gcc/i686-pc-mingw32/4.7.4/ld.exe: cannot find -lglfw
collect2.exe: error: ld returned 1 exit status
gnatlink: error when calling C:\GNAT\2014\bin\gcc.exe
gnatmake: *** link failed.

all this just to be able to view an example of a binding. unacceptable.

glfw is on my drive. according to 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: openglada build problem.
  2014-07-29  1:05       ` pincerfae
@ 2014-07-29  8:12         ` Dmitry A. Kazakov
  0 siblings, 0 replies; 12+ messages in thread
From: Dmitry A. Kazakov @ 2014-07-29  8:12 UTC (permalink / raw)


On Mon, 28 Jul 2014 18:05:16 -0700 (PDT), pincerfae@gmail.com wrote:

> all this just to be able to view an example of a binding. unacceptable.

Binding cannot install things they are bound to.

> glfw is on my drive. according to

But you need a [static/import] *library* of.

The library must be located on the library path used by the gcc and so
ultimately by GNAT. This has little to do with Ada or bindings. If you
don't have it on the path you must ensure that the gcc switch
-L<library-path> appears *before* -lglfw. There are dozens different way to
achieve linking to a certain library. Sorry for repeating but this is a
routine when working with gcc.

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2014-07-29  8:12 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-26 22:23 openglada build problem pincerfae
2014-07-27  7:16 ` Dmitry A. Kazakov
2014-07-27 21:12   ` pincerfae
2014-07-27 21:20     ` Nasser M. Abbasi
2014-07-27 22:13     ` Simon Wright
2014-07-27 22:36       ` Nasser M. Abbasi
2014-07-28  2:48         ` pincerfae
2014-07-28  3:46     ` Luke A. Guest
2014-07-28 17:58       ` pincerfae
2014-07-28 18:30       ` pincerfae
2014-07-29  1:05       ` pincerfae
2014-07-29  8:12         ` Dmitry A. Kazakov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox