2002-05-23 09:11:35 +00:00
|
|
|
#!/bin/sh
|
|
|
|
# __________ __ ___.
|
|
|
|
# Open \______ \ ____ ____ | | _\_ |__ _______ ___
|
|
|
|
# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
|
|
|
|
# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
|
|
|
|
# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
|
|
|
|
# \/ \/ \/ \/ \/
|
|
|
|
# $Id$
|
|
|
|
#
|
|
|
|
|
2004-10-04 13:02:41 +00:00
|
|
|
# global CC options for all platforms
|
|
|
|
CCOPTS="-W -Wall -O -nostdlib -ffreestanding -Wstrict-prototypes"
|
2002-09-02 11:50:52 +00:00
|
|
|
|
2002-10-17 09:08:05 +00:00
|
|
|
#
|
|
|
|
# Begin Function Definitions
|
|
|
|
#
|
2002-05-23 09:11:35 +00:00
|
|
|
input() {
|
|
|
|
read response
|
|
|
|
echo $response
|
|
|
|
}
|
|
|
|
|
2004-09-22 08:58:50 +00:00
|
|
|
shcc () {
|
|
|
|
CC=sh-elf-gcc
|
|
|
|
LD=sh-elf-ld
|
|
|
|
AR=sh-elf-ar
|
|
|
|
AS=sh-elf-as
|
|
|
|
OC=sh-elf-objcopy
|
2004-10-04 13:02:41 +00:00
|
|
|
GCCOPTS="$CCOPTS -m1"
|
2004-10-07 07:08:57 +00:00
|
|
|
GCCOPTIMIZE="-fomit-frame-pointer -fschedule-insns"
|
2004-09-22 08:58:50 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
coldfirecc () {
|
|
|
|
CC=m68k-elf-gcc
|
|
|
|
LD=m68k-elf-ld
|
|
|
|
AR=m68k-elf-ar
|
|
|
|
AS=m68k-elf-as
|
|
|
|
OC=m68k-elf-objcopy
|
2004-11-19 00:44:07 +00:00
|
|
|
GCCOPTS="$CCOPTS -g -m5200 -Wa\,-m5249"
|
2004-10-07 07:08:57 +00:00
|
|
|
GCCOPTIMIZE="-fomit-frame-pointer"
|
2004-09-22 08:58:50 +00:00
|
|
|
}
|
|
|
|
|
2002-10-17 09:19:34 +00:00
|
|
|
whichsim () {
|
2002-08-02 12:06:07 +00:00
|
|
|
|
|
|
|
if [ -z "$simver" ]; then
|
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Figure out win32/x11 GUI
|
|
|
|
#
|
|
|
|
echo ""
|
|
|
|
echo "Build (W)in32 or (X)11 GUI version? (X)"
|
|
|
|
|
|
|
|
option=`input`;
|
|
|
|
|
|
|
|
case $option in
|
|
|
|
[Ww])
|
|
|
|
simver="win32"
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
simver="x11"
|
|
|
|
;;
|
|
|
|
esac
|
2003-02-26 09:13:47 +00:00
|
|
|
echo "Selected $simver simulator"
|
2002-08-02 12:06:07 +00:00
|
|
|
fi
|
2002-10-17 09:19:34 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
simul () {
|
2002-08-02 12:06:07 +00:00
|
|
|
|
2002-05-31 07:22:38 +00:00
|
|
|
sed > Makefile \
|
2004-05-26 11:07:16 +00:00
|
|
|
-e "s,@ROOTDIR@,${rootdir},g" \
|
2003-01-16 14:37:30 +00:00
|
|
|
-e "s,@ARCHOS@,${archos},g" \
|
2002-05-31 07:22:38 +00:00
|
|
|
-e "s,@DEBUG@,${debug},g" \
|
|
|
|
-e "s,@KEYPAD@,${keypad},g" \
|
|
|
|
-e "s,@PWD@,${pwd},g" \
|
2002-09-20 06:38:38 +00:00
|
|
|
-e "s,@LANGUAGE@,${language},g" \
|
2004-06-14 15:05:58 +00:00
|
|
|
-e "s,@TARGET@,${target},g" \
|
2002-08-02 12:06:07 +00:00
|
|
|
-e "s,@SIMVER@,${simver},g" \
|
2002-05-31 07:22:38 +00:00
|
|
|
<<EOF
|
2002-08-11 09:17:47 +00:00
|
|
|
## Automaticly generated. http://rockbox.haxx.se
|
2002-05-31 07:22:38 +00:00
|
|
|
|
2004-09-22 08:58:50 +00:00
|
|
|
export ARCHOS=@ARCHOS@
|
|
|
|
export ROOTDIR=@ROOTDIR@
|
|
|
|
export FIRMDIR=\$(ROOTDIR)/firmware
|
|
|
|
export APPSDIR=\$(ROOTDIR)/apps
|
|
|
|
export TOOLSDIR=\$(ROOTDIR)/tools
|
|
|
|
export DOCSDIR=\$(ROOTDIR)/docs
|
|
|
|
export APPSDIR=@ROOTDIR@/apps
|
|
|
|
export SIMDIR=\$(ROOTDIR)/uisimulator/@SIMVER@
|
|
|
|
export DEBUG=@DEBUG@
|
|
|
|
export KEYPAD=@KEYPAD@
|
|
|
|
export OBJDIR=@PWD@
|
|
|
|
export SIMVER=@SIMVER@
|
|
|
|
export TARGET=@TARGET@
|
|
|
|
export LANGUAGE=@LANGUAGE@
|
|
|
|
export VERSION=\$(shell date +%y%m%d-%H%M)
|
2002-05-31 07:22:38 +00:00
|
|
|
|
2002-07-26 14:13:03 +00:00
|
|
|
.PHONY:
|
2002-05-31 07:22:38 +00:00
|
|
|
|
|
|
|
all: sim
|
|
|
|
|
|
|
|
sim:
|
2004-09-22 08:58:50 +00:00
|
|
|
\$(MAKE) -C \$(SIMDIR)
|
2002-05-31 07:22:38 +00:00
|
|
|
|
2002-08-15 10:07:27 +00:00
|
|
|
clean:
|
2004-09-22 08:58:50 +00:00
|
|
|
\$(MAKE) -C \$(SIMDIR) clean
|
2004-08-24 09:37:30 +00:00
|
|
|
rm -rf rockbox.zip
|
2002-05-31 07:22:38 +00:00
|
|
|
|
2002-08-15 10:07:27 +00:00
|
|
|
tags:
|
|
|
|
@rm -f TAGS
|
2004-09-22 08:58:50 +00:00
|
|
|
make -C \$(SIMDIR) tags
|
2002-05-31 07:22:38 +00:00
|
|
|
|
2004-06-14 15:05:58 +00:00
|
|
|
zip:
|
2004-08-24 15:13:08 +00:00
|
|
|
\$(TOOLSDIR)/buildzip.pl -r "\$(ROOTDIR)" sim\$(TARGET)
|
2004-06-14 15:05:58 +00:00
|
|
|
|
|
|
|
install:
|
|
|
|
@echo "installing a full setup in your archos dir"
|
|
|
|
@(make zip && cd archos && unzip -oq ../rockbox.zip)
|
2002-05-31 07:22:38 +00:00
|
|
|
EOF
|
|
|
|
|
2002-06-06 13:33:38 +00:00
|
|
|
echo "Created Makefile"
|
2002-05-31 08:38:35 +00:00
|
|
|
|
2002-06-06 13:33:38 +00:00
|
|
|
if [ -d "archos" ]; then
|
|
|
|
echo "sub directory archos already present"
|
|
|
|
else
|
|
|
|
mkdir archos
|
|
|
|
echo "created an archos subdirectory for simulating the hard disk"
|
|
|
|
fi
|
2002-05-31 08:38:35 +00:00
|
|
|
|
2002-05-31 07:22:38 +00:00
|
|
|
}
|
|
|
|
|
2002-10-17 09:08:05 +00:00
|
|
|
picklang() {
|
|
|
|
# figure out which languages that are around
|
2004-05-26 11:07:16 +00:00
|
|
|
for file in $rootdir/apps/lang/*.lang; do
|
2002-10-17 09:08:05 +00:00
|
|
|
clean=`echo $file | sed -e 's:.*/::g' | cut "-d." -f1`
|
|
|
|
langs="$langs $clean"
|
|
|
|
done
|
|
|
|
|
|
|
|
num=1
|
|
|
|
for one in $langs; do
|
|
|
|
echo "$num. $one"
|
|
|
|
num=`expr $num + 1`
|
|
|
|
done
|
|
|
|
|
|
|
|
read pick
|
|
|
|
return $pick;
|
|
|
|
}
|
|
|
|
|
|
|
|
whichlang() {
|
|
|
|
num=1
|
|
|
|
for one in $langs; do
|
|
|
|
if [ "$num" = "$pick" ]; then
|
|
|
|
echo $one
|
|
|
|
return
|
|
|
|
fi
|
|
|
|
num=`expr $num + 1`
|
|
|
|
done
|
|
|
|
}
|
|
|
|
|
|
|
|
target=$1
|
|
|
|
debug=$2
|
|
|
|
|
|
|
|
if test "$1" = "--help"; then
|
|
|
|
echo "Rockbox configure script."
|
|
|
|
echo "Invoke this in a directory to generate a Makefile to build Rockbox"
|
|
|
|
echo "Do *NOT* run this within the tools directory!"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
|
|
|
if test -r "configure"; then
|
|
|
|
# this is a check for a configure script in the current directory, it there
|
|
|
|
# is one, try to figure out if it is this one!
|
|
|
|
|
|
|
|
if { grep "^# Jukebox" configure >/dev/null 2>&1 ; } then
|
|
|
|
echo "WEEEEEEEEP. Don't run this configure script within the tools directory."
|
|
|
|
echo "It will only cause you pain and grief. Instead do this:"
|
|
|
|
echo ""
|
|
|
|
echo " cd .."
|
|
|
|
echo " mkdir build-dir"
|
|
|
|
echo " cd build-dir"
|
|
|
|
echo " ../tools/configure"
|
|
|
|
echo ""
|
|
|
|
echo "Much happiness will arise from this. Enjoy"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2002-05-31 08:21:20 +00:00
|
|
|
if [ "$target" = "--help" -o \
|
|
|
|
"$target" = "-h" ]; then
|
|
|
|
echo "Just invoke the script and answer the questions."
|
|
|
|
echo "This script will write a Makefile for you"
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2002-05-31 07:22:38 +00:00
|
|
|
# get our current directory
|
|
|
|
pwd=`pwd`;
|
2002-05-23 09:11:35 +00:00
|
|
|
|
2002-05-23 10:10:44 +00:00
|
|
|
if [ "$target" = "update" ]; then
|
2004-09-22 08:58:50 +00:00
|
|
|
echo "configure update is unfortunately no longer supported"
|
|
|
|
exit
|
2002-05-31 07:22:38 +00:00
|
|
|
else
|
|
|
|
|
2003-02-26 09:13:47 +00:00
|
|
|
echo "This script will setup your Rockbox build environment."
|
|
|
|
echo "Further docs here: http://rockbox.haxx.se/docs/"
|
2002-05-31 07:22:38 +00:00
|
|
|
echo ""
|
|
|
|
|
2002-05-23 10:10:44 +00:00
|
|
|
fi
|
|
|
|
|
2004-09-22 08:58:50 +00:00
|
|
|
if [ -z "$rootdir" ]; then
|
|
|
|
##################################################################
|
|
|
|
# Figure out where the source code root is!
|
|
|
|
#
|
|
|
|
|
|
|
|
firmfile="crt0.S" # a file to check for in the firmware root dir
|
|
|
|
|
|
|
|
for dir in . .. ../.. ../rockbox*; do
|
|
|
|
if [ -f $dir/firmware/$firmfile ]; then
|
|
|
|
rootdir=$dir
|
|
|
|
break
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
|
|
|
|
if [ -z "$rootdir" ]; then
|
|
|
|
echo "This script couldn't find your source code root directory. Please enter the"
|
|
|
|
echo "full path to the source code directory here:"
|
|
|
|
|
|
|
|
firmdir=`input`
|
|
|
|
fi
|
|
|
|
|
|
|
|
#####################################################################
|
|
|
|
# Convert the possibly relative directory name to an absolute version
|
|
|
|
#
|
|
|
|
now=`pwd`
|
|
|
|
cd $rootdir
|
|
|
|
rootdir=`pwd`
|
|
|
|
|
|
|
|
echo "Using this source code root directory:"
|
|
|
|
echo $rootdir
|
|
|
|
echo ""
|
|
|
|
|
|
|
|
# cd back to the build dir
|
|
|
|
cd $now
|
|
|
|
fi
|
|
|
|
|
2003-01-16 14:37:30 +00:00
|
|
|
if [ -z "$archos" ]; then
|
2002-05-23 09:11:35 +00:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Figure out target platform
|
|
|
|
#
|
|
|
|
|
2003-12-12 10:48:40 +00:00
|
|
|
echo "Enter target platform: (default is Archos Recorder)"
|
2002-05-23 09:11:35 +00:00
|
|
|
|
2002-10-15 12:25:57 +00:00
|
|
|
echo "1 - Archos Player/Studio"
|
|
|
|
echo "2 - Archos Recorder"
|
2003-01-16 14:37:30 +00:00
|
|
|
echo "3 - Archos FM Recorder"
|
2003-11-19 06:40:59 +00:00
|
|
|
echo "4 - Archos Recorder v2"
|
2004-09-09 06:01:46 +00:00
|
|
|
echo "7 - Archos Ondio SP"
|
|
|
|
echo "8 - Archos Ondio FM"
|
2004-09-16 14:36:08 +00:00
|
|
|
echo "9 - Iriver H100"
|
2002-05-23 09:11:35 +00:00
|
|
|
|
|
|
|
getit=`input`;
|
|
|
|
|
|
|
|
case $getit in
|
|
|
|
|
|
|
|
1)
|
2003-01-16 14:37:30 +00:00
|
|
|
archos="player"
|
2002-05-23 09:11:35 +00:00
|
|
|
target="-DARCHOS_PLAYER"
|
2004-09-22 08:58:50 +00:00
|
|
|
shcc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="$rootdir/tools/scramble"
|
2004-09-22 08:58:50 +00:00
|
|
|
output="archos.mod"
|
|
|
|
appextra="player"
|
|
|
|
archosrom=""
|
2004-10-07 08:20:25 +00:00
|
|
|
flash=""
|
2004-09-22 21:40:45 +00:00
|
|
|
plugins="yes"
|
2004-09-22 08:58:50 +00:00
|
|
|
;;
|
|
|
|
|
2003-01-16 14:37:30 +00:00
|
|
|
3)
|
|
|
|
archos="fmrecorder"
|
|
|
|
target="-DARCHOS_FMRECORDER"
|
2004-09-22 08:58:50 +00:00
|
|
|
shcc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="$rootdir/tools/scramble -fm"
|
2004-09-22 08:58:50 +00:00
|
|
|
output="ajbrec.ajz"
|
|
|
|
appextra="recorder"
|
|
|
|
archosrom="$pwd/rombox.ucl"
|
2004-10-07 08:20:25 +00:00
|
|
|
flash="$pwd/rockbox.ucl"
|
2004-09-22 21:40:45 +00:00
|
|
|
plugins="yes"
|
2003-01-16 14:37:30 +00:00
|
|
|
;;
|
|
|
|
|
2003-11-19 06:40:59 +00:00
|
|
|
4)
|
|
|
|
archos="recorderv2"
|
|
|
|
target="-DARCHOS_RECORDERV2"
|
2004-09-22 08:58:50 +00:00
|
|
|
shcc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="$rootdir/tools/scramble -v2"
|
2004-09-22 08:58:50 +00:00
|
|
|
output="ajbrec.ajz"
|
|
|
|
appextra="recorder"
|
|
|
|
archosrom="$pwd/rombox.ucl"
|
2004-10-07 08:20:25 +00:00
|
|
|
flash="$pwd/rockbox.ucl"
|
2004-09-22 21:40:45 +00:00
|
|
|
plugins="yes"
|
2003-11-19 06:40:59 +00:00
|
|
|
;;
|
|
|
|
|
2004-09-09 06:01:46 +00:00
|
|
|
7)
|
|
|
|
archos="ondiosp"
|
|
|
|
target="-DARCHOS_ONDIOSP"
|
2004-09-22 08:58:50 +00:00
|
|
|
shcc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="$rootdir/tools/scramble -osp"
|
2004-09-22 08:58:50 +00:00
|
|
|
output="ajbrec.ajz"
|
|
|
|
appextra="recorder"
|
2004-10-07 06:51:22 +00:00
|
|
|
archosrom="$pwd/rombox.ucl"
|
2004-10-07 08:20:25 +00:00
|
|
|
flash="$pwd/rockbox.ucl"
|
2004-10-07 06:51:22 +00:00
|
|
|
plugins="yes"
|
2004-09-09 06:01:46 +00:00
|
|
|
;;
|
|
|
|
|
|
|
|
8)
|
|
|
|
archos="ondiofm"
|
|
|
|
target="-DARCHOS_ONDIOFM"
|
2004-09-22 08:58:50 +00:00
|
|
|
shcc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="$rootdir/tools/scramble -ofm"
|
2004-09-22 08:58:50 +00:00
|
|
|
output="ajbrec.ajz"
|
|
|
|
appextra="recorder"
|
2004-10-07 06:51:22 +00:00
|
|
|
archosrom="$pwd/rombox.ucl"
|
2004-10-07 08:20:25 +00:00
|
|
|
flash="$pwd/rockbox.ucl"
|
2004-10-07 06:51:22 +00:00
|
|
|
plugins="yes"
|
2004-09-16 14:36:08 +00:00
|
|
|
;;
|
|
|
|
|
|
|
|
9)
|
|
|
|
archos="h100"
|
|
|
|
target="-DIRIVER_H100"
|
2004-09-16 21:19:21 +00:00
|
|
|
memory=32 # always
|
2004-09-22 08:58:50 +00:00
|
|
|
coldfirecc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="cp"
|
2004-09-22 08:58:50 +00:00
|
|
|
output="rockbox.iriver"
|
2004-11-19 00:44:07 +00:00
|
|
|
appextra="recorder"
|
2004-09-22 08:58:50 +00:00
|
|
|
archosrom=""
|
2004-10-07 08:20:25 +00:00
|
|
|
flash=""
|
2004-10-07 08:36:25 +00:00
|
|
|
plugins=""
|
2002-05-23 09:11:35 +00:00
|
|
|
;;
|
|
|
|
|
2004-09-22 09:29:58 +00:00
|
|
|
*)
|
|
|
|
archos="recorder"
|
|
|
|
target="-DARCHOS_RECORDER"
|
|
|
|
shcc
|
2004-10-07 08:08:05 +00:00
|
|
|
tool="$rootdir/tools/scramble"
|
2004-09-22 09:29:58 +00:00
|
|
|
output="ajbrec.ajz"
|
|
|
|
appextra="recorder"
|
|
|
|
archosrom="$pwd/rombox.ucl"
|
2004-10-07 08:20:25 +00:00
|
|
|
flash="$pwd/rockbox.ucl"
|
2004-09-22 21:40:45 +00:00
|
|
|
plugins="yes"
|
2004-09-22 09:29:58 +00:00
|
|
|
;;
|
|
|
|
|
2002-05-23 09:11:35 +00:00
|
|
|
esac
|
2003-02-26 09:13:47 +00:00
|
|
|
|
|
|
|
echo "Platform set to $archos"
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
if [ -z "$memory" ]; then
|
|
|
|
size="2"
|
|
|
|
if [ -z "$update" ]; then
|
|
|
|
echo "Enter size of your RAM (in MB): (defaults to 2)"
|
|
|
|
size=`input`;
|
|
|
|
fi
|
|
|
|
|
|
|
|
case $size in
|
|
|
|
8)
|
|
|
|
memory="8"
|
|
|
|
;;
|
|
|
|
*)
|
|
|
|
memory="2"
|
|
|
|
;;
|
|
|
|
|
|
|
|
esac
|
|
|
|
echo "Memory size selected: $memory MB"
|
2002-05-23 09:11:35 +00:00
|
|
|
fi
|
|
|
|
|
2002-05-23 10:10:44 +00:00
|
|
|
if [ -z "$debug" ]; then
|
|
|
|
##################################################################
|
|
|
|
# Figure out debug on/off
|
|
|
|
#
|
2002-05-31 07:22:38 +00:00
|
|
|
echo "Build (N)ormal, (D)ebug or (S)imulated version? (N)"
|
2002-05-23 09:11:35 +00:00
|
|
|
|
2002-05-23 10:10:44 +00:00
|
|
|
option=`input`;
|
2002-05-23 09:11:35 +00:00
|
|
|
|
2002-05-23 10:10:44 +00:00
|
|
|
case $option in
|
2002-05-31 07:22:38 +00:00
|
|
|
[Ss])
|
2004-09-22 08:58:50 +00:00
|
|
|
debug="1"
|
2002-05-31 07:22:38 +00:00
|
|
|
simulator="yes"
|
2003-02-26 09:13:47 +00:00
|
|
|
echo "Simulator build selected"
|
2002-10-17 09:19:34 +00:00
|
|
|
whichsim
|
2002-05-31 07:22:38 +00:00
|
|
|
;;
|
|
|
|
[Dd])
|
2004-09-22 08:58:50 +00:00
|
|
|
debug="1"
|
2003-02-26 09:13:47 +00:00
|
|
|
echo "Debug build selected"
|
2004-10-04 13:02:41 +00:00
|
|
|
GCCOPTS="$GCCOPTS -g -DDEBUG"
|
2002-05-23 10:10:44 +00:00
|
|
|
;;
|
|
|
|
*)
|
2004-09-22 08:58:50 +00:00
|
|
|
debug=""
|
2003-02-26 09:13:47 +00:00
|
|
|
echo "Normal build selected"
|
2004-10-07 07:08:57 +00:00
|
|
|
GCCOPTS="$GCCOPTS $GCCOPTIMIZE"
|
2002-05-23 10:10:44 +00:00
|
|
|
;;
|
|
|
|
|
|
|
|
esac
|
|
|
|
fi
|
2002-05-23 09:11:35 +00:00
|
|
|
|
2003-04-22 22:18:57 +00:00
|
|
|
|
2002-09-20 06:38:38 +00:00
|
|
|
if [ -z "$language" ]; then
|
|
|
|
|
|
|
|
echo "Select a number for the language to use (default is english)"
|
|
|
|
|
|
|
|
picklang
|
|
|
|
language=`whichlang`
|
|
|
|
|
|
|
|
if [ -z "$language" ]; then
|
|
|
|
# pick a default
|
|
|
|
language="english"
|
|
|
|
fi
|
2003-02-26 09:13:47 +00:00
|
|
|
echo "Language set to $language"
|
2002-09-20 06:38:38 +00:00
|
|
|
fi
|
|
|
|
|
2002-10-17 09:14:57 +00:00
|
|
|
if [ "yes" = "$simulator" ]; then
|
|
|
|
# we have already dealt with the simulator Makefile separately
|
2002-10-17 09:19:34 +00:00
|
|
|
simul
|
2002-10-17 09:14:57 +00:00
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2002-05-23 09:39:31 +00:00
|
|
|
sed > Makefile \
|
2004-05-26 11:07:16 +00:00
|
|
|
-e "s,@ROOTDIR@,${rootdir},g" \
|
2002-05-23 09:39:31 +00:00
|
|
|
-e "s,@DEBUG@,${debug},g" \
|
2003-02-26 09:13:47 +00:00
|
|
|
-e "s,@MEMORY@,${memory},g" \
|
2002-05-23 09:39:31 +00:00
|
|
|
-e "s,@TARGET@,${target},g" \
|
2003-01-16 14:37:30 +00:00
|
|
|
-e "s,@ARCHOS@,${archos},g" \
|
2002-09-20 06:38:38 +00:00
|
|
|
-e "s,@LANGUAGE@,${language},g" \
|
2002-05-23 09:39:31 +00:00
|
|
|
-e "s,@PWD@,${pwd},g" \
|
2004-09-22 08:58:50 +00:00
|
|
|
-e "s,@CC@,${CC},g" \
|
|
|
|
-e "s,@LD@,${LD},g" \
|
|
|
|
-e "s,@AR@,${AR},g" \
|
|
|
|
-e "s,@AS@,${AS},g" \
|
|
|
|
-e "s,@OC@,${OC},g" \
|
|
|
|
-e "s,@TOOL@,${tool},g" \
|
|
|
|
-e "s,@OUTPUT@,${output},g" \
|
|
|
|
-e "s,@APPEXTRA@,${appextra},g" \
|
|
|
|
-e "s,@ARCHOSROM@,${archosrom},g" \
|
2004-10-07 08:20:25 +00:00
|
|
|
-e "s,@FLASHFILE@,${flash},g" \
|
2004-09-22 21:40:45 +00:00
|
|
|
-e "s,@PLUGINS@,${plugins},g" \
|
2004-10-04 13:02:41 +00:00
|
|
|
-e "s,@GCCOPTS@,${GCCOPTS},g" \
|
2002-05-23 09:39:31 +00:00
|
|
|
<<EOF
|
2002-08-11 09:17:47 +00:00
|
|
|
## Automaticly generated. http://rockbox.haxx.se
|
2002-05-23 10:10:44 +00:00
|
|
|
|
2004-09-22 08:58:50 +00:00
|
|
|
export ROOTDIR=@ROOTDIR@
|
|
|
|
export FIRMDIR=\$(ROOTDIR)/firmware
|
|
|
|
export APPSDIR=\$(ROOTDIR)/apps
|
|
|
|
export TOOLSDIR=\$(ROOTDIR)/tools
|
|
|
|
export DOCSDIR=\$(ROOTDIR)/docs
|
|
|
|
export DEBUG=@DEBUG@
|
|
|
|
export ARCHOS=@ARCHOS@
|
|
|
|
export ARCHOSROM=@ARCHOSROM@
|
2004-10-07 08:20:25 +00:00
|
|
|
export FLASHFILE=@FLASHFILE@
|
2004-09-22 08:58:50 +00:00
|
|
|
export TARGET=@TARGET@
|
|
|
|
export OBJDIR=@PWD@
|
|
|
|
export LANGUAGE=@LANGUAGE@
|
|
|
|
export MEMORYSIZE=@MEMORY@
|
|
|
|
export VERSION=\$(shell date +%y%m%d-%H%M)
|
2004-10-07 08:08:05 +00:00
|
|
|
export MKFIRMWARE=@TOOL@
|
2004-09-22 08:58:50 +00:00
|
|
|
export BINARY=@OUTPUT@
|
|
|
|
export APPEXTRA=@APPEXTRA@
|
2004-09-22 21:40:45 +00:00
|
|
|
export ENABLEDPLUGINS=@PLUGINS@
|
2004-09-22 08:58:50 +00:00
|
|
|
export CC=@CC@
|
|
|
|
export LD=@LD@
|
|
|
|
export AR=@AR@
|
|
|
|
export AS=@AS@
|
|
|
|
export OC=@OC@
|
2004-10-04 13:02:41 +00:00
|
|
|
export GCCOPTS=@GCCOPTS@
|
2004-09-22 08:58:50 +00:00
|
|
|
|
|
|
|
.PHONY: all clean tags zip
|
|
|
|
|
|
|
|
all:
|
|
|
|
@\$(MAKE) -C \$(FIRMDIR)
|
|
|
|
@\$(MAKE) -C \$(APPSDIR)
|
2002-05-24 09:33:37 +00:00
|
|
|
|
2002-05-23 13:55:26 +00:00
|
|
|
clean:
|
2004-09-22 08:58:50 +00:00
|
|
|
@\$(MAKE) -C \$(FIRMDIR) clean
|
|
|
|
@\$(MAKE) -C \$(APPSDIR) clean
|
|
|
|
@rm -f rockbox.zip TAGS
|
2002-08-15 09:32:59 +00:00
|
|
|
|
|
|
|
tags:
|
|
|
|
@rm -f TAGS
|
2004-09-22 08:58:50 +00:00
|
|
|
\$(MAKE) -C \$(FIRMDIR) tags
|
|
|
|
\$(MAKE) -C \$(APPSDIR) tags
|
|
|
|
\$(MAKE) -C \$(APPSDIR)/plugins tags
|
|
|
|
\$(MAKE) -C \$(APPSDIR)/plugins/lib tags
|
2004-05-21 19:05:47 +00:00
|
|
|
|
|
|
|
zip:
|
2004-08-24 15:13:08 +00:00
|
|
|
\$(TOOLSDIR)/buildzip.pl -r "\$(ROOTDIR)" \$(TARGET)
|
2002-05-23 09:11:35 +00:00
|
|
|
EOF
|
2002-05-23 09:39:31 +00:00
|
|
|
|
|
|
|
echo "Created Makefile"
|