首页 > 解决方案 > 如何在 ADA 中集成 GLUT 时解决“未定义的 glGetDoublev 引用”?使用的 IDE:GPS。我试图创建一个简单的窗口

问题描述

示例主代码:(main.adb)

    with GL;
    with GLUT;
    procedure Main is
       L_window_status : Integer;

    begin
       GLUT.Init;
       L_window_status:= GLUT.CreateWindow(Title => "PAV") ;
    end Main;

控制台错误消息:

gprbuild -d -PD:\Training\IPM\opengl.gpr
Bind
   [gprbind]      main.bexch
   [Ada]          main.ali
Link
   [link]         main.adb
c:/gnat/2019/bin/../libexec/gcc/x86_64-pc-mingw32/8.3.1/ld.exe: D:\Training\IPM\obj\GL.o:GL.adb:(.text+0x49a0): undefined reference to `glGetDoublev'
c:/gnat/2019/bin/../libexec/gcc/x86_64-pc-mingw32/8.3.1/ld.exe: D:\Training\IPM\obj\GL.o:GL.adb:(.text+0x49bb): undefined reference to `glGetString'

标签: openglada

解决方案


推荐阅读