Author Topic: Build errors on ARM architecture GCC 6.3.1  (Read 5627 times)

bdheeman

  • Newbie
  • *
  • Posts: 3
    • View Profile
    • Working together, works!
Build errors on ARM architecture GCC 6.3.1
« on: March 09, 2017, 01:00:05 PM »
Hi,

Today, when attempted to build YateBTS after an 'svn update' at 601 now, for Rasberry Pi 3 Model B running ArchLinux-ARM using GCC/G++ 6.3.1 the build failed with following errors:

Code: [Select]
MAC.cpp: In member function 'GPRS::PDCHL1FEC* GPRS::L2MAC::macPickChannel()':
MAC.cpp:838:28: error: 'ch' cannot appear in a constant-expression
  for (RListIterator<typeof(ch)> itr(macPacchs); itr.next(ch); ) {
                            ^~
MAC.cpp:838:30: error: a function call cannot appear in a constant-expression
  for (RListIterator<typeof(ch)> itr(macPacchs); itr.next(ch); ) {
                              ^
MAC.cpp:838:31: error: template argument 1 is invalid
  for (RListIterator<typeof(ch)> itr(macPacchs); itr.next(ch); ) {
                               ^
MAC.cpp:838:46: error: cannot convert 'GPRS::PDCHL1FECList_t {aka RList<GPRS::PDCHL1FEC*>}' to 'int' in initialization
  for (RListIterator<typeof(ch)> itr(macPacchs); itr.next(ch); ) {
                                              ^
MAC.cpp:838:53: error: request for member 'next' in 'itr', which is of non-class type 'int'
  for (RListIterator<typeof(ch)> itr(macPacchs); itr.next(ch); ) {
                                                     ^~~~
MAC.cpp: At global scope:
MAC.cpp:655:13: warning: 'void GPRS::dumpPdch()' defined but not used [-Wunused-function]
 static void dumpPdch()
             ^~~~~~~~
make[2]: *** [Makefile:122: MAC.o] Error 1
make[2]: Leaving directory '/home/bdheeman/devel/abs/local/yatebts-svn/src/yatebts-svn/mbts/GPRS'
make[1]: *** [Makefile:140: ../GPRS/libGPRS.a] Error 2
make[1]: Leaving directory '/home/bdheeman/devel/abs/local/yatebts-svn/src/yatebts-svn/mbts/apps'
make: *** [Makefile:54: all] Error 2

FYI, I'm forced to override defaults in your Makefile(s), for the reasons of compatibility; the build otherwise was failing a lot and that's how I successfully build Yate and YateBTS a few days ago:

Code: [Select]
export CC="gcc -std=c90 -Wall"
export CXX="g++ -std=c++98 -Wall"