Compiling OF in raspbian Stretch


#22

hello method one good so far but I can not find the config.linuxarmv6l.default.mk file to change it?

run a find search :::find: ‘config.linuxarmv6l.default.mk’: No such file or directory

thanks for any advice


#23

Hi @flx, you can find the file in the open frameworks directory /libs/openFrameworksCompiled/project/linuxarmv6l/.

Some of us have had a (somewhat) parallel thread here: Raspberry Pi Poco error.

@bakercp thank you so much for methods 1 and 2 above! I just installed Stretch on an RPi3 and successfully compiled the “master branch” via both methods. And the polygonExample builds and runs just fine with both methods. I also switched drivers in raps-config to match the chosen method.

I have not tried my own application with the ofxGPIO add-on yet (see post above from @ayruos), but will try soon and edit this post according to what I find. I’ll also try a 3d example to see how that goes.

For what its worth, I think the mesa drivers are the way to go, at least in terms of maintaining a common windowing system as @bakercp stated above. And I feel this is worth it even if there is a performance drop in the short term. The mesa drivers are open-source and likely will benefit the Pi and its users in the years to come. The Pi hardware will likely become faster and/or more capable as time goes by as well.

And thanks to everyone who has contributed to this and the other related threads. Its nice to have made some progress on the transition from Jessie to Stretch on the Pi. The forum has been really a great resource for this issue.

Edit: The 3dPrimitivesExample runs fine with both methods. I had the similar errors as @ayruos with ofxGPIO when compiling.


#24

I just added the paths to the post for both methods just to be more explicit.


#25

7 posts were split to a new topic: Running ofxGPIO on Raspbian Stretch


#26

Thanks …I found the file…

http://www.lazo.cl/
Visual & Audio Thinking
www.lazo.cl


#27

RPi 3 OS: Stretch 64kb used for Graphics

Well I have tried openFrameworks on a RPi 3 and still cannot get it running, so I will give openFrameworks a miss.
I may be a problem finding an alternative though.

Perhaps in future it will run…I hope so .


#28

I just got everything running on Stretch, including ofxGPIO (at least the MCP stuff). What issues are you facing?


#29

TRpi 3 and Stretch?
WHat was your setup?

I get compiler errors (Podo(?) ) and a receiver error on a directory as posted by mar.carnet.
I also want to install opencv 3.3.1 on the system as well - in fact, this has priority -
so adjustments to the graphics that may influence this are to be avoided.


#30

hey,
after making some attempts to install a make a ready OF system on RPi, I think it should be nice to have an SD image ready to burn-and-run.
could be very helpful for some people.


#31

Just tried both methods, but sadly neither worked. Method 1 crashed and while method 2 did make it further, these are the errors I got at run time as some mentioned above:
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 gtk±3.0 libmpg123
with PKG_CONFIG_LIBDIR=
[notice ] ofAppEGLWindow: createSurface(): setting up EGL Display
[notice ] ofAppEGLWindow: createSurface(): EGL Display correctly set 0x10634d8
MESA-LOADER: failed to retrieve device information
MESA-LOADER: failed to retrieve device information
MESA-LOADER: failed to retrieve device information
[notice ] ofAppEGLWindow: createSurface(): no current renderer selected
[notice ] ofAppEGLWindow: createSurface(): default renderer detected
[notice ] ofAppEGLWindow: createSurface(): surface created correctly
[notice ] ofAppEGLWindow: createSurface(): API bound correctly
[notice ] ofAppEGLWindow: createSurface(): -----EGL-----
[notice ] ofAppEGLWindow: createSurface(): EGL_VERSION_MAJOR = 1
[notice ] ofAppEGLWindow: createSurface(): EGL_VERSION_MINOR = 4
[notice ] ofAppEGLWindow: createSurface(): EGL_CLIENT_APIS = OpenGL OpenGL_ES
[notice ] ofAppEGLWindow: createSurface(): EGL_VENDOR = Mesa Project
[notice ] ofAppEGLWindow: createSurface(): EGL_VERSION = 1.4 (DRI2)
[notice ] ofAppEGLWindow: createSurface(): EGL_EXTENSIONS = EGL_CHROMIUM_sync_control EGL_EXT_buffer_age EGL_EXT_image_dma_buf_import EGL_KHR_cl_event2 EGL_KHR_create_context EGL_KHR_fence_sync EGL_KHR_get_all_proc_addresses EGL_KHR_gl_colorspace EGL_KHR_gl_renderbuffer_image EGL_KHR_gl_texture_2D_image EGL_KHR_gl_texture_3D_image EGL_KHR_gl_texture_cubemap_image EGL_KHR_image EGL_KHR_image_base EGL_KHR_image_pixmap EGL_KHR_no_config_context EGL_KHR_reusable_sync EGL_KHR_surfaceless_context EGL_KHR_wait_sync EGL_MESA_configless_context EGL_MESA_drm_image EGL_MESA_image_dma_buf_export EGL_NOK_texture_from_pixmap EGL_WL_bind_wayland_display
[notice ] ofAppEGLWindow: createSurface(): GL_RENDERER = Gallium 0.4 on VC4 V3D 2.1
[notice ] ofAppEGLWindow: createSurface(): GL_VERSION = OpenGL ES-CM 1.1 Mesa 13.0.6
[notice ] ofAppEGLWindow: createSurface(): GL_VENDOR = Broadcom
[notice ] ofAppEGLWindow: createSurface(): -------------
[ error ] ofAppEGLWindow: setupPeripherals(): peripherals not supported on X11Using a RPi3 with Stretch.

Any tips would be super appreciated! Thanks!


#32

Here’s a step by step of what I did :slight_smile:

###1. Installed latest Raspbian to microSD card via Etcher.
###2. Boot the Raspberry Pi 3 - it boots into the Pixel desktop by default.
Open the terminal and do usual housekeeping,

sudo apt-get update
sudo apt-get upgrade 

Then,

sudo raspi-config

From here I did 1. Expand Filesystem, 2. Switch on SSH & SPI (SPI might not be required for you, I need it), 3. Memory Split to 64 and 4. Set Boot to Console Autologin, 5. Advanced Options -> GL Driver > “G3 Legacy” “Original non-GL desktop driver” [This is according to the guide here and according to @bakercp’s post above ].

At this point the Pi would ask for a reboot, I’d say not right now :slight_smile:

Open the browser, I downloaded the of_v20170714_linuxarmv6l_nightly.tar.gz (yes, the nightly build! - I don’t think 0.9.8 works any longer). I put everything from here into a folder called openFrameworks in my home directory.

Now I reboot.

###3. On reboot,

  1. navigate to the scripts folder
    cd openFrameworks/scripts/linux/debian
  2. do
    sudo ./install_dependenies.sh
  3. Then,
    sudo ./install_codecs.sh
  4. Then go back to the main openFrameworks folder.
  5. Navigate to,
    cd libs/openFrameworksCompiled/project/linuxarmv6l/
  6. Edit the file there as mentioned by @bakercp
    nano config.linuxarmv6l.default.mk
  7. Replace

PLATFORM_LIBRARIES += GLESv2
PLATFORM_LIBRARIES += GLESv1_CM
PLATFORM_LIBRARIES += EGL

with

PLATFORM_LIBRARIES += brcmGLESv2
PLATFORM_LIBRARIES += brcmEGL

###4. Now it’s time to compile openFrameworks!

sudo make Release -C /home/pi/openFrameworks/libs/openFrameworksCompiled/project

If you get a access denied error at any point just rerun the command as sudo, that happened to me a couple of times, don’t remember at which points - happened while compiling some examples for the first time too, so future reference too.

This is going to take a while. So take a break.

Once this is done, go to any example and make. It should work.

###5. Don’t forget to reset the memory split from raspi-config back to 128 or 256.

@moebiussurfing (and @ThreeDOgs) I could make a SD image ready to burn and run if you can wait till Tuesday/Wednesday. All my stuff is at school.


Is it possible to compile OF 0.9.8 on Raspbian Stretch?
#33

That would be very nice!!
Thanks for the tips anyway.


#34

Thank you so much! Super super appreciate you listing all the steps! I will give this another try!


#35

2.1.2018
Hello,

Thank you for your email.
Please see mycomments in your text

[ayruos] ayruos https://forum.openframeworks.cc/users/ayruos
December 30

Here’s a step by step of what I did :slight_smile:

  1. Installed latest Raspbian to microSD card via Etcher
  <https://etcher.io>.


  2. Boot the Raspberry Pi 3 - it boots into the Pixel desktop by
  default.

Open the terminal and do usual housekeeping,

|sudo apt-get update sudo apt-get upgrade|

Then,

sudo raspi-config

From here I did 1. Expand Filesystem, 2. Switch on SSH & SPI (SPI
might not be required for you, I need it), 3. Memory Split to 64 and
4. Set Boot to Console Autologin. [This is according to the guide here
http://openframeworks.cc/setup/raspberrypi/raspberry-pi-getting-started/].

At this point the Pi would ask for a reboot, I’d say not right now
:slight_smile:

I think you do need the reboot here.

Open the browser, I downloaded the
of_v20170714_linuxarmv6l_nightly.tar.gz (yes, the nightly build!). I
put everything from here into a folder called openFrameworks in my
home directory.

http://openframeworks.cc/versions/nightly/ this is no
of_v20170714_linuxarmv6l_nightly.tar.gz so I assume
of_linuxarmv6l_nightly.tar.gz was meant.
however qa nightly version may contain changes that may lead to
different error messages.
So I chose the /*of_v0.9.8_linuxarmv6l_release.tar.gz */version.
The memory size was set to 64 using a Model 2 B RPi

During the install
|sudo ./install_dependenies.sh

This runs for a w´hile but again exits with an error.

|/ls.o
/home/pi/openFrameworks/scripts/apothecary/build/poco/Net/obj/Linux/armv7l/release_static/OAuth20Credentials.o//
//ranlib
/home/pi/openFrameworks/scripts/apothecary/build/poco/lib/Linux/armv7l/libPocoNet.a//
//make[1]: Leaving directory
‘/home/pi/openFrameworks/scripts/apothecary/build/poco/Net’//
//
// ^ Received error ^//
//pi@host2:~/openFrameworks/scripts/linux/debian $ /

Perhaps you could help further…but I think there is a fundemental
error in the compiling of paco .
I would like to use openFrameworks but will wait for any comment and
later retry with night compile verion of openframeworks ARM6
if that fails then I must find another alternative to frameworks.

Many thanks

BG

Now I reboot.

  3. On reboot,
  1. navigate to the scripts folder
    |cd openFrameworks/scripts/linux/debian|
  2. do
    |sudo ./install_dependenies.sh|

|#|

  1. Then,
    |sudo ./install_codecs.sh <-------------- I had not done this!|
  2. Then go back to the main openFrameworks folder.
  3. Navigate to,
    |cd libs/openFrameworksCompiled/project/linuxarmv6l/|
  4. Edit the file there as mentioned by @bakercp
    https://forum.openframeworks.cc/users/bakercp
    |nano config.linuxarmv6l.default.mk|

|cd open|


#36

Hey! Are you using the nightly build of Arm6? As I said before, 0.9.8 doesn’t compile any longer, and hasn’t for a while.


#37

I can see from your log it’s Arm7 Poco that fails, Use Arm6 Nightly version of oF!


#38

I did write that I am not too keen to use a nightly build because it may change and perhaps give different
messages.
Why 0.9.8 ArmV6 cannot compile and still in the release list is not good. How is one supposed to know that? Assuming you are right, this is not good project control.
Scanning the openframework.cc site I did not find any reference to 0.9.8 not working.

However, I will try the nightly build and see how that functions.


#39

Well if you’d read the release list more carefully, it says
openFrameworks 0.9.0 supports the Raspberry Pi via the recommended Linux distribution Raspbian "Jessie" (hard float).

So the fact that you’re trying to install it on Stretch in itself should be something you shouldn’t be doing.

There’s no need to be so salty, the oF developers put in a lot of work to give us what they’re giving us and either appreciate that or find something else to use. If you read this thread more carefully you’ll see it fairly well documented that 0.9.8 doesn’t work with Stretch because of the libssl version of Stretch which can’t compile Poco (has nothing to do with oF).


#40

The text relates to 0.9.0 not 0.9.8 and Jessie has been overtaken with Stretch.
Under no circumstances will I develop new Software under an old Operating system.

My comment was not salty, but a justifiable remark. Poco is used by Openframeworks so it is an integral part of oF. A bit of critic must be acceptable if not there is something wrong.

Tomorrow I will have the time for the new download and install. So we will see if itt compiles under stretch.


#41

Thank you so much @ayruos! I followed your steps and used the nightly build you mentioned and so far so good! Ran a couple of the examples and they worked. Really appreciate it.