compileOF.sh fails to compile OpenFrameworks on Arch Linux

Some Arch guru have to help you here.

Can you make the examples?

is this thread of any use?

Let me try and see if it works.

On my machine I also have libopenexr-dev installed. I don’t know if this makes any difference but maybe worth a try.

before I have to quit the system update again, what else related packages do you have installed

Well, I ran the install_dep and install_codecs script, just like you did. I don’t think I added anything manually to make it work (but who knows, I use this machine for developing other stuff too). :slight_smile:

And I always run my machine with the latest updates (Debian 11.4 Testing).

I was unable to find any package under that name so back to trying to upgrade my system and hope that it fixes the isse.

After an upgrade and installing a couple more packages, I managed to run both the CLI and GUI. But then when I want to actually create the project it gives me this error

Command failed: /bin/sh -c "/home/archspect/of_v20220724_linux64gcc6_release/apps/projectGenerator/commandLine/bin/projectGenerator"  -o"/home/archspect/of_v20220724_linux64gcc6_release" -a" " -p"linux64" -t"" "/home/archspect/of_v20220724_linux64gcc6_release/apps/myApps/mySketch"
malloc_consolidate(): invalid chunk size

I can’t reproduce this error on my Debian machine. This is when you run the compiled projectgenerator with the window/GUI?

Can you create an oF project from inside QT Creator, whis is the supported IDE for oF on GNU/Linux? (QT Creator > Create project > openFrameworks > openFrameworks application)

“This is when you run the compiled projectgenerator with the window/GUI?”

Yes

Can you create an oF project from inside QT Creator, whis is the supported IDE for oF on GNU/Linux? (QT Creator > Create project > openFrameworks > openFrameworks application)

Well this is gonna take forever to download (I have very bad internet)

More errors


/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxSvg/src/ofxSvg.cpp:30: error: undefined reference to 'ofToDataPath[abi:cxx11](boost::filesystem::path const&, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxSvg/src/ofxSvg.cpp:37: error: undefined reference to 'ofBufferFromFile(boost::filesystem::path const&, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:32: error: undefined reference to 'ofFile::open(boost::filesystem::path const&, ofFile::Mode, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:258: error: undefined reference to 'ofFilePath::getEnclosingDirectory[abi:cxx11](boost::filesystem::path const&, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:259: error: undefined reference to 'ofFilePath::getFileName[abi:cxx11](boost::filesystem::path const&, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:260: error: undefined reference to 'ofFilePath::join[abi:cxx11](boost::filesystem::path const&, boost::filesystem::path const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:260: error: undefined reference to 'ofFilePath::join[abi:cxx11](boost::filesystem::path const&, boost::filesystem::path const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:262: error: undefined reference to 'ofFile::doesFileExist(boost::filesystem::path const&, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxAssimpModelLoader/src/ofxAssimpModelLoader.cpp:282: error: undefined reference to 'ofLoadImage(ofTexture&, boost::filesystem::path const&, ofImageLoadSettings const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxVectorGraphics/src/ofxVectorGraphics.cpp:154: error: undefined reference to 'ofToDataPath[abi:cxx11](boost::filesystem::path const&, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:104: error: undefined reference to 'ofTrueTypeFont::load(boost::filesystem::path const&, int, bool, bool, bool, float, int)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:232: error: undefined reference to 'ofFilePath::getFileExt[abi:cxx11](boost::filesystem::path const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:235: error: undefined reference to 'ofFile::ofFile(boost::filesystem::path const&, ofFile::Mode, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:236: error: undefined reference to 'ofXml::load(boost::filesystem::path const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:239: error: undefined reference to 'ofXml::save(boost::filesystem::path const&) const'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:251: error: undefined reference to 'ofFilePath::getFileExt[abi:cxx11](boost::filesystem::path const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:254: error: undefined reference to 'ofXml::load(boost::filesystem::path const&)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxGui/src/ofxBaseGui.cpp:258: error: undefined reference to 'ofFile::ofFile(boost::filesystem::path const&, ofFile::Mode, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/libs/openFrameworks/utils/ofJson.h:19: error: undefined reference to 'ofFile::ofFile(boost::filesystem::path const&, ofFile::Mode, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/libs/openFrameworks/utils/ofJson.h:57: error: undefined reference to 'ofFile::ofFile(boost::filesystem::path const&, ofFile::Mode, bool)'
/home/archspect/of_v20220724_linux64gcc6_release/addons/ofxOpenCv/src/ofxCvHaarFinder.cpp:56: error: undefined reference to 'ofToDataPath[abi:cxx11](boost::filesystem::path const&, bool)'
collect2: error: ld returned 1 exit status
Process failed with exit code 1.
The following products could not be built for configuration Debug_Desktop_038b678e9426a45b:
untitled1
Error while building/deploying project untitled1 (kit: Desktop)
When executing step "Qbs Build"
21:55:24: Elapsed time: 00:03.

Hi @Archspect , I hope the following is helpful for the errors in your most recent post:

The nightly build now supports c++17. There were some changes made to support a new file system to accomplish this. There is a flag set in the config.linux.common.mk file (line 139), which can be commented out if c++17 is not desired when oF is compiled with the compileOF.sh script:

PLATFORM_CXXVER = -std=c++17

If oF is compiled for c++17 (the default in the nightly), then the projects should be too. So you may have to uncomment and add a flag in the project config.make file (scroll down to the bottom of this file):

PROJECT_CXX += -std=c++17

Or if you’re using Qt Creator you’d set this flag in the project .qbs file.

1 Like

I added the line in the qbs file and it compiled fine. but when I run it it gives me this error

/home/archspect/untitled1/bin/untitled1_debug: error while loading shared libraries: libfmod.so.12: cannot open shared object file: No such file or directory

It still gives that error after installing libfmod

Maybe this post will help:

One other thing: you don’t really need the project generator if it doesn’t work. You can copy another project and edit the files manually. But using QT Creator to create a new project works pretty good.

Is there any way that I will be able to use openframeworks without any Qt things involved?

Hey sure you don’t have to use Qt. I’ve seen some forum threads with linux users who use VSCode for example. I don’t think VSCode is officially supported for linux like Qt Creator, but people have gotten it working, including maybe with code completion. CodeBlocks was officially supported several years ago before Qt Creator. I’ve used Geany on a Raspberry Pi before, so a light-weight editor like that could work. In general, code completion and etc could be an issue with alternative IDEs. Accommodating oF for Arch linux (and related distress) could be a bit more complex too because of the rolling nature of the distro.

Searching the forum might be a good place to start. There may be more threads like this one: Linux users, what IDE are you using and do you have code completion?

Perfect! but how can I get it working without Qbs and Qt Creator?

Hey also regarding this issue, I had the same problem this morning on macOS: Project generator error with addons on macOS . So this should eventually get resolved.

Oh good to know.

If by “it” you mean oF: oF doesn’t depend on Q*. You can use any text editor, as @TimChi mentioned you can use any text editor and make via CLI.

Although I do recommend QT Creator as it is supported and lets you navigate files and folders very nicely.

I think it depends on what IDE you want to use, if any. oF projects can be compiled with make. So a classic and simple way to make a new project is to copy the folder of the (unaltered) emptyExample project into a new location, making sure its at the same “level” from the oF root directory. Then open a terminal at the folder and type make to build it. Addons can be listed by their names (like ofxGui) in the addons.make file. Flags for libraries and etc can be set in the config.make file. This is where you’d add the project flag for c++17 for example.

I learned quite a bit about oF by using make on the pi. Its a little fiddly to troubleshoot the compiler errors sometimes. But its a fun and grounded way to use oF!

1 Like