Results 1 to 2 of 2

Thread: Undefined Reference Error Message

  1. #1
    Junior Member Newbie
    Join Date
    Jul 2009

    Undefined Reference Error Message

    I've just started working with OpenGL, I use Dev C++ compiler,
    I installed OpenGL as follows:

    opengl32.dll,glu32.dll,gl32.dll>>>copied to System Dir
    glut.h,gl.h,glu.h>>>copied to include dir
    glu32.lib, opengl32.lib,glut32.lit >>>copied to lib directory

    As trying to run first example of red-book,"hello.cpp", I always face following error messages in Dev C++ compiler

    undefined reference to "__glutInitWithExit@12"

    It is notable that windows.h and glut.h are included.

    So, where is the problem?


  2. #2
    Senior Member Regular Contributor
    Join Date
    Jun 2009
    FL , USA

    Re: Undefined Reference Error Message

    Possibly the compiler is not getting the pointer to this function.
    I came across a post in this forum where they explain to get function pointers using some PFN... ( do not remember exactly).

    Or the lib file containing the signature is not included. Try project and compiler settings first.

Similar Threads

  1. Undefined reference error
    By SagoO in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 11-15-2010, 09:17 AM
  2. {Linker error} undefined reference to ...
    By jauhoy in forum OpenGL: Windows
    Replies: 3
    Last Post: 03-25-2009, 06:43 PM
  3. [Linker error] Undefined reference to 'gl***'
    By Anklebiter in forum OpenGL: Basic Coding
    Replies: 6
    Last Post: 01-19-2005, 09:47 AM
  4. Error!!! Undefined reference
    By just_started in forum OpenGL: Basic Coding
    Replies: 13
    Last Post: 07-31-2003, 08:38 AM
  5. [Linker error] undefined reference to ...
    By in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 12-29-2002, 01:13 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Proudly hosted by Digital Ocean