Trouble compiling raspberry pi userland utils

Raspberry Pi 2

Trouble compiling raspberry pi userland utils

Postby claudiop » Thu Jul 23, 2015 12:31 am

Hi. I am trying (using this guide: https://thinkrpi.wordpress.com/2013/05/ ... mpilation/) to compile the raspberry pi utils (like raspicam) to use them with OpenCV.
The problem is that apparently a much newer GCC version than Raspbian has is causing trouble (at least it seems that it is GCC's fault).

Doing a make results in:
$this->bbcode_second_pass_quote('', '
')Scanning dependencies of target vcos
[ 0%] Building C object interface/vcos/pthreads/CMakeFiles/vcos.dir/vcos_pthreads.c.o
In file included from /home/claudio/userland/build/inc/interface/vcos/vcos.h:127:0,
from /home/claudio/userland/interface/vcos/pthreads/vcos_pthreads.c:29:
/home/claudio/userland/build/inc/interface/vcos/vcos_thread.h:269:6: error: inline function 'vcos_thread_resume' declared but never defined [-Werror]
void vcos_thread_resume(VCOS_THREAD_T *thread);
^
/home/claudio/userland/build/inc/interface/vcos/vcos_thread.h:262:5: error: inline function 'vcos_thread_running' declared but never defined [-Werror]
int vcos_thread_running(VCOS_THREAD_T *thread);
^
/home/claudio/userland/build/inc/interface/vcos/vcos_thread.h:251:15: error: inline function 'vcos_change_preemption' declared but never defined [-Werror]
VCOS_UNSIGNED vcos_change_preemption(VCOS_UNSIGNED pe);
^
/home/claudio/userland/build/inc/interface/vcos/vcos_thread.h:234:6: error: inline function 'vcos_thread_relinquish' declared but never defined [-Werror]
void vcos_thread_relinquish(void);
^
/home/claudio/userland/build/inc/interface/vcos/vcos_thread.h:186:15: error: inline function 'vcos_thread_get_affinity' declared but never defined [-Werror]
VCOS_UNSIGNED vcos_thread_get_affinity(VCOS_THREAD_T *thread);
^
cc1: all warnings being treated as errors
interface/vcos/pthreads/CMakeFiles/vcos.dir/build.make:54: recipe for target 'interface/vcos/pthreads/CMakeFiles/vcos.dir/vcos_pthreads.c.o' failed
make[2]: *** [interface/vcos/pthreads/CMakeFiles/vcos.dir/vcos_pthreads.c.o] Error 1
CMakeFiles/Makefile2:92: recipe for target 'interface/vcos/pthreads/CMakeFiles/vcos.dir/all' failed
make[1]: *** [interface/vcos/pthreads/CMakeFiles/vcos.dir/all] Error 2
Makefile:136: recipe for target 'all' failed
make: *** [all] Error 2


At first I though I was doing it wrong, by mistyping something, but searching for the problem quickly returned this:
https://github.com/raspberrypi/userland/issues/220

Well, if I didn't missed anything, by that part of the guide it still is the unmmodified official code, which is packaged in the repositories, and successfuly works.
If on one hand the repo doesn't has the latest git, on the other hand that issue is from february, so it probably was fixed already somehow by the packager.

How was it fixed? Am I missing something?

Thanks
claudiop
 
Posts: 3
Joined: Thu Jul 23, 2015 12:15 am

Re: Trouble compiling raspberry pi userland utils

Postby claudiop » Thu Jul 23, 2015 3:08 pm

I managed to find a spare MicroSD card and tried to do the same under Raspbian.
It happens that the same problems occur, but as warnings instead of errors.

So, the trouble is almost for sure with GCC getting more strict with its compilations.
The Raspbian GCC is 4.6, should I be able to move the resulting binaries to the Arch system?
I've heard somewhere that GCC broke some compatibility with the 5th release, thats why I am asking.

AUR has a couple of older versions of GCC, but they do include patches and no ARMV7 support announced on them. Since i imagine GCC as some compilation which takes forever, I would also like to know if using one of those would work before trying by myself.
claudiop
 
Posts: 3
Joined: Thu Jul 23, 2015 12:15 am

Re: Trouble compiling raspberry pi userland utils

Postby claudiop » Fri Jul 24, 2015 1:46 pm

After leaving the question of the RPi forums, it seems that there's a way simpler way to do things for me.
Not solved but the thread can be closed
claudiop
 
Posts: 3
Joined: Thu Jul 23, 2015 12:15 am


Return to Broadcom

Who is online

Users browsing this forum: No registered users and 4 guests