1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53
|
.SUFFIXES: .i
# edit any of the following if they dont apply to toyur system
CC = gcc
AS = as
MAKE = make
INSTALL = install
# you can leave this as is....
SRCS = test.c
OBJS = $(SRCS:.c=.o)
# change these options as you need for maximum optimisation on your system
CCOPTIONS = \
-m486 \
-O2 \
-funroll-all-loops \
-malign-loops=2 \
-malign-jumps=2 \
-malign-functions=2 \
-ffast-math \
-Winline \
-g \
-I. \
-I/usr/X11/include \
-I/usr/X11R6/include \
-I/usr/openwin/include \
test: $(OBJS)
$(RM) $@
$(CC) -o $@ $(OBJS) \
-L/usr/X11R6/lib -L/usr/local/lib \
-L/usr/openwin/lib \
-lX11 -lXext -lXtst -lFnlib -lImlib -ljpeg -ltiff -lpng -lz -lm -lgif
clean::
$(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut "#"*
.c.o:
$(CC) $(CCOPTIONS) -c $< -o $@
clean::
$(RM) test
install:: test
$(INSTALL) test $(DESTDIR)
|