blob: 1b1489df653210186db2a9acdcf1177f642af05a (
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
26
27
28
29
|
CC ?= gcc
PLUGINDIR ?= $(shell pkg-config --variable=plugindir purple)
CFLAGS += -Wall -fPIC
LDFLAGS += -shared
CPPFLAGS += $(shell pkg-config --cflags glib-2.0 json-glib-1.0 purple)
LIBS += $(shell pkg-config --libs glib-2.0 json-glib-1.0 purple)
TARGET = libsteam.so
OBJS = libsteam.o steam_connection.o
%.o: %.c %.h
$(CC) $(CFLAGS) $(CPPFLAGS) -c $*.c
$(TARGET): $(OBJS)
$(CC) $(LDFLAGS) $(CFLAGS) -o $@ $(OBJS) $(LIBS)
install: $(TARGET)
@install -Dm755 $(TARGET) "$(DESTDIR)$(PLUGINDIR)/$(TARGET)"
uninstall:
@rm -f "$(DESTDIR)$(PLUGINDIR)/$(TARGET)"
clean:
@rm -f $(OBJS) $(TARGET)
.PHONY: uninstall clean
|