3 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
4 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
5 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
6 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
11 # global CC options for all platforms
12 CCOPTS
="-W -Wall -Wundef -O -nostdlib -ffreestanding -Wstrict-prototypes -pipe"
14 use_logf
="#undef ROCKBOX_HAS_LOGF"
16 scriptver
=`echo '$Revision$' | sed -e 's:\\$::g' -e 's/Revision: //'`
21 # Begin Function Definitions
31 WINDRES
=${prefix}windres
32 DLLTOOL
=${prefix}dlltool
33 DLLWRAP
=${prefix}dllwrap
34 RANLIB
=${prefix}ranlib
42 if [ "$ARG_ARM_EABI" = "1" ]; then
43 prefixtools arm-elf-eabi-
51 # scan the $PATH for the given command
58 # echo "checks for $file in $path" >&2
59 if test -f "$path/$file"; then
64 # check whether caller wants literal return value if not found
65 if [ "$2" = "--lit" ]; then
70 # scan the $PATH for sdl-config - if crosscompiling, require that it is
71 # a mingw32 sdl-config
78 #echo "checks for $file in $path" >&2
79 if test -f "$path/$file"; then
80 if [ "yes" = "${crosscompile}" ]; then
81 if [ "0" != `$path/$file --libs |grep -c mwindows` ]; then
95 # default tool setup for native building
99 GCCOPTS
='-W -Wall -g -fno-builtin'
102 output
="rockboxui" # use this as default output binary name
107 if [ $1 = "sdl" ]; then
108 if [ -z "$sdl" ]; then
109 echo "configure didn't find sdl-config, which indicates that you"
110 echo "don't have SDL (properly) installed. Please correct and"
111 echo "re-run configure!"
114 # generic sdl-config checker
115 sdl_cflags
=`$sdl --cflags`
116 sdl_libs
=`$sdl --libs`
120 # default share option, override below if needed
121 SHARED_FLAG
="-shared"
125 echo "Cygwin host detected"
128 GCCOPTS
="$GCCOPTS $sdl_cflags"
129 LDOPTS
="-mconsole $sdl_libs"
131 output
="rockboxui.exe" # use this as output binary name
135 echo "MinGW host detected"
138 GCCOPTS
="$GCCOPTS $sdl_cflags"
139 LDOPTS
="-mconsole $sdl_libs"
141 output
="rockboxui.exe" # use this as output binary name
145 echo "Linux host detected"
146 GCCOPTS
="$GCCOPTS $sdl_cflags"
151 echo "FreeBSD host detected"
153 GCCOPTS
="$GCCOPTS $sdl_cflags"
158 echo "Darwin host detected"
160 GCCOPTS
="$GCCOPTS $sdl_cflags"
162 SHARED_FLAG
="-dynamiclib -Wl\,-single_module"
166 echo "[ERROR] Unsupported system: $uname, fix configure and retry"
171 GCCOPTS
="$GCCOPTS -I\$(SIMDIR)"
173 if test "X$crosscompile" != "Xyes"; then
174 if [ "`uname -m`" = "x86_64" ] ||
[ "`uname -m`" = "amd64" ]; then
175 # fPIC is needed to make shared objects link
176 # setting visibility to hidden is necessary to avoid strange crashes
177 # due to symbol clashing
178 GCCOPTS
="$GCCOPTS -fPIC -fvisibility=hidden"
182 cat >$tmpdir/conftest-
$id.c
<<EOF
184 int main(int argc, char **argv)
187 char *varp = (char *)&var;
195 $CC -o $tmpdir/conftest-
$id $tmpdir/conftest-
$id.c
2>/dev
/null
197 if test `$tmpdir/conftest-$id 2>/dev/null` -gt "1"; then
205 if [ $1 = "sdl" ]; then
206 echo "Simulator environment deemed $endian endian"
207 elif [ $1 = "checkwps" ]; then
208 echo "CheckWPS environment deemed $endian endian"
211 # use wildcard here to make it work even if it was named *.exe like
213 rm -f $tmpdir/conftest-
$id*
215 # We are crosscompiling
216 # add cross-compiler option(s)
217 prefixtools i586-mingw32msvc-
218 LDOPTS
="-mconsole $sdl_libs"
219 output
="rockboxui.exe" # use this as output binary name
220 endian
="little" # windows is little endian
225 # functions for setting up cross-compiler names and options
226 # also set endianess and what the exact recommended gcc version is
227 # the gcc version should most likely match what versions we build with
232 GCCOPTS
="$CCOPTS -m1"
233 GCCOPTIMIZE
="-fomit-frame-pointer -fschedule-insns"
239 prefixtools calmrisc16-unknown-elf-
240 GCCOPTS
="-Wl\,--no-check-sections $CCOPTS"
241 GCCOPTIMIZE
="-fomit-frame-pointer"
246 prefixtools m68k-elf-
247 GCCOPTS
="$CCOPTS -m5206e -Wa\,-m5249 -malign-int -mstrict-align"
248 GCCOPTIMIZE
="-fomit-frame-pointer"
255 GCCOPTS
="$CCOPTS -mcpu=arm7tdmi"
256 if test "X$1" != "Xshort" -a "$ARG_ARM_EABI" != "1"; then
257 GCCOPTS
="$GCCOPTS -mlong-calls"
259 GCCOPTIMIZE
="-fomit-frame-pointer"
265 GCCOPTS
="$CCOPTS -mcpu=arm9tdmi"
266 if test "$modelname" != "gigabeatfx" -a "$t_manufacturer" != "as3525" -a "$ARG_ARM_EABI" != "1"; then
267 GCCOPTS
="$GCCOPTS -mlong-calls"
269 GCCOPTIMIZE
="-fomit-frame-pointer"
275 GCCOPTS
="$CCOPTS -mbig-endian -mcpu=arm940t"
276 if test "ARG_ARM_EABI" != "1"; then
277 GCCOPTS
="$GCCOPTS -mlong-calls"
279 GCCOPTIMIZE
="-fomit-frame-pointer"
285 GCCOPTS
="$CCOPTS -mcpu=arm940t"
286 if test "ARG_ARM_EABI" != "1"; then
287 GCCOPTS
="$GCCOPTS -mlong-calls"
289 GCCOPTIMIZE
="-fomit-frame-pointer"
295 GCCOPTS
="$CCOPTS -mcpu=arm9e"
296 if test "ARG_ARM_EABI" != "1"; then
297 GCCOPTS
="$GCCOPTS -mlong-calls"
299 GCCOPTIMIZE
="-fomit-frame-pointer"
305 GCCOPTS
="$CCOPTS -mcpu=arm926ej-s"
306 if test "ARG_ARM_EABI" != "1"; then
307 GCCOPTS
="$GCCOPTS -mlong-calls"
309 GCCOPTIMIZE
="-fomit-frame-pointer"
315 GCCOPTS
="$CCOPTS -mcpu=arm1136jf-s"
316 if test "$modelname" != "gigabeats" -a "ARG_ARM_EABI" != "1"; then
317 GCCOPTS
="$GCCOPTS -mlong-calls"
319 GCCOPTIMIZE
="-fomit-frame-pointer"
325 GCCOPTS
="$CCOPTS -mcpu=arm1176jz-s"
326 if test "ARG_ARM_EABI" != "1"; then
327 GCCOPTS
="$GCCOPTS -mlong-calls"
329 GCCOPTIMIZE
="-fomit-frame-pointer"
334 prefixtools mipsel-elf-
335 GCCOPTS
="$CCOPTS -march=mips32 -mtune=r4600 -mno-mips16 -mno-long-calls"
336 GCCOPTS
="$GCCOPTS -ffunction-sections -msoft-float -G 0 -Wno-parentheses"
337 GCCOPTIMIZE
="-fomit-frame-pointer"
343 atype
=`echo "$1" | cut -c 2-`
344 ##################################################################
345 # Prompt for specific developer options
347 if [ "$atype" ]; then
352 echo "Enter your developer options (press enter when done)"
353 printf "(D)EBUG, (L)ogf, (S)imulator, (P)rofiling, (V)oice, (W)in32 crosscompile"
354 if [ "$memory" = "2" ]; then
357 if [ "$modelname" = "archosplayer" ]; then
358 printf ", Use (A)TA poweroff"
360 if [ "$t_model" = "ondio" ]; then
361 printf ", (B)acklight MOD"
363 if [ "$modelname" = "iaudiom5" ]; then
364 printf ", (F)M radio MOD"
366 if [ "$modelname" = "iriverh120" ]; then
373 while [ $cont = "1" ]; do
375 if [ "$interact" ]; then
378 option
=`echo "$atype" | cut -c 1`
383 if [ "yes" = "$profile" ]; then
384 echo "Debug is incompatible with profiling"
386 echo "DEBUG build enabled"
391 echo "logf() support enabled"
395 echo "Simulator build enabled"
399 if [ "yes" = "$use_debug" ]; then
400 echo "Profiling is incompatible with debug"
402 echo "Profiling support is enabled"
407 echo "Voice build selected"
411 if [ "$memory" = "2" ]; then
413 echo "Memory size selected: 8MB"
417 if [ "$modelname" = "archosplayer" ]; then
418 have_ata_poweroff
="#define HAVE_ATA_POWEROFF"
419 echo "ATA poweroff enabled"
423 if [ "$t_model" = "ondio" ]; then
424 have_backlight
="#define HAVE_BACKLIGHT"
425 echo "Backlight functions enabled"
429 if [ "$modelname" = "iaudiom5" ]; then
430 have_fmradio_in
="#define HAVE_FMRADIO_IN"
431 echo "FM radio functions enabled"
435 if [ "$modelname" = "iriverh120" ]; then
436 config_rtc
="#define CONFIG_RTC RTC_DS1339_DS3231"
437 have_rtc_alarm
="#define HAVE_RTC_ALARM"
438 echo "RTC functions enabled (DS1339/DS3231)"
442 echo "Enabling Windows 32 cross-compiling"
446 if [ "$interact" ]; then
449 echo "[ERROR] Option $option unsupported"
453 if [ "$interact" ]; then
454 btype
="$btype$option"
456 atype
=`echo "$atype" | cut -c 2-`
457 [ "$atype" ] || cont
=0
462 if [ "yes" = "$voice" ]; then
463 # Ask about languages to build
465 voicelanguage
=`whichlang`
466 echo "Voice language set to $voicelanguage"
468 # Configure encoder and TTS engine for each language
469 for thislang
in `echo $voicelanguage | sed 's/,/ /g'`; do
470 voiceconfig
"$thislang"
473 if [ "yes" = "$use_debug" ]; then
475 GCCOPTS
="$GCCOPTS -g -DDEBUG"
477 if [ "yes" = "$logf" ]; then
478 use_logf
="#define ROCKBOX_HAS_LOGF 1"
480 if [ "yes" = "$simulator" ]; then
482 extradefines
="$extradefines -DSIMULATOR"
486 if [ "yes" = "$profile" ]; then
487 extradefines
="$extradefines -DRB_PROFILE"
488 PROFILE_OPTS
="-finstrument-functions"
492 # Configure voice settings
495 if [ ! "$ARG_TTS" ]; then
496 echo "Building $thislang voice for $modelname. Select options"
500 if [ -n "`findtool flite`" ]; then
504 DEFAULT_TTS_OPTS
=$FLITE_OPTS
505 DEFAULT_NOISEFLOOR
="500"
508 if [ -n "`findtool espeak`" ]; then
512 DEFAULT_TTS_OPTS
=$ESPEAK_OPTS
513 DEFAULT_NOISEFLOOR
="500"
516 if [ -n "`findtool festival`" ]; then
517 FESTIVAL
="(F)estival "
520 FESTIVAL_OPTS
="--language italian"
523 FESTIVAL_OPTS
="--language spanish"
526 FESTIVAL_OPTS
="--language finnish"
529 FESTIVAL_OPTS
="--language czech"
535 DEFAULT_TTS
="festival"
536 DEFAULT_TTS_OPTS
=$FESTIVAL_OPTS
537 DEFAULT_NOISEFLOOR
="500"
540 if [ -n "`findtool swift`" ]; then
544 DEFAULT_TTS_OPTS
=$SWIFT_OPTS
545 DEFAULT_NOISEFLOOR
="500"
548 # Allow SAPI if Windows is in use
549 if [ -n "`findtool winver`" ]; then
553 DEFAULT_TTS_OPTS
=$SAPI_OPTS
554 DEFAULT_NOISEFLOOR
="500"
558 if [ "$FESTIVAL" = "$FLITE" ] && [ "$FLITE" = "$ESPEAK" ] && [ "$ESPEAK" = "$SAPI" ] && [ "$SAPI" = "$SWIFT" ]; then
559 echo "You need Festival, eSpeak or Flite in your path, or SAPI available to build voice files"
563 if [ "$ARG_TTS" ]; then
566 echo "TTS engine to use: ${FLITE}${FESTIVAL}${ESPEAK}${SAPI}${SWIFT}(${DEFAULT_CHOICE})?"
569 advopts
="$advopts --tts=$option"
573 NOISEFLOOR
="500" # TODO: check this value
579 TTS_OPTS
=$ESPEAK_OPTS
582 TTS_ENGINE
="festival"
584 TTS_OPTS
=$FESTIVAL_OPTS
597 TTS_ENGINE
=$DEFAULT_TTS
598 TTS_OPTS
=$DEFAULT_TTS_OPTS
599 NOISEFLOOR
=$DEFAULT_NOISEFLOOR
601 echo "Using $TTS_ENGINE for TTS"
603 # Select which voice to use for Festival
604 if [ "$TTS_ENGINE" = "festival" ]; then
605 voicelist
=`echo "(voice.list)"|festival -i 2>/dev/null |tr "\n" " "|sed -e 's/.*festival> (\(.*\)) festival>/\1/'|sort`
606 for voice
in $voicelist; do
607 TTS_FESTIVAL_VOICE
="$voice" # Default choice
610 if [ "$ARG_VOICE" ]; then
614 for voice
in $voicelist; do
615 printf "%3d. %s\n" "$i" "$voice"
618 printf "Please select which Festival voice to use (default is $TTS_FESTIVAL_VOICE): "
622 for voice
in $voicelist; do
623 if [ "$i" = "$CHOICE" -o "$voice" = "$CHOICE" ]; then
624 TTS_FESTIVAL_VOICE
="$voice"
628 advopts
="$advopts --voice=$CHOICE"
629 echo "Festival voice set to $TTS_FESTIVAL_VOICE"
630 echo "(voice_$TTS_FESTIVAL_VOICE)" > festival-prolog.scm
633 # Read custom tts options from command line
634 if [ "$ARG_TTSOPTS" ]; then
635 TTS_OPTS
="$ARG_TTSOPTS"
636 advopts
="$advopts --ttsopts='$TTS_OPTS'"
637 echo "$TTS_ENGINE options set to $TTS_OPTS"
640 if [ "$swcodec" = "yes" ]; then
643 ENC_OPTS
="-q 4 -c 10"
645 if [ -n "`findtool lame`" ]; then
648 ENC_OPTS
="--resample 12 -t -m m -h -V 9.999 -S -B 64 --vbr-new"
650 echo "You need LAME in the system path to build voice files for"
651 echo "HWCODEC targets."
656 echo "Using $ENCODER for encoding voice clips"
658 # Read custom encoder options from command line
659 if [ "$ARG_ENCOPTS" ]; then
660 ENC_OPTS
="$ARG_ENCOPTS"
661 advopts
="$advopts --encopts='$ENC_OPTS'"
662 echo "$ENCODER options set to $ENC_OPTS"
666 if [ -n "`findtool cygpath`" ]; then
667 TEMPDIR
=`cygpath . -a -w`
672 # figure out which languages that are around
673 for file in $rootdir/apps
/lang
/*.lang
; do
674 clean
=`basename $file .lang`
675 langs
="$langs $clean"
678 if [ "$ARG_LANG" ]; then
681 echo "Select a number for the language to use (default is english)"
682 # FIXME The multiple-language feature is currently broken
683 # echo "You may enter a comma-separated list of languages to build"
686 for one
in $langs; do
692 advopts
="$advopts --language=$pick"
697 # Allow the user to pass a comma-separated list of langauges
698 for thispick
in `echo $pick | sed 's/,/ /g'`; do
700 for one
in $langs; do
701 # Accept both the language number and name
702 if [ "$num" = "$thispick" ] ||
[ "$thispick" = "$one" ]; then
703 if [ "$output" = "" ]; then
712 if [ -z "$output" ]; then
720 echo "Rockbox configure script."
721 echo "Invoke this in a directory to generate a Makefile to build Rockbox"
722 echo "Do *NOT* run this within the tools directory!"
725 Usage: configure [OPTION]...
727 --target=TARGET Sets the target, TARGET can be either the target ID or
728 corresponding string. Run without this option to see all
731 --ram=RAM Sets the RAM for certain targets. Even though any number
732 is accepted, not every number is correct. The default
733 value will be applied, if you entered a wrong number
734 (which depends on the target). Watch the output. Run
735 without this option if you are not sure which the right
738 --type=TYPE Sets the build type. Shortcuts are also valid.
739 Run without this option to see all available types.
740 Multiple values are allowed and managed in the input
741 order. So --type=b stands for Bootloader build, while
742 --type=ab stands for "Backlight MOD" build.
744 --language=LANG Set the language used for voice generation (used only if
747 --tts=ENGINE Set the TTS engine used for voice generation (used only
750 --voice=VOICE Set voice to use with selected TTS (used only if TYPE is
753 --ttsopts=OPTS Set TTS engine manual options (used only if TYPE is AV).
755 --encopts=OPTS Set encoder manual options (used only if ATYPE is AV).
757 --rbdir=dir Use alternative rockbox directory (default: ${rbdir}).
758 This is useful for having multiple alternate builds on
759 your device that you can load with ROLO. However as the
760 bootloader looks for .rockbox you won't be able to boot
763 --ccache Enable ccache use (done by default these days)
764 --no-ccache Disable ccache use
766 --eabi Make configure prefer toolchains that are able to compile
767 for the new ARM standard abi EABI
768 --no-eabi The opposite of --eabi (prefer old non-eabi toolchains)
769 --help Shows this message (must not be used with other options)
790 --ccache) ARG_CCACHE
=1;;
791 --no-ccache) ARG_CCACHE
=0;;
792 --encopts=*) ARG_ENCOPTS
=`echo "$arg" | cut -d = -f 2`;;
793 --language=*) ARG_LANG
=`echo "$arg" | cut -d = -f 2`;;
794 --ram=*) ARG_RAM
=`echo "$arg" | cut -d = -f 2`;;
795 --rbdir=*) ARG_RBDIR
=`echo "$arg" | cut -d = -f 2`;;
796 --target=*) ARG_TARGET
=`echo "$arg" | cut -d = -f 2`;;
797 --tts=*) ARG_TTS
=`echo "$arg" | cut -d = -f 2`;;
798 --ttsopts=*) ARG_TTSOPTS
=`echo "$arg" | cut -d = -f 2`;;
799 --type=*) ARG_TYPE
=`echo "$arg" | cut -d = -f 2`;;
800 --voice=*) ARG_VOICE
=`echo "$arg" | cut -d = -f 2`;;
801 --eabi) ARG_ARM_EABI
=1;;
802 --no-eabi) ARG_ARM_EABI
=0;;
804 *) err
=1; echo "[ERROR] Option '$arg' unsupported";;
811 if [ "$TMPDIR" != "" ]; then
816 echo Using temporary directory
$tmpdir
818 if test -r "configure"; then
819 # this is a check for a configure script in the current directory, it there
820 # is one, try to figure out if it is this one!
822 if { grep "^# Jukebox" configure
>/dev
/null
2>&1 ; } then
823 echo "WEEEEEEEEP. Don't run this configure script within the tools directory."
824 echo "It will only cause you pain and grief. Instead do this:"
827 echo " mkdir build-dir"
829 echo " ../tools/configure"
831 echo "Much happiness will arise from this. Enjoy"
836 # get our current directory
839 if { echo $pwd |
grep " "; } then
840 echo "You're running this script in a path that contains space. The build"
841 echo "system is unfortunately not clever enough to deal with this. Please"
842 echo "run the script from a different path, rename the path or fix the build"
847 if [ -z "$rootdir" ]; then
848 ##################################################################
849 # Figure out where the source code root is!
851 rootdir
=`dirname $0`/..
/
853 #####################################################################
854 # Convert the possibly relative directory name to an absolute version
860 # cd back to the build dir
865 appsdir
='\$(ROOTDIR)/apps'
866 firmdir
='\$(ROOTDIR)/firmware'
867 toolsdir
='\$(ROOTDIR)/tools'
870 ##################################################################
871 # Figure out target platform
874 if [ "$ARG_TARGET" ]; then
877 echo "Enter target platform:"
879 ==Archos== ==iriver== ==Apple iPod==
880 0) Player/Studio 10) H120/H140 20) Color/Photo
881 1) Recorder 11) H320/H340 21) Nano 1G
882 2) FM Recorder 12) iHP-100/110/115 22) Video
883 3) Recorder v2 13) iFP-790 23) 3G
884 4) Ondio SP 14) H10 20Gb 24) 4G Grayscale
885 5) Ondio FM 15) H10 5/6Gb 25) Mini 1G
887 ==Toshiba== 27) 1G, 2G
888 ==Cowon/iAudio== 40) Gigabeat F/X 28) Nano 2G
889 30) X5/X5V/X5L 41) Gigabeat S
890 31) M5/M5L ==SanDisk==
891 32) 7 ==Olympus= 50) Sansa e200
892 33) D2 70) M:Robe 500 51) Sansa e200R
893 34) M3/M3L 71) M:Robe 100 52) Sansa c200
895 ==Creative== ==Philips== 54) Sansa c100
896 90) Zen Vision:M 30GB 100) GoGear SA9200 55) Sansa Clip
897 91) Zen Vision:M 60GB 101) GoGear HDD1630/ 56) Sansa e200v2
898 92) Zen Vision HDD1830 57) Sansa m200v4
899 102) GoGear HDD6330 58) Sansa Fuze
900 ==Onda== 59) Sansa c200v2
901 120) VX747 ==Meizu== 60) Sansa Clipv2
902 121) VX767 110) M6SL 61) Sansa View
903 122) VX747+ 111) M6SP
904 123) VX777 112) M3 ==Logik==
906 ==Samsung== ==Tatung==
907 140) YH-820 150) Elio TPJ-1022 ==Lyre project==
908 141) YH-920 130) Lyre proto 1
909 142) YH-925 131) Mini2440
916 # Set of tools built for all target platforms:
917 toolset
="rdf2binary convbdf codepages"
919 # Toolsets for some target families:
920 archosbitmaptools
="$toolset scramble descramble sh2d uclpack bmp2rb"
921 iriverbitmaptools
="$toolset scramble descramble mkboot bmp2rb"
922 iaudiobitmaptools
="$toolset scramble descramble mkboot bmp2rb"
923 ipodbitmaptools
="$toolset scramble bmp2rb"
924 gigabeatbitmaptools
="$toolset scramble descramble bmp2rb"
925 tccbitmaptools
="$toolset scramble bmp2rb"
926 # generic is used by IFP, Meizu and Onda
927 genericbitmaptools
="$toolset bmp2rb"
928 # scramble is used by all other targets
929 scramblebitmaptools
="$genericbitmaptools scramble"
932 # ---- For each target ----
935 # target_id: a unique number identifying this target, IS NOT the menu number.
936 # Just use the currently highest number+1 when you add a new
938 # modelname: short model name used all over to identify this target
939 # memory: number of megabytes of RAM this target has. If the amount can
940 # be selected by the size prompt, let memory be unset here
941 # target: -Ddefine passed to the build commands to make the correct
942 # config-*.h file get included etc
943 # tool: the tool that takes a plain binary and converts that into a
944 # working "firmware" file for your target
945 # output: the final output file name
946 # boottool: the tool that takes a plain binary and generates a bootloader
947 # file for your target (or blank to use $tool)
948 # bootoutput:the final output file name for the bootloader (or blank to use
950 # appextra: passed to the APPEXTRA variable in the Makefiles.
951 # TODO: add proper explanation
952 # archosrom: used only for Archos targets that build a special flashable .ucl
954 # flash: name of output for flashing, for targets where there's a special
955 # file output for this.
956 # plugins: set to 'yes' to build the plugins. Early development builds can
957 # set this to no in the early stages to have an easier life for a
959 # swcodec: set 'yes' on swcodec targets
960 # toolset: lists what particular tools in the tools/ directory that this
961 # target needs to have built prior to building Rockbox
964 # *cc: sets up gcc and compiler options for your target builds. Note
965 # that if you select a simulator build, the compiler selection is
966 # overridden later in the script.
972 modelname
="archosplayer"
973 target
="-DARCHOS_PLAYER"
975 tool
="$rootdir/tools/scramble"
977 appextra
="player:gui"
978 archosrom
="$pwd/rombox.ucl"
979 flash
="$pwd/rockbox.ucl"
983 # toolset is the tools within the tools directory that we build for
984 # this particular target.
985 toolset
="$toolset scramble descramble sh2d player_unifont uclpack"
987 # Note: the convbdf is present in the toolset just because: 1) the
988 # firmware/Makefile assumes it is present always, and 2) we will need it when we
989 # build the player simulator
992 t_manufacturer
="archos"
998 modelname
="archosrecorder"
999 target
="-DARCHOS_RECORDER"
1001 tool
="$rootdir/tools/scramble"
1002 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1003 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1005 appextra
="recorder:gui"
1006 #archosrom="$pwd/rombox.ucl"
1007 flash
="$pwd/rockbox.ucl"
1010 # toolset is the tools within the tools directory that we build for
1011 # this particular target.
1012 toolset
=$archosbitmaptools
1014 t_manufacturer
="archos"
1020 modelname
="archosfmrecorder"
1021 target
="-DARCHOS_FMRECORDER"
1023 tool
="$rootdir/tools/scramble -fm"
1024 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1025 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1027 appextra
="recorder:gui"
1028 #archosrom="$pwd/rombox.ucl"
1029 flash
="$pwd/rockbox.ucl"
1032 # toolset is the tools within the tools directory that we build for
1033 # this particular target.
1034 toolset
=$archosbitmaptools
1036 t_manufacturer
="archos"
1042 modelname
="archosrecorderv2"
1043 target
="-DARCHOS_RECORDERV2"
1045 tool
="$rootdir/tools/scramble -v2"
1046 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1047 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1049 appextra
="recorder:gui"
1050 #archosrom="$pwd/rombox.ucl"
1051 flash
="$pwd/rockbox.ucl"
1054 # toolset is the tools within the tools directory that we build for
1055 # this particular target.
1056 toolset
=$archosbitmaptools
1058 t_manufacturer
="archos"
1064 modelname
="archosondiosp"
1065 target
="-DARCHOS_ONDIOSP"
1067 tool
="$rootdir/tools/scramble -osp"
1068 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1069 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1071 appextra
="recorder:gui"
1072 archosrom
="$pwd/rombox.ucl"
1073 flash
="$pwd/rockbox.ucl"
1076 # toolset is the tools within the tools directory that we build for
1077 # this particular target.
1078 toolset
=$archosbitmaptools
1080 t_manufacturer
="archos"
1086 modelname
="archosondiofm"
1087 target
="-DARCHOS_ONDIOFM"
1089 tool
="$rootdir/tools/scramble -ofm"
1090 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1091 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1093 appextra
="recorder:gui"
1094 #archosrom="$pwd/rombox.ucl"
1095 flash
="$pwd/rockbox.ucl"
1098 toolset
=$archosbitmaptools
1100 t_manufacturer
="archos"
1106 modelname
="archosav300"
1107 target
="-DARCHOS_AV300"
1110 tool
="$rootdir/tools/scramble -mm=C"
1111 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1112 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1114 appextra
="recorder:gui"
1117 # toolset is the tools within the tools directory that we build for
1118 # this particular target.
1119 toolset
="$toolset scramble descramble bmp2rb"
1120 # architecture, manufacturer and model for the target-tree build
1122 t_manufacturer
="archos"
1128 modelname
="iriverh120"
1129 target
="-DIRIVER_H120"
1132 tool
="$rootdir/tools/scramble -add=h120"
1133 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1134 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1135 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1136 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1137 output
="rockbox.iriver"
1138 bootoutput
="bootloader.iriver"
1139 appextra
="recorder:gui"
1140 flash
="$pwd/rombox.iriver"
1143 # toolset is the tools within the tools directory that we build for
1144 # this particular target.
1145 toolset
=$iriverbitmaptools
1147 t_manufacturer
="iriver"
1153 modelname
="iriverh300"
1154 target
="-DIRIVER_H300"
1157 tool
="$rootdir/tools/scramble -add=h300"
1158 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1159 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1160 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1161 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1162 output
="rockbox.iriver"
1163 appextra
="recorder:gui"
1166 # toolset is the tools within the tools directory that we build for
1167 # this particular target.
1168 toolset
=$iriverbitmaptools
1170 t_manufacturer
="iriver"
1176 modelname
="iriverh100"
1177 target
="-DIRIVER_H100"
1180 tool
="$rootdir/tools/scramble -add=h100"
1181 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1182 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1183 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1184 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1185 output
="rockbox.iriver"
1186 bootoutput
="bootloader.iriver"
1187 appextra
="recorder:gui"
1188 flash
="$pwd/rombox.iriver"
1191 # toolset is the tools within the tools directory that we build for
1192 # this particular target.
1193 toolset
=$iriverbitmaptools
1195 t_manufacturer
="iriver"
1201 modelname
="iriverifp7xx"
1202 target
="-DIRIVER_IFP7XX"
1206 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1207 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1208 output
="rockbox.wma"
1209 appextra
="recorder:gui"
1212 # toolset is the tools within the tools directory that we build for
1213 # this particular target.
1214 toolset
=$genericbitmaptools
1216 t_manufacturer
="pnx0101"
1217 t_model
="iriver-ifp7xx"
1222 modelname
="iriverh10"
1223 target
="-DIRIVER_H10"
1226 tool
="$rootdir/tools/scramble -mi4v3 -model=h10 -type=RBOS"
1227 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1228 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1229 output
="rockbox.mi4"
1230 appextra
="recorder:gui"
1233 boottool
="$rootdir/tools/scramble -mi4v3 -model=h10 -type=RBBL"
1234 bootoutput
="H10_20GC.mi4"
1235 # toolset is the tools within the tools directory that we build for
1236 # this particular target.
1237 toolset
=$scramblebitmaptools
1238 # architecture, manufacturer and model for the target-tree build
1240 t_manufacturer
="iriver"
1246 modelname
="iriverh10_5gb"
1247 target
="-DIRIVER_H10_5GB"
1250 tool
="$rootdir/tools/scramble -mi4v2 -model=h105 -type=RBOS"
1251 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1252 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1253 output
="rockbox.mi4"
1254 appextra
="recorder:gui"
1257 boottool
="$rootdir/tools/scramble -mi4v2 -model=h105 -type=RBBL"
1258 bootoutput
="H10.mi4"
1259 # toolset is the tools within the tools directory that we build for
1260 # this particular target.
1261 toolset
=$scramblebitmaptools
1262 # architecture, manufacturer and model for the target-tree build
1264 t_manufacturer
="iriver"
1270 modelname
="ipodcolor"
1271 target
="-DIPOD_COLOR"
1274 tool
="$rootdir/tools/scramble -add=ipco"
1275 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1276 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1277 output
="rockbox.ipod"
1278 appextra
="recorder:gui"
1281 bootoutput
="bootloader-$modelname.ipod"
1282 # toolset is the tools within the tools directory that we build for
1283 # this particular target.
1284 toolset
=$ipodbitmaptools
1285 # architecture, manufacturer and model for the target-tree build
1287 t_manufacturer
="ipod"
1293 modelname
="ipodnano1g"
1294 target
="-DIPOD_NANO"
1297 tool
="$rootdir/tools/scramble -add=nano"
1298 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1299 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1300 output
="rockbox.ipod"
1301 appextra
="recorder:gui"
1304 bootoutput
="bootloader-$modelname.ipod"
1305 # toolset is the tools within the tools directory that we build for
1306 # this particular target.
1307 toolset
=$ipodbitmaptools
1308 # architecture, manufacturer and model for the target-tree build
1310 t_manufacturer
="ipod"
1316 modelname
="ipodvideo"
1317 target
="-DIPOD_VIDEO"
1319 tool
="$rootdir/tools/scramble -add=ipvd"
1320 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1321 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1322 output
="rockbox.ipod"
1323 appextra
="recorder:gui"
1326 bootoutput
="bootloader-$modelname.ipod"
1327 # toolset is the tools within the tools directory that we build for
1328 # this particular target.
1329 toolset
=$ipodbitmaptools
1330 # architecture, manufacturer and model for the target-tree build
1332 t_manufacturer
="ipod"
1342 tool
="$rootdir/tools/scramble -add=ip3g"
1343 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1344 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1345 output
="rockbox.ipod"
1346 appextra
="recorder:gui"
1349 bootoutput
="bootloader-$modelname.ipod"
1350 # toolset is the tools within the tools directory that we build for
1351 # this particular target.
1352 toolset
=$ipodbitmaptools
1353 # architecture, manufacturer and model for the target-tree build
1355 t_manufacturer
="ipod"
1365 tool
="$rootdir/tools/scramble -add=ip4g"
1366 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1367 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1368 output
="rockbox.ipod"
1369 appextra
="recorder:gui"
1372 bootoutput
="bootloader-$modelname.ipod"
1373 # toolset is the tools within the tools directory that we build for
1374 # this particular target.
1375 toolset
=$ipodbitmaptools
1376 # architecture, manufacturer and model for the target-tree build
1378 t_manufacturer
="ipod"
1384 modelname
="ipodmini1g"
1385 target
="-DIPOD_MINI"
1388 tool
="$rootdir/tools/scramble -add=mini"
1389 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1390 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1391 output
="rockbox.ipod"
1392 appextra
="recorder:gui"
1395 bootoutput
="bootloader-$modelname.ipod"
1396 # toolset is the tools within the tools directory that we build for
1397 # this particular target.
1398 toolset
=$ipodbitmaptools
1399 # architecture, manufacturer and model for the target-tree build
1401 t_manufacturer
="ipod"
1407 modelname
="ipodmini2g"
1408 target
="-DIPOD_MINI2G"
1411 tool
="$rootdir/tools/scramble -add=mn2g"
1412 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1413 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1414 output
="rockbox.ipod"
1415 appextra
="recorder:gui"
1418 bootoutput
="bootloader-$modelname.ipod"
1419 # toolset is the tools within the tools directory that we build for
1420 # this particular target.
1421 toolset
=$ipodbitmaptools
1422 # architecture, manufacturer and model for the target-tree build
1424 t_manufacturer
="ipod"
1430 modelname
="ipod1g2g"
1431 target
="-DIPOD_1G2G"
1434 tool
="$rootdir/tools/scramble -add=1g2g"
1435 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1436 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1437 output
="rockbox.ipod"
1438 appextra
="recorder:gui"
1441 bootoutput
="bootloader-$modelname.ipod"
1442 # toolset is the tools within the tools directory that we build for
1443 # this particular target.
1444 toolset
=$ipodbitmaptools
1445 # architecture, manufacturer and model for the target-tree build
1447 t_manufacturer
="ipod"
1453 modelname
="ipodnano2g"
1454 target
="-DIPOD_NANO2G"
1457 tool
="$rootdir/tools/scramble -add=nn2g"
1458 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1459 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1460 output
="rockbox.ipod"
1461 appextra
="recorder:gui"
1464 bootoutput
="bootloader-$modelname.ipod"
1465 # toolset is the tools within the tools directory that we build for
1466 # this particular target.
1467 toolset
=$ipodbitmaptools
1468 # architecture, manufacturer and model for the target-tree build
1470 t_manufacturer
="s5l8700"
1471 t_model
="ipodnano2g"
1476 modelname
="iaudiox5"
1477 target
="-DIAUDIO_X5"
1480 tool
="$rootdir/tools/scramble -add=iax5"
1481 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1482 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1483 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1484 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 7"
1485 output
="rockbox.iaudio"
1486 appextra
="recorder:gui"
1489 # toolset is the tools within the tools directory that we build for
1490 # this particular target.
1491 toolset
="$iaudiobitmaptools"
1492 # architecture, manufacturer and model for the target-tree build
1494 t_manufacturer
="iaudio"
1500 modelname
="iaudiom5"
1501 target
="-DIAUDIO_M5"
1504 tool
="$rootdir/tools/scramble -add=iam5"
1505 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1506 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1507 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1508 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 7"
1509 output
="rockbox.iaudio"
1510 appextra
="recorder:gui"
1513 # toolset is the tools within the tools directory that we build for
1514 # this particular target.
1515 toolset
="$iaudiobitmaptools"
1516 # architecture, manufacturer and model for the target-tree build
1518 t_manufacturer
="iaudio"
1528 tool
="$rootdir/tools/scramble -add=i7"
1529 boottool
="$rootdir/tools/scramble -tcc=crc"
1530 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1531 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1532 output
="rockbox.iaudio"
1533 appextra
="recorder:gui"
1536 bootoutput
="I7_FW.BIN"
1537 # toolset is the tools within the tools directory that we build for
1538 # this particular target.
1539 toolset
="$tccbitmaptools"
1540 # architecture, manufacturer and model for the target-tree build
1542 t_manufacturer
="tcc77x"
1552 tool
="$rootdir/tools/scramble -add=d2"
1554 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1555 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1557 bootoutput
="bootloader-cowond2.bin"
1558 appextra
="recorder:gui"
1561 toolset
="$tccbitmaptools"
1562 # architecture, manufacturer and model for the target-tree build
1564 t_manufacturer
="tcc780x"
1570 modelname
="iaudiom3"
1571 target
="-DIAUDIO_M3"
1574 tool
="$rootdir/tools/scramble -add=iam3"
1575 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1576 bmp2rb_native
="$rootdir/tools/bmp2rb -f 7"
1577 output
="rockbox.iaudio"
1578 appextra
="recorder:gui"
1581 # toolset is the tools within the tools directory that we build for
1582 # this particular target.
1583 toolset
="$iaudiobitmaptools"
1584 # architecture, manufacturer and model for the target-tree build
1586 t_manufacturer
="iaudio"
1592 modelname
="gigabeatfx"
1593 target
="-DGIGABEAT_F"
1596 tool
="$rootdir/tools/scramble -add=giga"
1597 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1598 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1599 output
="rockbox.gigabeat"
1600 appextra
="recorder:gui"
1603 toolset
=$gigabeatbitmaptools
1604 boottool
="$rootdir/tools/scramble -gigabeat"
1605 bootoutput
="FWIMG01.DAT"
1606 # architecture, manufacturer and model for the target-tree build
1608 t_manufacturer
="s3c2440"
1609 t_model
="gigabeat-fx"
1614 modelname
="gigabeats"
1615 target
="-DGIGABEAT_S"
1618 tool
="$rootdir/tools/scramble -add=gigs"
1619 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1620 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1621 output
="rockbox.gigabeat"
1622 appextra
="recorder:gui"
1625 toolset
="$gigabeatbitmaptools"
1626 boottool
="$rootdir/tools/scramble -gigabeats"
1628 # architecture, manufacturer and model for the target-tree build
1630 t_manufacturer
="imx31"
1631 t_model
="gigabeat-s"
1636 modelname
="mrobe500"
1637 target
="-DMROBE_500"
1640 tool
="$rootdir/tools/scramble -add=m500"
1641 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1642 bmp2rb_native
="$rootdir/tools/bmp2rb -f 8"
1643 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1644 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1645 output
="rockbox.mrobe500"
1646 appextra
="recorder:gui"
1649 toolset
=$gigabeatbitmaptools
1651 bootoutput
="rockbox.mrboot"
1652 # architecture, manufacturer and model for the target-tree build
1654 t_manufacturer
="tms320dm320"
1660 modelname
="mrobe100"
1661 target
="-DMROBE_100"
1664 tool
="$rootdir/tools/scramble -mi4v2 -model=m100 -type=RBOS"
1665 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1666 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1667 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1668 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1669 output
="rockbox.mi4"
1670 appextra
="recorder:gui"
1673 boottool
="$rootdir/tools/scramble -mi4v2 -model=m100 -type=RBBL"
1674 bootoutput
="pp5020.mi4"
1675 # toolset is the tools within the tools directory that we build for
1676 # this particular target.
1677 toolset
=$scramblebitmaptools
1678 # architecture, manufacturer and model for the target-tree build
1680 t_manufacturer
="olympus"
1686 modelname
="logikdax"
1687 target
="-DLOGIK_DAX"
1690 tool
="$rootdir/tools/scramble -add=ldax"
1691 boottool
="$rootdir/tools/scramble -tcc=crc"
1692 bootoutput
="player.rom"
1693 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1694 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1695 output
="rockbox.logik"
1696 appextra
="recorder:gui"
1699 # toolset is the tools within the tools directory that we build for
1700 # this particular target.
1701 toolset
=$tccbitmaptools
1702 # architecture, manufacturer and model for the target-tree build
1704 t_manufacturer
="tcc77x"
1710 modelname
="zenvisionm30gb"
1711 target
="-DCREATIVE_ZVM"
1714 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1715 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1716 tool
="$rootdir/tools/scramble -creative=zvm"
1718 output
="rockbox.zvm"
1719 appextra
="recorder:gui"
1722 toolset
=$ipodbitmaptools
1723 boottool
="$rootdir/tools/scramble -creative=zvm -no-ciff"
1724 bootoutput
="rockbox.zvmboot"
1725 # architecture, manufacturer and model for the target-tree build
1727 t_manufacturer
="tms320dm320"
1728 t_model
="creative-zvm"
1733 modelname
="zenvisionm60gb"
1734 target
="-DCREATIVE_ZVM60GB"
1737 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1738 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1739 tool
="$rootdir/tools/scramble -creative=zvm60 -no-ciff"
1741 output
="rockbox.zvm60"
1742 appextra
="recorder:gui"
1745 toolset
=$ipodbitmaptools
1746 boottool
="$rootdir/tools/scramble -creative=zvm60"
1747 bootoutput
="rockbox.zvm60boot"
1748 # architecture, manufacturer and model for the target-tree build
1750 t_manufacturer
="tms320dm320"
1751 t_model
="creative-zvm"
1756 modelname
="zenvision"
1757 target
="-DCREATIVE_ZV"
1760 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1761 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1762 tool
="$rootdir/tools/scramble -creative=zenvision -no-ciff"
1765 appextra
="recorder:gui"
1768 toolset
=$ipodbitmaptools
1769 boottool
="$rootdir/tools/scramble -creative=zenvision"
1770 bootoutput
="rockbox.zvboot"
1771 # architecture, manufacturer and model for the target-tree build
1773 t_manufacturer
="tms320dm320"
1774 t_model
="creative-zvm"
1779 modelname
="sansae200"
1780 target
="-DSANSA_E200"
1781 memory
=32 # supposedly
1783 tool
="$rootdir/tools/scramble -mi4v3 -model=e200 -type=RBOS"
1784 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1785 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1786 output
="rockbox.mi4"
1787 appextra
="recorder:gui"
1790 boottool
="$rootdir/tools/scramble -mi4v3 -model=e200 -type=RBBL"
1791 bootoutput
="PP5022.mi4"
1792 # toolset is the tools within the tools directory that we build for
1793 # this particular target.
1794 toolset
=$scramblebitmaptools
1795 # architecture, manufacturer and model for the target-tree build
1797 t_manufacturer
="sandisk"
1798 t_model
="sansa-e200"
1802 # the e200R model is pretty much identical to the e200, it only has a
1803 # different option to the scramble tool when building a bootloader and
1804 # makes the bootloader output file name in all lower case.
1806 modelname
="sansae200r"
1807 target
="-DSANSA_E200"
1808 memory
=32 # supposedly
1810 tool
="$rootdir/tools/scramble -mi4v3 -model=e20r -type=RBOS"
1811 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1812 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1813 output
="rockbox.mi4"
1814 appextra
="recorder:gui"
1817 boottool
="$rootdir/tools/scramble -mi4r -model=e20r -type=RBBL"
1818 bootoutput
="pp5022.mi4"
1819 # toolset is the tools within the tools directory that we build for
1820 # this particular target.
1821 toolset
=$scramblebitmaptools
1822 # architecture, manufacturer and model for the target-tree build
1824 t_manufacturer
="sandisk"
1825 t_model
="sansa-e200"
1830 modelname
="sansac200"
1831 target
="-DSANSA_C200"
1832 memory
=32 # supposedly
1834 tool
="$rootdir/tools/scramble -mi4v3 -model=c200 -type=RBOS"
1835 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1836 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1837 output
="rockbox.mi4"
1838 appextra
="recorder:gui"
1841 boottool
="$rootdir/tools/scramble -mi4v3 -model=c200 -type=RBBL"
1842 bootoutput
="firmware.mi4"
1843 # toolset is the tools within the tools directory that we build for
1844 # this particular target.
1845 toolset
=$scramblebitmaptools
1846 # architecture, manufacturer and model for the target-tree build
1848 t_manufacturer
="sandisk"
1849 t_model
="sansa-c200"
1854 modelname
="sansam200"
1855 target
="-DSANSA_M200"
1858 tool
="$rootdir/tools/scramble -add=m200"
1859 boottool
="$rootdir/tools/scramble -tcc=crc"
1860 bootoutput
="player.rom"
1861 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1862 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1863 output
="rockbox.m200"
1864 appextra
="recorder:gui"
1867 # toolset is the tools within the tools directory that we build for
1868 # this particular target.
1869 toolset
=$tccbitmaptools
1870 # architecture, manufacturer and model for the target-tree build
1872 t_manufacturer
="tcc77x"
1878 modelname
="sansac100"
1879 target
="-DSANSA_C100"
1882 tool
="$rootdir/tools/scramble -add=c100"
1883 boottool
="$rootdir/tools/scramble -tcc=crc"
1884 bootoutput
="player.rom"
1885 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1886 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1887 output
="rockbox.c100"
1888 appextra
="recorder:gui"
1891 # toolset is the tools within the tools directory that we build for
1892 # this particular target.
1893 toolset
=$tccbitmaptools
1894 # architecture, manufacturer and model for the target-tree build
1896 t_manufacturer
="tcc77x"
1902 modelname
="sansaclip"
1903 target
="-DSANSA_CLIP"
1905 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1906 bmp2rb_native
="$bmp2rb_mono"
1907 tool
="$rootdir/tools/scramble -add=clip"
1908 output
="rockbox.sansa"
1909 bootoutput
="bootloader-clip.sansa"
1910 appextra
="recorder:gui"
1913 toolset
=$scramblebitmaptools
1915 t_manufacturer
="as3525"
1916 t_model
="sansa-clip"
1923 modelname
="sansae200v2"
1924 target
="-DSANSA_E200V2"
1926 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1927 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1928 tool
="$rootdir/tools/scramble -add=e2v2"
1929 output
="rockbox.sansa"
1930 bootoutput
="bootloader-e200v2.sansa"
1931 appextra
="recorder:gui"
1934 toolset
=$scramblebitmaptools
1936 t_manufacturer
="as3525"
1937 t_model
="sansa-e200v2"
1944 modelname
="sansam200v4"
1945 target
="-DSANSA_M200V4"
1947 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1948 bmp2rb_native
="$bmp2rb_mono"
1949 tool
="$rootdir/tools/scramble -add=m2v4"
1950 output
="rockbox.sansa"
1951 bootoutput
="bootloader-m200v4.sansa"
1952 appextra
="recorder:gui"
1955 toolset
=$scramblebitmaptools
1957 t_manufacturer
="as3525"
1958 t_model
="sansa-m200v4"
1965 modelname
="sansafuze"
1966 target
="-DSANSA_FUZE"
1968 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1969 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1970 tool
="$rootdir/tools/scramble -add=fuze"
1971 output
="rockbox.sansa"
1972 bootoutput
="bootloader-fuze.sansa"
1973 appextra
="recorder:gui"
1976 toolset
=$scramblebitmaptools
1978 t_manufacturer
="as3525"
1979 t_model
="sansa-fuze"
1986 modelname
="sansac200v2"
1987 target
="-DSANSA_C200V2"
1988 memory
=2 # as per OF diagnosis mode
1989 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1990 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1991 tool
="$rootdir/tools/scramble -add=c2v2"
1992 output
="rockbox.sansa"
1993 bootoutput
="bootloader-c200v2.sansa"
1994 appextra
="recorder:gui"
1997 # toolset is the tools within the tools directory that we build for
1998 # this particular target.
1999 toolset
=$scramblebitmaptools
2000 # architecture, manufacturer and model for the target-tree build
2002 t_manufacturer
="as3525"
2003 t_model
="sansa-c200v2"
2009 modelname
="sansaclipv2"
2010 target
="-DSANSA_CLIPV2"
2013 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2014 bmp2rb_native
="$bmp2rb_mono"
2015 tool
="$rootdir/tools/scramble -add=clv2"
2016 output
="rockbox.sansa"
2017 bootoutput
="bootloader-clipv2.sansa"
2018 appextra
="recorder:gui"
2021 toolset
=$scramblebitmaptools
2023 t_manufacturer
="as3525"
2024 t_model
="sansa-clipv2"
2028 echo "Sansa View is not yet supported!"
2031 modelname
="sansaview"
2032 target
="-DSANSA_VIEW"
2035 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2036 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2037 output
="rockbox.mi4"
2041 boottool
="$rootdir/tools/scramble -mi4v3 -model=view -type=RBBL"
2042 bootoutput
="firmware.mi4"
2043 # toolset is the tools within the tools directory that we build for
2044 # this particular target.
2045 toolset
=$scramblebitmaptools
2047 t_manufacturer
="sandisk"
2048 t_model
="sansa-view"
2053 modelname
="tatungtpj1022"
2054 target
="-DTATUNG_TPJ1022"
2057 tool
="$rootdir/tools/scramble -add tpj2"
2058 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2059 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
2060 output
="rockbox.elio"
2061 appextra
="recorder:gui"
2064 boottool
="$rootdir/tools/scramble -mi4v2"
2065 bootoutput
="pp5020.mi4"
2066 # toolset is the tools within the tools directory that we build for
2067 # this particular target.
2068 toolset
=$scramblebitmaptools
2069 # architecture, manufacturer and model for the target-tree build
2071 t_manufacturer
="tatung"
2077 modelname
="gogearsa9200"
2078 target
="-DPHILIPS_SA9200"
2079 memory
=32 # supposedly
2081 tool
="$rootdir/tools/scramble -mi4v3 -model=9200 -type=RBOS"
2082 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2083 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2084 output
="rockbox.mi4"
2085 appextra
="recorder:gui"
2088 boottool
="$rootdir/tools/scramble -mi4v3 -model=9200 -type=RBBL"
2089 bootoutput
="FWImage.ebn"
2090 # toolset is the tools within the tools directory that we build for
2091 # this particular target.
2092 toolset
=$scramblebitmaptools
2093 # architecture, manufacturer and model for the target-tree build
2095 t_manufacturer
="philips"
2101 modelname
="gogearhdd1630"
2102 target
="-DPHILIPS_HDD1630"
2103 memory
=32 # supposedly
2105 tool
="$rootdir/tools/scramble -mi4v3 -model=1630 -type=RBOS"
2106 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2107 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2108 output
="rockbox.mi4"
2109 appextra
="recorder:gui"
2112 boottool
="$rootdir/tools/scramble -mi4v3 -model=1630 -type=RBBL"
2113 bootoutput
="FWImage.ebn"
2114 # toolset is the tools within the tools directory that we build for
2115 # this particular target.
2116 toolset
=$scramblebitmaptools
2117 # architecture, manufacturer and model for the target-tree build
2119 t_manufacturer
="philips"
2125 modelname
="gogearhdd6330"
2126 target
="-DPHILIPS_HDD6330"
2127 memory
=32 # supposedly
2129 tool
="$rootdir/tools/scramble -mi4v3 -model=6330 -type=RBOS"
2130 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2131 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2132 output
="rockbox.mi4"
2133 appextra
="recorder:gui"
2136 boottool
="$rootdir/tools/scramble -mi4v3 -model=6330 -type=RBBL"
2137 bootoutput
="FWImage.ebn"
2138 # toolset is the tools within the tools directory that we build for
2139 # this particular target.
2140 toolset
=$scramblebitmaptools
2141 # architecture, manufacturer and model for the target-tree build
2143 t_manufacturer
="philips"
2149 modelname
="meizum6sl"
2150 target
="-DMEIZU_M6SL"
2154 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2155 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2156 output
="rockbox.meizu"
2157 appextra
="recorder:gui"
2160 toolset
=$genericbitmaptools
2162 bootoutput
="rockboot.ebn"
2163 # architecture, manufacturer and model for the target-tree build
2165 t_manufacturer
="s5l8700"
2166 t_model
="meizu-m6sl"
2171 modelname
="meizum6sp"
2172 target
="-DMEIZU_M6SP"
2176 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2177 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2178 output
="rockbox.meizu"
2179 appextra
="recorder:gui"
2182 toolset
=$genericbitmaptools
2184 bootoutput
="rockboot.ebn"
2185 # architecture, manufacturer and model for the target-tree build
2187 t_manufacturer
="s5l8700"
2188 t_model
="meizu-m6sp"
2198 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2199 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2200 output
="rockbox.meizu"
2201 appextra
="recorder:gui"
2204 toolset
=$genericbitmaptools
2206 bootoutput
="rockboot.ebn"
2207 # architecture, manufacturer and model for the target-tree build
2209 t_manufacturer
="s5l8700"
2215 modelname
="ondavx747"
2216 target
="-DONDA_VX747"
2219 tool
="$rootdir/tools/scramble -add=x747"
2220 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2221 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2222 output
="rockbox.vx747"
2223 appextra
="recorder:gui"
2226 toolset
=$genericbitmaptools
2227 boottool
="$rootdir/tools/scramble -ccpmp"
2228 bootoutput
="ccpmp.bin"
2229 # architecture, manufacturer and model for the target-tree build
2231 t_manufacturer
="ingenic_jz47xx"
2232 t_model
="onda_vx747"
2237 modelname
="ondavx767"
2238 target
="-DONDA_VX767"
2242 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2243 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2244 output
="rockbox.vx767"
2245 appextra
="recorder:gui"
2248 toolset
=$genericbitmaptools
2249 boottool
="$rootdir/tools/scramble -ccpmp"
2250 bootoutput
="ccpmp.bin"
2251 # architecture, manufacturer and model for the target-tree build
2253 t_manufacturer
="ingenic_jz47xx"
2254 t_model
="onda_vx767"
2259 modelname
="ondavx747p"
2260 target
="-DONDA_VX747P"
2263 tool
="$rootdir/tools/scramble -add=747p"
2264 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2265 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2266 output
="rockbox.vx747p"
2267 appextra
="recorder:gui"
2270 toolset
=$genericbitmaptools
2271 boottool
="$rootdir/tools/scramble -ccpmp"
2272 bootoutput
="ccpmp.bin"
2273 # architecture, manufacturer and model for the target-tree build
2275 t_manufacturer
="ingenic_jz47xx"
2276 t_model
="onda_vx747"
2281 modelname
="ondavx777"
2282 target
="-DONDA_VX777"
2285 tool
="$rootdir/tools/scramble -add=x777"
2286 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2287 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2288 output
="rockbox.vx777"
2289 appextra
="recorder:gui"
2292 toolset
=$genericbitmaptools
2293 boottool
="$rootdir/tools/scramble -ccpmp"
2294 bootoutput
="ccpmp.bin"
2295 # architecture, manufacturer and model for the target-tree build
2297 t_manufacturer
="ingenic_jz47xx"
2298 t_model
="onda_vx747"
2303 modelname
="lyreproto1"
2304 target
="-DLYRE_PROTO1"
2308 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2309 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2310 output
="rockbox.lyre"
2311 appextra
="recorder:gui"
2314 toolset
=$scramblebitmaptools
2316 bootoutput
="bootloader-proto1.lyre"
2317 # architecture, manufacturer and model for the target-tree build
2319 t_manufacturer
="at91sam"
2320 t_model
="lyre_proto1"
2325 modelname
="mini2440"
2329 tool
="$rootdir/tools/scramble -add=m244"
2330 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2331 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2332 output
="rockbox.mini2440"
2333 appextra
="recorder:gui"
2336 toolset
=$scramblebitmaptools
2338 bootoutput
="bootloader-mini2440.lyre"
2339 # architecture, manufacturer and model for the target-tree build
2341 t_manufacturer
="s3c2440"
2347 modelname
="samsungyh820"
2348 target
="-DSAMSUNG_YH820"
2351 tool
="$rootdir/tools/scramble -mi4v2 -model=y820 -type=RBOS"
2352 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2353 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2354 output
="rockbox.mi4"
2355 appextra
="recorder:gui"
2358 boottool
="$rootdir/tools/scramble -mi4v2 -model=y820 -type=RBBL"
2359 bootoutput
="FW_YH820.mi4"
2360 # toolset is the tools within the tools directory that we build for
2361 # this particular target.
2362 toolset
=$scramblebitmaptools
2363 # architecture, manufacturer and model for the target-tree build
2365 t_manufacturer
="samsung"
2371 modelname
="samsungyh920"
2372 target
="-DSAMSUNG_YH920"
2375 tool
="$rootdir/tools/scramble -mi4v2 -model=y920 -type=RBOS"
2376 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2377 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
2378 output
="rockbox.mi4"
2379 appextra
="recorder:gui"
2382 boottool
="$rootdir/tools/scramble -mi4v2 -model=y920 -type=RBBL"
2383 bootoutput
="PP5020.mi4"
2384 # toolset is the tools within the tools directory that we build for
2385 # this particular target.
2386 toolset
=$scramblebitmaptools
2387 # architecture, manufacturer and model for the target-tree build
2389 t_manufacturer
="samsung"
2395 modelname
="samsungyh925"
2396 target
="-DSAMSUNG_YH925"
2399 tool
="$rootdir/tools/scramble -mi4v2 -model=y925 -type=RBOS"
2400 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2401 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2402 output
="rockbox.mi4"
2403 appextra
="recorder:gui"
2406 boottool
="$rootdir/tools/scramble -mi4v2 -model=y925 -type=RBBL"
2407 bootoutput
="FW_YH925.mi4"
2408 # toolset is the tools within the tools directory that we build for
2409 # this particular target.
2410 toolset
=$scramblebitmaptools
2411 # architecture, manufacturer and model for the target-tree build
2413 t_manufacturer
="samsung"
2419 modelname
="samsungyps3"
2420 target
="-DSAMSUNG_YPS3"
2424 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2425 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2426 output
="rockbox.yps3"
2427 appextra
="recorder:gui"
2430 toolset
=$genericbitmaptools
2432 bootoutput
="rockboot.ebn"
2433 # architecture, manufacturer and model for the target-tree build
2435 t_manufacturer
="s5l8700"
2441 echo "Please select a supported target platform!"
2447 echo "Platform set to $modelname"
2451 ############################################################################
2452 # Amount of memory, for those that can differ. They have $memory unset at
2456 if [ -z "$memory" ]; then
2459 if [ "$ARG_RAM" ]; then
2462 echo "Enter size of your RAM (in MB): (Defaults to 32)"
2475 if [ "$ARG_RAM" ]; then
2478 echo "Enter size of your RAM (in MB): (Defaults to 2)"
2491 echo "Memory size selected: $memory MB"
2492 [ "$ARG_TYPE" ] ||
echo ""
2496 ##################################################################
2497 # Figure out build "type"
2500 # the ifp7x0 is the only platform that supports building a gdb stub like
2504 gdbstub
="(G)DB stub, "
2506 sansae200r|sansae200
)
2507 gdbstub
="(I)nstaller, "
2510 gdbstub
="(E)raser, "
2515 if [ "$ARG_TYPE" ]; then
2518 echo "Build (N)ormal, (A)dvanced, (S)imulator, (B)ootloader, (C)heckWPS, (D)atabase tool, $gdbstub(M)anual: (Defaults to N)"
2524 appsdir
='\$(ROOTDIR)/bootloader'
2526 extradefines
="-DBOOTLOADER -DE200R_INSTALLER -ffunction-sections -fdata-sections"
2528 echo "e200R-installer build selected"
2531 appsdir
='\$(ROOTDIR)/bootloader'
2533 echo "C2(4)0 or C2(5)0"
2537 extradefines
="-DBOOTLOADER -DC200_ERASE -DC240_ERASE -ffunction-sections -fdata-sections"
2538 echo "c240 eraser build selected"
2541 extradefines
="-DBOOTLOADER -DC200_ERASE -DC250_ERASE -ffunction-sections -fdata-sections"
2542 echo "c240 eraser build selected"
2546 echo "c200 eraser build selected"
2549 if test $t_manufacturer = "archos"; then
2550 # Archos SH-based players do this somewhat differently for
2552 appsdir
='\$(ROOTDIR)/flash/bootbox'
2555 appsdir
='\$(ROOTDIR)/bootloader'
2558 if test -n "$boottool"; then
2561 if test -n "$bootoutput"; then
2565 extradefines
="-DBOOTLOADER -ffunction-sections -fdata-sections"
2567 echo "Bootloader build selected"
2570 if [ "$modelname" = "sansae200r" ]; then
2571 echo "Do not use the e200R target for simulator builds. Use e200 instead."
2576 extradefines
="-DSIMULATOR"
2579 echo "Simulator build selected"
2582 echo "Advanced build selected"
2583 whichadvanced
$btype
2586 extradefines
="-DSTUB" # for target makefile symbol EXTRA_DEFINES
2587 appsdir
='\$(ROOTDIR)/gdb'
2596 echo "GDB stub build selected"
2601 echo "Manual build selected"
2609 appsdir
='\$(ROOTDIR)/tools/checkwps';
2610 output
='checkwps.'${modelname};
2612 echo "CheckWPS build selected"
2620 appsdir
='\$(ROOTDIR)/tools/database';
2621 output
='database.'${modelname};
2623 echo "Database tool build selected"
2626 if [ "$modelname" = "sansae200r" ]; then
2627 echo "Do not use the e200R target for regular builds. Use e200 instead."
2631 btype
="N" # set it explicitly since RET only gets here as well
2632 echo "Normal build selected"
2636 # to be able running "make manual" from non-manual configuration
2639 manualdev
="archosfmrecorder"
2642 manualdev
="iriverh100"
2645 manualdev
="ipodmini1g"
2648 manualdev
=$modelname
2652 if [ -z "$debug" ]; then
2653 GCCOPTS
="$GCCOPTS $GCCOPTIMIZE"
2656 echo "Using source code root directory: $rootdir"
2658 # this was once possible to change at build-time, but no more:
2663 if [ "yes" = "$simulator" ]; then
2664 # setup compiler and things for simulator
2667 if [ -d "simdisk" ]; then
2668 echo "Subdirectory 'simdisk' already present"
2671 echo "Created a 'simdisk' subdirectory for simulating the hard disk"
2675 # Now, figure out version number of the (gcc) compiler we are about to use
2676 gccver
=`$CC -dumpversion`;
2678 # figure out the binutil version too and display it, mostly for the build
2679 # system etc to be able to see it easier
2680 if [ $uname = "Darwin" ]; then
2681 ldver
=`$LD -v 2>&1 | sed -e 's/[^0-9.-]//g'`
2683 ldver
=`$LD --version | head -n 1 | sed -e 's/[^0-9.]//g'`
2686 if [ -z "$gccver" ]; then
2687 echo "[WARNING] The compiler you must use ($CC) is not in your path!"
2688 echo "[WARNING] this may cause your build to fail since we cannot do the"
2689 echo "[WARNING] checks we want now."
2692 # gccver should now be "3.3.5", "3.4.3", "2.95.3-6" and similar, but don't
2695 num1
=`echo $gccver | cut -d . -f1`
2696 num2
=`echo $gccver | cut -d . -f2`
2697 gccnum
=`(expr $num1 "*" 100 + $num2) 2>/dev/null`
2704 echo "Using $CC $gccver ($gccnum)"
2706 if test "$gccnum" -ge "400"; then
2707 # gcc 4.0 is just *so* much pickier on arguments that differ in signedness
2708 # so we ignore that warnings for now
2710 GCCOPTS
="$GCCOPTS -Wno-pointer-sign"
2713 if test "$gccnum" -ge "401"; then
2714 # this is a lame hack to avoid "warning: dereferencing type-punned pointer
2715 # will break strict-aliasing rules"
2717 GCCOPTS
="$GCCOPTS -fno-strict-aliasing"
2720 if test "$gccnum" -ge "402"; then
2721 # disable warning about "warning: initialized field overwritten" as gcc 4.2
2722 # and later would throw it for several valid cases
2723 GCCOPTS
="$GCCOPTS -Wno-override-init"
2731 # cross-compile for win32
2734 # Verify that the cross-compiler is of a recommended version!
2735 if test "$gccver" != "$gccchoice"; then
2736 echo "WARNING: Your cross-compiler $CC $gccver is not of the recommended"
2737 echo "WARNING: version $gccchoice!"
2738 echo "WARNING: This may cause your build to fail since it may be a version"
2739 echo "WARNING: that isn't functional or known to not be the best choice."
2740 echo "WARNING: If you suffer from build problems, you know that this is"
2741 echo "WARNING: a likely source for them..."
2749 echo "Using $LD $ldver"
2751 # check the compiler for SH platforms
2752 if test "$CC" = "sh-elf-gcc"; then
2753 if test "$gccnum" -lt "400"; then
2754 echo "WARNING: Consider upgrading your compiler to the 4.0.X series!"
2755 echo "WARNING: http://www.rockbox.org/twiki/bin/view/Main/CrossCompiler"
2757 # figure out patch status
2758 gccpatch
=`$CC --version`;
2760 if { echo $gccpatch |
grep "rockbox" >/dev
/null
2>&1; } then
2761 echo "gcc $gccver is rockbox patched"
2762 # then convert -O to -Os to get smaller binaries!
2763 GCCOPTS
=`echo $GCCOPTS | sed 's/ -O / -Os /'`
2765 echo "WARNING: You use an unpatched gcc compiler: $gccver"
2766 echo "WARNING: http://www.rockbox.org/twiki/bin/view/Main/CrossCompiler"
2771 if test "$CC" = "m68k-elf-gcc"; then
2772 # convert -O to -Os to get smaller binaries!
2773 GCCOPTS
=`echo $GCCOPTS | sed 's/ -O / -Os /'`
2776 if [ "$ARG_CCACHE" = "1" ]; then
2777 echo "Enable ccache for building"
2779 elif [ "$ARG_CCACHE" != "0" ]; then
2780 ccache
=`findtool ccache`
2781 if test -n "$ccache"; then
2782 echo "Found and uses ccache ($ccache)"
2786 # figure out the full path to the various commands if possible
2787 HOSTCC
=`findtool gcc --lit`
2788 HOSTAR
=`findtool ar --lit`
2789 CC
=`findtool ${CC} --lit`
2790 LD
=`findtool ${AR} --lit`
2791 AR
=`findtool ${AR} --lit`
2792 AS
=`findtool ${AS} --lit`
2793 OC
=`findtool ${OC} --lit`
2794 WINDRES
=`findtool ${WINDRES} --lit`
2795 DLLTOOL
=`findtool ${DLLTOOL} --lit`
2796 DLLWRAP
=`findtool ${DLLWRAP} --lit`
2797 RANLIB
=`findtool ${RANLIB} --lit`
2799 if test -n "$ccache"; then
2803 if test "X$endian" = "Xbig"; then
2804 defendian
="ROCKBOX_BIG_ENDIAN"
2806 defendian
="ROCKBOX_LITTLE_ENDIAN"
2809 if [ "$ARG_RBDIR" ]; then
2811 echo "Using alternate rockbox dir: ${rbdir}"
2815 -e "s,@ENDIAN@,${defendian},g" \
2816 -e "s,^#undef ROCKBOX_HAS_LOGF,$use_logf,g" \
2817 -e "s,@config_rtc@,$config_rtc,g" \
2818 -e "s,@have_rtc_alarm@,$have_rtc_alarm,g" \
2819 -e "s,@RBDIR@,${rbdir},g" \
2820 -e "s,@have_backlight@,$have_backlight,g" \
2821 -e "s,@have_fmradio_in@,$have_fmradio_in,g" \
2822 -e "s,@have_ata_poweroff@,$have_ata_poweroff,g" \
2824 /* This header was made by configure */
2825 #ifndef __BUILD_AUTOCONF_H
2826 #define __BUILD_AUTOCONF_H
2828 /* Define endianess for the target or simulator platform */
2831 /* Define this if you build rockbox to support the logf logging and display */
2832 #undef ROCKBOX_HAS_LOGF
2834 /* optional define for a backlight modded Ondio */
2837 /* optional define for FM radio mod for iAudio M5 */
2840 /* optional define for ATA poweroff on Player */
2843 /* optional defines for RTC mod for h1x0 */
2847 /* root of Rockbox */
2848 #define ROCKBOX_DIR "/@RBDIR@"
2850 #endif /* __BUILD_AUTOCONF_H */
2853 if test -n "$t_cpu"; then
2854 TARGET_INC
="-I\$(FIRMDIR)/target/$t_cpu/$t_manufacturer/$t_model"
2855 TARGET_INC
="$TARGET_INC -I\$(FIRMDIR)/target/$t_cpu/$t_manufacturer"
2856 TARGET_INC
="$TARGET_INC -I\$(FIRMDIR)/target/$t_cpu"
2860 if test "$simulator" = "yes"; then
2861 # add simul make stuff on the #SIMUL# line
2862 simmagic1
="s,@SIMUL1@,\$(SILENT)\$(MAKE) -C \$(SIMDIR) OBJDIR=\$(BUILDDIR)/sim,"
2863 simmagic2
="s,@SIMUL2@,\$(SILENT)\$(MAKE) -C \$(ROOTDIR)/uisimulator/common OBJDIR=\$(BUILDDIR)/comsim,"
2865 # delete the lines that match
2866 simmagic1
='/@SIMUL1@/D'
2867 simmagic2
='/@SIMUL2@/D'
2870 if test "$swcodec" = "yes"; then
2871 voicetoolset
="rbspeexenc voicefont wavtrim"
2873 voicetoolset
="voicefont wavtrim"
2876 if test "$apps" = "apps"; then
2877 # only when we build "real" apps we build the .lng files
2881 #### Fix the cmdline ###
2882 if test -n "$ccache"; then
2886 cmdline
="$cmdline--target=\$(MODELNAME) --ram=\$(MEMORYSIZE) --rbdir=\$(RBDIR) --type=$btype$advopts"
2890 -e "s,@ROOTDIR@,${rootdir},g" \
2891 -e "s,@DEBUG@,${debug},g" \
2892 -e "s,@MEMORY@,${memory},g" \
2893 -e "s,@TARGET_ID@,${target_id},g" \
2894 -e "s,@TARGET@,${target},g" \
2895 -e "s,@CPU@,${t_cpu},g" \
2896 -e "s,@MANUFACTURER@,${t_manufacturer},g" \
2897 -e "s,@MODELNAME@,${modelname},g" \
2898 -e "s,@LANGUAGE@,${language},g" \
2899 -e "s:@VOICELANGUAGE@:${voicelanguage}:g" \
2900 -e "s,@PWD@,${pwd},g" \
2901 -e "s,@HOSTCC@,${HOSTCC},g" \
2902 -e "s,@HOSTAR@,${HOSTAR},g" \
2903 -e "s,@CC@,${CC},g" \
2904 -e "s,@LD@,${LD},g" \
2905 -e "s,@AR@,${AR},g" \
2906 -e "s,@AS@,${AS},g" \
2907 -e "s,@OC@,${OC},g" \
2908 -e "s,@WINDRES@,${WINDRES},g" \
2909 -e "s,@DLLTOOL@,${DLLTOOL},g" \
2910 -e "s,@DLLWRAP@,${DLLWRAP},g" \
2911 -e "s,@RANLIB@,${RANLIB},g" \
2912 -e "s,@TOOL@,${tool},g" \
2913 -e "s,@BMP2RB_NATIVE@,${bmp2rb_native},g" \
2914 -e "s,@BMP2RB_MONO@,${bmp2rb_mono},g" \
2915 -e "s,@BMP2RB_REMOTENATIVE@,${bmp2rb_remotenative},g" \
2916 -e "s,@BMP2RB_REMOTEMONO@,${bmp2rb_remotemono},g" \
2917 -e "s,@OUTPUT@,${output},g" \
2918 -e "s,@APPEXTRA@,${appextra},g" \
2919 -e "s,@ARCHOSROM@,${archosrom},g" \
2920 -e "s,@FLASHFILE@,${flash},g" \
2921 -e "s,@PLUGINS@,${plugins},g" \
2922 -e "s,@CODECS@,${swcodec},g" \
2923 -e "s,@PROFILE_OPTS@,${PROFILE_OPTS},g" \
2924 -e "s,@SHARED_FLAG@,${SHARED_FLAG},g" \
2925 -e "s,@GCCOPTS@,${GCCOPTS},g" \
2926 -e "s,@TARGET_INC@,${TARGET_INC},g" \
2927 -e "s!@LDOPTS@!${LDOPTS}!g" \
2928 -e "s,@LOADADDRESS@,${loadaddress},g" \
2929 -e "s,@EXTRADEF@,${extradefines},g" \
2930 -e "s,@APPSDIR@,${appsdir},g" \
2931 -e "s,@FIRMDIR@,${firmdir},g" \
2932 -e "s,@TOOLSDIR@,${toolsdir},g" \
2933 -e "s,@APPS@,${apps},g" \
2934 -e "s,@SIMVER@,${simver},g" \
2935 -e "s,@GCCVER@,${gccver},g" \
2936 -e "s,@GCCNUM@,${gccnum},g" \
2937 -e "s,@UNAME@,${uname},g" \
2938 -e "s,@ENDIAN@,${defendian},g" \
2939 -e "s,@TOOLSET@,${toolset},g" \
2942 -e "s,@MANUALDEV@,${manualdev},g" \
2943 -e "s,@ENCODER@,${ENC_CMD},g" \
2944 -e "s,@ENC_OPTS@,${ENC_OPTS},g" \
2945 -e "s,@TTS_ENGINE@,${TTS_ENGINE},g" \
2946 -e "s,@TTS_OPTS@,${TTS_OPTS},g" \
2947 -e "s,@VOICETOOLSET@,${voicetoolset},g" \
2948 -e "s,@LANGS@,${buildlangs},g" \
2949 -e "s,@USE_ELF@,${USE_ELF},g" \
2950 -e "s,@RBDIR@,${rbdir},g" \
2951 -e "s,@PREFIX@,$PREFIX,g" \
2952 -e "s,@CMDLINE@,$cmdline,g" \
2954 ## Automatically generated. http://www.rockbox.org/
2956 export ROOTDIR=@ROOTDIR@
2957 export FIRMDIR=@FIRMDIR@
2958 export APPSDIR=@APPSDIR@
2959 export TOOLSDIR=@TOOLSDIR@
2960 export DOCSDIR=\$(ROOTDIR)/docs
2961 export MANUALDIR=\${ROOTDIR}/manual
2962 export DEBUG=@DEBUG@
2963 export MODELNAME=@MODELNAME@
2964 export ARCHOSROM=@ARCHOSROM@
2965 export FLASHFILE=@FLASHFILE@
2966 export TARGET_ID=@TARGET_ID@
2967 export TARGET=@TARGET@
2969 export MANUFACTURER=@MANUFACTURER@
2971 export BUILDDIR=@PWD@
2972 export LANGUAGE=@LANGUAGE@
2973 export VOICELANGUAGE=@VOICELANGUAGE@
2974 export MEMORYSIZE=@MEMORY@
2975 export VERSION:=\$(shell \$(ROOTDIR)/tools/version.sh \$(ROOTDIR))
2976 export BUILDDATE:=\$(shell date -u +'-DYEAR=%Y -DMONTH=%m -DDAY=%d')
2977 export MKFIRMWARE=@TOOL@
2978 export BMP2RB_MONO=@BMP2RB_MONO@
2979 export BMP2RB_NATIVE=@BMP2RB_NATIVE@
2980 export BMP2RB_REMOTEMONO=@BMP2RB_REMOTEMONO@
2981 export BMP2RB_REMOTENATIVE=@BMP2RB_REMOTENATIVE@
2982 export BINARY=@OUTPUT@
2983 export APPEXTRA=@APPEXTRA@
2984 export ENABLEDPLUGINS=@PLUGINS@
2985 export SOFTWARECODECS=@CODECS@
2986 export EXTRA_DEFINES=@EXTRADEF@
2987 export HOSTCC=@HOSTCC@
2988 export HOSTAR=@HOSTAR@
2994 export WINDRES=@WINDRES@
2995 export DLLTOOL=@DLLTOOL@
2996 export DLLWRAP=@DLLWRAP@
2997 export RANLIB=@RANLIB@
2998 export PREFIX=@PREFIX@
2999 export PROFILE_OPTS=@PROFILE_OPTS@
3000 export SIMVER=@SIMVER@
3001 export SIMDIR=\$(ROOTDIR)/uisimulator/sdl
3002 export GCCOPTS=@GCCOPTS@
3003 export TARGET_INC=@TARGET_INC@
3004 export LOADADDRESS=@LOADADDRESS@
3005 export SHARED_FLAG=@SHARED_FLAG@
3006 export LDOPTS=@LDOPTS@
3007 export GCCVER=@GCCVER@
3008 export GCCNUM=@GCCNUM@
3009 export UNAME=@UNAME@
3010 export MANUALDEV=@MANUALDEV@
3011 export TTS_OPTS=@TTS_OPTS@
3012 export TTS_ENGINE=@TTS_ENGINE@
3013 export ENC_OPTS=@ENC_OPTS@
3014 export ENCODER=@ENCODER@
3015 export USE_ELF=@USE_ELF@
3016 export RBDIR=@RBDIR@
3018 CONFIGURE_OPTIONS=@CMDLINE@
3020 include \$(TOOLSDIR)/root.make
3024 echo "Created Makefile"