Note that there are some explanatory texts on larger screens.

plurals
  1. POCompiling a Derelict program (D)
    primarykey
    data
    text
    <p>I've spent hours trying to do this with no success, so I'm here now.</p> <p>I'm trying to compile <a href="http://bloutiouf.blogspot.com/2011/08/introducing-shaders-in-d.html" rel="nofollow">this (click)</a> program to test my Derelict installation with no success.</p> <p>I'm using the Arch Linux distribution. I've been trying with multiple command lines and different DMD2 (and GDC) packages from the AUR (community managed repository). I also tried installing Derelict by either DSSS or from the AUR.</p> <p>One command line option is:</p> <pre><code>gdc -I/usr/include/d2/ -L -ldl -L -lDerelictGL -L -lDerelictGLUL -L -lDerelictSDL -L -lDerelictUtil *.d -ofexample </code></pre> <p>and another:</p> <pre><code>dmd2 -I/usr/include/d2 main </code></pre> <p>They both throw a plethora of ugly linker errors (different each).</p> <p>The directories where the supposedly correct files are are:</p> <pre><code>libraries: /usr/lib/libDerelict*.a "headers": /usr/include/d2/derelict/&lt;folders of modules&gt; </code></pre> <p>I'll be glad to supply you with any kind of additional information.</p> <p>Thank you,<br> Nanthiel</p> <p><strong>EDIT</strong></p> <p>When I run this:</p> <pre><code>dmd -I/usr/include/d2 main.d Display.d -ofexample -L-lDerelictGL -L-lDerelictGLU -L-lDerelictSDL -L-lDerelictUtil -L-ldl </code></pre> <p>it works. However, only with GDC. Not with DMD2. I don't know why.</p> <p>GDC versions: GCC (4.5.1) gdc (0.30) dmd (2.056) DMD2 version: I don't know how to get it. :/ But it should be the newest one, as it's from git.</p> <p>Also, Derelict wants Open GL 3.0 support for custom shaders, when 2.0 should be enough. =/</p> <p><strong>EDIT 2</strong></p> <p>Here are the linker errors, sorry for the slow update.</p> <pre><code> dmd -I/usr/include/d2 main.d Display.d -ofexample -L-lDerelictGL -L-lDerelictGLU -L-lDerelictSDL -L-lDerelictUtil -L-ldl /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(gl.o): In function `_D8derelict6opengl2gl16DerelictGLLoader17getExtensionStateMFAyaZE8derelict6opengl7gltypes16GLExtensionState': (.text+0x38f9): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(gl.o): In function `_D8derelict6opengl2gl16DerelictGLLoader17isExtensionLoadedMFAyaZb': (.text+0x395d): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(gl.o): In function `_D8derelict6opengl2gl16DerelictGLLoader20isExtensionSupportedMFAyaZb': (.text+0x39c9): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(gl.o): In function `_D8derelict6opengl2gl16DerelictGLLoader14loadExtensionsMFZv': (.text+0x3a6d): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(gl.o): In function `_D8derelict6opengl2gl16DerelictGLLoader18loadModernVersionsMFE8derelict6opengl2gl9GLVersionZE8derelict6opengl2gl9GLVersion': (.text+0x3de0): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(gl.o):(.text+0x4889): more undefined references to `_d_throw' follow /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D6object70__T16AssociativeArrayTAyaTE8derelict6opengl7gltypes16GLExtensionStateZ16AssociativeArray3dupMFNdZHAyaE8derelict6opengl7gltypes16GLExtensionState17__foreachbody1277MFKAyaKE8derelict6opengl7gltypes16GLExtensionStateZi': (.text+0x5b): undefined reference to `_aaGetp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader23getLoadedExtensionNamesFZAAya': (.text+0x149): undefined reference to `_aaGetRvaluep' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader23getLoadedExtensionNamesFZAAya': (.text+0x180): undefined reference to `_d_arrayappendcTp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader26getNotLoadedExtensionNamesFZAAya': (.text+0x298): undefined reference to `_d_arrayappendcTp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader26getNotLoadedExtensionNamesFZAAya': (.text+0x2ee): undefined reference to `_aaGetRvaluep' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader26getNotLoadedExtensionNamesFZAAya': (.text+0x35c): undefined reference to `_d_arrayappendcTp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader11extGetStateFAyaZE8derelict6opengl7gltypes16GLExtensionState': (.text+0x46f): undefined reference to `_aaInp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader13extLoadCommonFZv': (.text+0x126f2): undefined reference to `_aaGetp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader13extLoadCommonFZv': (.text+0x1272d): undefined reference to `_aaGetp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader13extLoadCommonFZv': (.text+0x12780): undefined reference to `_aaGetp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader13extLoadCommonFZv': (.text+0x127f4): undefined reference to `_aaGetp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D8derelict6opengl9extloader13extLoadCommonFZv': (.text+0x12840): undefined reference to `_aaGetp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o):(.text+0x1288c): more undefined references to `_aaGetp' follow /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictGL.a(extloader.o): In function `_D6object70__T16AssociativeArrayTAyaTE8derelict6opengl7gltypes16GLExtensionStateZ16AssociativeArray3getMFAyaLE8derelict6opengl7gltypes16GLExtensionStateZE8derelict6opengl7gltypes16GLExtensionState': (.text._D6object70__T16AssociativeArrayTAyaTE8derelict6opengl7gltypes16GLExtensionStateZ16AssociativeArray3getMFAyaLE8derelict6opengl7gltypes16GLExtensionStateZE8derelict6opengl7gltypes16GLExtensionState[_D6object70__T16AssociativeArrayTAyaTE8derelict6opengl7gltypes16GLExtensionStateZ16AssociativeArray3getMFAyaLE8derelict6opengl7gltypes16GLExtensionStateZE8derelict6opengl7gltypes16GLExtensionState]+0x2a): undefined reference to `_aaInp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictUtil.a(exception.o): In function `_D8derelict4util9exception22SharedLibLoadException8throwNewFxAAaxAAaZv': (.text+0x1fe): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictUtil.a(exception.o): In function `_D8derelict4util9exception28Derelict_HandleMissingSymbolFAyaAyaZv': (.text+0x4e2): undefined reference to `_d_throw' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictUtil.a(sharedlib.o): In function `_D8derelict4util9sharedlib9SharedLib4loadMFAAyaZv': (.text+0x176): undefined reference to `_d_arrayappendcTp' /usr/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libDerelictUtil.a(sharedlib.o): In function `_D8derelict4util9sharedlib9SharedLib4loadMFAAyaZv': (.text+0x1d8): undefined reference to `_d_arrayappendcTp' collect2: ld returned 1 exit status --- errorlevel 1 </code></pre> <p><strong>EDIT 3</strong></p> <p>I tried re-installing everything (checked Derelict2 out from SVN, reinstalled DMD2, the <code>dmd2-complete</code> package from the AUR) and recompiled Derelict2 again this time using DMD2. It worked. And it also all compiles well now! I don't know what was going on.</p> <p>If anyone could tell me, what is the procedure of marking this as "solved" or something, now?</p> <p>Thank you,<br> Nanthiel</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload