asm/Makefile
author Markus Bröker <mbroeker@largo.dyndns.tv>
Sat, 13 Dec 2008 17:58:05 +0100
changeset 12 9f0ce4eaa1ce
parent 5 d752cbe8208e
child 66 2b4f786d9073
permissions -rw-r--r--
I added a small db_bridge to the repository committer: Markus Bröker <mbroeker@largo.homelinux.org>

CC=gcc -g -ggdb
CFLAGS=-Wall -O2 -Iinclude
LDFLAGS=
NASM=nasm -f elf -Iinclude/
TARGET=stackinfo
OBJECTS=main.o get_sp.o

.SUFFIXES: .c .asm

.c.o:
	@echo Compiling $< ...
	@$(CC) -c $(CFLAGS) -o $@ $<

.asm.o:
	@echo Assembling $< ...
	@$(NASM) $< -o $@

all: $(TARGET) decimal

$(TARGET): $(OBJECTS)
	@echo Linking $(OBJECTS) ...
	@$(CC) $(LDFLAGS) $(OBJECTS) -o $@

decimal: decimal.o
	$(CC) $(CFLAGS) -o $@ $<

.PHONY: clean uninstall

clean:
	rm -f $(TARGET) decimal *.o *~

install: $(TARGET) decimal
	install -d ~/bin
	install $(TARGET) decimal ~/bin

uninstall:
	rm -f ~/bin/decimal
	rm -f ~/bin/$(TARGET)