Compile problems on arch linux

Hi all, my first post in here :smiley:
Processing’s OpenGL support is broken on Linux, which gave me the push to finally trying to get my head around of instead!

I am trying to compile the emptyExample in the myApps folder using make, but instead of a binary, I am getting this output:

https://pastebin.com/9YLcZy5G

I have no idea where to even begin looking to make this work. The project also does not compile in qtcreator. Help much appreciated!

K

EDIT: When opening the project in qtcreator, it seems the project is not able to locate the path of ofMain.h relative to the ofApp.h file…

EDIT: It seems poco is the culprit. I removed the nightly package from AUR and ran the dependency script. I got the message that poco needs to be recompiled due to GCC > 5. Output from the compile here:

https://pastebin.com/LP0Y1iSM

Any ideas on how to make poco compile correctly? Do I even need it?

Hi sorry OF 0.9.8 is not compatible anymore with latest linux releases, you need to use the nightly builds instead, which you can find below the normal downloads, untill we release the next version soon

Hi Arturo,

Thanks for the pointer. I’ve installed the nightly build. poco is no longer an issue, but I am now getting this when trying to compile:

[kf@arch emptyExample]$ make -j3
HOST_OS=Linux
checking pkg-config libraries: cairo zlib gstreamer-app-1.0 gstreamer-1.0 gstreamer-video-1.0 gstreamer-base-1.0 libudev freetype2 fontconfig sndfile openal openssl libcurl glfw3 rtaudio libpulse-simple alsa gl glu glew gtk±3.0 libmpg123
with PKG_CONFIG_LIBDIR=
Compiling OF library for Release
make[1]: Entering directory ‘/home/kf/of_v20170714_linux64_release/libs/openFrameworksCompiled/project’
HOST_OS=Linux
checking pkg-config libraries: cairo zlib gstreamer-app-1.0 gstreamer-1.0 gstreamer-video-1.0 gstreamer-base-1.0 libudev freetype2 fontconfig sndfile openal openssl libcurl glfw3 rtaudio libpulse-simple alsa gl glu glew gtk±3.0 libmpg123
with PKG_CONFIG_LIBDIR=
HOST_OS=Linux
checking pkg-config libraries: cairo zlib gstreamer-app-1.0 gstreamer-1.0 gstreamer-video-1.0 gstreamer-base-1.0 libudev freetype2 fontconfig sndfile openal openssl libcurl glfw3 rtaudio libpulse-simple alsa gl glu glew gtk±3.0 libmpg123
with PKG_CONFIG_LIBDIR=
HOST_OS=Linux
checking pkg-config libraries: cairo zlib gstreamer-app-1.0 gstreamer-1.0 gstreamer-video-1.0 gstreamer-base-1.0 libudev freetype2 fontconfig sndfile openal openssl libcurl glfw3 rtaudio libpulse-simple alsa gl glu glew gtk±3.0 libmpg123
with PKG_CONFIG_LIBDIR=
Done!
make[1]: Leaving directory ‘/home/kf/of_v20170714_linux64_release/libs/openFrameworksCompiled/project’

Compiling emptyExample for Release
make[1]: Entering directory ‘/home/kf/of_v20170714_linux64_release/apps/myApps/emptyExample’
HOST_OS=Linux
checking pkg-config libraries: cairo zlib gstreamer-app-1.0 gstreamer-1.0 gstreamer-video-1.0 gstreamer-base-1.0 libudev freetype2 fontconfig sndfile openal openssl libcurl glfw3 rtaudio libpulse-simple alsa gl glu glew gtk±3.0 libmpg123
with PKG_CONFIG_LIBDIR=
Linking bin/emptyExample for linux64
g++ -o bin/emptyExample obj/linux64/Release/src/ofApp.o obj/linux64/Release/src/main.o /home/kf/of_v20170714_linux64_release/libs/openFrameworksCompiled/lib/linux64/libopenFrameworks.a -Wl,-rpath=./libs:./bin/libs -Wl,–as-needed -Wl,–gc-sections -L/home/kf/of_v20170714_linux64_release/libs/fmodex/lib/linux64/ -lfmodex /home/kf/of_v20170714_linux64_release/libs/kiss/lib/linux64/libkiss.a /home/kf/of_v20170714_linux64_release/libs/tess2/lib/linux64/libtess2.a -lz -lgstapp-1.0 -lgstvideo-1.0 -lgstbase-1.0 -lgstreamer-1.0 -ludev -lfontconfig -lfreetype -lsndfile -lopenal -lssl -lcrypto -lcurl -lglfw -lrtaudio -ljack -lpulse-simple -lpulse -lasound -lGLEW -lGLU -lGL -lgtk-3 -lgdk-3 -lpangocairo-1.0 -lpango-1.0 -latk-1.0 -lcairo-gobject -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lmpg123 -lglut -lX11 -lXrandr -lXxf86vm -lXi -lXcursor -ldl -lpthread -lfreeimage -lboost_filesystem -lboost_system -lpugixml -luriparser -lXinerama
/usr/bin/ld: /home/kf/of_v20170714_linux64_release/libs/kiss/lib/linux64/libkiss.a(kiss_fftr.o): relocation R_X86_64_32 against .rodata' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: /home/kf/of_v20170714_linux64_release/libs/tess2/lib/linux64/libtess2.a(tess.o): relocation R_X86_64_32 against.data’ can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: /home/kf/of_v20170714_linux64_release/libs/tess2/lib/linux64/libtess2.a(mesh.o): relocation R_X86_64_32 against .rodata.str1.1' can not be used when making a shared object; recompile with -fPIC /usr/bin/ld: /home/kf/of_v20170714_linux64_release/libs/tess2/lib/linux64/libtess2.a(sweep.o): relocation R_X86_64_32S against.rodata’ can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: /home/kf/of_v20170714_linux64_release/libs/tess2/lib/linux64/libtess2.a(dict.o): relocation R_X86_64_32 against `.rodata.str1.1’ can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Nonrepresentable section on output
collect2: error: ld returned 1 exit status
make[1]: *** [/home/kf/of_v20170714_linux64_release/libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk:405: bin/emptyExample] Error 1
make[1]: Leaving directory ‘/home/kf/of_v20170714_linux64_release/apps/myApps/emptyExample’
make: *** [/home/kf/of_v20170714_linux64_release/libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk:129: Release] Error 2

you need to download the gcc6 version

Works like a charm! Thanks a lot :slight_smile:

Hi Arturo,

Not sure if I should make a new thread for this or not but I believe I’ve had the same problem as @kflak1.

I’m using Manjaro 17.1.3 and I had trouble with Poco initially so swapped to the nightly build (gcc6) but I’ve experienced a problem when compiling OF:

https://pastebin.com/Kh4tRysm

It seems that I’m using gcc v7 so not sure if that is causing an issue.

Thanks in advance,
Gareth

gcc7 should work with the gcc6 download. the error you get doens’t say where compiling has failed which is weird. can you try compiling an example?

Maybe this thread will help you?

Kenneth