Wiki > Main > PortingHowTo (compare)
Difference: PortingHowTo (r9 vs. r8)
When starting to port Rockbox to a new platform, the first thing to do is create a new build target. This will allow Rockbox to be configured and built for the new platform. In order to do this, you need to edit some files, and create some new ones.
This is the tool that creates a build tree for a target. It creates a Makefile and an autoconf.h file. Find the "# Figure out target platform" comment in the script and add an entry for your target, preferably by copying an existing one. You will then need to set up a bunch of variables for your specific target. Here is the iAudio X5 target:
30|x5) 1 |x5) target_id=12 # a unique number identifying this target, IS NOT the menu number. # Just use the currently highest number+1 when you add a new target. modelname="x5" # This is the name of the target, used later on in the script target="-DIAUDIO_X5" # The #define used in firmware/export/config.h for conditional compilation memory=16 # how many megabytes of RAM coldfirecc # Which compiler to use, see the beginning of the file tool="$rootdir/tools/scramble -add=iax5" # Which command to use for creating a rockbox binary to be loaded by the boot loader bmp2rb_mono="$rootdir/tools/bmp2rb -f 0" # How to create a monochrome bitmap bmp2rb_native="$rootdir/tools/bmp2rb -f 4" # How to create a native bitmap bmp2rb_remotemono="$rootdir/tools/bmp2rb -f 0" # How to create a monochrome bitmap for the remote lcd bmp2rb_remotenative="$rootdir/tools/bmp2rb -f 0" # How to create a native bitmap for the remote lcd output="rockbox.iaudio" # The name of the Rockbox binary file appextra="recorder:gui" # What directories in the apps/ tree to include in compilation archosrom="" # The name of the binary file if the device supports running directly from flash (mostly Archos related) flash="" # The name of the Rockbox binary file if the device supports having the binary in flash (mostly Archos related) plugins="yes" # Does it support plugins? codecs="libmad liba52 libffmpegFLAC libTremor libwavpack dumb libmusepack libalac libfaad libm4a" # What codecs it supports # toolset is the tools within the tools directory that we build for # this particular target. toolset="$iaudiobitmaptools" # architecture, manufacturer and model for the target-tree build t_cpu="coldfire" t_manufacturer="iaudio" t_model="x5" ;;
Here you need to add
Here you might need to add or change a few things to create binaries for your platform.
This file dictates which source files are compiled into the firmware. Make sure all files you need to be build are listed here. Also add all new drivers you add to the target tree to the bottom of this file. Use
This file dictates which features and plugins are compiled. Make sure all features and plugins you need for your target are included here and use
Here [platform] is the name of the system (eg. config-ipodmini.h). ipodmini.h). This file should contain all
Add drivers specific to your device's hardware here. Replace [cpu], [manufacturer] and [model] with your device's details. For more details, see TargetTree.
r10 - 18 Mar 2010 - 21:57:10 - MarcinBukatRevision r9 - 02 Feb 2010 - 19:47 - MichaelSparmann
Revision r8 - 16 Sep 2009 - 07:44 - BjornStenberg
Copyright © by the contributing authors.