EngineerZone
All Places
Processors and DSP
Software and Development Tools
GNU Toolchain for Blackfin
Discussions
As i new with this uclinux and blackfin. I want to know how to port uclinux on blackfin?
I am host pc is Linux (Ubuntu), i had installed tool chain by following http://docs.blackfin.uclinux.org/doku.php?id=toolchain:installing
Installing Packages on a Debian-based distro
You can try using the update repository to install things, in three simple steps. (coLinux users, who are using the coLinux install from this site can skip steps one and two, since this is installed by default):
Install the ADI key: $ wget http://download.analog.com/27516/distros/debian/apt.key $ sudo apt-key add apt.key
Add this line to /etc/apt/sources.list.d/blackfin.sources.list by: $ sudo su - # mkdir -p /etc/apt/sources.list.d # cd /etc/apt/sources.list.d # echo deb http://download.analog.com/27516/distros/debian stable main > blackfin.sources.list
Update all your local cache files:$ sudo apt-get update
Then install the toolchain tuple you're interested in:$ sudo apt-get install blackfin-toolchain-uclinux blackfin-toolchain-linux-uclibc
after that i set the environment path variable by
$ export PATH=$PATH:/opt/uClinux/bfin-uclinux/bin:/opt/uClinux/bfin-linux-uclibc/bin
after that i compiled a small C code using this tool chain, n got .o and .gdb file.
first i want run image of uclinux on simulator, so downloaded skyeye 1.2.4
after untar,
while doing "make" on skyeye,
root@ubuntu:/opt/uClinux/skyeye-1.2.4# make
--------------------------- NOTICE ------------------------------
If you always get error, please run "make NO_CHECK=1" instead.
-----------------------------------------------------------------
Checking whether host is big endian ... no
Checking gcc ... OK ( gcc version: 4.4.3 )
Checking whether the compiler supports x86 asm ... FAILED
*** It seems that the compiler don't support inline x86 AT&T ASM codes.
*** Run "make NO_DBCT=1" instead to ignore it.
make: *** [check] Error 1
root@ubuntu:/opt/uClinux/skyeye-1.2.4# ^C
root@ubuntu:/opt/uClinux/skyeye-1.2.4# make NO_CHECK=1
gcc -c device/nandflash/nandflash_smallblock.c -o binary/nandflash_smallblock.o -g -O2 -D_FILE_OFFSET_BITS=64 -DSTANDALONE -DDEFAULT_INLINE=0 -DMODET -DMODET -I arch/arm -I arch/arm/common -I arch/arm/common/mmu -I arch/arm/mach -I arch/bfin/common -I arch/bfin/mach -I arch/coldfire/common -I arch/ppc/common -I device -I device/net -I device/lcd -I device/flash -I device/uart -I device/nandflash -I utils -I utils/share -I utils/main -I utils/config -I utils/debugger -DARM -I. -DGTK_LCD
device/nandflash/nandflash_smallblock.c: In function ‘nandflash_sb_setup’:
device/nandflash/nandflash_smallblock.c:521: warning: incompatible implicit declaration of built-in function ‘free’
device/nandflash/nandflash_smallblock.c:528: warning: incompatible implicit declaration of built-in function ‘free’
device/nandflash/nandflash_smallblock.c:550: warning: incompatible implicit declaration of built-in function ‘free’
device/nandflash/nandflash_smallblock.c:555: warning: format ‘%d’ expects type ‘int’, but argument 2 has type ‘__off64_t’
device/nandflash/nandflash_smallblock.c:559: warning: incompatible implicit declaration of built-in function ‘free’
device/nandflash/nandflash_smallblock.c:539: warning: ignoring return value of ‘write’, declared with attribute warn_unused_result
device/nandflash/nandflash_smallblock.c: In function ‘nandflash_sb_uninstall’:
device/nandflash/nandflash_smallblock.c:612: warning: incompatible implicit declaration of built-in function ‘free’
In file included from /usr/include/fcntl.h:205,
from device/nandflash/nandflash_smallblock.c:19:
In function ‘open’,
inlined from ‘nandflash_sb_setup’ at device/nandflash/nandflash_smallblock.c:519:
/usr/include/bits/fcntl2.h:51: error: call to ‘__open_missing_mode’ declared with attribute error: open with O_CREAT in second argument needs 3 arguments
make: *** [binary/nandflash_smallblock.o] Error 1
root@ubuntu:/opt/uClinux/skyeye-1.2.4# make NO_DBCT=1
--------------------------- NOTICE ------------------------------
If you always get error, please run "make NO_CHECK=1" instead.
-----------------------------------------------------------------
Checking whether host is big endian ... no
Checking gcc ... OK ( gcc version: 4.4.3 )
Checking bfd library ... FAILED
*** It seems that you don't have bfd library.
*** Run "make NO_BFD=1" instead to ignore it.
make: *** [check] Error 1
I want to know how to port uclinux on blackfin. The tool chain which is i had installed is right one..?? which uclinux version is better to use? which uboot i have to use? Is uboot is required for running the uclinux on simulator? and how to make image of uclinux.? which filesystem is required for porting?
Tell me the procedure and guide me in this because in not handy with this uclinux and blackfin.
You don't need to port uClinux on blackfin. This is already done by ADI. You just need to download uClinux-dist source package, configure and build. The latest stable release is 2011R1. You have to build and boot uboot for your board before you can run Linux. ext2/3, initramfs, jffs2, ubifs, romfs and other file systems are already supported by uClinux distribution from ADI.
Please refer to docs.blackfin.uclinux.org for detals and download source tar balls on blackfin.uclinux.org.
i want to configure eclipse with blackfin tool chain, as i had installed toolchain and also compiled small c code, bt want to use eclipse for our project. any suggestion ??
As i had installed all the above plug in. But i am getting error in building the code. i followed this: http://docs.blackfin.uclinux.org/doku.php?id=toolchain:eclipse:install .
Error is as follows:
**** Build of configuration Debug for project test ****
**** WARNING: The "Debug" Configuration may not build ****
**** because it uses the "Blackfin Linux FDPIC (bfin-linux-uclibc)" ****
**** tool-chain that is unsupported on this system. ****
**** Attempting to build... ****
make all
Building file: ../src/hello.c
Invoking: Blackfin FDPIC C Compiler
bfin-linux-uclibc-gcc -D_KERNEL_ -D_linux_ -Dlinux -I/opt/uClinux/bfin-uclinux/bin:/opt/uClinux/bfin-linux-uclibc/bin -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF"src/hello.d" -MT"src/hello.d" -o"src/hello.o" "../src/hello.c"
/bin/sh: bfin-linux-uclibc-gcc: not found
make: *** [src/hello.o] Error 127
As my path is /opt/uClinux/bfin-uclinux/bin:/opt/uClinux/bfin-linux-uclibc/bin.
Can i can compile the code with this toolchain on terminal, but not on eclipse
Hi,
Please don't post the same question 5 times over 4 different threads.
The error you are seeing would happen if the compiler wasn't visible to eclipse, e.g. it's not in the PATH.
You say you are on Ubuntu. How are you setting your PATH and how are you launching Eclipse?
Stu
>> **** WARNING: The "Debug" Configuration may not build ****
>> **** because it uses the "Blackfin Linux FDPIC (bfin-linux-uclibc)" ****
>> **** tool-chain that is unsupported on this system. ****
Your issue regarding the warning that is put out when you build has been logged as http://blackfin.uclinux.org/gf/tracker/7292.