Simple BeamUI project won't link

Daren Scot Wilson darenw at darenscotwilson.com
Wed Dec 16 07:02:11 UTC 2020


Trying out the beamui GUI package, obtained by git clone from 
github.  The "basic" example builds and runs.

So I create a new project from scratch, with "dub init beamy 
beamui" (ircc) in a directory outside beamui's, sibling to it in 
fact.  This builds and runs, but does not make use of beamui at 
all. So I copy a tiny bit from the basic example. It only 
initializes a GuiApp:

import std.stdio;
import beamui;

     int main()
     {
         GuiApp app;
         if (!app.initialize())   {
             writeln("App no init :(");
             return 1;
         }
         return 0;
     }


Here's the dub file:


     name "beamy"
     description "trying BeamUI"
     license "none"
     authors "darenw"

     targetName "beamy"
     targetType "executable"

     dependency "beamui"  path="../../beamui/"
     dependency "beamui:platforms"  path="../../beamui/platforms/"

Running "dub build" leads to compiling but no linking.  undefined 
reference to `initPlatformProxy'.  Note that this build takes 
place in a directory such that ../../beamui/ goes to the 
top-level directory for beamui. Changing the path or replacing 
'beamui' with 'beamuixxx' prevents the build from getting 
anywhere at all, so the path is right.

I compared everything with the basic example, but am either 
missing some obvious detail or have something screwed up, or 
failed to add something, or need to say some secret magic 
incantation.

I'm working on an Arch Linux machine with lots of RAM, but a user 
with not enough practice at D yet.



More information about the Digitalmars-d-learn mailing list