Subversion Repositories Projects

Rev

Rev 1866 | Rev 2040 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

#!/bin/sh
#/****************************************************************************
# *   Copyright (C) 2009-2014 by Claas Anders "CaScAdE" Rathje               *
# *   admiralcascade@gmail.com                                               *
# *   Project-URL: http://www.mylifesucks.de/oss/c-osd/                      *
# *                                                                          *
# *   This program is free software; you can redistribute it and/or modify   *
# *   it under the terms of the GNU General Public License as published by   *
# *   the Free Software Foundation; either version 2 of the License.         *
# *                                                                          *
# *   This program is distributed in the hope that it will be useful,        *
# *   but WITHOUT ANY WARRANTY; without even the implied warranty of         *
# *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          *
# *   GNU General Public License for more details.                           *
# *                                                                          *
# *   You should have received a copy of the GNU General Public License      *
# *   along with this program; if not, write to the                          *
# *   Free Software Foundation, Inc.,                                        *
# *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.              *
# ****************************************************************************/

DATE=`date +%Y%m%d-%H%M`
#DATE="20090604-1350"
REVISION=`svn info .. | awk '$1 == "Revision:" {print $2}'`

# build pal hex
export CFLAGS="-DBUILDDATE=\\\"${DATE}\\\" "
make clean
make
mv C-OSD.hex C-OSD-${DATE}-pal.hex

# build ntsc hex
export CFLAGS="-DNTSC=1 -DBUILDDATE=\\\"${DATE}\\\" "
make clean
make
mv C-OSD.hex C-OSD-${DATE}-ntsc.hex

#build pal hex FCONLY
export CFLAGS="-DFCONLY=1 -DBUILDDATE=\\\"${DATE}\\\" "
make clean
make
mv C-OSD.hex C-OSD-${DATE}-pal-fconly.hex

# build ntsc hex FCONLY
export CFLAGS="-DNTSC=1 -DFCONLY=1 -DBUILDDATE=\\\"${DATE}\\\" "
make clean
make
mv C-OSD.hex C-OSD-${DATE}-ntsc-fconly.hex


# build character files
# PAL
make clean
export CFLAGS="-DWRITECHARS=1 -DBUILDDATE=\\\"${DATE}\\\" "
make
mv C-OSD.hex C-OSD-characters-pal.hex

# and NTSC as well
make clean
export CFLAGS="-DNTSC=1 -DWRITECHARS=1 -DBUILDDATE=\\\"${DATE}\\\" "
make
mv C-OSD.hex C-OSD-characters-ntsc.hex



# clean up
make clean

md5sum *.hex

# pack all stuff
mkdir C-OSD-${DATE}
mv *.hex C-OSD-${DATE}
cp ../CHANGE.LOG C-OSD-${DATE}
cp ../LICENSE.TXT C-OSD-${DATE}
cp ../README.TXT C-OSD-${DATE}
zip -r -9 -q C-OSD-${DATE}.zip C-OSD-${DATE}
rm -rf C-OSD-${DATE}

du -h C-OSD-${DATE}.zip
echo "building based on revision $REVISION is now DONE..."