diff options
author | John van Groningen | 2003-10-03 15:04:29 +0000 |
---|---|---|
committer | John van Groningen | 2003-10-03 15:04:29 +0000 |
commit | 2074fa88d1f6e40d8869e4ab3cfd5f1afd57348c (patch) | |
tree | 0eabb651c75167cebf658fc018bb24379f86f152 /Makefile.linux | |
parent | omit windows exception handler for linux, add some sections for optimised lin... (diff) |
add makefiles for linux
Diffstat (limited to 'Makefile.linux')
-rw-r--r-- | Makefile.linux | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/Makefile.linux b/Makefile.linux new file mode 100644 index 0000000..6809c36 --- /dev/null +++ b/Makefile.linux @@ -0,0 +1,34 @@ + +SDIR = ./ +ODIR = ./ + +DEFINES = -DUSE_CLIB -DLINUX -DI486 -DGNU_C -DELF +DEFINESA = -D USE_CLIB -D LINUX -D I486 -D GNU_C -D ELF + +all: $(ODIR)_startup.o + +$(ODIR)_startup.o: $(ODIR)istartup.o $(ODIR)ifileIO3.o $(ODIR)scon.o $(ODIR)ufileIO2.o $(ODIR)uwrite_heap.o + ld -r -o $(ODIR)_startup.o $(ODIR)istartup.o $(ODIR)scon.o $(ODIR)ifileIO3.o $(ODIR)ufileIO2.o uwrite_heap.o + +$(ODIR)scon.o: $(SDIR)scon.c +# gcc -c -O $(DEFINES) -o $(ODIR)scon.o $(SDIR)scon.c + $(CC) -O $(DEFINES) -ffunction-sections -fdata-sections $(SDIR)scon.c -S -o $(ODIR)scon.s + mv $(ODIR)scon.s $(ODIR)scon.s.copy + grep -v -w ___main $(ODIR)scon.s.copy > $(ODIR)scon.s + as $(DEFINES_A) $(ODIR)scon.s -o $(ODIR)scon.o + +$(ODIR)ufileIO2.o: $(SDIR)ufileIO2.c + gcc -c -O $(DEFINES) -ffunction-sections -fdata-sections -o $(ODIR)ufileIO2.o $(SDIR)ufileIO2.c + +$(ODIR)istartup.o: $(SDIR)istartup.s + cp $(ODIR)istartup.s $(ODIR)istartup.cpp + $(CC) $(DEFINES) -E $(ODIR)istartup.cpp > $(ODIR)istartup.t + sed s/@// < $(SDIR)/istartup.t > $(ODIR)istartup.a + as $(DEFINES_A) $(ODIR)istartup.a -o $(ODIR)istartup.o + +$(ODIR)ifileIO3.o: $(SDIR)ifileIO3.s + cp $(ODIR)ifileIO3.s $(ODIR)ifileIO3.cpp + $(CC) $(DEFINES) -E $(ODIR)ifileIO3.cpp > $(ODIR)ifileIO3.t + sed s/@// < $(SDIR)/ifileIO3.t > $(ODIR)ifileIO3.a + as $(DEFINES_A) $(ODIR)ifileIO3.a -o $(ODIR)ifileIO3.o + |