parser/calc/Makefile
author Markus Bröker <mbroeker@largo.dyndns.tv>
Tue, 19 May 2009 02:58:59 +0200
changeset 93 66b3596f71b6
parent 66 2b4f786d9073
permissions -rw-r--r--
make cross_getch invisible the cross_getch function will be called from the JNI Wrapper and must not be visible to others committer: Markus Bröker <mbroeker@largo.homelinux.org>

      CC = gcc
      LD = ld
    YACC = bison -y
    FLEX = flex
  CFLAGS = -Wall -O2 -ansi -D_XOPEN_SOURCE=500
 LDFLAGS =
 INCLUDE = -Iinclude

OBJECTS  = main.o
OBJECTS += parser.o
OBJECTS += lexer.o

TARGET = calc

.SUFFIXES: .c .y .l

.c.o:
	$(CC) -c $(CFLAGS) $(INCLUDE) $(CONFIG) $<

.y.c:
	$(YACC) -d $< -o $@

.l.c:
	$(FLEX) -o $@ $<

all: $(TARGET)


$(TARGET): $(OBJECTS)
	$(CC) $(CFLAGS) $(LDFLAGS) $(OBJECTS) -o $@

.PHONY: distclean clean

clean:
	rm -f *.[oae];
	rm -f *~;
	rm -f parser.h

distclean:
	make clean
	rm -f $(TARGET)