Project

General

Profile

Bug #3616

atomic.h problem when building for armel

Added by virtual dj over 8 years ago. Updated over 8 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
-
Category:
non-x86
Target version:
-
Start date:
2016-03-09
Due date:
% Done:

100%

Estimated time:
Found in version:
a44061c
Affected Versions:

Description

I'm trying to build the latest git (a44061c) and it works on x86 and x64 but not under arm.
I configured it leaving out ffmpeg, avahi, libav and hdhomerun stuff:

./configure --disable-avahi --enable-bundle --disable-libav --disable-libffmpeg_static --disable-libx264_static --disable-libx265_static --disable-dbus_1 --disable-hdhomerun_client --disable-hdhomerun_static
But it fails just before the end with this error:
...
MKBUNDLE        bundle.c
CC              bundle.o
CC              build.o
CC              timestamp.o
CC              tvheadend
/root/tvheadend/tvheadend/build.linux/src/main.o: In function `atomic_exchange_s64':
/root/tvheadend/tvheadend/src/atomic.h:159: undefined reference to `__sync_lock_test_and_set_8'
/root/tvheadend/tvheadend/src/atomic.h:159: undefined reference to `__sync_lock_test_and_set_8'
/root/tvheadend/tvheadend/src/atomic.h:159: undefined reference to `__sync_lock_test_and_set_8'
/root/tvheadend/tvheadend/build.linux/src/subscriptions.o: In function `atomic_exchange_u64':
/root/tvheadend/tvheadend/src/atomic.h:153: undefined reference to `__sync_lock_test_and_set_8'
/root/tvheadend/tvheadend/src/atomic.h:153: undefined reference to `__sync_lock_test_and_set_8'
collect2: ld returned 1 exit status
make: *** [/root/tvheadend/tvheadend/build.linux/tvheadend] Error 1
As I said, this only happens on armel. I hope it's not due to gcc 4.4.5 as I prefer not updating it; compilation always worked in the past.
root@debian-armel:~/tvheadend/tvheadend# uname -a
Linux debian-armel 2.6.32-5-versatile #1 Wed Jan 12 23:05:11 UTC 2011 armv5tejl GNU/Linux
root@debian-armel:~/tvheadend/tvheadend# gcc -v
Using built-in specs.
Target: arm-linux-gnueabi
Configured with: ../src/configure -v --with-pkgversion='Debian 4.4.5-8' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.4 --enable-shared --enable-multiarch --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4 --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc --disable-sjlj-exceptions --enable-checking=release --build=arm-linux-gnueabi --host=arm-linux-gnueabi --target=arm-linux-gnueabi
Thread model: posix
gcc version 4.4.5 (Debian 4.4.5-8)
May it be an error due to recent changes in atomic.h?

History

#1

Updated by Jaroslav Kysela over 8 years ago

  • Status changed from New to Fixed
  • % Done changed from 0 to 100

Applied in changeset commit:tvheadend|eda03e9ce445d154dcc6f67e0de4f8651971a356.

#2

Updated by virtual dj over 8 years ago

Thanks for the answer, but there are still errors (this time immediately after running make):

make[2]: Leaving directory `/root/tvheadend/tvheadend'
make[1]: Leaving directory `/root/tvheadend/tvheadend'
CC              src/version.o
CC              src/uuid.o
cc1: warnings being treated as errors
In file included from src/tvhlog.h:32,
                 from src/tvheadend.h:52,
                 from src/uuid.c:20:
src/atomic.h: In function ‘atomic_exchange_u64’:
src/atomic.h:162: error: no return statement in function returning non-void
src/atomic.h: In function ‘atomic_exchange_s64’:
src/atomic.h:176: error: no return statement in function returning non-void
make: *** [/root/tvheadend/tvheadend/build.linux/src/uuid.o] Error 1

#3

Updated by virtual dj over 8 years ago

... in fact the return is really missing.

Also available in: Atom PDF