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"
14 use_logf
="#undef ROCKBOX_HAS_LOGF"
16 scriptver
=`echo '$Revision$' | sed -e 's:\\$::g' -e 's/Revision: //'`
19 # Begin Function Definitions
29 WINDRES
=${prefix}windres
30 DLLTOOL
=${prefix}dlltool
31 DLLWRAP
=${prefix}dllwrap
32 RANLIB
=${prefix}ranlib
40 # naive approach to selecting a mingw cross-compiler on linux/*nix
41 echo "Enabling win32 crosscompiling"
43 prefixtools i586-mingw32msvc-
45 LDOPTS
="-lgdi32 -luser32 -mwindows"
46 # add cross-compiler option(s)
47 GCCOPTS
="$GCCOPTS -mno-cygwin"
49 output
="rockboxui.exe" # use this as output binary name
51 endian
="little" # windows is little endian
54 # scan the $PATH for the given command
61 # echo "checks for $file in $path" >&2
62 if test -f "$path/$file"; then
72 # default tool setup for native building
76 GCCOPTS
='-W -Wall -g -fno-builtin'
78 output
="rockboxui" # use this as default output binary name
80 # generic sdl-config checker
81 sdl
=`findtool sdl-config`
83 if [ -z "$sdl" ]; then
84 echo "configure didn't find sdl-config, which indicates that you"
85 echo "don't have SDL (properly) installed. Please correct and"
86 echo "re-run configure!"
90 # default share option, override below if needed
95 echo "Cygwin host detected"
98 GCCOPTS
="$GCCOPTS `sdl-config --cflags`"
99 LDOPTS
="`sdl-config --libs` -mconsole"
101 output
="rockboxui.exe" # use this as output binary name
105 echo "Linux host detected"
107 if [ "0" != `sdl-config --libs |grep -c mwindows` ]; then
108 # Enable crosscompiling if sdl-config is from Windows SDL
111 GCCOPTS
="$GCCOPTS `sdl-config --cflags`"
112 LDOPTS
="`sdl-config --libs`"
116 echo "FreeBSD host detected"
118 GCCOPTS
="$GCCOPTS `sdl-config --cflags`"
119 LDOPTS
="`sdl-config --libs`"
123 echo "Darwin host detected"
125 GCCOPTS
="$GCCOPTS `sdl-config --cflags`"
126 LDOPTS
="`sdl-config --libs`"
127 SHARED_FLAG
="-dynamiclib -Wl\,-single_module"
131 echo "Unsupported system: $uname, fix configure and retry"
136 if [ "`uname -m`" = "x86_64" ]; then
137 GCCOPTS
="$GCCOPTS -fPIC" # needed to make shared objects link
140 GCCOPTS
="$GCCOPTS -I\$(SIMDIR)"
142 if test "X$crosscompile" != "Xyes"; then
144 cat >/tmp
/conftest-
$id.c
<<EOF
146 int main(int argc, char **argv)
149 char *varp = (char *)&var;
157 $CC -o /tmp
/conftest-
$id /tmp
/conftest-
$id.c
2>/dev
/null
159 if test `/tmp/conftest-$id 2>/dev/null` -gt "1"; then
166 echo "Simulator environment deemed $endian endian"
168 # use wildcard here to make it work even if it was named *.exe like
170 rm -f /tmp
/conftest-
$id*
176 GCCOPTS
="$CCOPTS -m1"
177 GCCOPTIMIZE
="-fomit-frame-pointer -fschedule-insns"
182 prefixtools calmrisc16-unknown-elf-
183 GCCOPTS
="-Wl\,--no-check-sections $CCOPTS"
184 GCCOPTIMIZE
="-fomit-frame-pointer"
189 prefixtools m68k-elf-
190 GCCOPTS
="$CCOPTS -m5206e -Wa\,-m5249 -malign-int -mstrict-align"
191 GCCOPTIMIZE
="-fomit-frame-pointer"
197 GCCOPTS
="$CCOPTS -mcpu=arm7tdmi"
198 if test "X$1" != "Xshort"; then
199 GCCOPTS
="$GCCOPTS -mlong-calls"
201 GCCOPTIMIZE
="-fomit-frame-pointer"
207 GCCOPTS
="$CCOPTS -mcpu=arm9tdmi -mlong-calls"
208 GCCOPTIMIZE
="-fomit-frame-pointer"
213 ##################################################################
214 # Prompt for specific developer options
217 echo "Enter your developer options (press enter when done)"
218 echo -n "(D)EBUG, (L)ogf, (S)imulator, (P)rofiling, (V)oice"
219 if [ "$memory" = "2" ]; then
220 echo -n ", (8)MB MOD"
222 if [ "$archos" = "h120" ]; then
223 echo -n ", (R)TC MOD"
229 while [ $cont = "1" ]; do
235 if [ "yes" = "$profile" ]; then
236 echo "Debug is incompatible with profiling"
243 echo "logf() support enabled"
247 echo "Simulator build enabled"
251 if [ "yes" = "$use_debug" ]; then
252 echo "Profiling is incompatible with debug"
254 echo "Profiling support is enabled"
259 echo "Voice build selected"
263 if [ "$memory" = "2" ]; then
265 echo "Memory size selected: 8MB"
271 if [ "$archos" = "h120" ]; then
272 config_rtc
="#define CONFIG_RTC RTC_DS1339_DS3231"
273 have_rtc_alarm
="#define HAVE_RTC_ALARM"
274 echo "RTC functions enabled (DS1339/DS3231)"
286 if [ "yes" = "$voice" ]; then
287 toolset
="${toolset} voicefont wavtrim"
289 # Ask about languages to build
290 echo "Select a number for the language to use (default is english)"
291 # The multiple-language feature is currently broken
292 # echo "You may enter a comma-separated list of languages to build"
295 voicelanguage
=`whichlang`
297 if [ -z "$voicelanguage" ]; then
299 voicelanguage
="english"
301 echo "Voice language set to $voicelanguage"
303 # Configure encoder and TTS engine for each language
304 for thislang
in `echo $voicelanguage | sed 's/,/ /g'`; do
305 voiceconfig
"$thislang"
308 if [ "yes" = "$use_debug" ]; then
310 GCCOPTS
="$GCCOPTS -g -DDEBUG"
312 if [ "yes" = "$logf" ]; then
313 use_logf
="#define ROCKBOX_HAS_LOGF 1"
315 if [ "yes" = "$simulator" ]; then
317 extradefines
="$extradefines -DSIMULATOR"
319 if [ "yes" = "$profile" ]; then
320 extradefines
="$extradefines -DRB_PROFILE"
321 PROFILE_OPTS
="-finstrument-functions"
325 # Configure voice settings
328 echo "Building $thislang voice for $archos. Select options"
331 if [ -f "`which flite`" ]; then
335 DEFAULT_TTS_OPTS
=$FLITE_OPTS
336 DEFAULT_NOISEFLOOR
="500"
339 if [ -f "`which espeak`" ]; then
343 DEFAULT_TTS_OPTS
=$ESPEAK_OPTS
344 DEFAULT_NOISEFLOOR
="500"
347 if [ -f "`which festival`" ]; then
348 FESTIVAL
="(F)estival "
351 FESTIVAL_OPTS
="--language italian"
354 FESTIVAL_OPTS
="--language spanish"
357 FESTIVAL_OPTS
="--language finnish"
360 FESTIVAL_OPTS
="--language czech"
366 DEFAULT_TTS
="festival"
367 DEFAULT_TTS_OPTS
=$FESTIVAL_OPTS
368 DEFAULT_NOISEFLOOR
="500"
371 if [ -f "`which swift`" ]; then
375 DEFAULT_TTS_OPTS
=$SWIFT_OPTS
376 DEFAULT_NOISEFLOOR
="500"
379 # Allow SAPI if Windows is in use
380 if [ -f "`which winver`" ]; then
384 DEFAULT_TTS_OPTS
=$SAPI_OPTS
385 DEFAULT_NOISEFLOOR
="500"
389 if [ "$FESTIVAL" = "$FLITE" ] && [ "$FLITE" = "$ESPEAK" ] && [ "$ESPEAK" = "$SAPI" ] && [ "$SAPI" = "$SWIFT" ]; then
390 echo "You need Festival, eSpeak or Flite in your path, or SAPI available to build voice files"
394 echo "TTS engine to use: ${FLITE}${FESTIVAL}${ESPEAK}${SAPI}${SWIFT}(${DEFAULT_CHOICE})?"
399 NOISEFLOOR
="500" # TODO: check this value
405 TTS_OPTS
=$ESPEAK_OPTS
408 TTS_ENGINE
="festival"
410 TTS_OPTS
=$FESTIVAL_OPTS
423 TTS_ENGINE
=$DEFAULT_TTS
424 TTS_OPTS
=$DEFAULT_TTS_OPTS
425 NOISEFLOOR
=$DEFAULT_NOISEFLOOR
427 echo "Using $TTS_ENGINE for TTS"
429 # Allow the user to input manual commandline options
430 printf "Enter $TTS_ENGINE options (enter for defaults \"$TTS_OPTS\"): "
431 USER_TTS_OPTS
=`input`
432 if [ -n "$USER_TTS_OPTS" ]; then
433 TTS_OPTS
="$USER_TTS_OPTS"
438 if [ -f "`which oggenc`" ]; then
441 VORBIS_OPTS
="-q0 --downmix"
442 DEFAULT_ENC_OPTS
=$VORBIS_OPTS
445 if [ -f "`which speexenc`" ]; then
446 SPEEXENC
="(S)peexenc "
447 DEFAULT_ENC
="speexenc"
448 SPEEX_OPTS
="" # TODO: find appropriate options for speex
449 DEFAULT_ENC_OPTS
=$SPEEX_OPTS
452 if [ -f "`which lame`" ]; then
455 LAME_OPTS
="--resample 12 -t -m m -h -V 9 -S -B 64 --vbr-new"
456 DEFAULT_ENC_OPTS
=$LAME_OPTS
460 if [ "$LAME" = "" ]; then
461 echo "You currently need to have Lame installed to build voice files"
464 # echo "Encoder to use: ${LAME}${OGGENC}${SPEEXENC}(${DEFAULT_CHOICE})?"
466 # echo "Note: Use Lame - the other options won't work"
472 ENC_OPTS
=$VORBIS_OPTS
484 ENC_OPTS
=$DEFAULT_ENC_OPTS
486 echo "Using $ENCODER for encoding voice clips"
488 # Allow the user to input manual commandline options
489 printf "Enter $ENCODER options (enter for defaults \"$ENC_OPTS\"): "
490 USER_ENC_OPTS
=`input`
491 if [ -n "$USER_ENC_OPTS" ]; then
492 ENC_OPTS
=$USER_ENC_OPTS
496 if [ -f "`which cygpath`" ]; then
497 TEMPDIR
=`cygpath . -a -w`
502 # figure out which languages that are around
503 for file in $rootdir/apps
/lang
/*.lang
; do
504 clean
=`echo $file | sed -e 's:.*/::g' | cut "-d." -f1`
505 langs
="$langs $clean"
509 for one
in $langs; do
519 # Allow the user to pass a comma-separated list of langauges
520 for thispick
in `echo $pick | sed 's/,/ /g'`; do
522 for one
in $langs; do
523 # Accept both the language number and name
524 if [ "$num" = "$thispick" ] ||
[ "$thispick" = "$one" ]; then
525 if [ "$output" = "" ]; then
539 if test "$opt" = "--help"; then
540 echo "Rockbox configure script."
541 echo "Invoke this in a directory to generate a Makefile to build Rockbox"
542 echo "Do *NOT* run this within the tools directory!"
544 echo "Usage: configure [--ccache][--no-ccache]"
548 if test -r "configure"; then
549 # this is a check for a configure script in the current directory, it there
550 # is one, try to figure out if it is this one!
552 if { grep "^# Jukebox" configure
>/dev
/null
2>&1 ; } then
553 echo "WEEEEEEEEP. Don't run this configure script within the tools directory."
554 echo "It will only cause you pain and grief. Instead do this:"
557 echo " mkdir build-dir"
559 echo " ../tools/configure"
561 echo "Much happiness will arise from this. Enjoy"
566 # get our current directory
569 if { echo $pwd |
grep " "; } then
570 echo "You're running this script in a path that contains space. The build"
571 echo "system is unfortunately not clever enough to deal with this. Please"
572 echo "run the script from a different path, rename the path or fix the build"
577 if [ -z "$rootdir" ]; then
578 ##################################################################
579 # Figure out where the source code root is!
581 rootdir
=`dirname $0`/..
/
583 #####################################################################
584 # Convert the possibly relative directory name to an absolute version
590 # cd back to the build dir
595 appsdir
='\$(ROOTDIR)/apps'
596 firmdir
='\$(ROOTDIR)/firmware'
597 toolsdir
='\$(ROOTDIR)/tools'
600 ##################################################################
601 # Figure out target platform
604 echo "Enter target platform:"
606 ==Archos== ==iriver== ==Apple iPod==
607 0) Player/Studio 10) H120/H140 20) Color/Photo
608 1) Recorder 11) H320/H340 21) Nano
609 2) FM Recorder 12) iHP-100/110/115 22) Video
610 3) Recorder v2 13) iFP-790 23) 3G
611 4) Ondio SP 14) H10 20Gb 24) 4G Grayscale
612 5) Ondio FM 15) H10 5/6Gb 25) Mini 1G
616 ==iAudio== ==Toshiba== ==SanDisk==
617 30) X5/X5V/X5L 40) Gigabeat F 50) Sansa e200
618 31) M5/M5L 51) Sansa e200R
621 ==Tatung== ==Olympus==
622 60) Elio TPJ-1022 70) M:Robe 500
627 # Set of tools built for all target platforms:
628 toolset
="rdf2binary convbdf codepages"
630 # Toolsets for some target families:
631 archosbitmaptools
="$toolset scramble descramble sh2d uclpack bmp2rb"
632 iriverbitmaptools
="$toolset scramble descramble mkboot bmp2rb"
633 iaudiobitmaptools
="$toolset scramble descramble mkboot bmp2rb"
634 ipodbitmaptools
="$toolset scramble ipod_fw bmp2rb"
635 gigabeatbitmaptools
="$toolset scramble descramble bmp2rb"
636 # generic is used by IFP, H10, Sansa-e200
637 genericbitmaptools
="$toolset bmp2rb"
640 # ---- For each target ----
643 # target_id: a unique number identifying this target, DOES NOT necessarily
644 # have to be the menu number. Just use the currently highest
645 # number+1 when you add a new target.
646 # archos: short model name used all over to identify this target
647 # memory: number of megabytes of RAM this target has. If the amount can
648 # be selected by the size prompt, let memory be unset here
649 # target: -Ddefine passed to the build commands to make the correct
650 # config-*.h file get included etc
651 # tool: the tool that takes a plain binary and converts that into a
652 # working "firmware" file for your target
653 # output: the final output file name
654 # boottool: the tool that takes a plain binary and generates a bootloader
655 # file for your target (or blank to use $tool)
656 # bootoutput:the final output file name for the bootloader (or blank to use
658 # appextra: passed to the APPEXTRA variable in the Makefiles.
659 # TODO: add proper explanation
660 # archosrom: used only for Archos targets that build a special flashable .ucl
661 # image. Set to blank for other builds.
662 # flash: the same as archosrom. These two should be merged
663 # plugins: set to 'yes' to build the plugins. Early development builds can
664 # set this to no in the early stages to have an easier life for a
666 # swcodec: set 'yes' on swcodec targets
667 # toolset: lists what particular tools in the tools/ directory that this
668 # target needs to have built prior to building Rockbox
671 # *cc: sets up gcc and compiler options for your target builds. Note
672 # that if you select a simulator build, the compiler selection is
673 # overridden later in the script.
680 target
="-DARCHOS_PLAYER"
682 tool
="$rootdir/tools/scramble"
684 appextra
="player:gui"
685 archosrom
="$pwd/rombox.ucl"
686 flash
="$pwd/rockbox.ucl"
690 # toolset is the tools within the tools directory that we build for
691 # this particular target.
692 toolset
="$toolset scramble descramble sh2d player_unifont uclpack"
694 # Note: the convbdf is present in the toolset just because: 1) the
695 # firmware/Makefile assumes it is present always, and 2) we will need it when we
696 # build the player simulator
699 t_manufacturer
="archos"
706 target
="-DARCHOS_RECORDER"
708 tool
="$rootdir/tools/scramble"
709 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
710 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
712 appextra
="recorder:gui"
713 archosrom
="" #"$pwd/rombox.ucl"
714 flash
="$pwd/rockbox.ucl"
717 # toolset is the tools within the tools directory that we build for
718 # this particular target.
719 toolset
=$archosbitmaptools
721 t_manufacturer
="archos"
728 target
="-DARCHOS_FMRECORDER"
730 tool
="$rootdir/tools/scramble -fm"
731 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
732 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
734 appextra
="recorder:gui"
735 archosrom
="" #"$pwd/rombox.ucl"
736 flash
="$pwd/rockbox.ucl"
739 # toolset is the tools within the tools directory that we build for
740 # this particular target.
741 toolset
=$archosbitmaptools
743 t_manufacturer
="archos"
750 target
="-DARCHOS_RECORDERV2"
752 tool
="$rootdir/tools/scramble -v2"
753 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
754 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
756 appextra
="recorder:gui"
757 archosrom
="" #"$pwd/rombox.ucl"
758 flash
="$pwd/rockbox.ucl"
761 # toolset is the tools within the tools directory that we build for
762 # this particular target.
763 toolset
=$archosbitmaptools
765 t_manufacturer
="archos"
772 target
="-DARCHOS_ONDIOSP"
774 tool
="$rootdir/tools/scramble -osp"
775 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
776 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
778 appextra
="recorder:gui"
779 archosrom
="$pwd/rombox.ucl"
780 flash
="$pwd/rockbox.ucl"
783 # toolset is the tools within the tools directory that we build for
784 # this particular target.
785 toolset
=$archosbitmaptools
787 t_manufacturer
="archos"
794 target
="-DARCHOS_ONDIOFM"
796 tool
="$rootdir/tools/scramble -ofm"
797 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
798 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
800 appextra
="recorder:gui"
801 archosrom
="" #"$pwd/rombox.ucl"
802 flash
="$pwd/rockbox.ucl"
805 toolset
=$archosbitmaptools
807 t_manufacturer
="archos"
814 target
="-DARCHOS_AV300"
817 tool
="$rootdir/tools/scramble -mm=C"
818 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
819 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
821 appextra
="recorder:gui"
826 # toolset is the tools within the tools directory that we build for
827 # this particular target.
828 toolset
="$toolset scramble descramble bmp2rb"
829 # architecture, manufacturer and model for the target-tree build
831 t_manufacturer
="archos"
838 target
="-DIRIVER_H120"
841 tool
="$rootdir/tools/scramble -add=h120"
842 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
843 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
844 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
845 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
846 output
="rockbox.iriver"
847 appextra
="recorder:gui"
849 flash
="$pwd/rombox.iriver"
852 # toolset is the tools within the tools directory that we build for
853 # this particular target.
854 toolset
=$iriverbitmaptools
856 t_manufacturer
="iriver"
863 target
="-DIRIVER_H300"
866 tool
="$rootdir/tools/scramble -add=h300"
867 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
868 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
869 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
870 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
871 output
="rockbox.iriver"
872 appextra
="recorder:gui"
877 # toolset is the tools within the tools directory that we build for
878 # this particular target.
879 toolset
=$iriverbitmaptools
881 t_manufacturer
="iriver"
888 target
="-DIRIVER_H100"
891 tool
="$rootdir/tools/scramble -add=h100"
892 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
893 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
894 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
895 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 0"
896 output
="rockbox.iriver"
897 appextra
="recorder:gui"
902 # toolset is the tools within the tools directory that we build for
903 # this particular target.
904 toolset
=$iriverbitmaptools
906 t_manufacturer
="iriver"
913 target
="-DIRIVER_IFP7XX"
917 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
918 bmp2rb_native
="$rootdir/tools/bmp2rb -f 0"
920 appextra
="recorder:gui"
925 # toolset is the tools within the tools directory that we build for
926 # this particular target.
927 toolset
=$genericbitmaptools
929 t_manufacturer
="pnx0101"
930 t_model
="iriver-ifp7xx"
936 target
="-DIRIVER_H10"
939 tool
="$rootdir/tools/scramble -mi4v3 -model=h10 -type=RBOS"
940 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
941 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
943 appextra
="recorder:gui"
948 boottool
="$rootdir/tools/scramble -mi4v3 -model=h10 -type=RBBL"
949 bootoutput
="H10_20GC.mi4"
950 # toolset is the tools within the tools directory that we build for
951 # this particular target.
952 toolset
="$genericbitmaptools scramble"
953 # architecture, manufacturer and model for the target-tree build
955 t_manufacturer
="iriver"
962 target
="-DIRIVER_H10_5GB"
965 tool
="$rootdir/tools/scramble -mi4v2 -model=h105 -type=RBOS"
966 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
967 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
969 appextra
="recorder:gui"
974 boottool
="$rootdir/tools/scramble -mi4v2 -model=h105 -type=RBBL"
976 # toolset is the tools within the tools directory that we build for
977 # this particular target.
978 toolset
="$genericbitmaptools scramble"
979 # architecture, manufacturer and model for the target-tree build
981 t_manufacturer
="iriver"
988 target
="-DIPOD_COLOR"
991 tool
="$rootdir/tools/scramble -add=ipco"
992 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
993 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
994 output
="rockbox.ipod"
995 appextra
="recorder:gui"
1000 bootoutput
="bootloader-$archos.ipod"
1001 # toolset is the tools within the tools directory that we build for
1002 # this particular target.
1003 toolset
=$ipodbitmaptools
1004 # architecture, manufacturer and model for the target-tree build
1006 t_manufacturer
="ipod"
1013 target
="-DIPOD_NANO"
1016 tool
="$rootdir/tools/scramble -add=nano"
1017 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1018 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1019 output
="rockbox.ipod"
1020 appextra
="recorder:gui"
1025 bootoutput
="bootloader-$archos.ipod"
1026 # toolset is the tools within the tools directory that we build for
1027 # this particular target.
1028 toolset
=$ipodbitmaptools
1029 # architecture, manufacturer and model for the target-tree build
1031 t_manufacturer
="ipod"
1038 target
="-DIPOD_VIDEO"
1040 tool
="$rootdir/tools/scramble -add=ipvd"
1041 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1042 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1043 output
="rockbox.ipod"
1044 appextra
="recorder:gui"
1049 bootoutput
="bootloader-$archos.ipod"
1050 # toolset is the tools within the tools directory that we build for
1051 # this particular target.
1052 toolset
=$ipodbitmaptools
1053 # architecture, manufacturer and model for the target-tree build
1055 t_manufacturer
="ipod"
1065 tool
="$rootdir/tools/scramble -add=ip3g"
1066 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1067 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1068 output
="rockbox.ipod"
1069 appextra
="recorder:gui"
1074 bootoutput
="bootloader-$archos.ipod"
1075 # toolset is the tools within the tools directory that we build for
1076 # this particular target.
1077 toolset
=$ipodbitmaptools
1078 # architecture, manufacturer and model for the target-tree build
1080 t_manufacturer
="ipod"
1090 tool
="$rootdir/tools/scramble -add=ip4g"
1091 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1092 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1093 output
="rockbox.ipod"
1094 appextra
="recorder:gui"
1099 bootoutput
="bootloader-$archos.ipod"
1100 # toolset is the tools within the tools directory that we build for
1101 # this particular target.
1102 toolset
=$ipodbitmaptools
1103 # architecture, manufacturer and model for the target-tree build
1105 t_manufacturer
="ipod"
1112 target
="-DIPOD_MINI"
1115 tool
="$rootdir/tools/scramble -add=mini"
1116 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1117 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1118 output
="rockbox.ipod"
1119 appextra
="recorder:gui"
1124 bootoutput
="bootloader-$archos.ipod"
1125 # toolset is the tools within the tools directory that we build for
1126 # this particular target.
1127 toolset
=$ipodbitmaptools
1128 # architecture, manufacturer and model for the target-tree build
1130 t_manufacturer
="ipod"
1137 target
="-DIPOD_MINI2G"
1140 tool
="$rootdir/tools/scramble -add=mn2g"
1141 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1142 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1143 output
="rockbox.ipod"
1144 appextra
="recorder:gui"
1149 bootoutput
="bootloader-$archos.ipod"
1150 # toolset is the tools within the tools directory that we build for
1151 # this particular target.
1152 toolset
=$ipodbitmaptools
1153 # architecture, manufacturer and model for the target-tree build
1155 t_manufacturer
="ipod"
1162 target
="-DIPOD_1G2G"
1165 tool
="$rootdir/tools/scramble -add=1g2g"
1166 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1167 bmp2rb_native
="$rootdir/tools/bmp2rb -f 6"
1168 output
="rockbox.ipod"
1169 appextra
="recorder:gui"
1174 bootoutput
="bootloader-$archos.ipod"
1175 # toolset is the tools within the tools directory that we build for
1176 # this particular target.
1177 toolset
=$ipodbitmaptools
1178 # architecture, manufacturer and model for the target-tree build
1180 t_manufacturer
="ipod"
1187 target
="-DIAUDIO_X5"
1190 tool
="$rootdir/tools/scramble -add=iax5"
1191 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1192 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1193 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1194 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 7"
1195 output
="rockbox.iaudio"
1196 appextra
="recorder:gui"
1201 # toolset is the tools within the tools directory that we build for
1202 # this particular target.
1203 toolset
="$iaudiobitmaptools"
1204 # architecture, manufacturer and model for the target-tree build
1206 t_manufacturer
="iaudio"
1213 target
="-DIAUDIO_M5"
1216 tool
="$rootdir/tools/scramble -add=iam5"
1217 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1218 bmp2rb_native
="$rootdir/tools/bmp2rb -f 2"
1219 bmp2rb_remotemono
="$rootdir/tools/bmp2rb -f 0"
1220 bmp2rb_remotenative
="$rootdir/tools/bmp2rb -f 7"
1221 output
="rockbox.iaudio"
1222 appextra
="recorder:gui"
1227 # toolset is the tools within the tools directory that we build for
1228 # this particular target.
1229 toolset
="$iaudiobitmaptools"
1230 # architecture, manufacturer and model for the target-tree build
1232 t_manufacturer
="iaudio"
1239 target
="-DGIGABEAT_F"
1242 tool
="$rootdir/tools/scramble -add=giga"
1243 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1244 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1245 output
="rockbox.gigabeat"
1246 appextra
="recorder:gui"
1251 toolset
=$gigabeatbitmaptools
1252 boottool
="$rootdir/tools/scramble -gigabeat"
1253 bootoutput
="FWIMG01.DAT"
1254 # architecture, manufacturer and model for the target-tree build
1256 t_manufacturer
="s3c2440"
1257 t_model
="gigabeat-fx"
1263 target
="-DMROBE_500"
1266 tool
="$rootdir/tools/scramble -add=giga"
1267 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1268 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1269 output
="rockbox.mrobe500"
1270 appextra
="recorder:gui"
1275 toolset
=$gigabeatbitmaptools
1277 bootoutput
="rockbox.mrboot"
1278 # architecture, manufacturer and model for the target-tree build
1280 t_manufacturer
="olympus"
1287 target
="-DSANSA_E200"
1288 memory
=32 # supposedly
1290 tool
="$rootdir/tools/scramble -mi4v3 -model=e200 -type=RBOS"
1291 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1292 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1293 output
="rockbox.mi4"
1294 appextra
="recorder:gui"
1299 boottool
="$rootdir/tools/scramble -mi4v3 -model=e200 -type=RBBL"
1300 bootoutput
="PP5022.mi4"
1301 # toolset is the tools within the tools directory that we build for
1302 # this particular target.
1303 toolset
="$genericbitmaptools scramble"
1304 # architecture, manufacturer and model for the target-tree build
1306 t_manufacturer
="sandisk"
1307 t_model
="sansa-e200"
1311 # the e200R model is pretty much identical to the e200, it only has a
1312 # different option to the scramble tool when building a bootloader and
1313 # makes the bootloader output file name in all lower case.
1316 target
="-DSANSA_E200"
1317 memory
=32 # supposedly
1319 tool
="$rootdir/tools/scramble -mi4v3 -model=e20r -type=RBOS"
1320 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1321 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1322 output
="rockbox.mi4"
1323 appextra
="recorder:gui"
1328 boottool
="$rootdir/tools/scramble -mi4r -model=e20r -type=RBBL"
1329 bootoutput
="pp5022.mi4"
1330 # toolset is the tools within the tools directory that we build for
1331 # this particular target.
1332 toolset
="$genericbitmaptools scramble"
1333 # architecture, manufacturer and model for the target-tree build
1335 t_manufacturer
="sandisk"
1336 t_model
="sansa-e200"
1342 target
="-DSANSA_C200"
1343 memory
=32 # supposedly
1345 tool
="$rootdir/tools/scramble -mi4v3 -model=c200 -type=RBOS"
1346 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1347 bmp2rb_native
="$rootdir/tools/bmp2rb -f 4"
1348 output
="rockbox.mi4"
1349 appextra
="recorder:gui"
1354 boottool
="$rootdir/tools/scramble -mi4v3 -model=c200 -type=RBBL"
1355 bootoutput
="firmware.mi4"
1356 # toolset is the tools within the tools directory that we build for
1357 # this particular target.
1358 toolset
="$genericbitmaptools scramble"
1359 # architecture, manufacturer and model for the target-tree build
1361 t_manufacturer
="sandisk"
1362 t_model
="sansa-c200"
1368 target
="-DELIO_TPJ1022"
1371 tool
="$rootdir/tools/scramble -add tpj2"
1372 bmp2rb_mono
="$rootdir/tools/bmp2rb -f 0"
1373 bmp2rb_native
="$rootdir/tools/bmp2rb -f 5"
1374 output
="rockbox.elio"
1375 appextra
="recorder:gui"
1380 boottool
="$rootdir/tools/scramble -mi4v2"
1381 bootoutput
="pp5020.mi4"
1382 # toolset is the tools within the tools directory that we build for
1383 # this particular target.
1384 toolset
="$genericbitmaptools scramble"
1385 # architecture, manufacturer and model for the target-tree build
1387 t_manufacturer
="tatung"
1392 echo "Please select a supported target platform!"
1398 echo "Platform set to $archos"
1402 ############################################################################
1403 # Amount of memory, for those that can differ. They have $memory unset at
1407 if [ -z "$memory" ]; then
1411 echo "Enter size of your RAM (in MB): (Defaults to 32)"
1424 echo "Enter size of your RAM (in MB): (defaults to 2)"
1437 echo "Memory size selected: $memory MB"
1441 ##################################################################
1442 # Figure out build "type"
1445 # the ifp7x0 is the only platform that supports building a gdb stub like
1449 gdbstub
="(G)DB stub, "
1452 gdbstub
="(I)installer, "
1459 echo "Build (N)ormal, (A)dvanced, (S)imulator, (B)ootloader, $gdbstub(M)anual (N)"
1465 appsdir
='\$(ROOTDIR)/bootloader'
1467 extradefines
="-DBOOTLOADER -DE200R_INSTALLER -ffunction-sections -fdata-sections"
1469 output
="bootloader.bin"
1470 echo "e200R-installer build selected"
1473 if test $t_manufacturer = "archos"; then
1474 # Archos SH-based players do this somewhat differently for
1476 appsdir
='\$(ROOTDIR)/flash/bootbox'
1479 appsdir
='\$(ROOTDIR)/bootloader'
1482 if test -n "$boottool"; then
1485 if test -n "$bootoutput"; then
1489 extradefines
="-DBOOTLOADER -ffunction-sections -fdata-sections"
1491 echo "Bootloader build selected"
1496 extradefines
="-DSIMULATOR"
1497 echo "Simulator build selected"
1500 echo "Advanced build selected"
1504 extradefines
="-DSTUB" # for target makefile symbol EXTRA_DEFINES
1505 appsdir
='\$(ROOTDIR)/gdb'
1514 echo "GDB stub build selected"
1517 appsdir
='\$(ROOTDIR)/manual'
1518 firmdir
='\$(ROOTDIR)/manual/platform' # No Makefile here. Effectively ig:res target
1522 echo "Manual build selected"
1526 echo "Normal build selected"
1530 # to be able running "make manual" from non-manual configuration
1533 manualdev
="recorderv2fm"
1536 manualdev
="recorderv2fm"
1542 manualdev
="ipodmini"
1549 if [ -z "$debug" ]; then
1550 GCCOPTS
="$GCCOPTS $GCCOPTIMIZE"
1553 echo "Using source code root directory: $rootdir"
1555 # this was once possible to change at build-time, but no more:
1560 if [ "yes" = "$simulator" ]; then
1561 # setup compiler and things for simulator
1564 if [ -d "archos" ]; then
1565 echo "sub directory archos already present"
1568 echo "created an archos subdirectory for simulating the hard disk"
1572 # Now, figure out version number of the (gcc) compiler we are about to use
1573 gccver
=`$CC -dumpversion`;
1575 # figure out the binutil version too and display it, mostly for the build
1576 # system etc to be able to see it easier
1577 ldver
=`$LD --version | head -n 1 | sed -e 's/[^0-9.]//g'`
1579 if [ -z "$gccver" ]; then
1580 echo "WARNING: The compiler you must use ($CC) is not in your path!"
1581 echo "WARNING: this may cause your build to fail since we cannot do the"
1582 echo "WARNING: checks we want now."
1585 # gccver should now be "3.3.5", "3.4.3", "2.95.3-6" and similar, but don't
1588 num1
=`echo $gccver | cut -d . -f1`
1589 num2
=`echo $gccver | cut -d . -f2`
1590 gccnum
=`(expr $num1 "*" 100 + $num2) 2>/dev/null`
1597 echo "Using $CC $gccver ($gccnum)"
1599 if test "$gccnum" -ge "400"; then
1600 # gcc 4.0 is just *so* much pickier on arguments that differ in signedness
1601 # so we ignore that warnings for now
1603 GCCOPTS
="$GCCOPTS -Wno-pointer-sign"
1606 if test "$gccnum" -ge "401"; then
1607 # this is a lame hack to avoid "warning: dereferencing type-punned pointer
1608 # will break strict-aliasing rules"
1610 GCCOPTS
="$GCCOPTS -fno-strict-aliasing"
1613 if test "$gccnum" -ge "402"; then
1614 # disable warning about "warning: initialized field overwritten" as gcc 4.2
1615 # and later would throw it for several valid cases
1616 GCCOPTS
="$GCCOPTS -Wno-override-init"
1621 echo "Using $LD $ldver"
1623 # check the compiler for SH platforms
1624 if test "$CC" = "sh-elf-gcc"; then
1625 if test "$gccnum" -lt "400"; then
1626 echo "WARNING: Consider upgrading your compiler to the 4.0.X series!"
1627 echo "WARNING: http://www.rockbox.org/twiki/bin/view/Main/CrossCompiler"
1629 # figure out patch status
1630 gccpatch
=`$CC --version`;
1632 if { echo $gccpatch |
grep "rockbox" >/dev
/null
2>&1; } then
1633 echo "gcc $gccver is rockbox patched"
1634 # then convert -O to -Os to get smaller binaries!
1635 GCCOPTS
=`echo $GCCOPTS | sed 's/ -O / -Os /'`
1637 echo "WARNING: You use an unpatched gcc compiler: $gccver"
1638 echo "WARNING: http://www.rockbox.org/twiki/bin/view/Main/CrossCompiler"
1643 if test "$CC" = "m68k-elf-gcc"; then
1644 # convert -O to -Os to get smaller binaries!
1645 GCCOPTS
=`echo $GCCOPTS | sed 's/ -O / -Os /'`
1648 if test "$1" = "--ccache"; then
1649 echo "Enable ccache for building"
1652 if test "$1" != "--no-ccache"; then
1653 ccache
=`findtool ccache`
1654 if test -n "$ccache"; then
1655 echo "Found and uses ccache ($ccache)"
1660 if test -n "$ccache"; then
1664 if test "X$endian" = "Xbig"; then
1665 defendian
="ROCKBOX_BIG_ENDIAN"
1667 defendian
="ROCKBOX_LITTLE_ENDIAN"
1671 -e "s,@ENDIAN@,${defendian},g" \
1672 -e "s,^#undef ROCKBOX_HAS_LOGF,$use_logf,g" \
1673 -e "s,@config_rtc@,$config_rtc,g" \
1674 -e "s,@have_rtc_alarm@,$have_rtc_alarm,g" \
1676 /* This header was made by configure */
1677 #ifndef __BUILD_AUTOCONF_H
1678 #define __BUILD_AUTOCONF_H
1680 /* Define endianess for the target or simulator platform */
1683 /* Define this if you build rockbox to support the logf logging and display */
1684 #undef ROCKBOX_HAS_LOGF
1686 /* optional defines for RTC mod for h1x0 */
1690 #endif /* __BUILD_AUTOCONF_H */
1693 if test -n "$t_cpu"; then
1694 TARGET_INC
="-I\$(FIRMDIR)/target/$t_cpu/$t_manufacturer/$t_model"
1695 TARGET_INC
="$TARGET_INC -I\$(FIRMDIR)/target/$t_cpu/$t_manufacturer"
1696 TARGET_INC
="$TARGET_INC -I\$(FIRMDIR)/target/$t_cpu"
1700 if test "$simulator" = "yes"; then
1701 # add simul make stuff on the #SIMUL# line
1702 simmagic1
="s,@SIMUL1@,\$(SILENT)\$(MAKE) -C \$(SIMDIR) OBJDIR=\$(BUILDDIR)/sim,"
1703 simmagic2
="s,@SIMUL2@,\$(SILENT)\$(MAKE) -C \$(ROOTDIR)/uisimulator/common OBJDIR=\$(BUILDDIR)/comsim,"
1705 # delete the lines that match
1706 simmagic1
='/@SIMUL1@/D'
1707 simmagic2
='/@SIMUL2@/D'
1711 -e "s,@ROOTDIR@,${rootdir},g" \
1712 -e "s,@DEBUG@,${debug},g" \
1713 -e "s,@MEMORY@,${memory},g" \
1714 -e "s,@TARGET_ID@,${target_id},g" \
1715 -e "s,@TARGET@,${target},g" \
1716 -e "s,@CPU@,${t_cpu},g" \
1717 -e "s,@MANUFACTURER@,${t_manufacturer},g" \
1718 -e "s,@ARCHOS@,${archos},g" \
1719 -e "s,@LANGUAGE@,${language},g" \
1720 -e "s:@VOICELANGUAGE@:${voicelanguage}:g" \
1721 -e "s,@PWD@,${pwd},g" \
1722 -e "s,@CC@,${CC},g" \
1723 -e "s,@LD@,${LD},g" \
1724 -e "s,@AR@,${AR},g" \
1725 -e "s,@AS@,${AS},g" \
1726 -e "s,@OC@,${OC},g" \
1727 -e "s,@WINDRES@,${WINDRES},g" \
1728 -e "s,@DLLTOOL@,${DLLTOOL},g" \
1729 -e "s,@DLLWRAP@,${DLLWRAP},g" \
1730 -e "s,@RANLIB@,${RANLIB},g" \
1731 -e "s,@TOOL@,${tool},g" \
1732 -e "s,@BMP2RB_NATIVE@,${bmp2rb_native},g" \
1733 -e "s,@BMP2RB_MONO@,${bmp2rb_mono},g" \
1734 -e "s,@BMP2RB_REMOTENATIVE@,${bmp2rb_remotenative},g" \
1735 -e "s,@BMP2RB_REMOTEMONO@,${bmp2rb_remotemono},g" \
1736 -e "s,@OUTPUT@,${output},g" \
1737 -e "s,@APPEXTRA@,${appextra},g" \
1738 -e "s,@ARCHOSROM@,${archosrom},g" \
1739 -e "s,@FLASHFILE@,${flash},g" \
1740 -e "s,@PLUGINS@,${plugins},g" \
1741 -e "s,@CODECS@,${swcodec},g" \
1742 -e "s,@PROFILE_OPTS@,${PROFILE_OPTS},g" \
1743 -e "s,@SHARED_FLAG@,${SHARED_FLAG},g" \
1744 -e "s,@GCCOPTS@,${GCCOPTS},g" \
1745 -e "s,@TARGET_INC@,${TARGET_INC},g" \
1746 -e "s!@LDOPTS@!${LDOPTS}!g" \
1747 -e "s,@LOADADDRESS@,${loadaddress},g" \
1748 -e "s,@EXTRADEF@,${extradefines},g" \
1749 -e "s,@APPSDIR@,${appsdir},g" \
1750 -e "s,@FIRMDIR@,${firmdir},g" \
1751 -e "s,@TOOLSDIR@,${toolsdir},g" \
1752 -e "s,@APPS@,${apps},g" \
1753 -e "s,@SIMVER@,${simver},g" \
1754 -e "s,@GCCVER@,${gccver},g" \
1755 -e "s,@GCCNUM@,${gccnum},g" \
1756 -e "s,@UNAME@,${uname},g" \
1757 -e "s,@ENDIAN@,${defendian},g" \
1758 -e "s,@TOOLSET@,${toolset},g" \
1761 -e "s,@MANUALDEV@,${manualdev},g" \
1762 -e "s,@ENCODER@,${ENCODER},g" \
1763 -e "s,@ENC_OPTS@,${ENC_OPTS},g" \
1764 -e "s,@TTS_ENGINE@,${TTS_ENGINE},g" \
1765 -e "s,@TTS_OPTS@,${TTS_OPTS},g" \
1767 ## Automaticly generated. http://www.rockbox.org/
1775 # old 'make' versions don't have the built-in 'info' function
1776 info=old\$(shell echo >&2 "Consider upgrading to GNU make 3.81+ for optimum build performance.")
1777 ifeq (\$(call info),old)
1778 export info=echo "\$\$(1)";
1781 export ROOTDIR=@ROOTDIR@
1782 export FIRMDIR=@FIRMDIR@
1783 export APPSDIR=@APPSDIR@
1784 export TOOLSDIR=@TOOLSDIR@
1785 export DOCSDIR=\$(ROOTDIR)/docs
1786 export MANUALDIR=\${ROOTDIR}/manual
1787 export DEBUG=@DEBUG@
1788 export ARCHOS=@ARCHOS@
1789 export ARCHOSROM=@ARCHOSROM@
1790 export FLASHFILE=@FLASHFILE@
1791 export TARGET_ID=@TARGET_ID@
1792 export TARGET=@TARGET@
1794 export MANUFACTURER=@MANUFACTURER@
1796 export BUILDDIR=@PWD@
1797 export LANGUAGE=@LANGUAGE@
1798 export VOICELANGUAGE=@VOICELANGUAGE@
1799 export MEMORYSIZE=@MEMORY@
1800 export VERSION=\$(shell \$(ROOTDIR)/tools/svnversion.sh \$(ROOTDIR))
1801 export BUILDDATE=\$(shell date -u +'-DYEAR=%Y -DMONTH=%m -DDAY=%d')
1802 export MKFIRMWARE=@TOOL@
1803 export BMP2RB_MONO=@BMP2RB_MONO@
1804 export BMP2RB_NATIVE=@BMP2RB_NATIVE@
1805 export BMP2RB_REMOTEMONO=@BMP2RB_REMOTEMONO@
1806 export BMP2RB_REMOTENATIVE=@BMP2RB_REMOTENATIVE@
1807 export BINARY=@OUTPUT@
1808 export APPEXTRA=@APPEXTRA@
1809 export ENABLEDPLUGINS=@PLUGINS@
1810 export SOFTWARECODECS=@CODECS@
1811 export EXTRA_DEFINES=@EXTRADEF@
1818 export WINDRES=@WINDRES@
1819 export DLLTOOL=@DLLTOOL@
1820 export DLLWRAP=@DLLWRAP@
1821 export RANLIB=@RANLIB@
1822 export PROFILE_OPTS=@PROFILE_OPTS@
1823 export SIMVER=@SIMVER@
1824 export SIMDIR=\$(ROOTDIR)/uisimulator/sdl
1825 export GCCOPTS=@GCCOPTS@
1826 export TARGET_INC=@TARGET_INC@
1827 export LOADADDRESS=@LOADADDRESS@
1828 export SHARED_FLAG=@SHARED_FLAG@
1829 export LDOPTS=@LDOPTS@
1830 export GCCVER=@GCCVER@
1831 export GCCNUM=@GCCNUM@
1832 export UNAME=@UNAME@
1833 export MANUALDEV=@MANUALDEV@
1834 export TTS_OPTS=@TTS_OPTS@
1835 export TTS_ENGINE=@TTS_ENGINE@
1836 export ENC_OPTS=@ENC_OPTS@
1837 export ENCODER=@ENCODER@
1839 # Do not print "Entering directory ..."
1840 MAKEFLAGS += --no-print-directory
1842 .PHONY: all clean tags zip tools manual bin build info
1847 \$(SILENT)\$(TOOLSDIR)/mkinfo.pl \$(BUILDDIR)/rockbox-info.txt
1852 \$(SILENT)\$(MAKE) -C \$(FIRMDIR) OBJDIR=\$(BUILDDIR)/firmware
1853 \$(SILENT)\$(MAKE) -C \$(APPSDIR) OBJDIR=\$(BUILDDIR)/@APPS@
1858 \$(SILENT)\$(MAKE) -C \$(FIRMDIR) OBJDIR=\$(BUILDDIR)/firmware
1859 \$(SILENT)\$(MAKE) -C \$(APPSDIR) OBJDIR=\$(BUILDDIR)/@APPS@ \$(BUILDDIR)/\$(BINARY)
1862 \$(SILENT)\$(MAKE) -C \$(APPSDIR) OBJDIR=\$(BUILDDIR)/@APPS@ rocks
1864 veryclean: clean toolsclean
1867 \$(SILENT)\$(MAKE) -C \$(TOOLSDIR) clean
1870 \$(SILENT)echo Cleaning build directory
1871 \$(SILENT)rm -rf rockbox.zip TAGS @APPS@ firmware comsim sim lang.[ch]\
1872 manual *.pdf *.a credits.raw @OUTPUT@ bitmaps pluginbitmaps \
1873 @ARCHOSROM@ @FLASHFILE@ UI256.bmp rockbox-full.zip \
1874 html txt rockbox-manual*.zip sysfont.h rockbox-info.txt \
1875 voicefontids *.wav *.mp3 *.voice
1878 \$(SILENT)\$(MAKE) -C \$(TOOLSDIR) CC=\$(HOSTCC) @TOOLSET@
1881 \$(SILENT)rm -f TAGS
1882 \$(SILENT)\$(MAKE) -C \$(FIRMDIR) tags
1883 \$(SILENT)\$(MAKE) -C \$(APPSDIR) tags
1884 \$(SILENT)\$(MAKE) -C \$(APPSDIR)/plugins tags
1885 \$(SILENT)\$(MAKE) -C \$(APPSDIR)/plugins/lib tags
1888 \$(SILENT)\$(TOOLSDIR)/buildzip.pl \$(VERBOSEOPT) -t \"\$(ARCHOS)\" -r "\$(ROOTDIR)" -f 1 -o rockbox-fonts.zip \$(TARGET) \$(BINARY)
1891 \$(SILENT)for f in \`cat \$(BUILDDIR)/@APPS@/features\`; do feat="\$\$feat:\$\$f" ; done ; \\
1892 \$(TOOLSDIR)/buildzip.pl \$(VERBOSEOPT) -t \"\$(ARCHOS)\$\$feat\" -i \"\$(TARGET_ID)\" -r "\$(ROOTDIR)" \$(TARGET) \$(BINARY)
1895 \$(SILENT)find . -name "*.map" | xargs zip rockbox-maps.zip
1898 \$(SILENT)for f in \`cat \$(BUILDDIR)/@APPS@/features\`; do feat="\$\$feat:\$\$f" ; done; \\
1899 \$(TOOLSDIR)/buildzip.pl \$(VERBOSEOPT) -t \"\$(ARCHOS)\$\$feat\" -i \"\$(TARGET_ID)\" -r "\$(ROOTDIR)" -f 2 -o rockbox-full.zip \$(TARGET) \$(BINARY)
1902 \$(SILENT)for f in \`cat \$(BUILDDIR)/@APPS@/features\`; do feat="\$\$feat:\$\$f" ; done; \\
1903 \$(TOOLSDIR)/buildzip.pl \$(VERBOSEOPT) -t \"\$(ARCHOS)\$\$feat\" -i \"\$(TARGET_ID)\" -o "rockbox.7z" -z "7za a" -r "\$(ROOTDIR)" \$(TARGET) \$(BINARY)
1906 \$(SILENT)rm -f rockbox.tar
1907 \$(SILENT)for f in \`cat \$(BUILDDIR)/@APPS@/features\`; do feat="\$\$feat:\$\$f" ; done; \\
1908 \$(TOOLSDIR)/buildzip.pl \$(VERBOSEOPT) -t \"\$(ARCHOS)\$\$feat\" -i \"\$(TARGET_ID)\" -o "rockbox.tar" -z "tar --no-recursion -uf" -r "\$(ROOTDIR)" \$(TARGET) \$(BINARY)
1911 \$(SILENT)bzip2 -f9 rockbox.tar
1914 \$(SILENT)gzip -f9 rockbox.tar
1918 \$(SILENT)\$(MAKE) -C \$(MANUALDIR) OBJDIR=\$(BUILDDIR)/manual manual-pdf
1920 \$(SILENT)\$(MAKE) -C \$(MANUALDIR) OBJDIR=\$(BUILDDIR)/manual manual-html
1921 manual-zhtml: manual-zip
1923 \$(SILENT)\$(MAKE) -C \$(MANUALDIR) OBJDIR=\$(BUILDDIR)/manual manual-txt
1925 \$(SILENT)\$(MAKE) -C \$(MANUALDIR) OBJDIR=\$(BUILDDIR)/manual manual-txt-zip
1927 \$(SILENT)\$(MAKE) -C \$(MANUALDIR) OBJDIR=\$(BUILDDIR)/manual manual-zip
1930 \$(SILENT)\$(MAKE) -C \$(APPSDIR) OBJDIR=\$(BUILDDIR)/@APPS@ features
1933 @echo "A few helpful make targets"
1935 @echo "all - builds a full Rockbox (default), including tools"
1936 @echo "bin - builds only the Rockbox.<target name> file"
1937 @echo "clean - cleans a build directory (not tools)"
1938 @echo "veryclean - cleans the build and tools directories"
1939 @echo "manual - builds a manual"
1940 @echo "manual-html - HTML manual"
1941 @echo "manual-zip - HTML manual (zipped)"
1942 @echo "manual-txt - txt manual"
1943 @echo "fullzip - creates a rockbox.zip of your build with fonts"
1944 @echo "zip - creates a rockbox.zip of your build (no fonts)"
1945 @echo "gzip - creates a rockbox.tar.gz of your build (no fonts)"
1946 @echo "bzip2 - creates a rockbox.tar.bz2 of your build (no fonts)"
1947 @echo "7zip - creates a rockbox.7z of your build (no fonts)"
1948 @echo "fontzip - creates rockbox-fonts.zip"
1949 @echo "mapzip - creates rockbox-maps.zip with all .map files"
1950 @echo "tools - builds the tools only"
1951 @echo "install - installs your build (for simulator builds only)"
1955 if [ "yes" = "$simulator" ]; then
1957 cat >> Makefile
<<EOF
1960 @echo "installing a full setup in your archos dir"
1961 @(\$(MAKE) fullzip && cd archos && unzip -oq ../rockbox-full.zip)
1966 if [ "yes" = "$voice" ]; then
1968 cat >> Makefile
<<EOF
1970 voice: tools features
1971 \$(SILENT)for f in \`cat \$(BUILDDIR)/${apps}/features\`; do feat="\$\$feat:\$\$f" ; done ; \\
1972 for lang in \`echo \$(VOICELANGUAGE) |sed "s/,/ /g"\`; do \$(TOOLSDIR)/voice.pl -V -l=\$\$lang -t=\$(ARCHOS)\$\$feat -i=\$(TARGET_ID) -e=\$(ENCODER) -E="\$(ENC_OPTS)" -s=\$(TTS_ENGINE) -S="\$(TTS_OPTS)"; done \\
1977 echo "Created Makefile"