mirror of
https://github.com/vivier/EMILE.git
synced 2024-09-08 19:54:38 +00:00
apple_driver: initial revision
This commit is contained in:
parent
e101bf5337
commit
e9c96014f4
37
apple_driver/Makefile
Normal file
37
apple_driver/Makefile
Normal file
@ -0,0 +1,37 @@
|
||||
#
|
||||
#
|
||||
# (c) 2004,2005 Laurent Vivier <Laurent@lvivier.info>
|
||||
#
|
||||
#
|
||||
|
||||
TOP = $(shell pwd)
|
||||
VPATH = $(TOP)
|
||||
|
||||
ASFLAGS = -I$(TOP)
|
||||
|
||||
CFLAGS = $(OPT_CFLAGS) -nostdlib -nodefaultlibs -Wall -Werror -Wno-multichar -fpic -O2
|
||||
|
||||
SOURCES = head.S
|
||||
|
||||
.PHONY: all
|
||||
|
||||
all: apple_driver
|
||||
|
||||
apple_driver: apple_driver.o
|
||||
$(OBJCOPY) -j .text -j .data -j .rodata -j .got \
|
||||
-O binary apple_driver.o apple_driver
|
||||
|
||||
apple_driver.o: head.o
|
||||
$(LD) -o apple_driver.o head.o
|
||||
|
||||
.S.o:
|
||||
$(AS) $(ASFLAGS) -o $@ $^
|
||||
|
||||
install::
|
||||
install -d $(DESTDIR)/$(PREFIX)/lib/emile/
|
||||
install first_floppy $(DESTDIR)/$(PREFIX)/lib/emile/apple_driver
|
||||
|
||||
uninstall::
|
||||
rm -f $(DESTDIR)/$(PREFIX)/lib/emile/apple_driver
|
||||
|
||||
include $(TOP)/../Rules.mk
|
47
apple_driver/head.S
Normal file
47
apple_driver/head.S
Normal file
@ -0,0 +1,47 @@
|
||||
/*
|
||||
*
|
||||
* (c) 2006 Laurent Vivier <Laurent@lvivier.info>
|
||||
*
|
||||
* based on http://developer.apple.com/technotes/tn/tn1189.html
|
||||
*
|
||||
*/
|
||||
|
||||
.chip 68000
|
||||
.align 4
|
||||
|
||||
.global _start
|
||||
_start:
|
||||
primary_entry_point:
|
||||
bra.w primary_setup
|
||||
dc.w 0x0001
|
||||
|
||||
secondary_entry_point:
|
||||
bra.w secondary_setup
|
||||
|
||||
_driver_name:
|
||||
.string ".DebianCD"
|
||||
_version:
|
||||
dc.w 0x001
|
||||
_id:
|
||||
.string "Debian SCSI 0.0.1"
|
||||
|
||||
.string "Dummy AppleDriver for Debian boot CD"
|
||||
.string "(c) 2006 Laurent Vivier <Laurent@lvivier.info>"
|
||||
.string "All files are distributed under the terms of GPLv2 license."
|
||||
|
||||
.align 4
|
||||
primary_setup:
|
||||
ori.l #0x0f000000, %d5
|
||||
|
||||
secondary_setup:
|
||||
|
||||
movem.l %d1-%a4,%sp@-
|
||||
move.l %d5, %sp@-
|
||||
jsr %pc@(driver_entry)
|
||||
add.l #4, %sp
|
||||
movem.l %sp@+, %d1-%a4
|
||||
rts
|
||||
|
||||
driver_entry:
|
||||
moveq.l #0, %d0
|
||||
rts
|
Loading…
Reference in New Issue
Block a user