summaryrefslogtreecommitdiff
path: root/sample/Makefile
diff options
context:
space:
mode:
authorhpa <hpa>2002-06-11 05:48:29 +0000
committerhpa <hpa>2002-06-11 05:48:29 +0000
commitabac6f53695c0b99e0235ca3da81ab3cd822f475 (patch)
tree42c9c90abcb685ec654b25e680f6a0e272d1fe52 /sample/Makefile
parent73d0682dcdd250939e560d333b591d7a5a8299ca (diff)
downloadsyslinux-abac6f53695c0b99e0235ca3da81ab3cd822f475.tar.gz
Add an API for COMBOOT images, and add support for "COM32" -- 32-bit
linear .com files.
Diffstat (limited to 'sample/Makefile')
-rw-r--r--sample/Makefile18
1 files changed, 17 insertions, 1 deletions
diff --git a/sample/Makefile b/sample/Makefile
index f4ad1bcf..e6b648a0 100644
--- a/sample/Makefile
+++ b/sample/Makefile
@@ -15,15 +15,31 @@
## samples for syslinux users
##
+CC = gcc
+LD = ld
+CFLAGS = -O2 -fomit-frame-pointer -I..
+LDFLAGS = -s
+OBJCOPY = objcopy
PPMTOLSS16 = ../ppmtolss16
-all: syslogo.lss
+.SUFFIXES: .lss .c .o .elf .c32
+
+all: syslogo.lss hello.c32
+
+.c.o:
+ $(CC) $(CFLAGS) -c -o $@ $<
+
+.elf.c32:
+ $(OBJCOPY) -O binary $< $@
syslogo.lss: syslogo.png $(PPMTOLSS16)
pngtopnm syslogo.png | \
$(PPMTOLSS16) \#000000=0 \#d0d0d0=7 \#f6f6f6=15 \
> syslogo.lss
+hello.elf: hello.o
+ $(LD) -Ttext 0x101000 -e _start -o $@ $<
+
clean:
rm -f *.lss