Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Kreuzuebersetzer, Diskussion über Änderungen im Tuxbox-CDK und Tuxbox-CVS
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Hi folks,

I'm struggling to build a dbox2 image.

I configured with:

Code: Alles auswählen

./configure --with-webif=standard --with-mhw-epg --with-epg=standard \
--with-cvsdir=/home/mastag/dbox2 --with-etherwake \
--with-filesystem-tools=e2fsprogs,dosfstools --with-gcc47 \
--with-boxtype=dbox2 --enable-ide --enable-uclibc --enable-kernel26 \
--enable-xfs --enable-mmc --enable-nfsserver --enable-aformat \
--enable-cdkVcInfo --enable-clock --enable-dboxshot --enable-dvbsnoop \
--enable-eraseall --enable-fbshot --enable-ipkg --enable-logomask --enable-msgbox \
--enable-satfind --enable-shellexec --enable-sqlite --enable-sysinfo --enable-audioplay \
--enable-aviaext --enable-aviafbtool --enable-avswitch --enable-fbclear \
--enable-lcddump --enable-pluginx --enable-rcinfo --enable-ccache  \
--with-defaultlocale=english --with-ucodesdir=/home/mastag/dbox2/ucode \
--enable-dropbear --prefix=/home/mastag/dbox2/build --enable-getrc \
--enable-rcinfo --enable-lirc --enable-kb2rcd  --enable-maintainer-mode \
--with-kernel-conf=/home/mastag/dbox2/cdk/config/dbox2_kernel-2.6.config.m4
These are my working directories:

/home/mastag/dbox2/cdk - master branch
/home/mastag/dbox2/driver - driver_2_6_branch branch
/home/mastag/dbox2/apps - master branch
/home/mastag/dbox2/boot - master branch
/home/mastag/dbox2/hostapps - master branch
/home/mastag/dbox2/sandbox - master branch

/home/mastag/dbox2/ucode - contains all ucodes
/home/mastag/dbox2/build - build prefix

Code: Alles auswählen

cd /home/mastag/dbox2/apps/misc/libs && ./autogen.sh && CC=powerpc-tuxbox-linux-uclibc-gcc CXX=powerpc-tuxbox-linux-uclibc-g++ CFLAGS="-Wall -pipe -Os -fPIC -flto -fuse-linker-plugin" CXXFLAGS="-Wall -pipe -Os -fPIC -flto -fuse-linker-plugin" LDFLAGS="-Wl,-O1 -flto -fuse-linker-plugin" ./configure --build=x86_64-unknown-linux-gnu --host=powerpc-tuxbox-linux-uclibc --prefix=/home/mastag/dbox2/build/cdkroot --with-driver=/home/mastag/dbox2/driver --with-dvbincludes=/home/mastag/dbox2/build/cdkroot/include --with-boxtype=dbox2 --with-target=cdk   --enable-kernel26 --enable-maintainer-mode --enable-uclibc --without-debug   --enable-lirc  --enable-ide --enable-mmc   --enable-ccache         --enable-sqlite    --enable-radiotext        --enable-ipkg --enable-nfsserver  --with-etherwake
Generating configuration files for tuxbox-apps-misc-libs, please wait....
  aclocal
configure.ac:5: warning: AC_COMPILE_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
configure.ac:5: warning: AC_RUN_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
  libtoolize --automake
  autoconf
configure.ac:5: warning: AC_COMPILE_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
configure.ac:5: warning: AC_RUN_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
  autoheader
configure.ac:5: warning: AC_COMPILE_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
configure.ac:5: warning: AC_RUN_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
  automake --add-missing
configure.ac:5: warning: AC_COMPILE_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
configure.ac:5: warning: AC_RUN_IFELSE was called before AC_GNU_SOURCE
acinclude.m4:471: AC_GNU_SOURCE is expanded from...
acinclude.m4:1: TUXBOX_APPS is expanded from...
configure.ac:5: the top level
configure.ac:5: installing './config.guess'
configure.ac:5: installing './config.sub'
configure.ac:2: installing './install-sh'
configure.ac:2: installing './missing'
Makefile.am: installing './INSTALL'
Makefile.am: installing './COPYING' using GNU General Public License v3 file
Makefile.am:     Consider adding the COPYING file to the version control system
Makefile.am:     for your code, to avoid questions about which license your project uses
libconfigfile/Makefile.am: installing './depcomp'
configure: WARNING: unrecognized options: --with-driver, --with-dvbincludes, --with-boxtype, --enable-kernel26, --enable-uclibc, --enable-lirc, --enable-ide, --enable-mmc, --enable-ccache, --enable-sqlite, --enable-radiotext, --enable-ipkg, --enable-nfsserver, --with-etherwake
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for powerpc-tuxbox-linux-uclibc-strip... powerpc-tuxbox-linux-uclibc-strip
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU
checking for powerpc-tuxbox-linux-uclibc-gcc... powerpc-tuxbox-linux-uclibc-gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... yes
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether powerpc-tuxbox-linux-uclibc-gcc accepts -g... yes
checking for powerpc-tuxbox-linux-uclibc-gcc option to accept ISO C89... none needed
checking dependency style of powerpc-tuxbox-linux-uclibc-gcc... gcc3
checking how to run the C preprocessor... powerpc-tuxbox-linux-uclibc-gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking endian.h usability... yes
checking endian.h presence... yes
checking for endian.h... yes
checking whether byte ordering is bigendian... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... powerpc-tuxbox-linux-uclibc
checking whether to enable maintainer-specific portions of Makefiles... yes
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... 64
checking target... cdk
checking for powerpc-tuxbox-linux-uclibc-gcc... (cached) powerpc-tuxbox-linux-uclibc-gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether powerpc-tuxbox-linux-uclibc-gcc accepts -g... (cached) yes
checking for powerpc-tuxbox-linux-uclibc-gcc option to accept ISO C89... (cached) none needed
checking dependency style of powerpc-tuxbox-linux-uclibc-gcc... (cached) gcc3
checking whether we are using the GNU C++ compiler... yes
checking whether powerpc-tuxbox-linux-uclibc-g++ accepts -g... yes
checking dependency style of powerpc-tuxbox-linux-uclibc-g++... gcc3
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for fgrep... /usr/bin/grep -F
checking for ld used by powerpc-tuxbox-linux-uclibc-gcc... /home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld
checking if the linker (/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /home/mastag/dbox2/build/cdk/bin/powerpc-tuxbox-linux-uclibc-nm -B
checking the name lister (/home/mastag/dbox2/build/cdk/bin/powerpc-tuxbox-linux-uclibc-nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-unknown-linux-gnu file names to powerpc-tuxbox-linux-uclibc format... func_convert_file_noop
checking how to convert x86_64-unknown-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld option to reload object files... -r
checking for powerpc-tuxbox-linux-uclibc-objdump... powerpc-tuxbox-linux-uclibc-objdump
checking how to recognize dependent libraries... pass_all
checking for powerpc-tuxbox-linux-uclibc-dlltool... no
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for powerpc-tuxbox-linux-uclibc-ar... powerpc-tuxbox-linux-uclibc-ar
checking for archiver @FILE support... @
checking for powerpc-tuxbox-linux-uclibc-strip... (cached) powerpc-tuxbox-linux-uclibc-strip
checking for powerpc-tuxbox-linux-uclibc-ranlib... powerpc-tuxbox-linux-uclibc-ranlib
checking command to parse /home/mastag/dbox2/build/cdk/bin/powerpc-tuxbox-linux-uclibc-nm -B output from powerpc-tuxbox-linux-uclibc-gcc object... ok
checking for sysroot... no
checking for powerpc-tuxbox-linux-uclibc-mt... no
checking for mt... no
checking if : is a manifest tool... no
checking for dlfcn.h... yes
checking for objdir... .libs
checking if powerpc-tuxbox-linux-uclibc-gcc supports -fno-rtti -fno-exceptions... no
checking for powerpc-tuxbox-linux-uclibc-gcc option to produce PIC... -fPIC -DPIC
checking if powerpc-tuxbox-linux-uclibc-gcc PIC flag -fPIC -DPIC works... yes
checking if powerpc-tuxbox-linux-uclibc-gcc static flag -static works... yes
checking if powerpc-tuxbox-linux-uclibc-gcc supports -c -o file.o... yes
checking if powerpc-tuxbox-linux-uclibc-gcc supports -c -o file.o... (cached) yes
checking whether the powerpc-tuxbox-linux-uclibc-gcc linker (/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking how to run the C++ preprocessor... powerpc-tuxbox-linux-uclibc-g++ -E
checking for ld used by powerpc-tuxbox-linux-uclibc-g++... /home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld
checking if the linker (/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld) is GNU ld... yes
checking whether the powerpc-tuxbox-linux-uclibc-g++ linker (/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld) supports shared libraries... yes
checking for powerpc-tuxbox-linux-uclibc-g++ option to produce PIC... -fPIC -DPIC
checking if powerpc-tuxbox-linux-uclibc-g++ PIC flag -fPIC -DPIC works... yes
checking if powerpc-tuxbox-linux-uclibc-g++ static flag -static works... yes
checking if powerpc-tuxbox-linux-uclibc-g++ supports -c -o file.o... yes
checking if powerpc-tuxbox-linux-uclibc-g++ supports -c -o file.o... (cached) yes
checking whether the powerpc-tuxbox-linux-uclibc-g++ linker (/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating libconfigfile/Makefile
config.status: creating libconfigfile/tuxbox-configfile.pc
config.status: creating libconnection/Makefile
config.status: creating libconnection/tuxbox-connection.pc
config.status: creating libeventserver/Makefile
config.status: creating libeventserver/tuxbox-eventserver.pc
config.status: creating libmd5sum/Makefile
config.status: creating libmd5sum/tuxbox-md5sum.pc
config.status: creating libmpegtools/Makefile
config.status: creating libmpegtools/tuxbox-mpegtools.pc
config.status: creating libnet/Makefile
config.status: creating libnet/tuxbox-net.pc
config.status: creating libucodes/Makefile
config.status: creating libucodes/tuxbox-ucodes.pc
config.status: creating libxmltree/Makefile
config.status: creating libxmltree/tuxbox-xmltree.pc
config.status: creating libupnpclient/Makefile
config.status: creating libupnpclient/tuxbox-upnpclient.pc
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
configure: WARNING: unrecognized options: --with-driver, --with-dvbincludes, --with-boxtype, --enable-kernel26, --enable-uclibc, --enable-lirc, --enable-ide, --enable-mmc, --enable-ccache, --enable-sqlite, --enable-radiotext, --enable-ipkg, --enable-nfsserver, --with-etherwake
make -C /home/mastag/dbox2/apps/misc/libs all
make[3]: Map '/home/mastag/dbox2/apps/misc/libs' wordt binnengegaan
make  all-recursive
make[4]: Map '/home/mastag/dbox2/apps/misc/libs' wordt binnengegaan
Making all in libconfigfile
make[5]: Map '/home/mastag/dbox2/apps/misc/libs/libconfigfile' wordt binnengegaan
/bin/sh ../libtool --tag=CXX   --mode=compile powerpc-tuxbox-linux-uclibc-g++ -DHAVE_CONFIG_H -I. -I..     -Wall -pipe -Os -fPIC -flto -fuse-linker-plugin -MT configfile.lo -MD -MP -MF .deps/configfile.Tpo -c -o configfile.lo configfile.cpp
libtool: compile:  powerpc-tuxbox-linux-uclibc-g++ -DHAVE_CONFIG_H -I. -I.. -Wall -pipe -Os -fPIC -flto -fuse-linker-plugin -MT configfile.lo -MD -MP -MF .deps/configfile.Tpo -c configfile.cpp  -fPIC -DPIC -o .libs/configfile.o
configfile.cpp: In member function 'bool CConfigFile::saveConfig(const char*)':
configfile.cpp:96:24: error: 'unlink' was not declared in this scope
make[5]: *** [configfile.lo] Fout 1
make[5]: Map '/home/mastag/dbox2/apps/misc/libs/libconfigfile' wordt verlaten
make[4]: *** [all-recursive] Fout 1
make[4]: Map '/home/mastag/dbox2/apps/misc/libs' wordt verlaten
make[3]: *** [all] Fout 2
make[3]: Map '/home/mastag/dbox2/apps/misc/libs' wordt verlaten
make[2]: *** [misc_libs] Fout 2
make[2]: Map '/home/mastag/dbox2/cdk' wordt verlaten
make[1]: *** [/home/mastag/dbox2/build/cdkroot/lib/pkgconfig/tuxbox-xmltree.pc] Fout 2
make[1]: Map '/home/mastag/dbox2/cdk' wordt verlaten
make: *** [/home/mastag/dbox2/apps/dvb/zapit/src/zapit] Fout 2
Any help would be appreciated :)
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Fixed:

To successful build with gcc4.7/uclibc.

/apps/misc/libs/libconfigfile/configfile.cpp needs:
#include <unistd.h> for unlink

/apps/dvb/zapit/src/pzapit.cpp needs:
#include <stdlib.h> for atoi


Also a patch for nfs-utils-1.1.1 is needed for uclibc:
nfs-utils-1.1.1/utils/mount/mount.c - needs #include <sys/stat.h>
nfs-utils-1.1.1/utils/exportfs/exportfs.c - needs #include <sys/stat.h>

Now only thing that needs to be fixed is enigma:

Code: Alles auswählen

powerpc-tuxbox-linux-uclibc-g++ -DHAVE_CONFIG_H -I. -I../..  -I../../include -I../.. -I/home/mastag/dbox2/driver/include -I/home/mastag/dbox2/build/cdkroot/include -I/home/mastag/dbox2/build/cdkroot/include -I/home/mastag/dbox2/driver/include -fno-exceptions -fno-rtti -D_REENTRANT -DDISABLE_DREAMBOX_RC -DDISABLE_CI -DENABLE_FLASHTOOL -DENABLE_PRIVATE_EPG -DENABLE_MHW_EPG -DENABLE_IPKG -DENABLE_SQLITE -DUSE_UCLIBC -I/home/mastag/dbox2/build/cdkroot/include/freetype2 -I/home/mastag/dbox2/build/cdkroot/include   -I/home/mastag/dbox2/build/cdkroot/include   -I/home/mastag/dbox2/build/cdkroot/include/tuxbox   -I/home/mastag/dbox2/build/cdkroot/include -I/home/mastag/dbox2/driver/include   -I/home/mastag/dbox2/build/cdkroot/include/tuxbox   -I/home/mastag/dbox2/build/cdkroot/include/libpng12   -I/home/mastag/dbox2/build/cdkroot/lib/sigc++-1.2/include -I/home/mastag/dbox2/build/cdkroot/include/sigc++-1.2   -I/home/mastag/dbox2/build/cdkroot/include -I/home/mastag/dbox2/driver/include   -I/home/mastag/dbox2/build/cdkroot/include/tuxbox/xmltree    -Wall -pipe -Os -fPIC -flto -fuse-linker-plugin -MT epgcache.o -MD -MP -MF .deps/epgcache.Tpo -c -o epgcache.o epgcache.cpp
In file included from /home/mastag/dbox2/build/cdk/lib/gcc/powerpc-tuxbox-linux-uclibc/4.7.2/../../../../powerpc-tuxbox-linux-uclibc/include/c++/4.7.2/ext/hash_map:61:0,
                 from ../../include/lib/dvb/epgcache.h:6,
                 from epgcache.cpp:1:
/home/mastag/dbox2/build/cdk/lib/gcc/powerpc-tuxbox-linux-uclibc/4.7.2/../../../../powerpc-tuxbox-linux-uclibc/include/c++/4.7.2/backward/backward_warning.h:33:2: warning: #warning This file includes at least one deprecated or antiquated header which may be removed without further notice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated. [-Wcpp]
In file included from epgcache.cpp:1:0:
../../include/lib/dvb/epgcache.h:188:7: error: extra qualification 'eScheduleMhw::' on member 'timeMHW2DVB' [-fpermissive]
../../include/lib/dvb/epgcache.h:189:7: error: extra qualification 'eScheduleMhw::' on member 'timeMHW2DVB' [-fpermissive]
../../include/lib/dvb/epgcache.h:190:7: error: extra qualification 'eScheduleMhw::' on member 'timeMHW2DVB' [-fpermissive]
../../include/lib/dvb/epgcache.h:191:7: error: extra qualification 'eScheduleMhw::' on member 'storeTitle' [-fpermissive]
epgcache.cpp: In member function 'void eEPGCache::load()':
epgcache.cpp:1881:49: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
epgcache.cpp:1882:56: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
epgcache.cpp: In member function 'void eEPGCache::save()':
epgcache.cpp:2004:49: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
epgcache.cpp:2005:56: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
epgcache.cpp: At global scope:
epgcache.cpp:2100:83: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
epgcache.cpp: In member function 'void eScheduleMhw::timeMHW2DVB(u_char, u_char, u_char, u_char*)':
epgcache.cpp:2157:42: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]
make[5]: *** [epgcache.o] Fout 1
make[5]: Map '/home/mastag/dbox2/apps/tuxbox/enigma/lib/dvb' wordt verlaten
make[4]: *** [all-recursive] Fout 1
make[4]: Map '/home/mastag/dbox2/apps/tuxbox/enigma/lib/dvb' wordt verlaten
make[3]: *** [all-recursive] Fout 1
make[3]: Map '/home/mastag/dbox2/apps/tuxbox/enigma/lib' wordt verlaten
make[2]: *** [all-recursive] Fout 1
make[2]: Map '/home/mastag/dbox2/apps/tuxbox/enigma' wordt verlaten
make[1]: *** [all] Fout 2
make[1]: Map '/home/mastag/dbox2/apps/tuxbox/enigma' wordt verlaten
make: *** [enigma] Fout 2
Could anyone provide a patch or fix?
Thanks in advance!

EDIT: also figured out the Enigma issue.
It seems gcc 4.7 needs -fpermissive to build it.

Please commit the above patches/changes so we can successfully build dbox2 images :)
seife
Developer
Beiträge: 4189
Registriert: Sonntag 2. November 2003, 12:36

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von seife »

-fpermissive is only a workaround, it should not go into the repo, the code should be fixed instead (the error messages clearly say what's wrong, so fixes are trivial).
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Well with the changes from my second post.
I got it to build make flash-enigma-all-all

Afterwards there are lots of images in build/cdkflash

I picked enigma-jffs2_lzma.img2x because I'd like jffs2 with compression and flashed it to my dbox2.
Now all it says is: U-Boot 2012.04 and nothing happens.

My serial gives me:

Code: Alles auswählen

debug: BMon V1.1  mID 03                                                       
debug: feID 00    enxID 03                                                     
debug: fpID 52     dsID 01-23.8a.09.08.00.00-12                                
debug: HWrev 41  FPrev 0.23                                                    
debug: B/Ex/Fl(MB) 32/00/08                                                    
WATCHDOG reset enabled                                                         
dbox2:root> debug:                                                             
BOOTP/TFTP bootstrap loader (v0.3)                                             
debug:                                                                         
debug: Transmitting BOOTP request via broadcast                                
debug: Given up BOOTP/TFTP boot                                                
boot net failed                                                                
                                                                               
Flash-FS bootstrap loader (v1.5)                                                
                                                                                
Found Flash-FS superblock version 3.1                                           
Found file /root/platform/sagem-dbox2/kernel/os in Flash-FS                     
debug: Got Block #0040                                                          
                                                                                
will verify ELF image, start= 0x800000, size= 154088                            
verify sig: 262                                                                 
Branching to 0x40100                                                            
                                                                                
                                                                                
U-Boot 2012.04 (Tuxbox) (May 06 2013 - 23:14:53)                                
                                                                                
CPU:   PPC823ZTnnB2 at 66 MHz: 2 kB I-Cache 1 kB D-Cache                        
Board: DBOX2, Sagem, BMon V1.1                                                  
       Watchdog enabled                                                         
I2C:   ready                                                                    
DRAM:  32 MiB                                                                   
Flash: 8 MiB                                                                    
Scanning JFFS2 FS: ........... done.                                            
find_inode failed for name=boot.conf                                            
load: Failed to find inode                                                      
FB:    ready                                                                    
In:    serial                                                                   
Out:   serial                                                                   
Err:   serial                                                                   
Net:   SCC                                                                      
LCD:   ready                                                                    
find_inode failed for name=logo-lcd                                             
load: Failed to find inode                                                      
ready - can't find logo in flash                                                
find_inode failed for name=logo-fb                                              
load: Failed to find inode                                                      
can't find logo in flash                                                        
                                                                                
Options:                                                                        
  1: Console on null                                                            
  2: Console on ttyS0                                                           
  3: Console on framebuffer                                                     
Select option (1-3), other keys to stop autoboot:  0                            
............................................................... done            
Un-Protected 63 sectors                                                         
### FS (jffs2) loading 'vmlinuz' to 0x200000                                    
### FS load complete: 997068 bytes loaded to 0x200000                           
## Booting kernel from Legacy Image at 00200000 ...                             
   Image Name:   Linux-2.6.26.8-dbox2                                           
   Image Type:   PowerPC Linux Kernel Image (gzip compressed)                   
   Data Size:    997004 Bytes = 973.6 KiB                                       
   Load Address: 00000000                                                       
   Entry Point:  00000000                                                       
   Verifying Checksum ... OK                                                    
   Uncompressing Kernel Image ... OK                                            
[    0.000000] Linux version 2.6.26.8-dbox2 (mastag@intel4x) (gcc version 4.7.23
[    0.000000] Zone PFN ranges:                                                 
[    0.000000]   DMA             0 ->     8192                                  
[    0.000000]   Normal       8192 ->     8192                                  
[    0.000000] Movable zone start PFN for each node                             
[    0.000000] early_node_map[1] active PFN ranges                              
[    0.000000]     0:        0 ->     8192                                      
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pa8
[    0.000000] Kernel command line: root=/dev/mtdblock2 rw rootfstype=jffs2 con=
[    0.000000] PID hash table entries: 128 (order: 7, 512 bytes)                
[    0.000000] Decrementer Frequency = 247500000/60                             
[    0.000000] m8xx_wdt: active wdt found (SWTC: 0xFFFF, SWP: 0x1)              
[    0.000000] m8xx_wdt: keep-alive trigger installed (PITC: 0x2000)            
[   14.022528] Console: colour dummy device 80x25                               
[   14.022679] cpm_uart: console: compat mode                                   
[   14.022914] console [ttyCPM0] enabled                                        
[   15.066973] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)    
[   15.145453] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)      
[   15.236337] Memory: 30300k available (1592k kernel code, 480k data, 68k init)
[   15.524140] Mount-cache hash table entries: 512                              
[   15.593224] net_namespace: 192 bytes                                         
[   15.633917] NET: Registered protocol family 16                               
[   15.784127] NET: Registered protocol family 2                                
[   15.932935] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)   
[   16.013920] TCP established hash table entries: 1024 (order: 1, 8192 bytes)  
[   16.095467] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)         
[   16.171192] TCP: Hash tables configured (established 1024 bind 1024)         
[   16.246950] TCP reno registered                                              
[   16.313139] NET: Registered protocol family 1                                
[   16.363083] dbox2: Sagem board detected.                                     
[   16.429597] JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.              
[   16.501783] io scheduler noop registered                                     
[   16.545400] io scheduler deadline registered (default)                       
[   16.638182] Serial: CPM driver $Revision: 0.02 $                             
[   16.690365] cpm_uart: WARNING: no UART devices found on platform bus!        
[   16.767086] cpm_uart: the driver will guess configuration, but this mode is .
[   16.872509] ttyCPM0 at MMIO 0xff000a80 (irq = 20) is a CPM UART              
[   16.944968] ttyCPM1 at MMIO 0xff000a90 (irq = 19) is a CPM UART              
[   17.052623] loop: module loaded                                              
[   17.087856] Linux video capture interface: v2.00                             
[   17.146610] D-Box 2 flash driver (size->0x800000 mem->0x10000000)            
[   17.219015] D-Box 2 flash memory: Found 2 x16 devices at 0x0 in 32-bit bank  
[   17.299890]  Amd/Fujitsu Extended Query Table at 0x0040                      
[   17.361926] number of CFI chips: 1                                           
[   17.402357] cfi_cmdset_0002: Disabling erase-suspend-program due to code bro.
[   17.495190] Creating 5 MTD partitions on "D-Box 2 flash memory":             
[   17.566824] 0x00000000-0x00020000 : "BR bootloader"                          
[   17.634515] 0x00020000-0x00040000 : "FLFS (U-Boot)"                          
[   17.698685] 0x00040000-0x00800000 : "root (jffs2+lzma)"                      
[   17.767623] 0x00020000-0x00800000 : "Flash without bootloader"               
[   17.843509] 0x00000000-0x00800000 : "Complete Flash"                         
[   17.910916] mice: PS/2 mouse device common for all mice                      
[   17.975093] half-duplex mode enabled                                         
[   18.019753] eth0: CPM ENET Version 0.2 on SCC2, 00:50:9c:3c:e4:a3            
[   18.089592] TCP cubic registered                                             
[   18.128225] NET: Registered protocol family 17                               
[   18.972314] VFS: Mounted root (jffs2 filesystem).                            
[   19.029843] Freeing unused kernel memory: 68k init                           
[   19.223523] Kernel panic - not syncing: No init found.  Try passing init= op.
[   19.320294] Rebooting in 180 seconds..
There doesnt seem to be a /init in "cdkflash/root-enigma-jffs2_lzma" ?
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

So I tried to flash: enigma-jffs2.img2x, enigma-jffs2_lzma.img2x and enigma-jffs2_lzma_klzma.img2x
They all show the uboot screen but fail with:

[ 19.223523] Kernel panic - not syncing: No init found. Try passing init= op.
[ 19.320294] Rebooting in 180 seconds..

The root filesystem does have a /sbin/init which points to /bin/busybox.
I believe by default the kernel should look for /sbin/init if I'm not mistaken, so passing init=/sbin/init shouldn't be necessary (i think).

Also I cannot open the uboot console when I press 2 in my terminal:

Code: Alles auswählen

Options:                                                                       
  1: Console on null                                                           
  2: Console on ttyS0                                                           
  3: Console on framebuffer                                                     
Select option (1-3), other keys to stop autoboot:  0
So I cannot try passing init=/sbin/init

Any help would be appreciated :)
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Alright I started all over again clean:

I hope someone could give me some directions.
Most of the wiki and documentation are badly outdated.

So these are the steps I take to build:

From git://git.code.sf.net/p/tuxbox-cvs/:

/home/mastag/dbox2/cdk - master branch
/home/mastag/dbox2/driver - driver_2_6_branch branch
/home/mastag/dbox2/apps - master branch
/home/mastag/dbox2/boot - master branch
/home/mastag/dbox2/hostapps - master branch
/home/mastag/dbox2/sandbox - master branch

/home/mastag/dbox2/ucode - contains all ucodes
/home/mastag/dbox2/build - build prefix

Changes I made:
Modify libconfigfile and zapit:
apps/misc/libs/libconfigfile/configfile.cpp - add #include <unistd.h> to satisfy uclibc
apps/dvb/zapit/src/pzapit.cpp - add #include <stdlib.h> to satisfy uclibc

Modify cdk/Archive/nfs-utils-1.1.1.tar.gz:
nfs-utils-1.1.1/utils/mount/mount.c - add #include <sys/stat.h>
nfs-utils-1.1.1/utils/exportfs/exportfs.c - add #include <sys/stat.h>

Modify cdk/Archive/xfsprogs_2.9.4-1.tar.gz:
Force "-luuid" to satisfy linker

Modify cdk/make/enigma.mk
Add CXXFLAGS="-Wall -Os -mcpu=823 -pipe -fpermissive" to configure to not break on gcc 4.7

configure with:

Code: Alles auswählen

./configure --with-gcc47 --with-boxtype=dbox2 --enable-kernel26 --enable-uclibc \
--with-webif=standard --with-mhw-epg --with-epg=standard \
--with-cvsdir=/home/mastag/dbox2 --with-etherwake --enable-ide \
--enable-xfs --enable-mmc --enable-nfsserver --enable-aformat \
--enable-cdkVcInfo --enable-clock --enable-dboxshot --enable-eraseall \
--enable-fbshot --enable-ipkg --enable-logomask --enable-msgbox --enable-satfind \
--enable-shellexec --enable-sqlite --enable-sysinfo --enable-audioplay \
--enable-aviaext --enable-aviafbtool --enable-avswitch --enable-fbclear \
--with-defaultlocale=english --with-ucodesdir=/home/mastag/dbox2/ucode \
--enable-dropbear --prefix=/home/mastag/dbox2/build --enable-getrc \
--enable-rcinfo --enable-pluginx

Code: Alles auswählen

summary:
----------------------------------------
target cpu/boxtype:             ppc823/dbox2
kernel:                         2.6
kernel config:                  config/dbox2_kernel-2.6.config.m4
libc:                           uclibc
threads:                        nptl
target:                         powerpc-tuxbox-linux-uclibc
host:                           x86_64-unknown-linux-gnu
debug code:                     no
target prefix:                  /home/mastag/dbox2/build/cdkroot
host prefix:                    /home/mastag/dbox2/build/cdk
boot prefix:                    /home/mastag/dbox2/build/tftpboot
build prefix:                   /home/mastag/dbox2/cdk
root partition size:            0x660000
default locale:                 english
serversupport:                  /home/mastag/dbox2/build/serversupport
checkImage:
target apps directory:          /home/mastag/dbox2/apps
boot directory:                 /home/mastag/dbox2/boot
start script directory:         /home/mastag/dbox2/cdk/root
driver directory:               /home/mastag/dbox2/driver
host apps directory:            /home/mastag/dbox2/hostapps
logo directory:                 /home/mastag/dbox2/cdk/logos
customization directory:        /home/mastag/dbox2/cdk
ucode directory:                /home/mastag/dbox2/ucode
archive directory:              /home/mastag/dbox2/cdk/Archive
GNU server:                     ftp.gwdg.de/pub/misc/gnu/ftp/gnu
default server:                 www.tuxbox.org/cvsdata/files
update http prefix:
used busybox-m4-config:         config/busybox.config.m4
IDE support:                    yes
MMC support:                    yes
fdisk standalone:               no
mount standalone:               no
fstab default fs:               ext3
IDE/MMC: Ext2 support           yes / e2fsprogs
IDE/MMC: Ext3 support           yes / e2fsprogs
IDE/MMC: XFS support            yes / xfsprogs
IDE/MMC: REISERFS support       no
IDE/MMC: VFAT support           no
CIFS kernel module:             yes
SMBFS kernel module:            no
LUFS kernel module:             yes
NFS kernel module:              yes
NFS server:                     yes
Samba server:                   no
Automount:                      yes
Neutrino UPnP-support:          no
Neutrino Audioplayer:           yes
Neutrino Movieplayer:           yes
Neutrino Pictureviewer:         yes
Neutrino Mount:                 yes
Neutrino Drive-Setup:           no
Neutrino dvbsub                 yes
Neutrino EPG plus               yes
Radiotext support:              yes
FLAC support:                   no
CURL version:                   old
German keymaps:                 no

aformat                         yes
cdkVcInfo                       yes
blockads                        no
clock                           yes
cron                            no
dboxshot                        yes
dropbear                        yes
dvbsnoop                        no
eraseall                        yes
Esound support:                 no
ether-wake                      yes
fbshot                          yes
gdbserver                       no
getrc                           yes
hddtemp                         no
htop                            no
inadyn-mt                       no
input                           no
ipkg                            yes
kb2rcd                          no
LIRC                            no
lcshot                          no
links text mode browser         no
links graphics mode browser     no
logomask                        yes
msgbox                          yes
netio                           no
openntpd                        no
OpenVPN:                        no
procps                          no
rtc                             yes
satfind                         yes
shellexec                       yes
sqlite3 storage:                yes
strace                          no
sysinfo                         yes
tuxcal                          no
tuxcom                          yes
tuxmail                         yes
tuxtxt (internal)               yes (yes)
tuxwetter                       no
vncviewer                       no
wget                            no

Enigma: dbswitch                yes
Enigma: movieplayer             yes
Enigma: ngrab                   yes
Enigma: rss                     yes
Enigma: script                  yes
Enigma: weather                 no

FX2: C64 Emulator               no
FX2: lcdcirc                    no
FX2: Lemmings                   no
FX2: Mastermind                 no
FX2: MineSweeper                no
FX2: Outdoor                    no
FX2: PacMan                     no
FX2: Satfind                    no
FX2: Snake                      no
FX2: Sokoban                    no
FX2: Sol                        no
FX2: Solitair                   no
FX2: Sudoko                     no
FX2: Tank                       no
FX2: Tetris                     no
FX2: Vier gewinnt               no
FX2: Yahtzee                    no

Tools: audioplay                yes
Tools: aviaext                  yes
Tools: aviafbtool               yes
Tools: avswitch                 yes
Tools: fbclear                  yes
Tools: lcddump                  no
Tools: pluginx                  yes
Tools: rcinfo                   yes
Tools: rcsim                    yes
Tools: saa                      yes
Tools: showptsdiff              no
Tools: switch                   yes

ccache support:                 no
And then build with:
make flash-enigma-all-all

If I forgot something, or did something wrong then please correct me.
Build log will follow.
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

More build errors...

Code: Alles auswählen

[ -x /home/mastag/dbox2/cdk/root-enigma-local.sh ] && KERNEL=2.6 KERNELVERSION=2.6.26.8-dbox2 LIBC=uclibc BOXTYPE=dbox2 BOXMODEL= /home/mastag/dbox2/cdk/root-enigma-local.sh /home/mastag/dbox2/build/cdkflash /home/mastag/dbox2/cdk || true
rm -rf /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs
cp -rd /home/mastag/dbox2/build/cdkflash/root /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs
cp -rd /home/mastag/dbox2/build/cdkflash/root-squashfs/* /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs
cp -rd /home/mastag/dbox2/build/cdkflash/root-enigma/* /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs
rm -rf /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/man /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/share/man
make --assume-old=/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/ld.so.1 mklibs_librarypath=/home/mastag/dbox2/build/cdkflash/root-enigma/lib:/home/mastag/dbox2/build/cdkflash/root-enigma/lib/tuxbox/plugins:/home/mastag/dbox2/build/cdkflash/root/lib:/home/mastag/dbox2/build/cdkflash/root/lib/tuxbox/plugins:/home/mastag/dbox2/build/cdkflash/root-squashfs/lib:/home/mastag/dbox2/build/cdkroot/lib:/home/mastag/dbox2/build/cdkroot/lib/tuxbox/plugins
make[1]: Map '/home/mastag/dbox2/cdk' wordt binnengegaan
find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib -maxdepth 1 -type f -o -type l | xargs rm -f
cp -d /home/mastag/dbox2/build/cdkroot/lib/libnss_dns-?.*.so /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib
cp -d /home/mastag/dbox2/build/cdkroot/lib/libnss_files-?.*.so /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib
/home/mastag/dbox2/hostapps/mklibs/mklibs_uclibc.py --target powerpc-tuxbox-linux-uclibc --libc-extras-dir \
        /home/mastag/dbox2/build/cdkroot/lib/libc_pic \
        -d /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib \
        -D -L /home/mastag/dbox2/build/cdkflash/root-enigma/lib:/home/mastag/dbox2/build/cdkflash/root-enigma/lib/tuxbox/plugins:/home/mastag/dbox2/build/cdkflash/root/lib:/home/mastag/dbox2/build/cdkflash/root/lib/tuxbox/plugins:/home/mastag/dbox2/build/cdkflash/root-squashfs/lib:/home/mastag/dbox2/build/cdkroot/lib:/home/mastag/dbox2/build/cdkroot/lib/tuxbox/plugins \
        --root /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs \
        `find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/bin/ -path "*bin/?*" -type f` \
        `find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/var/bin/ -path "*bin/?*" -type f` \
        `find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/ -name "libnss_*" -type f` \
        `find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/ -name "libsqlite3*" -type f` \
        `find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/ -name "*.so" -type f` \
        `find /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/sbin/ -path "*sbin/?*" -type f`
find: `/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/var/bin/': Bestand of map bestaat niet
I: Using ld-uClibc.so.0 as dynamic linker.
I: library reduction pass 1
1225 symbols, 1047 unresolved
Command failed with status 1 : powerpc-tuxbox-linux-uclibc-gcc -nostdlib -nostartfiles -shared -Wl,-soname=libtuxbox-configfile.so.0 -u_ZN11CConfigFile9getStringEPKcRKSs -u_ZN11CConfigFile8getInt32EPKci -u_init -u_ZN11CConfigFile10loadConfigEPKc -u_ZN11CConfigFileC1Ecb -u_fini -o /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/libtuxbox-configfile.so.0-so  /home/mastag/dbox2/build/cdkroot/lib/libtuxbox-configfile.a   -shared -lgcc -L /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma/lib/tuxbox/plugins -L/home/mastag/dbox2/build/cdkflash/root/lib -L/home/mastag/dbox2/build/cdkflash/root/lib/tuxbox/plugins -L/home/mastag/dbox2/build/cdkflash/root-squashfs/lib -L/home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkroot/lib/tuxbox/plugins -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib:/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkflash/root/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib:/home/mastag/dbox2/build/cdk/powerpc-tuxbox-linux-uclibc/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs///lib/autofs -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//usr/local/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs//home/mastag/dbox2/build/cdkroot/lib -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs///lib/autofs -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs///lib/autofs -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs///lib/autofs -L/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs///lib/autofs -lgcc_s -lstdc++ -lm -lc
With output: /home/mastag/dbox2/build/cdkroot/lib/libtuxbox-configfile.a(configfile.o):(.got2+0x3c): undefined reference to `__dso_handle'
/home/mastag/dbox2/build/cdk/lib/gcc/powerpc-tuxbox-linux-uclibc/4.7.2/../../../../powerpc-tuxbox-linux-uclibc/bin/ld: /home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/libtuxbox-configfile.so.0-so: hidden symbol `__dso_handle' isn't defined
/home/mastag/dbox2/build/cdk/lib/gcc/powerpc-tuxbox-linux-uclibc/4.7.2/../../../../powerpc-tuxbox-linux-uclibc/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status
make[1]: *** [/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs/lib/ld.so.1] Fout 1
make[1]: Map '/home/mastag/dbox2/cdk' wordt verlaten
make: *** [/home/mastag/dbox2/build/cdkflash/root-enigma-squashfs] Fout 2
msrx111
Interessierter
Interessierter
Beiträge: 95
Registriert: Dienstag 14. Juni 2011, 17:50
Image: eigenkompilat neutrino
Image: eigenkompilat neutrino

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von msrx111 »

You dont´t have to build for dbox2 with uclibc.... building with normal libc will work... Last Enigma build of mine was September last year. But there were no changes so it'll build today....

But Why do you want to build with uclibc?????
seife
Developer
Beiträge: 4189
Registriert: Sonntag 2. November 2003, 12:36

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von seife »

actually, the combination of gcc4.7 and uclibc might simply be untested, I'd try without "--with-gcc47" and check if that works.
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Thanks :)

Well using gcc4 instead of gcc47 will produce an image without errors.
But it fails to boot on my Sagem (already posted in the gcc4 thread):

Code: Alles auswählen

/ # Detected STB:
        Vendor: Sagem
        Model: D-BOX2  (2 flash chips)
[   25.237974] [i2c-8xx]: mpc 8xx i2c init
[   25.300975] [i2c-8xx]: adapter: 0
[   25.855241] event: $Id: event.c,v 1.12.4.3 2007/10/09 01:04:05 carjay Exp $
[   26.522968] lcd: init lcd driver module
[   26.585782] lcd: found KS0713/SED153X lcd interface
[   27.243815] input: DBOX-2 FP IR as /devices/virtual/input/input0
[   27.382860] Oops: kernel access of bad area, sig: 11 [#1]
[   27.443444] PREEMPT
[   27.469483] NIP: c0129c30 LR: c012a760 CTR: c012a71c
[   27.528782] REGS: c1d9dd30 TRAP: 0300   Not tainted  (2.6.26.8-dbox2)
[   27.605701] MSR: 00009032 <EE,ME,IR,DR>  CR: 39000053  XER: 8000126e
[   27.681632] DAR: 0000000c, DSISR: c0000000
[   27.730538] TASK = c1c4a800[212] 'modprobe' THREAD: c1d9c000
[   27.796022] GPR00: c012a760 c1d9dde0 c1c4a800 00000000 c1d9de08 00000001 009effd5 c30555c0
[   27.895863] GPR08: 00000001 00000000 c38837c8 00000030 39000053 10080ae4 0000001c 00000033
[   27.995703] GPR16: c1da0820 c305e68c c305eb14 00000033 c305eaec 00000000 0000001e c305e590
[   28.095542] GPR24: 0000001f c305d000 00000000 c30555d0 c1d9e400 c1d29818 00000000 00000002
[   28.197455] NIP [c0129c30] i2c_transfer+0x14/0xbc
[   28.253625] LR [c012a760] i2c_master_send+0x44/0x68
[   28.311848] Call Trace:
[   28.340996] [c1d9dde0] [c305d000] 0xc305d000 (unreliable)
[   28.405471] [c1d9de00] [c012a760] i2c_master_send+0x44/0x68
[   28.472033] [c1d9de20] [c38811fc] fp_sendcmd+0x20/0x40 [dbox2_fp]
[   28.544833] [c1d9de40] [c3061150] dbox2_fp_rc_init+0xc4/0xdc [dbox2_fp_input]
[   28.630113] [c1d9de60] [c3061074] dbox2_fp_input_init+0x74/0x8c [dbox2_fp_input]
[   28.718513] [c1d9de80] [c0036ff8] sys_init_module+0x1490/0x1604
[   28.789232] [c1d9df40] [c0002660] ret_from_syscall+0x0/0x38
[   28.855764] Instruction dump:
[   28.891139] 38a5b71c 90010014 4bfd83d9 80010014 38210010 7c0803a6 4e800020 7c0802a6
[   28.983698] 9421ffe0 bf810010 90010024 7c7e1b78 <8123000c> 542b0024 80090000 7c9c2378
Unknown signal 11
[   30.107660] avia_gt_fb: $Id: avia_gt_fb_core.c,v 1.54.2.5 2007/10/09 01:03:38 carjay Exp $
[   30.203149] /home/mastag/dbox2/driver/dvb/drivers/media/dvb/avia/avia_gt.h: unsupported chipset
modprobe: can't load module avia_gt_fb (extra/dvb/drivers/media/dvb/avia/avia_gt_fb.ko): No such device
[   30.454677] avia_gt_lirc: $Id: avia_gt_lirc.c,v 1.14.4.7 2007/10/09 01:03:38 carjay Exp $
[   30.578494] Oops: kernel access of bad area, sig: 11 [#2]
[   30.639357] PREEMPT
[   30.665394] NIP: c38b6920 LR: c38b6914 CTR: 00000000
[   30.724715] REGS: c1da5d90 TRAP: 0300   Tainted: G      D    (2.6.26.8-dbox2)
[   30.809935] MSR: 00009032 <EE,ME,IR,DR>  CR: 35000039  XER: 8000126e
[   30.885866] DAR: 00000028, DSISR: c0000000
[   30.934772] TASK = c1c5ec00[227] 'modprobe' THREAD: c1da4000
[   31.000255] GPR00: 000186a0 c1da5e40 c1c5ec00 c38c1000 c38b0000 00000000 c3922a7c 00000000
[   31.100096] GPR08: ffffffff 00000000 c0210000 c000b2b4 c0266400 10080ae4 00000017 00000020
[   31.199936] GPR16: c1dd28c0 c305d9ec c305ddac 00000020 c305dd84 00000000 00000019 c305d920
[   31.299777] GPR24: 0000001a c305d000 00000000 c3885af0 c1dcf800 c1da5e68 c38c0000 fffffe00
[   31.401689] NIP [c38b6920] avia_gt_ir_register+0xcc/0x218 [avia_gt]
[   31.476579] LR [c38b6914] avia_gt_ir_register+0xc0/0x218 [avia_gt]
[   31.550403] Call Trace:
[   31.579547] [c1da5e40] [c38b68e0] avia_gt_ir_register+0x8c/0x218 [avia_gt] (unreliable)
[   31.675225] [c1da5e60] [c3063034] init_module+0x34/0xf0 [avia_gt_lirc]
[   31.753226] [c1da5e80] [c0036ff8] sys_init_module+0x1490/0x1604
[   31.823944] [c1da5f40] [c0002660] ret_from_syscall+0x0/0x38
[   31.890478] Instruction dump:
[   31.925861] 3c60c38c 3863d510 480018c9 3be0fff4 48000154 3ca00006 60a51a80 38800000
[   32.018416] 48001901 3d20c38c 8129d784 3c80c38b <a0690028> 38846e3c 4bff6a3d 2f830000
debug: DDF: Calibrating delay loop... debug: DDF: 66.76 BogoMIPS
debug: WATCHDOG RESET
This is with kernel26 and uclibc.

I'd like to use uclibc because of the smalle memory print.
But I can also try a build without uclibc.
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Ok so far:
gcc47 + uclibc + kernel26 = fail
This combination will fail to link to libstdc++ (see prev post)
At the stage where it breaks I find no libstdc++ in cdkflash/lib so I think the toolchain doesn't strip and place it there.

gcc4 + uclibc + kernel26 = fail
Builds fine but produces broken code (see prev post)

Code: Alles auswählen

[   27.382860] Oops: kernel access of bad area, sig: 11 [#1]
[   27.443444] PREEMPT
[   27.469483] NIP: c0129c30 LR: c012a760 CTR: c012a71c...
[   30.203149] /home/mastag/dbox2/driver/dvb/drivers/media/dvb/avia/avia_gt.h: unsupported chipset
modprobe: can't load module avia_gt_fb (extra/dvb/drivers/media/dvb/avia/avia_gt_fb.ko): No such device
gcc4 + kernel26 = fail
kernel complains about binutils being too old.
I think gcc4 is only supported with kernel 2.4 combination (as reported in the gcc4 thread).
Unless binutils is bumped.

gcc47 + kernel26 (glibc instead of uclibc)
Building right now atm...
Will report back soon.

Apologies if this is already known.
Most docs and wiki are outdated and my german is pretty bad.
MastaG
Interessierter
Interessierter
Beiträge: 20
Registriert: Montag 6. Mai 2013, 11:17

Re: Problem building dbox2 enigma (kernel2.6 gcc4.7 uclibc)

Beitrag von MastaG »

Building with gcc47 and kernel26 produces a working image :)

However I have one issue:
When viewing FTA channels on my Sagem DVB-C box it procudes broken picture and skipping sound.
Like it cannot keep up with the stream.
Here is my dmesg:

Code: Alles auswählen

(GCC) ) #5 PREEMPT Wed May 8 15:16:30 CEST 2013
[    0.000000] Entering add_active_range(0, 0, 8192) 0 entries of 256 used
[    0.000000] Zone PFN ranges:
[    0.000000]   DMA             0 ->     8192
[    0.000000]   Normal       8192 ->     8192
[    0.000000] Movable zone start PFN for each node
[    0.000000] early_node_map[1] active PFN ranges
[    0.000000]     0:        0 ->     8192
[    0.000000] On node 0 totalpages: 8192
[    0.000000]   DMA zone: 64 pages used for memmap
[    0.000000]   DMA zone: 0 pages reserved
[    0.000000]   DMA zone: 8128 pages, LIFO batch:0
[    0.000000]   Normal zone: 0 pages used for memmap
[    0.000000]   Movable zone: 0 pages used for memmap
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 8128
[    0.000000] Kernel command line: root=/dev/mtdblock2 rw rootfstype=jffs2 console=ttyS0,9600 dbox_duplex=
[    0.000000] PID hash table entries: 128 (order: 7, 512 bytes)
[    0.000000] Decrementer Frequency = 247500000/60
[    0.000000] m8xx_wdt: active wdt found (SWTC: 0xFFFF, SWP: 0x1)
[    0.000000] m8xx_wdt: keep-alive trigger installed (PITC: 0x2000)
[   23.525756] Console: colour dummy device 80x25
[   23.525908] cpm_uart: console: compat mode
[   23.526143] console [ttyCPM0] enabled
[   24.570207] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
[   24.648688] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
[   24.739572] Memory: 30300k available (1592k kernel code, 480k data, 68k init, 0k highmem)
[   24.839416] Calibrating delay loop... 65.33 BogoMIPS (lpj=326656)
[   25.027408] Mount-cache hash table entries: 512
[   25.096351] net_namespace: 192 bytes
[   25.137156] NET: Registered protocol family 16
[   25.287729] NET: Registered protocol family 2
[   25.436183] IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
[   25.517145] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[   25.598703] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[   25.674429] TCP: Hash tables configured (established 1024 bind 1024)
[   25.750187] TCP reno registered
[   25.816381] NET: Registered protocol family 1
[   25.866282] dbox2: Sagem board detected.
[   25.932991] JFFS2 version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
[   26.004977] io scheduler noop registered
[   26.048633] io scheduler deadline registered (default)
[   26.141789] Serial: CPM driver $Revision: 0.02 $
[   26.194636] cpm_uart: WARNING: no UART devices found on platform bus!
[   26.271357] cpm_uart: the driver will guess configuration, but this mode is no longer supported.
[   26.376778] ttyCPM0 at MMIO 0xff000a80 (irq = 20) is a CPM UART
[   26.449266] ttyCPM1 at MMIO 0xff000a90 (irq = 19) is a CPM UART
[   26.557520] loop: module loaded
[   26.592063] Linux video capture interface: v2.00
[   26.650913] D-Box 2 flash driver (size->0x800000 mem->0x10000000)
[   26.723289] D-Box 2 flash memory: Found 2 x16 devices at 0x0 in 32-bit bank
[   26.804213]  Amd/Fujitsu Extended Query Table at 0x0040
[   26.866241] number of CFI chips: 1
[   26.906570] cfi_cmdset_0002: Disabling erase-suspend-program due to code brokenness.
[   26.999461] Creating 5 MTD partitions on "D-Box 2 flash memory":
[   27.071145] 0x00000000-0x00020000 : "BR bootloader"
[   27.138955] 0x00020000-0x00040000 : "FLFS (U-Boot)"
[   27.203121] 0x00040000-0x00800000 : "root (jffs2+lzma)"
[   27.272052] 0x00020000-0x00800000 : "Flash without bootloader"
[   27.348003] 0x00000000-0x00800000 : "Complete Flash"
[   27.415557] mice: PS/2 mouse device common for all mice
[   27.479227] half-duplex mode enabled
[   27.523911] eth0: CPM ENET Version 0.2 on SCC2, 00:50:9c:3c:e4:a3
[   27.593856] TCP cubic registered
[   27.632496] NET: Registered protocol family 17
[   28.535571] VFS: Mounted root (jffs2 filesystem).
[   28.592359] Freeing unused kernel memory: 68k init
[   37.396513] [i2c-8xx]: mpc 8xx i2c init
[   37.475633] [i2c-8xx]: adapter: 0
[   37.846903] event: $Id: event.c,v 1.12.4.3 2007/10/09 01:04:05 carjay Exp $
[   38.294619] lcd: init lcd driver module
[   38.365577] lcd: found KS0713/SED153X lcd interface
[   38.756013] input: DBOX-2 FP IR as /devices/virtual/input/input0
[   39.157217] avia_av: $Id: avia_av_core.c,v 1.98.2.14 2009/01/17 07:09:44 seife Exp $
[   39.255449] firmware: requesting avia600.ux
[   40.055907] avia_av_core: decoder watchdog thread started.
[   40.125476] avia_av_event: $Id: avia_av_event.c,v 1.11.4.1 2005/01/21 21:23:38 carjay Exp $
[   40.323806] avia_av_proc: $Id: avia_av_proc.c,v 1.14.2.6 2009/02/12 21:00:36 rhabarber1848 Exp $
[   40.930106] avia_gt_core: $Id: avia_gt_core.c,v 1.48.2.6 2007/10/09 01:03:38 carjay Exp $
[   41.035416] avia_gt_core: autodetecting chip type... eNX
[   41.098342] avia_gt_enx: $Id: avia_gt_enx.c,v 1.21 2003/09/30 05:45:35 obi Exp $
[   41.352063] avia_gt_accel: $Id: avia_gt_accel.c,v 1.19.4.1 2007/10/09 01:03:38 carjay Exp $
[   41.455362] avia_gt_dmx: $Id: avia_gt_dmx.c,v 1.210.2.9 2008/11/23 10:26:25 seife Exp $
[   41.561409] firmware: requesting ucode.bin
[   41.656770] avia_gt_ucode: loaded ucode v0014
[   41.715389] avia_gt_ucode: ucode section filters disabled.
[   41.788942] avia_gt_dmx: warning, misaligned queue 0 (is 0xFD200, size 65536), aligning...
[   41.896521] avia_gt_dmx: demux watchdog thread started.
[   41.959217] avia_gt_gv: $Id: avia_gt_gv.c,v 1.39.2.5 2007/10/09 01:03:38 carjay Exp $
[   42.065065] avia_gt_pcm: $Id: avia_gt_pcm.c,v 1.29 2004/01/29 19:38:20 zwen Exp $
[   42.154348] avia_gt_pcm_set_rate(44100)
[   42.201614] avia_gt_capture: $Id: avia_gt_capture.c,v 1.32.4.5 2007/10/09 01:03:38 carjay Exp $
[   42.313490] avia_gt_pig: $Id: avia_gt_pig.c,v 1.40.4.3 2007/10/09 01:03:38 carjay Exp $
[   42.419404] avia_gt_capture: from: 720 x 576 -> 180 x 144, (requested: 180 x 144)
[   42.419676] avia_gt_capture: from: 720 x 576 -> 180 x 144, (requested: 180 x 144)
[   42.419891] avia_gt_vbi: $Id: avia_gt_vbi.c,v 1.26.4.1 2007/10/09 01:03:39 carjay Exp $
[   42.523086] avia_gt_ir: $Id: avia_gt_ir.c,v 1.30.4.6 2008/09/19 22:43:42 seife Exp $
[   42.619597] avia_gt_core: Loaded AViA eNX/GTX driver
[   42.776676] avia_gt_fb: $Id: avia_gt_fb_core.c,v 1.54.2.5 2007/10/09 01:03:38 carjay Exp $
[   42.935801] Console: switching to colour frame buffer device 90x36
[   43.111405] avia_gt_fb: fb0: AViA eNX/GTX FB frame buffer device
[   43.300153] avia_gt_lirc: $Id: avia_gt_lirc.c,v 1.14.4.7 2007/10/09 01:03:38 carjay Exp $
[   43.568472] avia_oss: $Id: avia_gt_oss.c,v 1.26 2004/05/31 22:56:02 carjay Exp $
[   43.662594] avia_gt_pcm_set_rate(44100)
[   43.881445] avia_gt_v4l2: $Id: avia_gt_v4l2.c,v 1.12.4.4 2007/10/09 01:03:38 carjay Exp $
[   44.246645] $Id: cam.c,v 1.30.2.6 2007/10/09 01:03:38 carjay Exp $
[   44.325760] firmware: requesting cam-alpha.bin
[   45.179357] $Id: dbox2_napi_core.c,v 1.1.2.14 2007/10/09 21:52:21 carjay Exp $
[   45.273848] DVB: registering new adapter (C-Cube AViA GTX/eNX with AViA 500/600)
[   45.369019] DVB: registering frontend 0 (Atmel AT76C651B DVB-C)...
[   45.475929] avia_av_napi: $Id: dbox2_avia_av_napi.c,v 1.1.2.2 2009/01/17 07:09:44 seife Exp $
[   45.636028] $Id: dbox2_cam_napi.c,v 1.1.2.1 2005/01/31 03:04:12 carjay Exp $
[   45.755646] avia_gt_napi: $Id: dbox2_avia_gt_napi.c,v 1.1.2.5 2009/01/17 07:09:44 seife Exp $
[   50.225840] RPC: Registered udp transport module.
[   50.279221] RPC: Registered tcp transport module.
[   77.079473] avia_av: setting stream type AVIA_AV_STREAM_TYPE_PES/AVIA_AV_STREAM_TYPE_PES
[   77.177188] PES, queue 0 normal
I did encountered: avia_gt_dmx: queue 6 overflow (count: 1) a few times.

I have the following files in my ucode dir (I renamed cam-alpha-kabel.bin to cam-alpha.bin):
avia600.ux
smartcard_sw
ucode_0014.bin
cam-alpha.bin
ucode.bin -> ucode_0014.bin
ucode_001A.bin

I also tried linking ucode.bin to ucode_001A.bin this produces stable sound but still broken picture.
Any ideas?