mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 05:05:20 -05:00
Work-in-progress (i.e. not well tested) changes: Add the option to build ipodpatcher with the Rockbox bootloaders embedded (see the comments in the Makefile for build instructions). This gives a new --install option which will search for an ipod, and if exactly one is found, will install the embedded bootloader. Even easier is the new interactive mode - running ipodpatcher with no command-line options (e.g. double-clicking on ipodpatcher.exe in Windows) will cause ipodpatcher to search for an ipod, and if exactly one is found, ask the user if he/she wishes to install the bootloader. Thanks to Bryan Childs for sample code to deal with prompts.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12235 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
deb8363751
commit
bdc27ff20c
4 changed files with 374 additions and 84 deletions
|
|
@ -1,5 +1,15 @@
|
|||
CFLAGS=-Wall
|
||||
|
||||
BOOT_H = ipod3g.h ipod4g.h ipodcolor.h ipodmini.h ipodmini2g.h ipodnano.h ipodvideo.h
|
||||
|
||||
# Uncomment the next two lines to build with embedded bootloaders and the
|
||||
# --install option and interactive mode. You need the full set of Rockbox
|
||||
# bootloaders in this directory - download them from
|
||||
# http://download.rockbox.org/bootloader/ipod/bootloaders.zip
|
||||
|
||||
BOOTSRC = ipod3g.c ipod4g.c ipodcolor.c ipodmini.c ipodmini2g.c ipodnano.c ipodvideo.c
|
||||
CFLAGS += -DWITH_BOOTOBJS
|
||||
|
||||
ifeq ($(findstring CYGWIN,$(shell uname)),CYGWIN)
|
||||
OUTPUT=ipodpatcher.exe
|
||||
CROSS=
|
||||
|
|
@ -9,15 +19,43 @@ OUTPUT=ipodpatcher
|
|||
CROSS=i586-mingw32msvc-
|
||||
endif
|
||||
|
||||
NATIVECC = gcc
|
||||
CC = $(CROSS)gcc
|
||||
|
||||
all: $(OUTPUT)
|
||||
|
||||
ipodpatcher: ipodpatcher.c ipodio-posix.c parttypes.h
|
||||
gcc $(CFLAGS) -o ipodpatcher ipodpatcher.c ipodio-posix.c
|
||||
ipodpatcher: ipodpatcher.c ipodio-posix.c parttypes.h $(BOOTSRC)
|
||||
gcc $(CFLAGS) -o ipodpatcher ipodpatcher.c ipodio-posix.c $(BOOTSRC)
|
||||
strip ipodpatcher
|
||||
|
||||
ipodpatcher.exe: ipodpatcher.c ipodio-win32.c parttypes.h
|
||||
$(CROSS)gcc $(CFLAGS) -o ipodpatcher.exe ipodpatcher.c ipodio-win32.c
|
||||
ipodpatcher.exe: ipodpatcher.c ipodio-win32.c parttypes.h $(BOOTSRC)
|
||||
$(CC) $(CFLAGS) -o ipodpatcher.exe ipodpatcher.c ipodio-win32.c $(BOOTSRC)
|
||||
$(CROSS)strip ipodpatcher.exe
|
||||
|
||||
ipod2c: ipod2c.c
|
||||
$(NATIVECC) $(CFLAGS) -o ipod2c ipod2c.c
|
||||
|
||||
ipod3g.c: bootloader-ipod3g.ipod ipod2c
|
||||
./ipod2c bootloader-ipod3g.ipod ipod3g
|
||||
|
||||
ipod4g.c: bootloader-ipod4g.ipod ipod2c
|
||||
./ipod2c bootloader-ipod4g.ipod ipod4g
|
||||
|
||||
ipodcolor.c: bootloader-ipodcolor.ipod ipod2c
|
||||
./ipod2c bootloader-ipodcolor.ipod ipodcolor
|
||||
|
||||
ipodmini.c: bootloader-ipodmini.ipod ipod2c
|
||||
./ipod2c bootloader-ipodmini.ipod ipodmini
|
||||
|
||||
ipodmini2g.c: bootloader-ipodmini2g.ipod ipod2c
|
||||
./ipod2c bootloader-ipodmini2g.ipod ipodmini2g
|
||||
|
||||
ipodnano.c: bootloader-ipodnano.ipod ipod2c
|
||||
./ipod2c bootloader-ipodnano.ipod ipodnano
|
||||
|
||||
ipodvideo.c: bootloader-ipodvideo.ipod ipod2c
|
||||
./ipod2c bootloader-ipodvideo.ipod ipodvideo
|
||||
|
||||
|
||||
clean:
|
||||
rm -f ipodpatcher.exe ipodpatcher *~
|
||||
rm -f ipodpatcher.exe ipodpatcher ipod2c *~ $(BOOTSRC) $(BOOT_H)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue