summaryrefslogtreecommitdiffstats
path: root/utils/regtools/Makefile
blob: 6ed827e257702a60c00e70fce55b78dd1b873b20 (plain)
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
DEFINES=
CC=gcc
CXX=g++
LD=g++
CFLAGS=-g -std=c99 -Wall $(DEFINES) -Ilib
CXXFLAGS=-g -Wall $(DEFINES) -Ilib
LDFLAGS=-Llib -lsocdesc `xml2-config --libs`
SRC=$(wildcard *.c)
SRCXX=$(wildcard *.cpp)
EXEC=$(SRC:.c=) $(SRCXX:.cpp=)
LIB=lib/libsocdesc.a

all: $(EXEC)

$(LIB):
	make -C lib

%: %.c $(LIB)
	$(CC) $(CFLAGS) -o $@ $< $(LDFLAGS)

%: %.cpp $(LIB)
	$(CXX) $(CXXFLAGS) -o $@ $< $(LDFLAGS)

clean:
	rm -fr $(EXEC)