

SHELL = /bin/sh
CC = gcc
INSTALL = /bin/cp -r
INSTALLDIR = $(DESTDIR)/usr/lib/GNUstep/Apps/Aileron.app
IMAGES = images
MISCFILES = AUTHORS.html


TARGET=Aileron

CFLAGS= `get-wings-flags --cflags` -I. -I/usr/include/c-client -Wall \
#-Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion \
#-Werror



LDFLAGS=`get-wings-flags --ldflags` -L/usr/X11R6/lib

LIBS= `get-wings-flags --libs` -lWMaker -lc-client -lcrypt  
#-lefence

MODULES = Addresses.o Aileron.o Composer.o Find.o HTMLParser.o Info.o \
MailBox.o Mailboxes.o Menu.o Preferences.o TimeStamp.o  HTMLWriter.o

all: $(TARGET)

install:
	strip $(TARGET)
	mkdir -p $(INSTALLDIR)
	$(INSTALL)  $(TARGET) $(MISCFILES) $(IMAGES) $(INSTALLDIR)

clean:
	rm -f $(MODULES) $(TARGET) core  *~

distclean:
	rm -f $(MODULES) $(TARGET) core 

$(TARGET): $(MODULES) Aileron.h
	$(CC) -g -o $(TARGET) $(MODULES) $(LIBS) $(LDFLAGS)

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

