hlswmaster/Makefile
2006-02-02 16:27:19 +01:00

24 lines
578 B
Makefile

# Toplevel Makefile
MASTER_SRC := src/client.c src/daemon.c src/logging.c src/main.c src/plugin.c src/plugin_helper.c src/scanner.c src/serverlist.c
PLUGIN_SRC := plugins/hlswproxy.c plugins/quake3.c
CFLAGS := -Wall -I. -I./include -g
# ############################
all: $(PLUGIN_SRC:%.c=%.so) src/hlswmaster
src/hlswmaster: $(MASTER_SRC:%.c=%.o)
gcc -ldl -lpthread -rdynamic $^ -o $@
%.o: %.c
$(CC) $(CFLAGS) -o $@ -c $<
%_sh.o: %.c
$(CC) $(CFLAGS) -fPIC -o $@ -c $<
%.so: %_sh.o
$(LD) -shared -o $@ $<
clean:
rm -rf src/hlswmaster src/*.o plugins/*.so plugins/*.o