Fehler beim Kompilieren



  • Programmiere gerade etwas OpenGL.

    g++ *.cpp glut32.lib -lopengl32 -lglu32
    

    Funktioniert alles soweit. Möchte jetzt ein spiel, dass den glm loader benutzt kompilieren.

    Das problem ist, dass ich dann folgende fehler bekomme:

    Warning: resolving ___glutInitWithExit by linking to ___glutInitWithExit@12
    Warning: resolving __imp__glEnable by linking to __imp__glEnable@4
    Warning: resolving __imp__glDisable by linking to __imp__glDisable@4
    Warning: resolving __imp__glTexEnvf by linking to __imp__glTexEnvf@12
    Warning: resolving __imp__glMaterialfv by linking to __imp__glMaterialfv@12
    Warning: resolving __imp__glBindTexture by linking to __imp__glBindTexture@8
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x48ca): undefined r
    eference to `_imp__glDeleteTextures'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5c74): undefined r
    eference to `_imp__glMaterialf'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5ce2): undefined r
    eference to `_imp__glColor3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5cf0): undefined r
    eference to `_imp__glBegin'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5d66): undefined r
    eference to `_imp__glNormal3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5d93): undefined r
    eference to `_imp__glNormal3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5dbb): undefined r
    eference to `_imp__glTexCoord2fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5ddb): undefined r
    eference to `_imp__glVertex3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5e08): undefined r
    eference to `_imp__glNormal3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5e30): undefined r
    eference to `_imp__glTexCoord2fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5e51): undefined r
    eference to `_imp__glVertex3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5e7e): undefined r
    eference to `_imp__glNormal3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5ea6): undefined r
    eference to `_imp__glTexCoord2fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5ec7): undefined r
    eference to `_imp__glVertex3fv'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5ed9): undefined r
    eference to `_imp__glEnd'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5f06): undefined r
    eference to `_imp__glGenLists'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5f1e): undefined r
    eference to `_imp__glNewList'
    C:\Users\chris\AppData\Local\Temp/cc3Frolz.o:glm.cpp:(.text+0x5f37): undefined r
    eference to `_imp__glEndList'
    collect2: ld returned 1 exit status
    

    ich verstehe einfach nicht warum NUR in der "glm.cpp" die ganzen gl-Befehle aufeinmal zu fehlern führen. in dne anderen dateien funktioniren die gl-befehle doch noch...

    das problem scheinen auch andere zu haben, aber hab leider noch keine antwort gefunden.
    http://translate.google.de/translate?js=n&prev=_t&hl=de&ie=UTF-8&layout=2&eotf=1&sl=fr&tl=de&u=http%3A%2F%2Fforum.hardware.fr%2Fhfr%2FProgrammation%2FC-2%2Fquel-librairie-wavefront-sujet_49251_1.htm


Anmelden zum Antworten