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
176 # fPIC is needed to make shared objects link
177 # setting visibility to hidden is necessary to avoid strange crashes
178 # due to symbol clashing
179 GCCOPTS
="$GCCOPTS -fPIC -fvisibility=hidden"
180 # x86_64 supports MMX by default
184 echo "Enabling MMX support"
185 GCCOPTS
="$GCCOPTS -mmmx"
190 cat >$tmpdir/conftest-
$id.c
<<EOF
192 int main(int argc, char **argv)
195 char *varp = (char *)&var;
203 $CC -o $tmpdir/conftest-
$id $tmpdir/conftest-
$id.c
2>/dev
/null
205 if test `$tmpdir/conftest-$id 2>/dev/null` -gt "1"; then
213 if [ $1 = "sdl" ]; then
214 echo "Simulator environment deemed $endian endian"
215 elif [ $1 = "checkwps" ]; then
216 echo "CheckWPS environment deemed $endian endian"
219 # use wildcard here to make it work even if it was named *.exe like
221 rm -f $tmpdir/conftest-
$id*
223 # We are crosscompiling
224 # add cross-compiler option(s)
225 prefixtools i586-mingw32msvc-
226 LDOPTS
="-mconsole $sdl_libs"
227 output
="rockboxui.exe" # use this as output binary name
228 endian
="little" # windows is little endian
229 echo "Enabling MMX support"
230 GCCOPTS
="$GCCOPTS -mmmx"
235 # functions for setting up cross-compiler names and options
236 # also set endianess and what the exact recommended gcc version is
237 # the gcc version should most likely match what versions we build with
242 GCCOPTS
="$CCOPTS -m1"
243 GCCOPTIMIZE
="-fomit-frame-pointer -fschedule-insns"
249 prefixtools calmrisc16-unknown-elf-
250 GCCOPTS
="-Wl\,--no-check-sections $CCOPTS"
251 GCCOPTIMIZE
="-fomit-frame-pointer"
256 prefixtools m68k-elf-
257 GCCOPTS
="$CCOPTS -m5206e -Wa\,-m5249 -malign-int -mstrict-align"
258 GCCOPTIMIZE
="-fomit-frame-pointer"
265 GCCOPTS
="$CCOPTS -mcpu=arm7tdmi"
266 if test "X$1" != "Xshort" -a "$ARG_ARM_EABI" != "1"; then
267 GCCOPTS
="$GCCOPTS -mlong-calls"
269 GCCOPTIMIZE
="-fomit-frame-pointer"
275 GCCOPTS
="$CCOPTS -mcpu=arm9tdmi"
276 if test "$modelname" != "gigabeatfx" -a "$t_manufacturer" != "as3525" -a "$ARG_ARM_EABI" != "1"; then
277 GCCOPTS
="$GCCOPTS -mlong-calls"
279 GCCOPTIMIZE
="-fomit-frame-pointer"
285 GCCOPTS
="$CCOPTS -mbig-endian -mcpu=arm940t"
286 if test "$ARG_ARM_EABI" != "1"; then
287 GCCOPTS
="$GCCOPTS -mlong-calls"
289 GCCOPTIMIZE
="-fomit-frame-pointer"
295 GCCOPTS
="$CCOPTS -mcpu=arm940t"
296 if test "$ARG_ARM_EABI" != "1"; then
297 GCCOPTS
="$GCCOPTS -mlong-calls"
299 GCCOPTIMIZE
="-fomit-frame-pointer"
305 GCCOPTS
="$CCOPTS -mcpu=arm9e"
306 if test "$ARG_ARM_EABI" != "1"; then
307 GCCOPTS
="$GCCOPTS -mlong-calls"
309 GCCOPTIMIZE
="-fomit-frame-pointer"
315 GCCOPTS
="$CCOPTS -mcpu=arm926ej-s"
316 if test "$t_manufacturer" != "as3525" -a "$ARG_ARM_EABI" != "1"; then
317 GCCOPTS
="$GCCOPTS -mlong-calls"
319 GCCOPTIMIZE
="-fomit-frame-pointer"
325 GCCOPTS
="$CCOPTS -mcpu=arm1136jf-s"
326 if test "$modelname" != "gigabeats" -a "$ARG_ARM_EABI" != "1"; then
327 GCCOPTS
="$GCCOPTS -mlong-calls"
329 GCCOPTIMIZE
="-fomit-frame-pointer"
335 GCCOPTS
="$CCOPTS -mcpu=arm1176jz-s"
336 if test "$ARG_ARM_EABI" != "1"; then
337 GCCOPTS
="$GCCOPTS -mlong-calls"
339 GCCOPTIMIZE
="-fomit-frame-pointer"
344 prefixtools mipsel-elf-
345 GCCOPTS
="$CCOPTS -march=mips32 -mtune=r4600 -mno-mips16 -mno-long-calls"
346 GCCOPTS
="$GCCOPTS -ffunction-sections -msoft-float -G 0 -Wno-parentheses"
347 GCCOPTIMIZE
="-fomit-frame-pointer"
353 atype
=`echo "$1" | cut -c 2-`
354 ##################################################################
355 # Prompt for specific developer options
357 if [ "$atype" ]; then
362 echo "Enter your developer options (press enter when done)"
363 printf "(D)EBUG, (L)ogf, (S)imulator, (P)rofiling, (V)oice, (W)in32 crosscompile"
364 if [ "$memory" = "2" ]; then
367 if [ "$modelname" = "archosplayer" ]; then
368 printf ", Use (A)TA poweroff"
370 if [ "$t_model" = "ondio" ]; then
371 printf ", (B)acklight MOD"
373 if [ "$modelname" = "iaudiom5" ]; then
374 printf ", (F)M radio MOD"
376 if [ "$modelname" = "iriverh120" ]; then
383 while [ $cont = "1" ]; do
385 if [ "$interact" ]; then
388 option
=`echo "$atype" | cut -c 1`
393 if [ "yes" = "$profile" ]; then
394 echo "Debug is incompatible with profiling"
396 echo "DEBUG build enabled"
401 echo "logf() support enabled"
405 echo "Simulator build enabled"
409 if [ "yes" = "$use_debug" ]; then
410 echo "Profiling is incompatible with debug"
412 echo "Profiling support is enabled"
417 echo "Voice build selected"
421 if [ "$memory" = "2" ]; then
423 echo "Memory size selected: 8MB"
427 if [ "$modelname" = "archosplayer" ]; then
428 have_ata_poweroff
="#define HAVE_ATA_POWEROFF"
429 echo "ATA poweroff enabled"
433 if [ "$t_model" = "ondio" ]; then
434 have_backlight
="#define HAVE_BACKLIGHT"
435 echo "Backlight functions enabled"
439 if [ "$modelname" = "iaudiom5" ]; then
440 have_fmradio_in
="#define HAVE_FMRADIO_IN"
441 echo "FM radio functions enabled"
445 if [ "$modelname" = "iriverh120" ]; then
446 config_rtc
="#define CONFIG_RTC RTC_DS1339_DS3231"
447 have_rtc_alarm
="#define HAVE_RTC_ALARM"
448 echo "RTC functions enabled (DS1339/DS3231)"
452 echo "Enabling Windows 32 cross-compiling"
456 if [ "$interact" ]; then
459 echo "[ERROR] Option $option unsupported"
463 if [ "$interact" ]; then
464 btype
="$btype$option"
466 atype
=`echo "$atype" | cut -c 2-`
467 [ "$atype" ] || cont
=0
472 if [ "yes" = "$voice" ]; then
473 # Ask about languages to build
475 voicelanguage
=`whichlang`
476 echo "Voice language set to $voicelanguage"
478 # Configure encoder and TTS engine for each language
479 for thislang
in `echo $voicelanguage | sed 's/,/ /g'`; do
480 voiceconfig
"$thislang"
483 if [ "yes" = "$use_debug" ]; then
485 GCCOPTS
="$GCCOPTS -g -DDEBUG"
487 if [ "yes" = "$logf" ]; then
488 use_logf
="#define ROCKBOX_HAS_LOGF 1"
490 if [ "yes" = "$simulator" ]; then
492 extradefines
="$extradefines -DSIMULATOR"
496 if [ "yes" = "$profile" ]; then
497 extradefines
="$extradefines -DRB_PROFILE"
498 PROFILE_OPTS
="-finstrument-functions"
502 # Configure voice settings
505 if [ ! "$ARG_TTS" ]; then
506 echo "Building $thislang voice for $modelname. Select options"
510 if [ -n "`findtool flite`" ]; then
514 DEFAULT_TTS_OPTS
=$FLITE_OPTS
515 DEFAULT_NOISEFLOOR
="500"
518 if [ -n "`findtool espeak`" ]; then
522 DEFAULT_TTS_OPTS
=$ESPEAK_OPTS
523 DEFAULT_NOISEFLOOR
="500"
526 if [ -n "`findtool festival`" ]; then
527 FESTIVAL
="(F)estival "
530 FESTIVAL_OPTS
="--language italian"
533 FESTIVAL_OPTS
="--language spanish"
536 FESTIVAL_OPTS
="--language finnish"
539 FESTIVAL_OPTS
="--language czech"
545 DEFAULT_TTS
="festival"
546 DEFAULT_TTS_OPTS
=$FESTIVAL_OPTS
547 DEFAULT_NOISEFLOOR
="500"
550 if [ -n "`findtool swift`" ]; then
554 DEFAULT_TTS_OPTS
=$SWIFT_OPTS
555 DEFAULT_NOISEFLOOR
="500"
558 # Allow SAPI if Windows is in use
559 if [ -n "`findtool winver`" ]; then
563 DEFAULT_TTS_OPTS
=$SAPI_OPTS
564 DEFAULT_NOISEFLOOR
="500"
568 if [ "$FESTIVAL" = "$FLITE" ] && [ "$FLITE" = "$ESPEAK" ] && [ "$ESPEAK" = "$SAPI" ] && [ "$SAPI" = "$SWIFT" ]; then
569 echo "You need Festival, eSpeak or Flite in your path, or SAPI available to build voice files"
573 if [ "$ARG_TTS" ]; then
576 echo "TTS engine to use: ${FLITE}${FESTIVAL}${ESPEAK}${SAPI}${SWIFT}(${DEFAULT_CHOICE})?"
579 advopts
="$advopts --tts=$option"
583 NOISEFLOOR
="500" # TODO: check this value
589 TTS_OPTS
=$ESPEAK_OPTS
592 TTS_ENGINE
="festival"
594 TTS_OPTS
=$FESTIVAL_OPTS
607 TTS_ENGINE
=$DEFAULT_TTS
608 TTS_OPTS
=$DEFAULT_TTS_OPTS
609 NOISEFLOOR
=$DEFAULT_NOISEFLOOR
611 echo "Using $TTS_ENGINE for TTS"
613 # Select which voice to use for Festival
614 if [ "$TTS_ENGINE" = "festival" ]; then
615 voicelist
=`echo "(voice.list)"|festival -i 2>/dev/null |tr "\n" " "|sed -e 's/.*festival> (\(.*\)) festival>/\1/'|sort`
616 for voice
in $voicelist; do
617 TTS_FESTIVAL_VOICE
="$voice" # Default choice
620 if [ "$ARG_VOICE" ]; then
624 for voice
in $voicelist; do
625 printf "%3d. %s\n" "$i" "$voice"
628 printf "Please select which Festival voice to use (default is $TTS_FESTIVAL_VOICE): "
632 for voice
in $voicelist; do
633 if [ "$i" = "$CHOICE" -o "$voice" = "$CHOICE" ]; then
634 TTS_FESTIVAL_VOICE
="$voice"
638 advopts
="$advopts --voice=$CHOICE"
639 echo "Festival voice set to $TTS_FESTIVAL_VOICE"
640 echo "(voice_$TTS_FESTIVAL_VOICE)" > festival-prolog.scm
643 # Read custom tts options from command line
644 if [ "$ARG_TTSOPTS" ]; then
645 TTS_OPTS
="$ARG_TTSOPTS"
646 advopts
="$advopts --ttsopts='$TTS_OPTS'"
647 echo "$TTS_ENGINE options set to $TTS_OPTS"
650 if [ "$swcodec" = "yes" ]; then
653 ENC_OPTS
="-q 4 -c 10"
655 if [ -n "`findtool lame`" ]; then
658 ENC_OPTS
="--resample 12 -t -m m -h -V 9.999 -S -B 64 --vbr-new"
660 echo "You need LAME in the system path to build voice files for"
661 echo "HWCODEC targets."
666 echo "Using $ENCODER for encoding voice clips"
668 # Read custom encoder options from command line
669 if [ "$ARG_ENCOPTS" ]; then
670 ENC_OPTS
="$ARG_ENCOPTS"
671 advopts
="$advopts --encopts='$ENC_OPTS'"
672 echo "$ENCODER options set to $ENC_OPTS"
676 if [ -n "`findtool cygpath`" ]; then
677 TEMPDIR
=`cygpath . -a -w`
682 # figure out which languages that are around
683 for file in $rootdir/apps
/lang
/*.lang
; do
684 clean
=`basename $file .lang`
685 langs
="$langs $clean"
688 if [ "$ARG_LANG" ]; then
691 echo "Select a number for the language to use (default is english)"
692 # FIXME The multiple-language feature is currently broken
693 # echo "You may enter a comma-separated list of languages to build"
696 for one
in $langs; do
702 advopts
="$advopts --language=$pick"
707 # Allow the user to pass a comma-separated list of langauges
708 for thispick
in `echo $pick | sed 's/,/ /g'`; do
710 for one
in $langs; do
711 # Accept both the language number and name
712 if [ "$num" = "$thispick" ] ||
[ "$thispick" = "$one" ]; then
713 if [ "$output" = "" ]; then
722 if [ -z "$output" ]; then
730 echo "Rockbox configure script."
731 echo "Invoke this in a directory to generate a Makefile to build Rockbox"
732 echo "Do *NOT* run this within the tools directory!"
735 Usage: configure [OPTION]...
737 --target=TARGET Sets the target, TARGET can be either the target ID or
738 corresponding string. Run without this option to see all
741 --ram=RAM Sets the RAM for certain targets. Even though any number
742 is accepted, not every number is correct. The default
743 value will be applied, if you entered a wrong number
744 (which depends on the target). Watch the output. Run
745 without this option if you are not sure which the right
748 --type=TYPE Sets the build type. Shortcuts are also valid.
749 Run without this option to see all available types.
750 Multiple values are allowed and managed in the input
751 order. So --type=b stands for Bootloader build, while
752 --type=ab stands for "Backlight MOD" build.
754 --language=LANG Set the language used for voice generation (used only if
757 --tts=ENGINE Set the TTS engine used for voice generation (used only
760 --voice=VOICE Set voice to use with selected TTS (used only if TYPE is
763 --ttsopts=OPTS Set TTS engine manual options (used only if TYPE is AV).
765 --encopts=OPTS Set encoder manual options (used only if ATYPE is AV).
767 --rbdir=dir Use alternative rockbox directory (default: ${rbdir}).
768 This is useful for having multiple alternate builds on
769 your device that you can load with ROLO. However as the
770 bootloader looks for .rockbox you won't be able to boot
773 --ccache Enable ccache use (done by default these days)
774 --no-ccache Disable ccache use
776 --eabi Make configure prefer toolchains that are able to compile
777 for the new ARM standard abi EABI
778 --no-eabi The opposite of --eabi (prefer old non-eabi toolchains)
779 --help Shows this message (must not be used with other options)
800 --ccache) ARG_CCACHE
=1;;
801 --no-ccache) ARG_CCACHE
=0;;
802 --encopts=*) ARG_ENCOPTS
=`echo "$arg" | cut -d = -f 2`;;
803 --language=*) ARG_LANG
=`echo "$arg" | cut -d = -f 2`;;
804 --ram=*) ARG_RAM
=`echo "$arg" | cut -d = -f 2`;;
805 --rbdir=*) ARG_RBDIR
=`echo "$arg" | cut -d = -f 2`;;
806 --target=*) ARG_TARGET
=`echo "$arg" | cut -d = -f 2`;;
807 --tts=*) ARG_TTS
=`echo "$arg" | cut -d = -f 2`;;
808 --ttsopts=*) ARG_TTSOPTS
=`echo "$arg" | cut -d = -f 2`;;
809 --type=*) ARG_TYPE
=`echo "$arg" | cut -d = -f 2`;;
810 --voice=*) ARG_VOICE
=`echo "$arg" | cut -d = -f 2`;;
811 --eabi) ARG_ARM_EABI
=1;;
812 --no-eabi) ARG_ARM_EABI
=0;;
814 *) err
=1; echo "[ERROR] Option '$arg' unsupported";;
821 if [ "$TMPDIR" != "" ]; then
826 echo Using temporary directory
$tmpdir
828 if test -r "configure"; then
829 # this is a check for a configure script in the current directory, it there
830 # is one, try to figure out if it is this one!
832 if { grep "^# Jukebox" configure
>/dev
/null
2>&1 ; } then
833 echo "WEEEEEEEEP. Don't run this configure script within the tools directory."
834 echo "It will only cause you pain and grief. Instead do this:"
837 echo " mkdir build-dir"
839 echo " ../tools/configure"
841 echo "Much happiness will arise from this. Enjoy"
846 # get our current directory
849 if { echo $pwd |
grep " "; } then
850 echo "You're running this script in a path that contains space. The build"
851 echo "system is unfortunately not clever enough to deal with this. Please"
852 echo "run the script from a different path, rename the path or fix the build"
857 if [ -z "$rootdir" ]; then
858 ##################################################################
859 # Figure out where the source code root is!
861 rootdir
=`dirname $0`/..
/
863 #####################################################################
864 # Convert the possibly relative directory name to an absolute version
870 # cd back to the build dir
875 appsdir
='\$(ROOTDIR)/apps'
876 firmdir
='\$(ROOTDIR)/firmware'
877 toolsdir
='\$(ROOTDIR)/tools'
880 ##################################################################
881 # Figure out target platform
884 if [ "$ARG_TARGET" ]; then
887 echo "Enter target platform:"
889 ==Archos== ==iriver== ==Apple iPod==
890 0) Player/Studio 10) H120/H140 20) Color/Photo
891 1) Recorder 11) H320/H340 21) Nano 1G
892 2) FM Recorder 12) iHP-100/110/115 22) Video
893 3) Recorder v2 13) iFP-790 23) 3G
894 4) Ondio SP 14) H10 20Gb 24) 4G Grayscale
895 5) Ondio FM 15) H10 5/6Gb 25) Mini 1G
897 ==Toshiba== 27) 1G, 2G
898 ==Cowon/iAudio== 40) Gigabeat F/X 28) Nano 2G
899 30) X5/X5V/X5L 41) Gigabeat S
900 31) M5/M5L ==SanDisk==
901 32) 7 ==Olympus= 50) Sansa e200
902 33) D2 70) M:Robe 500 51) Sansa e200R
903 34) M3/M3L 71) M:Robe 100 52) Sansa c200
905 ==Creative== ==Philips== 54) Sansa c100
906 90) Zen Vision:M 30GB 100) GoGear SA9200 55) Sansa Clip
907 91) Zen Vision:M 60GB 101) GoGear HDD1630/ 56) Sansa e200v2
908 92) Zen Vision HDD1830 57) Sansa m200v4
909 102) GoGear HDD6330 58) Sansa Fuze
910 ==Onda== 59) Sansa c200v2
911 120) VX747 ==Meizu== 60) Sansa Clipv2
912 121) VX767 110) M6SL 61) Sansa View
913 122) VX747+ 111) M6SP 62) Sansa Clip+
914 123) VX777 112) M3 63) Sansa Fuze v2
917 ==Samsung== ==Tatung== 80) DAX 1GB MP3/DAB
918 140) YH-820 150) Elio TPJ-1022
919 141) YH-920 ==Lyre project==1
920 142) YH-925 ==Packard Bell== 130) Lyre proto 1
921 143) YP-S3 160) Vibe 500 131) Mini2440
927 # Set of tools built for all target platforms:
928 toolset
="rdf2binary convbdf codepages"
930 # Toolsets for some target families:
931 archosbitmaptools
="$toolset scramble descramble sh2d uclpack bmp2rb"
932 iriverbitmaptools
="$toolset scramble descramble mkboot bmp2rb"
933 iaudiobitmaptools
="$toolset scramble descramble mkboot bmp2rb"
934 ipodbitmaptools
="$toolset scramble bmp2rb"
935 gigabeatbitmaptools
="$toolset scramble descramble bmp2rb"
936 tccbitmaptools
="$toolset scramble bmp2rb"
937 # generic is used by IFP, Meizu and Onda
938 genericbitmaptools
="$toolset bmp2rb"
939 # scramble is used by all other targets
940 scramblebitmaptools
="$genericbitmaptools scramble"
943 # ---- For each target ----
946 # target_id: a unique number identifying this target, IS NOT the menu number.
947 # Just use the currently highest number+1 when you add a new
949 # modelname: short model name used all over to identify this target
950 # memory: number of megabytes of RAM this target has. If the amount can
951 # be selected by the size prompt, let memory be unset here
952 # target: -Ddefine passed to the build commands to make the correct
953 # config-*.h file get included etc
954 # tool: the tool that takes a plain binary and converts that into a
955 # working "firmware" file for your target
956 # output: the final output file name
957 # boottool: the tool that takes a plain binary and generates a bootloader
958 # file for your target (or blank to use $tool)
959 # bootoutput:the final output file name for the bootloader (or blank to use
961 # appextra: passed to the APPEXTRA variable in the Makefiles.
962 # TODO: add proper explanation
963 # archosrom: used only for Archos targets that build a special flashable .ucl
965 # flash: name of output for flashing, for targets where there's a special
966 # file output for this.
967 # plugins: set to 'yes' to build the plugins. Early development builds can
968 # set this to no in the early stages to have an easier life for a
970 # swcodec: set 'yes' on swcodec targets
971 # toolset: lists what particular tools in the tools/ directory that this
972 # target needs to have built prior to building Rockbox
975 # *cc: sets up gcc and compiler options for your target builds. Note
976 # that if you select a simulator build, the compiler selection is
977 # overridden later in the script.
983 modelname
="archosplayer"
984 target
="-DARCHOS_PLAYER"
986 tool
="$rootdir/tools/scramble"
988 appextra
="player:gui"
989 archosrom
="$pwd/rombox.ucl"
990 flash
="$pwd/rockbox.ucl"
994 # toolset is the tools within the tools directory that we build for
995 # this particular target.
996 toolset
="$toolset scramble descramble sh2d player_unifont uclpack"
998 # Note: the convbdf is present in the toolset just because: 1) the
999 # firmware/Makefile assumes it is present always, and 2) we will need it when we
1000 # build the player simulator
1003 t_manufacturer
="archos"
1009 modelname
="archosrecorder"
1010 target
="-DARCHOS_RECORDER"
1012 tool
="$rootdir/tools/scramble"
1013 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1014 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1016 appextra
="recorder:gui"
1017 #archosrom="$pwd/rombox.ucl"
1018 flash
="$pwd/rockbox.ucl"
1021 # toolset is the tools within the tools directory that we build for
1022 # this particular target.
1023 toolset
=$archosbitmaptools
1025 t_manufacturer
="archos"
1031 modelname
="archosfmrecorder"
1032 target
="-DARCHOS_FMRECORDER"
1034 tool
="$rootdir/tools/scramble -fm"
1035 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1036 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1038 appextra
="recorder:gui"
1039 #archosrom="$pwd/rombox.ucl"
1040 flash
="$pwd/rockbox.ucl"
1043 # toolset is the tools within the tools directory that we build for
1044 # this particular target.
1045 toolset
=$archosbitmaptools
1047 t_manufacturer
="archos"
1053 modelname
="archosrecorderv2"
1054 target
="-DARCHOS_RECORDERV2"
1056 tool
="$rootdir/tools/scramble -v2"
1057 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1058 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1060 appextra
="recorder:gui"
1061 #archosrom="$pwd/rombox.ucl"
1062 flash
="$pwd/rockbox.ucl"
1065 # toolset is the tools within the tools directory that we build for
1066 # this particular target.
1067 toolset
=$archosbitmaptools
1069 t_manufacturer
="archos"
1075 modelname
="archosondiosp"
1076 target
="-DARCHOS_ONDIOSP"
1078 tool
="$rootdir/tools/scramble -osp"
1079 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1080 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1082 appextra
="recorder:gui"
1083 #archosrom="$pwd/rombox.ucl"
1084 flash
="$pwd/rockbox.ucl"
1087 # toolset is the tools within the tools directory that we build for
1088 # this particular target.
1089 toolset
=$archosbitmaptools
1091 t_manufacturer
="archos"
1097 modelname
="archosondiofm"
1098 target
="-DARCHOS_ONDIOFM"
1100 tool
="$rootdir/tools/scramble -ofm"
1101 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1102 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1104 appextra
="recorder:gui"
1105 #archosrom="$pwd/rombox.ucl"
1106 flash
="$pwd/rockbox.ucl"
1109 toolset
=$archosbitmaptools
1111 t_manufacturer
="archos"
1117 modelname
="archosav300"
1118 target
="-DARCHOS_AV300"
1121 tool
="$rootdir/tools/scramble -mm=C"
1122 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1123 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1125 appextra
="recorder:gui"
1128 # toolset is the tools within the tools directory that we build for
1129 # this particular target.
1130 toolset
="$toolset scramble descramble bmp2rb"
1131 # architecture, manufacturer and model for the target-tree build
1133 t_manufacturer
="archos"
1139 modelname
="iriverh120"
1140 target
="-DIRIVER_H120"
1143 tool
="$rootdir/tools/scramble -add=h120"
1144 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1145 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1146 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1147 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1148 output
="rockbox.iriver"
1149 bootoutput
="bootloader.iriver"
1150 appextra
="recorder:gui"
1151 flash
="$pwd/rombox.iriver"
1154 # toolset is the tools within the tools directory that we build for
1155 # this particular target.
1156 toolset
=$iriverbitmaptools
1158 t_manufacturer
="iriver"
1164 modelname
="iriverh300"
1165 target
="-DIRIVER_H300"
1168 tool
="$rootdir/tools/scramble -add=h300"
1169 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1170 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1171 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1172 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1173 output
="rockbox.iriver"
1174 appextra
="recorder:gui"
1177 # toolset is the tools within the tools directory that we build for
1178 # this particular target.
1179 toolset
=$iriverbitmaptools
1181 t_manufacturer
="iriver"
1187 modelname
="iriverh100"
1188 target
="-DIRIVER_H100"
1191 tool
="$rootdir/tools/scramble -add=h100"
1192 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1193 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1194 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1195 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1196 output
="rockbox.iriver"
1197 bootoutput
="bootloader.iriver"
1198 appextra
="recorder:gui"
1199 flash
="$pwd/rombox.iriver"
1202 # toolset is the tools within the tools directory that we build for
1203 # this particular target.
1204 toolset
=$iriverbitmaptools
1206 t_manufacturer
="iriver"
1212 modelname
="iriverifp7xx"
1213 target
="-DIRIVER_IFP7XX"
1217 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1218 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1219 output
="rockbox.wma"
1220 appextra
="recorder:gui"
1223 # toolset is the tools within the tools directory that we build for
1224 # this particular target.
1225 toolset
=$genericbitmaptools
1227 t_manufacturer
="pnx0101"
1228 t_model
="iriver-ifp7xx"
1233 modelname
="iriverh10"
1234 target
="-DIRIVER_H10"
1237 tool
="$rootdir/tools/scramble -mi4v3 -model=h10 -type=RBOS"
1238 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1239 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1240 output
="rockbox.mi4"
1241 appextra
="recorder:gui"
1244 boottool
="$rootdir/tools/scramble -mi4v3 -model=h10 -type=RBBL"
1245 bootoutput
="H10_20GC.mi4"
1246 # toolset is the tools within the tools directory that we build for
1247 # this particular target.
1248 toolset
=$scramblebitmaptools
1249 # architecture, manufacturer and model for the target-tree build
1251 t_manufacturer
="iriver"
1257 modelname
="iriverh10_5gb"
1258 target
="-DIRIVER_H10_5GB"
1261 tool
="$rootdir/tools/scramble -mi4v2 -model=h105 -type=RBOS"
1262 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1263 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1264 output
="rockbox.mi4"
1265 appextra
="recorder:gui"
1268 boottool
="$rootdir/tools/scramble -mi4v2 -model=h105 -type=RBBL"
1269 bootoutput
="H10.mi4"
1270 # toolset is the tools within the tools directory that we build for
1271 # this particular target.
1272 toolset
=$scramblebitmaptools
1273 # architecture, manufacturer and model for the target-tree build
1275 t_manufacturer
="iriver"
1281 modelname
="ipodcolor"
1282 target
="-DIPOD_COLOR"
1285 tool
="$rootdir/tools/scramble -add=ipco"
1286 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1287 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1288 output
="rockbox.ipod"
1289 appextra
="recorder:gui"
1292 bootoutput
="bootloader-$modelname.ipod"
1293 # toolset is the tools within the tools directory that we build for
1294 # this particular target.
1295 toolset
=$ipodbitmaptools
1296 # architecture, manufacturer and model for the target-tree build
1298 t_manufacturer
="ipod"
1304 modelname
="ipodnano1g"
1305 target
="-DIPOD_NANO"
1308 tool
="$rootdir/tools/scramble -add=nano"
1309 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1310 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1311 output
="rockbox.ipod"
1312 appextra
="recorder:gui"
1315 bootoutput
="bootloader-$modelname.ipod"
1316 # toolset is the tools within the tools directory that we build for
1317 # this particular target.
1318 toolset
=$ipodbitmaptools
1319 # architecture, manufacturer and model for the target-tree build
1321 t_manufacturer
="ipod"
1327 modelname
="ipodvideo"
1328 target
="-DIPOD_VIDEO"
1330 tool
="$rootdir/tools/scramble -add=ipvd"
1331 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1332 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1333 output
="rockbox.ipod"
1334 appextra
="recorder:gui"
1337 bootoutput
="bootloader-$modelname.ipod"
1338 # toolset is the tools within the tools directory that we build for
1339 # this particular target.
1340 toolset
=$ipodbitmaptools
1341 # architecture, manufacturer and model for the target-tree build
1343 t_manufacturer
="ipod"
1353 tool
="$rootdir/tools/scramble -add=ip3g"
1354 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1355 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1356 output
="rockbox.ipod"
1357 appextra
="recorder:gui"
1360 bootoutput
="bootloader-$modelname.ipod"
1361 # toolset is the tools within the tools directory that we build for
1362 # this particular target.
1363 toolset
=$ipodbitmaptools
1364 # architecture, manufacturer and model for the target-tree build
1366 t_manufacturer
="ipod"
1376 tool
="$rootdir/tools/scramble -add=ip4g"
1377 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1378 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1379 output
="rockbox.ipod"
1380 appextra
="recorder:gui"
1383 bootoutput
="bootloader-$modelname.ipod"
1384 # toolset is the tools within the tools directory that we build for
1385 # this particular target.
1386 toolset
=$ipodbitmaptools
1387 # architecture, manufacturer and model for the target-tree build
1389 t_manufacturer
="ipod"
1395 modelname
="ipodmini1g"
1396 target
="-DIPOD_MINI"
1399 tool
="$rootdir/tools/scramble -add=mini"
1400 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1401 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1402 output
="rockbox.ipod"
1403 appextra
="recorder:gui"
1406 bootoutput
="bootloader-$modelname.ipod"
1407 # toolset is the tools within the tools directory that we build for
1408 # this particular target.
1409 toolset
=$ipodbitmaptools
1410 # architecture, manufacturer and model for the target-tree build
1412 t_manufacturer
="ipod"
1418 modelname
="ipodmini2g"
1419 target
="-DIPOD_MINI2G"
1422 tool
="$rootdir/tools/scramble -add=mn2g"
1423 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1424 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1425 output
="rockbox.ipod"
1426 appextra
="recorder:gui"
1429 bootoutput
="bootloader-$modelname.ipod"
1430 # toolset is the tools within the tools directory that we build for
1431 # this particular target.
1432 toolset
=$ipodbitmaptools
1433 # architecture, manufacturer and model for the target-tree build
1435 t_manufacturer
="ipod"
1441 modelname
="ipod1g2g"
1442 target
="-DIPOD_1G2G"
1445 tool
="$rootdir/tools/scramble -add=1g2g"
1446 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1447 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1448 output
="rockbox.ipod"
1449 appextra
="recorder:gui"
1452 bootoutput
="bootloader-$modelname.ipod"
1453 # toolset is the tools within the tools directory that we build for
1454 # this particular target.
1455 toolset
=$ipodbitmaptools
1456 # architecture, manufacturer and model for the target-tree build
1458 t_manufacturer
="ipod"
1464 modelname
="ipodnano2g"
1465 target
="-DIPOD_NANO2G"
1468 tool
="$rootdir/tools/scramble -add=nn2g"
1469 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1470 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1471 output
="rockbox.ipod"
1472 appextra
="recorder:gui"
1475 bootoutput
="bootloader-$modelname.ipod"
1476 # toolset is the tools within the tools directory that we build for
1477 # this particular target.
1478 toolset
=$ipodbitmaptools
1479 # architecture, manufacturer and model for the target-tree build
1481 t_manufacturer
="s5l8700"
1482 t_model
="ipodnano2g"
1487 modelname
="iaudiox5"
1488 target
="-DIAUDIO_X5"
1491 tool
="$rootdir/tools/scramble -add=iax5"
1492 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1493 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1494 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1495 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 7"
1496 output
="rockbox.iaudio"
1497 appextra
="recorder:gui"
1500 # toolset is the tools within the tools directory that we build for
1501 # this particular target.
1502 toolset
="$iaudiobitmaptools"
1503 # architecture, manufacturer and model for the target-tree build
1505 t_manufacturer
="iaudio"
1511 modelname
="iaudiom5"
1512 target
="-DIAUDIO_M5"
1515 tool
="$rootdir/tools/scramble -add=iam5"
1516 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1517 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1518 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1519 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 7"
1520 output
="rockbox.iaudio"
1521 appextra
="recorder:gui"
1524 # toolset is the tools within the tools directory that we build for
1525 # this particular target.
1526 toolset
="$iaudiobitmaptools"
1527 # architecture, manufacturer and model for the target-tree build
1529 t_manufacturer
="iaudio"
1539 tool
="$rootdir/tools/scramble -add=i7"
1540 boottool
="$rootdir/tools/scramble -tcc=crc"
1541 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1542 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1543 output
="rockbox.iaudio"
1544 appextra
="recorder:gui"
1547 bootoutput
="I7_FW.BIN"
1548 # toolset is the tools within the tools directory that we build for
1549 # this particular target.
1550 toolset
="$tccbitmaptools"
1551 # architecture, manufacturer and model for the target-tree build
1553 t_manufacturer
="tcc77x"
1563 tool
="$rootdir/tools/scramble -add=d2"
1565 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1566 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1568 bootoutput
="bootloader-cowond2.bin"
1569 appextra
="recorder:gui"
1572 toolset
="$tccbitmaptools"
1573 # architecture, manufacturer and model for the target-tree build
1575 t_manufacturer
="tcc780x"
1581 modelname
="iaudiom3"
1582 target
="-DIAUDIO_M3"
1585 tool
="$rootdir/tools/scramble -add=iam3"
1586 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1587 bmp2rb_native
="$rootdir/tools/bmp2rb -f 7"
1588 output
="rockbox.iaudio"
1589 appextra
="recorder:gui"
1592 # toolset is the tools within the tools directory that we build for
1593 # this particular target.
1594 toolset
="$iaudiobitmaptools"
1595 # architecture, manufacturer and model for the target-tree build
1597 t_manufacturer
="iaudio"
1603 modelname
="gigabeatfx"
1604 target
="-DGIGABEAT_F"
1607 tool
="$rootdir/tools/scramble -add=giga"
1608 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1609 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1610 output
="rockbox.gigabeat"
1611 appextra
="recorder:gui"
1614 toolset
=$gigabeatbitmaptools
1615 boottool
="$rootdir/tools/scramble -gigabeat"
1616 bootoutput
="FWIMG01.DAT"
1617 # architecture, manufacturer and model for the target-tree build
1619 t_manufacturer
="s3c2440"
1620 t_model
="gigabeat-fx"
1625 modelname
="gigabeats"
1626 target
="-DGIGABEAT_S"
1629 tool
="$rootdir/tools/scramble -add=gigs"
1630 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1631 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1632 output
="rockbox.gigabeat"
1633 appextra
="recorder:gui"
1636 toolset
="$gigabeatbitmaptools"
1637 boottool
="$rootdir/tools/scramble -gigabeats"
1639 # architecture, manufacturer and model for the target-tree build
1641 t_manufacturer
="imx31"
1642 t_model
="gigabeat-s"
1647 modelname
="mrobe500"
1648 target
="-DMROBE_500"
1651 tool
="$rootdir/tools/scramble -add=m500"
1652 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1653 bmp2rb_native
="$rootdir/tools/bmp2rb -f 8"
1654 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1655 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1656 output
="rockbox.mrobe500"
1657 appextra
="recorder:gui"
1660 toolset
=$gigabeatbitmaptools
1662 bootoutput
="rockbox.mrboot"
1663 # architecture, manufacturer and model for the target-tree build
1665 t_manufacturer
="tms320dm320"
1671 modelname
="mrobe100"
1672 target
="-DMROBE_100"
1675 tool
="$rootdir/tools/scramble -mi4v2 -model=m100 -type=RBOS"
1676 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1677 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1678 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1679 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
1680 output
="rockbox.mi4"
1681 appextra
="recorder:gui"
1684 boottool
="$rootdir/tools/scramble -mi4v2 -model=m100 -type=RBBL"
1685 bootoutput
="pp5020.mi4"
1686 # toolset is the tools within the tools directory that we build for
1687 # this particular target.
1688 toolset
=$scramblebitmaptools
1689 # architecture, manufacturer and model for the target-tree build
1691 t_manufacturer
="olympus"
1697 modelname
="logikdax"
1698 target
="-DLOGIK_DAX"
1701 tool
="$rootdir/tools/scramble -add=ldax"
1702 boottool
="$rootdir/tools/scramble -tcc=crc"
1703 bootoutput
="player.rom"
1704 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1705 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1706 output
="rockbox.logik"
1707 appextra
="recorder:gui"
1710 # toolset is the tools within the tools directory that we build for
1711 # this particular target.
1712 toolset
=$tccbitmaptools
1713 # architecture, manufacturer and model for the target-tree build
1715 t_manufacturer
="tcc77x"
1721 modelname
="zenvisionm30gb"
1722 target
="-DCREATIVE_ZVM"
1725 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1726 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1727 tool
="$rootdir/tools/scramble -creative=zvm"
1729 output
="rockbox.zvm"
1730 appextra
="recorder:gui"
1733 toolset
=$ipodbitmaptools
1734 boottool
="$rootdir/tools/scramble -creative=zvm -no-ciff"
1735 bootoutput
="rockbox.zvmboot"
1736 # architecture, manufacturer and model for the target-tree build
1738 t_manufacturer
="tms320dm320"
1739 t_model
="creative-zvm"
1744 modelname
="zenvisionm60gb"
1745 target
="-DCREATIVE_ZVM60GB"
1748 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1749 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1750 tool
="$rootdir/tools/scramble -creative=zvm60 -no-ciff"
1752 output
="rockbox.zvm60"
1753 appextra
="recorder:gui"
1756 toolset
=$ipodbitmaptools
1757 boottool
="$rootdir/tools/scramble -creative=zvm60"
1758 bootoutput
="rockbox.zvm60boot"
1759 # architecture, manufacturer and model for the target-tree build
1761 t_manufacturer
="tms320dm320"
1762 t_model
="creative-zvm"
1767 modelname
="zenvision"
1768 target
="-DCREATIVE_ZV"
1771 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1772 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1773 tool
="$rootdir/tools/scramble -creative=zenvision -no-ciff"
1776 appextra
="recorder:gui"
1779 toolset
=$ipodbitmaptools
1780 boottool
="$rootdir/tools/scramble -creative=zenvision"
1781 bootoutput
="rockbox.zvboot"
1782 # architecture, manufacturer and model for the target-tree build
1784 t_manufacturer
="tms320dm320"
1785 t_model
="creative-zvm"
1790 modelname
="sansae200"
1791 target
="-DSANSA_E200"
1792 memory
=32 # supposedly
1794 tool
="$rootdir/tools/scramble -mi4v3 -model=e200 -type=RBOS"
1795 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1796 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1797 output
="rockbox.mi4"
1798 appextra
="recorder:gui"
1801 boottool
="$rootdir/tools/scramble -mi4v3 -model=e200 -type=RBBL"
1802 bootoutput
="PP5022.mi4"
1803 # toolset is the tools within the tools directory that we build for
1804 # this particular target.
1805 toolset
=$scramblebitmaptools
1806 # architecture, manufacturer and model for the target-tree build
1808 t_manufacturer
="sandisk"
1809 t_model
="sansa-e200"
1813 # the e200R model is pretty much identical to the e200, it only has a
1814 # different option to the scramble tool when building a bootloader and
1815 # makes the bootloader output file name in all lower case.
1817 modelname
="sansae200r"
1818 target
="-DSANSA_E200"
1819 memory
=32 # supposedly
1821 tool
="$rootdir/tools/scramble -mi4v3 -model=e20r -type=RBOS"
1822 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1823 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1824 output
="rockbox.mi4"
1825 appextra
="recorder:gui"
1828 boottool
="$rootdir/tools/scramble -mi4r -model=e20r -type=RBBL"
1829 bootoutput
="pp5022.mi4"
1830 # toolset is the tools within the tools directory that we build for
1831 # this particular target.
1832 toolset
=$scramblebitmaptools
1833 # architecture, manufacturer and model for the target-tree build
1835 t_manufacturer
="sandisk"
1836 t_model
="sansa-e200"
1841 modelname
="sansac200"
1842 target
="-DSANSA_C200"
1843 memory
=32 # supposedly
1845 tool
="$rootdir/tools/scramble -mi4v3 -model=c200 -type=RBOS"
1846 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1847 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1848 output
="rockbox.mi4"
1849 appextra
="recorder:gui"
1852 boottool
="$rootdir/tools/scramble -mi4v3 -model=c200 -type=RBBL"
1853 bootoutput
="firmware.mi4"
1854 # toolset is the tools within the tools directory that we build for
1855 # this particular target.
1856 toolset
=$scramblebitmaptools
1857 # architecture, manufacturer and model for the target-tree build
1859 t_manufacturer
="sandisk"
1860 t_model
="sansa-c200"
1865 modelname
="sansam200"
1866 target
="-DSANSA_M200"
1869 tool
="$rootdir/tools/scramble -add=m200"
1870 boottool
="$rootdir/tools/scramble -tcc=crc"
1871 bootoutput
="player.rom"
1872 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1873 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
1874 output
="rockbox.m200"
1875 appextra
="recorder:gui"
1878 # toolset is the tools within the tools directory that we build for
1879 # this particular target.
1880 toolset
=$tccbitmaptools
1881 # architecture, manufacturer and model for the target-tree build
1883 t_manufacturer
="tcc77x"
1889 modelname
="sansac100"
1890 target
="-DSANSA_C100"
1893 tool
="$rootdir/tools/scramble -add=c100"
1894 boottool
="$rootdir/tools/scramble -tcc=crc"
1895 bootoutput
="player.rom"
1896 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1897 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1898 output
="rockbox.c100"
1899 appextra
="recorder:gui"
1902 # toolset is the tools within the tools directory that we build for
1903 # this particular target.
1904 toolset
=$tccbitmaptools
1905 # architecture, manufacturer and model for the target-tree build
1907 t_manufacturer
="tcc77x"
1913 modelname
="sansaclip"
1914 target
="-DSANSA_CLIP"
1916 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1917 bmp2rb_native
="$bmp2rb_mono"
1918 tool
="$rootdir/tools/scramble -add=clip"
1919 output
="rockbox.sansa"
1920 bootoutput
="bootloader-clip.sansa"
1921 appextra
="recorder:gui"
1924 toolset
=$scramblebitmaptools
1926 t_manufacturer
="as3525"
1927 t_model
="sansa-clip"
1934 modelname
="sansae200v2"
1935 target
="-DSANSA_E200V2"
1937 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1938 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1939 tool
="$rootdir/tools/scramble -add=e2v2"
1940 output
="rockbox.sansa"
1941 bootoutput
="bootloader-e200v2.sansa"
1942 appextra
="recorder:gui"
1945 toolset
=$scramblebitmaptools
1947 t_manufacturer
="as3525"
1948 t_model
="sansa-e200v2"
1955 modelname
="sansam200v4"
1956 target
="-DSANSA_M200V4"
1958 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1959 bmp2rb_native
="$bmp2rb_mono"
1960 tool
="$rootdir/tools/scramble -add=m2v4"
1961 output
="rockbox.sansa"
1962 bootoutput
="bootloader-m200v4.sansa"
1963 appextra
="recorder:gui"
1966 toolset
=$scramblebitmaptools
1968 t_manufacturer
="as3525"
1969 t_model
="sansa-m200v4"
1976 modelname
="sansafuze"
1977 target
="-DSANSA_FUZE"
1979 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1980 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1981 tool
="$rootdir/tools/scramble -add=fuze"
1982 output
="rockbox.sansa"
1983 bootoutput
="bootloader-fuze.sansa"
1984 appextra
="recorder:gui"
1987 toolset
=$scramblebitmaptools
1989 t_manufacturer
="as3525"
1990 t_model
="sansa-fuze"
1997 modelname
="sansac200v2"
1998 target
="-DSANSA_C200V2"
1999 memory
=2 # as per OF diagnosis mode
2000 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2001 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2002 tool
="$rootdir/tools/scramble -add=c2v2"
2003 output
="rockbox.sansa"
2004 bootoutput
="bootloader-c200v2.sansa"
2005 appextra
="recorder:gui"
2008 # toolset is the tools within the tools directory that we build for
2009 # this particular target.
2010 toolset
=$scramblebitmaptools
2011 # architecture, manufacturer and model for the target-tree build
2013 t_manufacturer
="as3525"
2014 t_model
="sansa-c200v2"
2020 modelname
="sansaclipv2"
2021 target
="-DSANSA_CLIPV2"
2023 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2024 bmp2rb_native
="$bmp2rb_mono"
2025 tool
="$rootdir/tools/scramble -add=clv2"
2026 output
="rockbox.sansa"
2027 bootoutput
="bootloader-clipv2.sansa"
2028 appextra
="recorder:gui"
2031 toolset
=$scramblebitmaptools
2033 t_manufacturer
="as3525"
2034 t_model
="sansa-clipv2"
2039 echo "Sansa View is not yet supported!"
2042 modelname
="sansaview"
2043 target
="-DSANSA_VIEW"
2046 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2047 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2048 output
="rockbox.mi4"
2052 boottool
="$rootdir/tools/scramble -mi4v3 -model=view -type=RBBL"
2053 bootoutput
="firmware.mi4"
2054 # toolset is the tools within the tools directory that we build for
2055 # this particular target.
2056 toolset
=$scramblebitmaptools
2058 t_manufacturer
="sandisk"
2059 t_model
="sansa-view"
2064 modelname
="sansaclipplus"
2065 target
="-DSANSA_CLIPPLUS"
2067 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2068 bmp2rb_native
="$bmp2rb_mono"
2069 tool
="$rootdir/tools/scramble -add=cli+"
2070 output
="rockbox.sansa"
2071 bootoutput
="bootloader-clipplus.sansa"
2072 appextra
="recorder:gui"
2075 toolset
=$scramblebitmaptools
2077 t_manufacturer
="as3525"
2078 t_model
="sansa-clipplus"
2084 modelname
="sansafuzev2"
2085 target
="-DSANSA_FUZEV2"
2087 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2088 bmp2rb_native
="$bmp2rb_mono"
2089 tool
="$rootdir/tools/scramble -add=fuz2"
2090 output
="rockbox.sansa"
2091 bootoutput
="bootloader-fuzev2.sansa"
2092 appextra
="recorder:gui"
2095 toolset
=$scramblebitmaptools
2097 t_manufacturer
="as3525"
2098 t_model
="sansa-fuzev2"
2104 modelname
="tatungtpj1022"
2105 target
="-DTATUNG_TPJ1022"
2108 tool
="$rootdir/tools/scramble -add tpj2"
2109 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2110 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
2111 output
="rockbox.elio"
2112 appextra
="recorder:gui"
2115 boottool
="$rootdir/tools/scramble -mi4v2"
2116 bootoutput
="pp5020.mi4"
2117 # toolset is the tools within the tools directory that we build for
2118 # this particular target.
2119 toolset
=$scramblebitmaptools
2120 # architecture, manufacturer and model for the target-tree build
2122 t_manufacturer
="tatung"
2128 modelname
="gogearsa9200"
2129 target
="-DPHILIPS_SA9200"
2130 memory
=32 # supposedly
2132 tool
="$rootdir/tools/scramble -mi4v3 -model=9200 -type=RBOS"
2133 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2134 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2135 output
="rockbox.mi4"
2136 appextra
="recorder:gui"
2139 boottool
="$rootdir/tools/scramble -mi4v3 -model=9200 -type=RBBL"
2140 bootoutput
="FWImage.ebn"
2141 # toolset is the tools within the tools directory that we build for
2142 # this particular target.
2143 toolset
=$scramblebitmaptools
2144 # architecture, manufacturer and model for the target-tree build
2146 t_manufacturer
="philips"
2152 modelname
="gogearhdd1630"
2153 target
="-DPHILIPS_HDD1630"
2154 memory
=32 # supposedly
2156 tool
="$rootdir/tools/scramble -mi4v3 -model=1630 -type=RBOS"
2157 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2158 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2159 output
="rockbox.mi4"
2160 appextra
="recorder:gui"
2163 boottool
="$rootdir/tools/scramble -mi4v3 -model=1630 -type=RBBL"
2164 bootoutput
="FWImage.ebn"
2165 # toolset is the tools within the tools directory that we build for
2166 # this particular target.
2167 toolset
=$scramblebitmaptools
2168 # architecture, manufacturer and model for the target-tree build
2170 t_manufacturer
="philips"
2176 modelname
="gogearhdd6330"
2177 target
="-DPHILIPS_HDD6330"
2178 memory
=32 # supposedly
2180 tool
="$rootdir/tools/scramble -mi4v3 -model=6330 -type=RBOS"
2181 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2182 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2183 output
="rockbox.mi4"
2184 appextra
="recorder:gui"
2187 boottool
="$rootdir/tools/scramble -mi4v3 -model=6330 -type=RBBL"
2188 bootoutput
="FWImage.ebn"
2189 # toolset is the tools within the tools directory that we build for
2190 # this particular target.
2191 toolset
=$scramblebitmaptools
2192 # architecture, manufacturer and model for the target-tree build
2194 t_manufacturer
="philips"
2200 modelname
="meizum6sl"
2201 target
="-DMEIZU_M6SL"
2205 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2206 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2207 output
="rockbox.meizu"
2208 appextra
="recorder:gui"
2211 toolset
=$genericbitmaptools
2213 bootoutput
="rockboot.ebn"
2214 # architecture, manufacturer and model for the target-tree build
2216 t_manufacturer
="s5l8700"
2217 t_model
="meizu-m6sl"
2222 modelname
="meizum6sp"
2223 target
="-DMEIZU_M6SP"
2227 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2228 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2229 output
="rockbox.meizu"
2230 appextra
="recorder:gui"
2233 toolset
=$genericbitmaptools
2235 bootoutput
="rockboot.ebn"
2236 # architecture, manufacturer and model for the target-tree build
2238 t_manufacturer
="s5l8700"
2239 t_model
="meizu-m6sp"
2249 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2250 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2251 output
="rockbox.meizu"
2252 appextra
="recorder:gui"
2255 toolset
=$genericbitmaptools
2257 bootoutput
="rockboot.ebn"
2258 # architecture, manufacturer and model for the target-tree build
2260 t_manufacturer
="s5l8700"
2266 modelname
="ondavx747"
2267 target
="-DONDA_VX747"
2270 tool
="$rootdir/tools/scramble -add=x747"
2271 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2272 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2273 output
="rockbox.vx747"
2274 appextra
="recorder:gui"
2277 toolset
=$genericbitmaptools
2278 boottool
="$rootdir/tools/scramble -ccpmp"
2279 bootoutput
="ccpmp.bin"
2280 # architecture, manufacturer and model for the target-tree build
2282 t_manufacturer
="ingenic_jz47xx"
2283 t_model
="onda_vx747"
2288 modelname
="ondavx767"
2289 target
="-DONDA_VX767"
2293 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2294 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2295 output
="rockbox.vx767"
2296 appextra
="recorder:gui"
2299 toolset
=$genericbitmaptools
2300 boottool
="$rootdir/tools/scramble -ccpmp"
2301 bootoutput
="ccpmp.bin"
2302 # architecture, manufacturer and model for the target-tree build
2304 t_manufacturer
="ingenic_jz47xx"
2305 t_model
="onda_vx767"
2310 modelname
="ondavx747p"
2311 target
="-DONDA_VX747P"
2314 tool
="$rootdir/tools/scramble -add=747p"
2315 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2316 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2317 output
="rockbox.vx747p"
2318 appextra
="recorder:gui"
2321 toolset
=$genericbitmaptools
2322 boottool
="$rootdir/tools/scramble -ccpmp"
2323 bootoutput
="ccpmp.bin"
2324 # architecture, manufacturer and model for the target-tree build
2326 t_manufacturer
="ingenic_jz47xx"
2327 t_model
="onda_vx747"
2332 modelname
="ondavx777"
2333 target
="-DONDA_VX777"
2336 tool
="$rootdir/tools/scramble -add=x777"
2337 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2338 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2339 output
="rockbox.vx777"
2340 appextra
="recorder:gui"
2343 toolset
=$genericbitmaptools
2344 boottool
="$rootdir/tools/scramble -ccpmp"
2345 bootoutput
="ccpmp.bin"
2346 # architecture, manufacturer and model for the target-tree build
2348 t_manufacturer
="ingenic_jz47xx"
2349 t_model
="onda_vx747"
2354 modelname
="lyreproto1"
2355 target
="-DLYRE_PROTO1"
2359 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2360 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2361 output
="rockbox.lyre"
2362 appextra
="recorder:gui"
2365 toolset
=$scramblebitmaptools
2367 bootoutput
="bootloader-proto1.lyre"
2368 # architecture, manufacturer and model for the target-tree build
2370 t_manufacturer
="at91sam"
2371 t_model
="lyre_proto1"
2376 modelname
="mini2440"
2380 tool
="$rootdir/tools/scramble -add=m244"
2381 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2382 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2383 output
="rockbox.mini2440"
2384 appextra
="recorder:gui"
2387 toolset
=$scramblebitmaptools
2389 bootoutput
="bootloader-mini2440.lyre"
2390 # architecture, manufacturer and model for the target-tree build
2392 t_manufacturer
="s3c2440"
2398 modelname
="samsungyh820"
2399 target
="-DSAMSUNG_YH820"
2402 tool
="$rootdir/tools/scramble -mi4v2 -model=y820 -type=RBOS"
2403 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2404 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2405 output
="rockbox.mi4"
2406 appextra
="recorder:gui"
2409 boottool
="$rootdir/tools/scramble -mi4v2 -model=y820 -type=RBBL"
2410 bootoutput
="FW_YH820.mi4"
2411 # toolset is the tools within the tools directory that we build for
2412 # this particular target.
2413 toolset
=$scramblebitmaptools
2414 # architecture, manufacturer and model for the target-tree build
2416 t_manufacturer
="samsung"
2422 modelname
="samsungyh920"
2423 target
="-DSAMSUNG_YH920"
2426 tool
="$rootdir/tools/scramble -mi4v2 -model=y920 -type=RBOS"
2427 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2428 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
2429 output
="rockbox.mi4"
2430 appextra
="recorder:gui"
2433 boottool
="$rootdir/tools/scramble -mi4v2 -model=y920 -type=RBBL"
2434 bootoutput
="PP5020.mi4"
2435 # toolset is the tools within the tools directory that we build for
2436 # this particular target.
2437 toolset
=$scramblebitmaptools
2438 # architecture, manufacturer and model for the target-tree build
2440 t_manufacturer
="samsung"
2446 modelname
="samsungyh925"
2447 target
="-DSAMSUNG_YH925"
2450 tool
="$rootdir/tools/scramble -mi4v2 -model=y925 -type=RBOS"
2451 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2452 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2453 output
="rockbox.mi4"
2454 appextra
="recorder:gui"
2457 boottool
="$rootdir/tools/scramble -mi4v2 -model=y925 -type=RBBL"
2458 bootoutput
="FW_YH925.mi4"
2459 # toolset is the tools within the tools directory that we build for
2460 # this particular target.
2461 toolset
=$scramblebitmaptools
2462 # architecture, manufacturer and model for the target-tree build
2464 t_manufacturer
="samsung"
2470 modelname
="samsungyps3"
2471 target
="-DSAMSUNG_YPS3"
2475 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2476 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
2477 output
="rockbox.yps3"
2478 appextra
="recorder:gui"
2481 toolset
=$genericbitmaptools
2483 bootoutput
="rockboot.ebn"
2484 # architecture, manufacturer and model for the target-tree build
2486 t_manufacturer
="s5l8700"
2493 target
="-DPBELL_VIBE500"
2496 tool
="$rootdir/tools/scramble -mi4v3 -model=v500 -type=RBOS"
2497 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
2498 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
2499 output
="jukebox.mi4"
2500 appextra
="recorder:gui"
2503 boottool
="$rootdir/tools/scramble -mi4v3 -model=v500 -type=RBBL"
2504 bootoutput
="rockbox.mi4"
2505 # toolset is the tools within the tools directory that we build for
2506 # this particular target.
2507 toolset
=$scramblebitmaptools
2508 # architecture, manufacturer and model for the target-tree build
2510 t_manufacturer
="pbell"
2515 echo "Please select a supported target platform!"
2521 echo "Platform set to $modelname"
2525 ############################################################################
2526 # Amount of memory, for those that can differ. They have $memory unset at
2530 if [ -z "$memory" ]; then
2533 if [ "$ARG_RAM" ]; then
2536 echo "Enter size of your RAM (in MB): (Defaults to 32)"
2549 if [ "$ARG_RAM" ]; then
2552 echo "Enter size of your RAM (in MB): (Defaults to 2)"
2565 echo "Memory size selected: $memory MB"
2566 [ "$ARG_TYPE" ] ||
echo ""
2570 ##################################################################
2571 # Figure out build "type"
2574 # the ifp7x0 is the only platform that supports building a gdb stub like
2578 gdbstub
="(G)DB stub, "
2580 sansae200r|sansae200
)
2581 gdbstub
="(I)nstaller, "
2584 gdbstub
="(E)raser, "
2589 if [ "$ARG_TYPE" ]; then
2592 echo "Build (N)ormal, (A)dvanced, (S)imulator, (B)ootloader, (C)heckWPS, (D)atabase tool, $gdbstub(M)anual: (Defaults to N)"
2598 appsdir
='\$(ROOTDIR)/bootloader'
2600 extradefines
="-DBOOTLOADER -DE200R_INSTALLER -ffunction-sections -fdata-sections"
2602 echo "e200R-installer build selected"
2605 appsdir
='\$(ROOTDIR)/bootloader'
2607 echo "C2(4)0 or C2(5)0"
2611 extradefines
="-DBOOTLOADER -DC200_ERASE -DC240_ERASE -ffunction-sections -fdata-sections"
2612 echo "c240 eraser build selected"
2615 extradefines
="-DBOOTLOADER -DC200_ERASE -DC250_ERASE -ffunction-sections -fdata-sections"
2616 echo "c240 eraser build selected"
2620 echo "c200 eraser build selected"
2623 if test $t_manufacturer = "archos"; then
2624 # Archos SH-based players do this somewhat differently for
2626 appsdir
='\$(ROOTDIR)/flash/bootbox'
2629 appsdir
='\$(ROOTDIR)/bootloader'
2632 if test -n "$boottool"; then
2635 if test -n "$bootoutput"; then
2639 extradefines
="-DBOOTLOADER -ffunction-sections -fdata-sections"
2641 echo "Bootloader build selected"
2644 if [ "$modelname" = "sansae200r" ]; then
2645 echo "Do not use the e200R target for simulator builds. Use e200 instead."
2650 extradefines
="-DSIMULATOR"
2653 echo "Simulator build selected"
2656 echo "Advanced build selected"
2657 whichadvanced
$btype
2660 extradefines
="-DSTUB" # for target makefile symbol EXTRA_DEFINES
2661 appsdir
='\$(ROOTDIR)/gdb'
2670 echo "GDB stub build selected"
2675 echo "Manual build selected"
2683 extradefines
="-DDEBUG"
2684 appsdir
='\$(ROOTDIR)/tools/checkwps';
2685 output
='checkwps.'${modelname};
2687 echo "CheckWPS build selected"
2695 appsdir
='\$(ROOTDIR)/tools/database';
2700 output
="database_${modelname}.exe"
2703 output
='database.'${modelname};
2707 echo "Database tool build selected"
2710 if [ "$modelname" = "sansae200r" ]; then
2711 echo "Do not use the e200R target for regular builds. Use e200 instead."
2715 btype
="N" # set it explicitly since RET only gets here as well
2716 echo "Normal build selected"
2720 # to be able running "make manual" from non-manual configuration
2723 manualdev
="archosfmrecorder"
2726 manualdev
="iriverh100"
2729 manualdev
="ipodmini1g"
2732 manualdev
=$modelname
2736 if [ -z "$debug" ]; then
2737 GCCOPTS
="$GCCOPTS $GCCOPTIMIZE"
2740 echo "Using source code root directory: $rootdir"
2742 # this was once possible to change at build-time, but no more:
2747 if [ "yes" = "$simulator" ]; then
2748 # setup compiler and things for simulator
2751 if [ -d "simdisk" ]; then
2752 echo "Subdirectory 'simdisk' already present"
2755 echo "Created a 'simdisk' subdirectory for simulating the hard disk"
2759 # Now, figure out version number of the (gcc) compiler we are about to use
2760 gccver
=`$CC -dumpversion`;
2762 # figure out the binutil version too and display it, mostly for the build
2763 # system etc to be able to see it easier
2764 if [ $uname = "Darwin" ]; then
2765 ldver
=`$LD -v 2>&1 | sed -e 's/[^0-9.-]//g'`
2767 ldver
=`$LD --version | head -n 1 | sed -e 's/[^0-9.]//g'`
2770 if [ -z "$gccver" ]; then
2771 echo "[WARNING] The compiler you must use ($CC) is not in your path!"
2772 echo "[WARNING] this may cause your build to fail since we cannot do the"
2773 echo "[WARNING] checks we want now."
2776 # gccver should now be "3.3.5", "3.4.3", "2.95.3-6" and similar, but don't
2779 num1
=`echo $gccver | cut -d . -f1`
2780 num2
=`echo $gccver | cut -d . -f2`
2781 gccnum
=`(expr $num1 "*" 100 + $num2) 2>/dev/null`
2788 echo "Using $CC $gccver ($gccnum)"
2790 if test "$gccnum" -ge "400"; then
2791 # gcc 4.0 is just *so* much pickier on arguments that differ in signedness
2792 # so we ignore that warnings for now
2794 GCCOPTS
="$GCCOPTS -Wno-pointer-sign"
2797 if test "$gccnum" -ge "401"; then
2798 # this is a lame hack to avoid "warning: dereferencing type-punned pointer
2799 # will break strict-aliasing rules"
2801 GCCOPTS
="$GCCOPTS -fno-strict-aliasing"
2804 if test "$gccnum" -ge "402"; then
2805 # disable warning about "warning: initialized field overwritten" as gcc 4.2
2806 # and later would throw it for several valid cases
2807 GCCOPTS
="$GCCOPTS -Wno-override-init"
2815 # cross-compile for win32
2818 # Verify that the cross-compiler is of a recommended version!
2819 if test "$gccver" != "$gccchoice"; then
2820 echo "WARNING: Your cross-compiler $CC $gccver is not of the recommended"
2821 echo "WARNING: version $gccchoice!"
2822 echo "WARNING: This may cause your build to fail since it may be a version"
2823 echo "WARNING: that isn't functional or known to not be the best choice."
2824 echo "WARNING: If you suffer from build problems, you know that this is"
2825 echo "WARNING: a likely source for them..."
2833 echo "Using $LD $ldver"
2835 # check the compiler for SH platforms
2836 if test "$CC" = "sh-elf-gcc"; then
2837 if test "$gccnum" -lt "400"; then
2838 echo "WARNING: Consider upgrading your compiler to the 4.0.X series!"
2839 echo "WARNING: http://www.rockbox.org/twiki/bin/view/Main/CrossCompiler"
2841 # figure out patch status
2842 gccpatch
=`$CC --version`;
2844 if { echo $gccpatch |
grep "rockbox" >/dev
/null
2>&1; } then
2845 echo "gcc $gccver is rockbox patched"
2846 # then convert -O to -Os to get smaller binaries!
2847 GCCOPTS
=`echo $GCCOPTS | sed 's/ -O / -Os /'`
2849 echo "WARNING: You use an unpatched gcc compiler: $gccver"
2850 echo "WARNING: http://www.rockbox.org/twiki/bin/view/Main/CrossCompiler"
2855 if test "$CC" = "m68k-elf-gcc"; then
2856 # convert -O to -Os to get smaller binaries!
2857 GCCOPTS
=`echo $GCCOPTS | sed 's/ -O / -Os /'`
2860 if [ "$ARG_CCACHE" = "1" ]; then
2861 echo "Enable ccache for building"
2863 elif [ "$ARG_CCACHE" != "0" ]; then
2864 ccache
=`findtool ccache`
2865 if test -n "$ccache"; then
2866 echo "Found and uses ccache ($ccache)"
2870 # figure out the full path to the various commands if possible
2871 HOSTCC
=`findtool gcc --lit`
2872 HOSTAR
=`findtool ar --lit`
2873 CC
=`findtool ${CC} --lit`
2874 LD
=`findtool ${AR} --lit`
2875 AR
=`findtool ${AR} --lit`
2876 AS
=`findtool ${AS} --lit`
2877 OC
=`findtool ${OC} --lit`
2878 WINDRES
=`findtool ${WINDRES} --lit`
2879 DLLTOOL
=`findtool ${DLLTOOL} --lit`
2880 DLLWRAP
=`findtool ${DLLWRAP} --lit`
2881 RANLIB
=`findtool ${RANLIB} --lit`
2883 if test -n "$ccache"; then
2887 if test "X$endian" = "Xbig"; then
2888 defendian
="ROCKBOX_BIG_ENDIAN"
2890 defendian
="ROCKBOX_LITTLE_ENDIAN"
2893 if [ "$ARG_RBDIR" ]; then
2895 echo "Using alternate rockbox dir: ${rbdir}"
2899 -e "s,@ENDIAN@,${defendian},g" \
2900 -e "s,^#undef ROCKBOX_HAS_LOGF,$use_logf,g" \
2901 -e "s,@config_rtc@,$config_rtc,g" \
2902 -e "s,@have_rtc_alarm@,$have_rtc_alarm,g" \
2903 -e "s,@RBDIR@,${rbdir},g" \
2904 -e "s,@have_backlight@,$have_backlight,g" \
2905 -e "s,@have_fmradio_in@,$have_fmradio_in,g" \
2906 -e "s,@have_ata_poweroff@,$have_ata_poweroff,g" \
2908 /* This header was made by configure */
2909 #ifndef __BUILD_AUTOCONF_H
2910 #define __BUILD_AUTOCONF_H
2912 /* Define endianess for the target or simulator platform */
2915 /* Define this if you build rockbox to support the logf logging and display */
2916 #undef ROCKBOX_HAS_LOGF
2918 /* optional define for a backlight modded Ondio */
2921 /* optional define for FM radio mod for iAudio M5 */
2924 /* optional define for ATA poweroff on Player */
2927 /* optional defines for RTC mod for h1x0 */
2931 /* root of Rockbox */
2932 #define ROCKBOX_DIR "/@RBDIR@"
2934 #endif /* __BUILD_AUTOCONF_H */
2937 if test -n "$t_cpu"; then
2938 TARGET_INC
="-I\$(FIRMDIR)/target/$t_cpu/$t_manufacturer/$t_model"
2939 TARGET_INC
="$TARGET_INC -I\$(FIRMDIR)/target/$t_cpu/$t_manufacturer"
2940 TARGET_INC
="$TARGET_INC -I\$(FIRMDIR)/target/$t_cpu"
2944 if test "$simulator" = "yes"; then
2945 # add simul make stuff on the #SIMUL# line
2946 simmagic1
="s,@SIMUL1@,\$(SILENT)\$(MAKE) -C \$(SIMDIR) OBJDIR=\$(BUILDDIR)/sim,"
2947 simmagic2
="s,@SIMUL2@,\$(SILENT)\$(MAKE) -C \$(ROOTDIR)/uisimulator/common OBJDIR=\$(BUILDDIR)/comsim,"
2949 # delete the lines that match
2950 simmagic1
='/@SIMUL1@/D'
2951 simmagic2
='/@SIMUL2@/D'
2954 if test "$swcodec" = "yes"; then
2955 voicetoolset
="rbspeexenc voicefont wavtrim"
2957 voicetoolset
="voicefont wavtrim"
2960 if test "$apps" = "apps"; then
2961 # only when we build "real" apps we build the .lng files
2965 #### Fix the cmdline ###
2966 if test -n "$ccache"; then
2969 if [ "$ARG_ARM_EABI" = "1" ]; then
2970 cmdline
="$cmdline--eabi "
2973 cmdline
="$cmdline--target=\$(MODELNAME) --ram=\$(MEMORYSIZE) --rbdir=\$(RBDIR) --type=$btype$advopts"
2977 -e "s,@ROOTDIR@,${rootdir},g" \
2978 -e "s,@DEBUG@,${debug},g" \
2979 -e "s,@MEMORY@,${memory},g" \
2980 -e "s,@TARGET_ID@,${target_id},g" \
2981 -e "s,@TARGET@,${target},g" \
2982 -e "s,@CPU@,${t_cpu},g" \
2983 -e "s,@MANUFACTURER@,${t_manufacturer},g" \
2984 -e "s,@MODELNAME@,${modelname},g" \
2985 -e "s,@LANGUAGE@,${language},g" \
2986 -e "s:@VOICELANGUAGE@:${voicelanguage}:g" \
2987 -e "s,@PWD@,${pwd},g" \
2988 -e "s,@HOSTCC@,${HOSTCC},g" \
2989 -e "s,@HOSTAR@,${HOSTAR},g" \
2990 -e "s,@CC@,${CC},g" \
2991 -e "s,@LD@,${LD},g" \
2992 -e "s,@AR@,${AR},g" \
2993 -e "s,@AS@,${AS},g" \
2994 -e "s,@OC@,${OC},g" \
2995 -e "s,@WINDRES@,${WINDRES},g" \
2996 -e "s,@DLLTOOL@,${DLLTOOL},g" \
2997 -e "s,@DLLWRAP@,${DLLWRAP},g" \
2998 -e "s,@RANLIB@,${RANLIB},g" \
2999 -e "s,@TOOL@,${tool},g" \
3000 -e "s,@BMP2RB_NATIVE@,${bmp2rb_native},g" \
3001 -e "s,@BMP2RB_MONO@,${bmp2rb_mono},g" \
3002 -e "s,@BMP2RB_REMOTENATIVE@,${bmp2rb_remotenative},g" \
3003 -e "s,@BMP2RB_REMOTEMONO@,${bmp2rb_remotemono},g" \
3004 -e "s,@OUTPUT@,${output},g" \
3005 -e "s,@APPEXTRA@,${appextra},g" \
3006 -e "s,@ARCHOSROM@,${archosrom},g" \
3007 -e "s,@FLASHFILE@,${flash},g" \
3008 -e "s,@PLUGINS@,${plugins},g" \
3009 -e "s,@CODECS@,${swcodec},g" \
3010 -e "s,@PROFILE_OPTS@,${PROFILE_OPTS},g" \
3011 -e "s,@SHARED_FLAG@,${SHARED_FLAG},g" \
3012 -e "s,@GCCOPTS@,${GCCOPTS},g" \
3013 -e "s,@TARGET_INC@,${TARGET_INC},g" \
3014 -e "s!@LDOPTS@!${LDOPTS}!g" \
3015 -e "s,@LOADADDRESS@,${loadaddress},g" \
3016 -e "s,@EXTRADEF@,${extradefines},g" \
3017 -e "s,@APPSDIR@,${appsdir},g" \
3018 -e "s,@FIRMDIR@,${firmdir},g" \
3019 -e "s,@TOOLSDIR@,${toolsdir},g" \
3020 -e "s,@APPS@,${apps},g" \
3021 -e "s,@SIMVER@,${simver},g" \
3022 -e "s,@GCCVER@,${gccver},g" \
3023 -e "s,@GCCNUM@,${gccnum},g" \
3024 -e "s,@UNAME@,${uname},g" \
3025 -e "s,@ENDIAN@,${defendian},g" \
3026 -e "s,@TOOLSET@,${toolset},g" \
3029 -e "s,@MANUALDEV@,${manualdev},g" \
3030 -e "s,@ENCODER@,${ENC_CMD},g" \
3031 -e "s,@ENC_OPTS@,${ENC_OPTS},g" \
3032 -e "s,@TTS_ENGINE@,${TTS_ENGINE},g" \
3033 -e "s,@TTS_OPTS@,${TTS_OPTS},g" \
3034 -e "s,@VOICETOOLSET@,${voicetoolset},g" \
3035 -e "s,@LANGS@,${buildlangs},g" \
3036 -e "s,@USE_ELF@,${USE_ELF},g" \
3037 -e "s,@RBDIR@,${rbdir},g" \
3038 -e "s,@PREFIX@,$PREFIX,g" \
3039 -e "s,@CMDLINE@,$cmdline,g" \
3040 -e "s,@SDLCONFIG@,$sdl,g" \
3042 ## Automatically generated. http://www.rockbox.org/
3044 export ROOTDIR=@ROOTDIR@
3045 export FIRMDIR=@FIRMDIR@
3046 export APPSDIR=@APPSDIR@
3047 export TOOLSDIR=@TOOLSDIR@
3048 export DOCSDIR=\$(ROOTDIR)/docs
3049 export MANUALDIR=\${ROOTDIR}/manual
3050 export DEBUG=@DEBUG@
3051 export MODELNAME=@MODELNAME@
3052 export ARCHOSROM=@ARCHOSROM@
3053 export FLASHFILE=@FLASHFILE@
3054 export TARGET_ID=@TARGET_ID@
3055 export TARGET=@TARGET@
3057 export MANUFACTURER=@MANUFACTURER@
3059 export BUILDDIR=@PWD@
3060 export LANGUAGE=@LANGUAGE@
3061 export VOICELANGUAGE=@VOICELANGUAGE@
3062 export MEMORYSIZE=@MEMORY@
3063 export VERSION:=\$(shell \$(ROOTDIR)/tools/version.sh \$(ROOTDIR))
3064 export BUILDDATE:=\$(shell date -u +'-DYEAR=%Y -DMONTH=%m -DDAY=%d')
3065 export MKFIRMWARE=@TOOL@
3066 export BMP2RB_MONO=@BMP2RB_MONO@
3067 export BMP2RB_NATIVE=@BMP2RB_NATIVE@
3068 export BMP2RB_REMOTEMONO=@BMP2RB_REMOTEMONO@
3069 export BMP2RB_REMOTENATIVE=@BMP2RB_REMOTENATIVE@
3070 export BINARY=@OUTPUT@
3071 export APPEXTRA=@APPEXTRA@
3072 export ENABLEDPLUGINS=@PLUGINS@
3073 export SOFTWARECODECS=@CODECS@
3074 export EXTRA_DEFINES=@EXTRADEF@
3075 export HOSTCC=@HOSTCC@
3076 export HOSTAR=@HOSTAR@
3082 export WINDRES=@WINDRES@
3083 export DLLTOOL=@DLLTOOL@
3084 export DLLWRAP=@DLLWRAP@
3085 export RANLIB=@RANLIB@
3086 export PREFIX=@PREFIX@
3087 export PROFILE_OPTS=@PROFILE_OPTS@
3088 export SIMVER=@SIMVER@
3089 export SIMDIR=\$(ROOTDIR)/uisimulator/sdl
3090 export GCCOPTS=@GCCOPTS@
3091 export TARGET_INC=@TARGET_INC@
3092 export LOADADDRESS=@LOADADDRESS@
3093 export SHARED_FLAG=@SHARED_FLAG@
3094 export LDOPTS=@LDOPTS@
3095 export GCCVER=@GCCVER@
3096 export GCCNUM=@GCCNUM@
3097 export UNAME=@UNAME@
3098 export MANUALDEV=@MANUALDEV@
3099 export TTS_OPTS=@TTS_OPTS@
3100 export TTS_ENGINE=@TTS_ENGINE@
3101 export ENC_OPTS=@ENC_OPTS@
3102 export ENCODER=@ENCODER@
3103 export USE_ELF=@USE_ELF@
3104 export RBDIR=@RBDIR@
3105 export SDLCONFIG=@SDLCONFIG@
3107 CONFIGURE_OPTIONS=@CMDLINE@
3109 include \$(TOOLSDIR)/root.make
3113 echo "Created Makefile"