Skip to content

Problems compiling examples

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #1879
    takamori67
    Member

    Hello everyone,
    I am new to OpenLB and not very experienced with coding.
    I successfully compiled the software library and examples. But when I tried to compile the cylinder2d example(after changing the ROOT in the Makefile to the examples/cylinder2d directory), it showed this message on the console:
    make[1]: Entering directory `/rwthfs/rz/cluster/home/sg490830/Desktop/olb/examples/cylinder2d’
    make[2]: Entering directory `/rwthfs/rz/cluster/home/sg490830/Desktop/olb/examples/cylinder2d’
    make[3]: Entering directory `/rwthfs/rz/cluster/home/sg490830/Desktop/olb/examples/cylinder2d’
    … and so on several thousand times until the memory was full. I tried several times, changed some parameters in the Makefile.inc, but nothing seems to work. During the compilation, cylinder2d.o and cylinder2d.d were created, but not any executable.
    I am using a Linux Sytem.

    I probably made some easy mistake, and would really appreciate your help. I always copied the Makefile.inc into the example directory, because otherwise, it would say that it couldn’t find the makefile.inc. Also, is it correct to change the ROOT:= to the example directory? And what about the SRC:= , I always leave it blank?

    Thanks in advance,
    Sumit

    #2483
    mathias
    Keymaster

    Just leave ROOT unchaned. Best Mathias

    #2484
    takamori67
    Member

    Dear Mathias, thank you for your quick reply.
    When I leave the Makefile unchanged and try to compile, this happens:

    Create dependencies for cylinder2d.cpp
    Compile cylinder2d.cpp
    g++ -DOLB_PRECOMPILED -O3 -Wall -std=c++0x -I../../src -I../../src/ -I../../src/external -c cylinder2d.cpp -o /home/sg490830/Desktop/olb/examples/cylinder2d/cylinder2d.o
    make[1]: Entering directory `/rwthfs/rz/cluster/home/sg490830/Desktop/olb’
    make[1]: *** Keine Regel, um »all« zu erstellen. Schluss.
    make[1]: Leaving directory `/rwthfs/rz/cluster/home/sg490830/Desktop/olb’
    make: *** [updatelib] Fehler 2

    #2485
    mathias
    Keymaster

    Dear takamori,

    Did you install a g++ compiler? Which g++ version do you have? Please, try with a fresh downloaded version. We did not have any problems compiling on Linux systems so far.
    Further, as you are a beginner, we strongly recomment you to come to our spring school next March which would give you a good start!

    Best
    Mathias

    #2486
    takamori67
    Member

    After updating my g++ the example is working. Thanks a lot!
    I will look into it.

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.