1#
2# GRX test programs makefile for LINUX/console.
3# Uses GNU make.
4#
5.SUFFIXES: .exe
6.PHONY: clean
7
8GRXVLNX=y
9
10include ../../makedefs.grx
11
12# The following line is useful only in this makefile to force recompilation
13GRXLIB = ../../lib/$(GRX_LIB_SUBDIR)/libgrx20.a
14# In normal use the library libgrx20.a or libgrx20.so is linked in through
15# {$L grx20} contained in the unit graph.pas called by "uses graph".
16# The same is valid for other ADDON libraries.
17# If the library is NOT installed give its path
18# (default when first compiling/testing the library)
19GRXLIBPATH = -L../../lib/$(GRX_LIB_SUBDIR)
20# When it is installed in a standard system location
21# (normal use) this is no more necessary
22
23ifeq ($(SET_SUIDROOT),y)
24EXECBITS = 4755
25else
26EXECBITS = 0755
27endif
28
29LIBS= $(GRXLIBPATH)
30
31# Compiler and options on your system
32COMPILER = $(PC) --automake
33
34PROGS= 			\
35	allmodes	\
36	modelist	\
37	colors		\
38	demo		\
39	small		\
40	palette
41
42all: $(PROGS)
43
44$(PROGS): % : %.pas $(GRXLIB) graph.pas
45	$(COMPILER) $(CCOPT) -o $* $*.pas $(LIBS)
46	chmod $(EXECBITS) $@
47
48clean:
49	rm -f *.o *.gpi *.gpm $(PROGS)
50
51