Installing an ARM Toolchain in Fedora

You can easily install an arm cross-compiler on Fedora as follows: cd /etc/yum.repos.d/ sudo wget http://ftp.linux.org.uk/pub/linux/arm/fedora/cross/cross.repo sudo yum install armv5tel-redhat-linux-gnueabi-gcc You can check the installation worked by checking the cross-compiler version [jaufranc@localhost ~]$ armv5tel-redhat-linux-gnueabi-gcc -v Using built-in specs. Target: armv5tel-redhat-linux-gnueabi Configured with: ../configure –prefix=/usr –mandir=/usr/share/man –infodir=/usr/share/info –enable-shared –enable-threads=posix –enable-checking=release –with-system-zlib –enable-__cxa_atexit –disable-libunwind-exceptions –enable-languages=c,c++ –disable-libgcj –with-sysroot=yes –enable-version-specific-runtime-libs –target=armv5tel-redhat-linux-gnueabi Thread model: posix gcc version 4.1.2 20070925 (Red Hat 4.1.2-33.fa1) This will only install the C compiler (gcc), to install the C++ compiler, run the following command: sudo yum install armv5tel-redhat-linux-gnueabi-gcc-c++ Tested in Fedora 12. Jean-Luc Aufranc (CNXSoft)Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his job as a software engineering manager, and starting to write daily news, and reviews full time later in 2011. www.cnx-software.com

Cross Compiling libavg for ARM

libavg is a high-level development platform for media-centric applications using Python as scripting language and written in C++. Bear in mind that are many dependencies with libavg 1.6. I have not built all the libraries required, but instead simply taken the pre-built binaries and header files in the qemu overo image and copied the files as follows: mkdir mnt sudo mount -o loop,offset=$[106496*512] overo_sd_alip.img mnt mkdir ~/edev/beagleboard/libs/lib -p mkdir ~/edev/beagleboard/libs/include cp mnt/usr/lib/* ~/edev/beagleboard/libs/lib/ -rf -d cp mnt/lib/* ~/edev/beagleboard/libs/lib/ -rf -d cp /mnt/usr/include/* ~/edev/beagleboard/libs/include -rf -d sudo umount mnt The -d flag skips the symlink, so we need to recreate then for all library so that the compiler can find libname.so instead of libname.so.12. Save the following scripts to symlinks.sh:

and run it where the arm libraries are located (in my case in /home/jaufranc/edev/beagleboard/libs/lib, /home/jaufranc/edev/beagleboard/libs/lib/arm-linux-gnueabi and /home/jaufranc/edev/beagleboard/libs/lib/mesa). This will  create symlinks for most libraries, but not all. Some will still […]

Cross-Compiling Mesa 3D Graphics Library for ARM

Mesa is an open-source implementation of the OpenGL specification that can be used for software emulation or  complete hardware acceleration for modern GPUs.The Mesa library is used by a variety of games (e.g. Quake 2.3), libraries (e.g PyOpenGL), science and technical applications and utilities (e.g. xscreensaver). MesaLib requires X11 libraries. I’ll assume those are already cross-compiled here. For this build, I used pre-built X11 libraries found in ALIP (ARM Internet Platform) binaries. I used the method described here and copied the libs in /lib and /usr/lib and header files in /lib/include found in the qemu overo image respectively to /home/jaufranc/edeve/beagleboard/libs/lib and /home/jaufranc/edeve/beagleboard/libs/include. make sure you use the “-d” with cp to avoid copying the symlinks or some symbolic links would point to x86 binaries or files that do not exist. Here are the instructions to cross-compile MesaLib 7.11 for ARM using arm-linux-guneabi-gcc: Download the latest version of Mesa source code: […]

Cross Compiling Boost C++ Libraries for ARM

Boost provides free peer-reviewed portable C++ source libraries. Ten Boost libraries are already included in the C++ Standards Committee’s Library Technical Report and will be in the new C++11 Standard. The Boost C++ libraries are already included in popular Linux and Unix distributions such as Fedora, Debian, Ubuntu and NetBSD and are used by projects such as Python, Xibo, Civilization IV, etc.. Here are the steps to cross-compile Boost C++ libraries for arm using arm-linux-guneabi-g++: Download the source code:

Extract the source code:

Bootstrap the code:

Modify the configuration file (project-build.jam) to use the ARM toolchain by replacing the line with “using gcc” by:

Install the python development package:

Build and install the boost libraries:

This was tested in Ubuntu 11.04 (natty) and 10.04 LTS with linaro g++ toolchain. Jean-Luc Aufranc (CNXSoft)Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his […]

Redirect all output to a log file

When you build a program or execute a shell command, the messages are often outputted to both standard output and standard error. If you want to send all ‘printf’ to a log file, use the following command: make > make.log 2>&1 “2>&1”  is the part that redirects standard error to standard out, allowing you to capture all messages. Jean-Luc Aufranc (CNXSoft)Jean-Luc started CNX Software in 2010 as a part-time endeavor, before quitting his job as a software engineering manager, and starting to write daily news, and reviews full time later in 2011. www.cnx-software.com

Summary of Google Devfest 2011 Chiang Mai, Thailand

I attended Google Devfest 2011 in Chiang Mai, Thailand last Saturday (24 September 2011) . This was really interesting and enlightening. So if are a developer, I really recommend to register to a Devfest if Google comes to your city. I was relatively surprised by the number of attendees which I estimate between 150 to 200. This Devfest focused on three main subjects: Android HTML5 (and Chrome) Google Analytics Please find the complete schedule below: Track 1 Track 2 09:00 – 09:30 Keynote 09:30 – 10:30 Android Market for Developers (Ankur Kotwal) 10:30 – 11:00 AM Break 11:00 – 12:00 Bleeding Edge HTML5 (Eric Bidelman) 12:00 – 13:00 Implementing Google Analytics (Vinoaj Vijeyakumaar) 13:00 – 14:00 Lunch 14:00 – 15:00 What’s New and Important in Android (Ankur Kotwal) Displaying Large Geographic Datasets: Google Fusion Tables (Luke Mahe) 15:00 – 16:00 These Aren’t the Site You’re Looking For: Modern HTML5 Web Apps (Eric Bidelman) Working Off the Grid: HTML5 Offline (Ernest Delgado) 16:00 – 16:30 PM Break 16:30 – 17:30 Insights […]

Learn How to Optimize Android Apps for Tablet

After India and the US last month, Google will organize Android Developer labs sessions in Europe to train developers to optimize their applications for Tablets. Registration is now open for the following European cities: Berlin — September 28 and 29. London — October 3 and 5. Paris — October 27 and 28. Sometimes late October…, but you can register now. This ADL series isn’t another set of introduction-to-Android sessions, nor any other kind of general overview like you may have at Google Devfest. It’s specifically aimed at optimizing Android applications for tablets, in particular creating high-quality tablet applications to provide a polished user interface and an enjoyable user-experience. Registration is open to anyone, but as Google can only accommodate a relatively small number of attendees, they will select attendees who already have an high quality Android app with the potential to be a top-tier tablet app. This series of labs will teach you: The best practices […]

Select an ARM MCU during Development with Atollic TrueSTUDIO for ARM

Atollic has released the latest version of TrueSTUDIO development tool for ARM, a C/C++ development tool for embedded developer that looks similar to Eclipse. It supports micro-controllers from a number of semiconductor manufacturers, making it possible to switch MCU supplier during the design process. This release of TrueSTUDIO supports several ARM MCU cores such as ARM7, ARM9, Cortex-M0, Cortex-M1, Cortex-M3 and Cortex-M4 processors. It also includes device-specific support for an extensive list of ARM processor-based micro-controller families, including: Atmel AT91SAM, EnergyMicro EFM32, Freescale Kinetis, Fujitsu FM3, STMicroelectronics STM32, Texas Instruments Stellaris and Toshiba TX. As well as an optimizing C/C++ compiler and a multiprocessor-aware debugger, the tool also has serial wire viewer tracing, graphical UML diagram editors for model-based design and architecture, performs code-quality analysis via TrueINSPECTOR and TrueANALYSER and features a test-automation toolbox (TureVERIFIER). There is also an ECLIPSE-based IDE with editor, x86 C/C++ build and debug tools for development of […]