Page 1 of 3 123 LastLast
Results 1 to 10 of 28

Thread: Makefile applications from Github won't run, open as text document

  1. #1
    Join Date
    May 2021
    Beans
    18

    Makefile applications from Github won't run, open as text document

    Hello,

    I'm a fairly new to Ubuntu and I am trying to run these 'DyanamicFoam' and 'TinyEngine' applications/makefiels that I downloaded from Github and are now located on my Desktop:




    TinyEngine is needed to run the DynamicFoam app, as mentioned in the DynamicFoam Readme:

    This system was built using TinyEngine. Install TinyEngine and then use the makefile to create an executable:

    make all


    In TinyEngine's Readme it says that it runs on Ubuntu 18 LTS

    So what I have done is bought a 2nd hand laptop:

    Lenovo Thinkpad X240 / i5-4300 CPU / 1.90Hz x 4
    Graphics Intel HD 4400
    8GB Memory

    I did an erase-install of Ubuntu 19.10 from a bootable USB stick, and an upgrade to version 20.04.

    Next I have installed via Terminal under Sudo -s all the dependencies listed near the end of TinyEninge's Readme:


    • OpenGL3: apt-get install libglu1-mesa-dev
    • SDL2: apt-get install libsdl2-dev libsdl2-ttf-dev libsdl2-mixer-dev libsdl2-image-dev
    • GLEW: apt-get install libglew-dev
    • Boost: apt-get install libboost-system-dev libboost-filesystem-dev
    • GLM: apt-get install libglm-dev
    • DearImGUI (already included!)
    • g++ (compiler)


    I also installed:


    • Homebrew
    • Make

    ------

    Now when I try to run the Makefiles in the TinyEngine-Master and DynamicFoam-main folders nothing happens, they just open as text-documents.

    Don't know how to solve this issue. Is it perhaps a problem with my Permissions, but I am logged in as the Root user, no? Or should I place these documents at an other location, such as 'lib' which I have tried. But I can't drag and drop them over there, and I couldn't find a solution how to move them over there.

    Any suggestions ... all help is welcome!

    Grtz,
    M.


    Attached:


    • System Overview
    • Versions read-out in Terminal of Make, g++ and Homebrew
    • Permission denied in Terminal when looking for the TinyEngine file
    • What I get when I click the makefiles that open as text docs.










    Last edited by michelvandegaer; May 16th, 2021 at 08:50 AM.

  2. #2
    Join Date
    Aug 2006
    Beans
    13,187
    Distro
    Ubuntu Mate 20.04 Focal Fossa

    Re: Makefile applications from Github won't run, open as text document

    ...
    Last edited by mikewhatever; May 16th, 2021 at 07:10 PM.

  3. #3
    Join Date
    May 2021
    Beans
    18

    Re: Makefile applications from Github won't run, open as text document

    Thanks for the reply, not sure what you exactly mean with 'executable' ... the files are downloadable via:

    https://github.com/weigert/DynamicFoam (600kb)
    https://github.com/weigert/TinyEngine (60Mb)

    I think the main problem is that when clicking on them they should 'automatically' run via the Terminal.

    I previously tried to run these applications on MacOSX using XCode, and there the Makefiles were listed in their map with a Terminal label/icon (see pic).

    But there I had other issues, so I though of doing it all 'native' and getting a smooth run.


  4. #4
    Join Date
    May 2021
    Beans
    18

    Re: Makefile applications from Github won't run, open as text document

    Small update.

    A practical problem was that I couldn't do a right-click on the laptop.

    So I installed the gnome-tweak-tool, and now I'm able to right-click and change the properties and the Default Application.

    I changed it to 'Run Software' and tried 'Software Install' (see pic).

    But nothing happened except a 'Run Software' wheel that rolled for a moment on the upper left side.

    There wasn't a Terminal option, mh.

    I also made everything in the map to read/write.

    BTW Not sure if I'm here at the right section (General) of the Forum regarding this problem?




    Last edited by michelvandegaer; May 16th, 2021 at 10:16 AM.

  5. #5
    Join Date
    Aug 2011
    Location
    51.8° N 5.8° E
    Beans
    5,920
    Distro
    Xubuntu 20.04 Focal Fossa

    Re: Makefile applications from Github won't run, open as text document

    Makefiles aren't executable files and you don't run them. Instead, you run make, which will find the makefile and interpret the instructions therein.

  6. #6
    Join Date
    May 2021
    Beans
    18

    Re: Makefile applications from Github won't run, open as text document

    Ok, so I ran 'Make' and got this response:

    No targets specified and no makefile found. Stop.

    BTW since the Makefile didn't open in the Terminal I did a copy/paste of whole the Makefile-code into the Terminal, but nothing happened.

    Here's the transcript: http://800million.org/Ub/Terminal_printout.txt

    Not sure if that made any sense.




  7. #7
    Join Date
    Dec 2014
    Beans
    1,805

    Re: Makefile applications from Github won't run, open as text document

    For various reasons - chief among them the need for elevated privileges for putting the include files in /usr/local/include and the library in /usr/local/lib - this makefile is not a good candidate for running through the GUI. So just open a terminal, change the working directory to the one with the makefile and run 'sudo make all' for TinyEngine.
    Code:
    cd ~/Desktop/TinyEngine-master
    sudo make all
    The situation is similar for DynamicFoam, but here there's a simpler solution: the file 'main' is a compiled executable. If you have the same version of Ubuntu as the author and have all the needed libraries installed, you can simply mark this file as executable and run it.

    Holger

  8. #8
    Join Date
    May 2021
    Beans
    18

    Re: Makefile applications from Github won't run, open as text document

    Hi Holger,

    Thanks for your feedback!

    I ran your code lines for TinyEngine Application and got:

    No rule to make target 'all'. Stop.

    I did the similar thing for the DynamicFoam Application and I got a bunch of errors, probably related to what you just wrote about needing the extra files from the author (or a library that's downloadable from Brew?), and a fatal error but that's probably related to the TinyEngine not being active.

    I also opened/ran the Makefile from within the DynamicFoam-main folder with Run Software ... but it didn't do anything, probably again related to the same errors mentioned here above.



  9. #9
    Join Date
    May 2021
    Beans
    18

    Re: Makefile applications from Github won't run, open as text document

    Wait. I made a mistake BRB

  10. #10
    Join Date
    May 2021
    Beans
    18

    Re: Makefile applications from Github won't run, open as text document

    I'm back.

    The 'mistake' was that I had renamed the folder TinyEngine-master to TinyEngine.

    I renamed it back to it's original name and ran the code snipped that used 'TinyEngine-master'.

    ... and got a fatal error of a file that could not be found (operations.hpp).

    I guess that relates to what you were mentioning earlier on regarding the need to have the same files as the author, and this is probably such a file/library. No?



Page 1 of 3 123 LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •