Skip to content
Snippets Groups Projects
Commit d3be60db authored by Vikram S. Adve's avatar Vikram S. Adve
Browse files

Make gcc generate assembly files (%.ll) until Chris has a stable

version of his gccas.  Plus another dumb bug fix (the bug, not the fix).

llvm-svn: 1134
parent 4d04e000
No related branches found
No related tags found
No related merge requests found
## -*-Makefile-*-
##------------------------------------------------------------------------
## Common rules for generating, linking, and compiling via LLVM.
##------------------------------------------------------------------------
.PHONY: clean default .PHONY: clean default
## Special targets to build a program from multiple source files ## Special targets to build a program from multiple source files
...@@ -20,7 +25,7 @@ LLINK = $(TOOLS)/link ...@@ -20,7 +25,7 @@ LLINK = $(TOOLS)/link
LLCFLAGS = LLCFLAGS =
LCC = /home/vadve/lattner/cvs/gcc_install/bin/gcc LCC = /home/vadve/lattner/cvs/gcc_install/bin/gcc
LCFLAGS = -DTORONTO -O2 $(LOCAL_CFLAGS) -Wall LCFLAGS = -O2 $(LOCAL_CFLAGS) -Wall
LLCLIB = $(LEVEL)/test/runtime.o LLCLIB = $(LEVEL)/test/runtime.o
LIBS = $(LLCLIB) $(LOCAL_LIBS) LIBS = $(LLCLIB) $(LOCAL_LIBS)
...@@ -58,7 +63,8 @@ clean : ...@@ -58,7 +63,8 @@ clean :
$(LLC) -f -trace $(LLCFLAGS) $< $(LLC) -f -trace $(LLCFLAGS) $<
%.o: %.c %.o: %.c
$(LCC) $(LCFLAGS) -c $< $(LCC) $(LCFLAGS) -S -o $*.ll $<
$(LAS) -o $@ $*.ll
%.bc: %.ll %.bc: %.ll
$(LAS) -f $< $(LAS) -f $<
......
## -*-Makefile-*-
##------------------------------------------------------------------------
## Common rules for generating, linking, and compiling via LLVM.
##------------------------------------------------------------------------
.PHONY: clean default .PHONY: clean default
## Special targets to build a program from multiple source files ## Special targets to build a program from multiple source files
...@@ -20,7 +25,7 @@ LLINK = $(TOOLS)/link ...@@ -20,7 +25,7 @@ LLINK = $(TOOLS)/link
LLCFLAGS = LLCFLAGS =
LCC = /home/vadve/lattner/cvs/gcc_install/bin/gcc LCC = /home/vadve/lattner/cvs/gcc_install/bin/gcc
LCFLAGS = -DTORONTO -O2 $(LOCAL_CFLAGS) -Wall LCFLAGS = -O2 $(LOCAL_CFLAGS) -Wall
LLCLIB = $(LEVEL)/test/runtime.o LLCLIB = $(LEVEL)/test/runtime.o
LIBS = $(LLCLIB) $(LOCAL_LIBS) LIBS = $(LLCLIB) $(LOCAL_LIBS)
...@@ -58,7 +63,8 @@ clean : ...@@ -58,7 +63,8 @@ clean :
$(LLC) -f -trace $(LLCFLAGS) $< $(LLC) -f -trace $(LLCFLAGS) $<
%.o: %.c %.o: %.c
$(LCC) $(LCFLAGS) -c $< $(LCC) $(LCFLAGS) -S -o $*.ll $<
$(LAS) -o $@ $*.ll
%.bc: %.ll %.bc: %.ll
$(LAS) -f $< $(LAS) -f $<
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment