1 | |
---|
2 | TARGETS = pymolproxy pymolproxy2 |
---|
3 | |
---|
4 | CC = @CC@ |
---|
5 | CC_SWITCHES = $(CFLAGS) $(EXTRA_CFLAGS) $(DEFINES) $(INCLUDES) |
---|
6 | CFLAGS = @CFLAGS@ |
---|
7 | DEFINES = -DSTANDALONE \ |
---|
8 | -DSVN_VERSION=\"$(SVN_VERSION)\" \ |
---|
9 | -DSTATSDIR=\"$(STATSDIR)\" |
---|
10 | EXTRA_CFLAGS = -Wall |
---|
11 | INCLUDES = $(TCL_INC_SPEC) -I$(srcdir) |
---|
12 | TCL_INC_SPEC = @TCL_INC_SPEC@ |
---|
13 | TCL_LIB_SPEC = @TCL_LIB_SPEC@ |
---|
14 | |
---|
15 | bindir = @bindir@ |
---|
16 | datadir = @datadir@ |
---|
17 | datarootdir = @datarootdir@ |
---|
18 | exec_prefix = @exec_prefix@ |
---|
19 | includedir = @includedir@ |
---|
20 | libdir = @libdir@ |
---|
21 | mandir = @mandir@ |
---|
22 | prefix = @prefix@ |
---|
23 | srcdir = @srcdir@ |
---|
24 | |
---|
25 | INSTALL = @INSTALL@ |
---|
26 | MKDIR_P = @MKDIR_P@ |
---|
27 | VPATH = $(srcdir) |
---|
28 | |
---|
29 | SVN_VERSION = $(shell svnversion $(srcdir)) |
---|
30 | STATSDIR = @STATSDIR@ |
---|
31 | |
---|
32 | .PHONY: all install clean distclean |
---|
33 | |
---|
34 | FILES = pymolproxy pymolproxy2 |
---|
35 | PROXY_OBJS = pymolproxy.o md5.o |
---|
36 | PROXY2_OBJS = pymolproxy2.o md5.o |
---|
37 | LIBS = $(TCL_LIB_SPEC) \ |
---|
38 | -Wl,-rpath,$(libdir) |
---|
39 | |
---|
40 | SCRIPTS = $(srcdir)/scripts/box.py |
---|
41 | |
---|
42 | all: $(TARGETS) |
---|
43 | |
---|
44 | pymolproxy: $(PROXY_OBJS) |
---|
45 | $(CC) $(CC_SWITCHES) -o $@ $^ $(LIBS) |
---|
46 | |
---|
47 | pymolproxy2: $(PROXY2_OBJS) |
---|
48 | $(CC) $(CC_SWITCHES) -o $@ $^ $(LIBS) -lpthread |
---|
49 | |
---|
50 | .c.o: |
---|
51 | $(CC) $(CC_SWITCHES) -o $@ -c $< |
---|
52 | |
---|
53 | install: install-pymolproxy install-scripts |
---|
54 | |
---|
55 | install-pymolproxy: pymolproxy pymolproxy2 |
---|
56 | $(MKDIR_P) -m 0755 $(bindir) |
---|
57 | for i in $(FILES) ; do \ |
---|
58 | $(INSTALL) -m 0555 $$i $(bindir) ; \ |
---|
59 | done |
---|
60 | |
---|
61 | install-scripts: |
---|
62 | $(MKDIR_P) -m 0755 $(libdir)/pymol/rappture |
---|
63 | for i in $(SCRIPTS) ; do \ |
---|
64 | $(INSTALL) -m 0555 $$i $(libdir)/pymol/rappture; \ |
---|
65 | done |
---|
66 | |
---|
67 | clean: |
---|
68 | $(RM) a.out *.o *~ core* $(TARGETS) *.log *.tmp logfile* .deps/*.d |
---|
69 | |
---|
70 | distclean: clean |
---|
71 | $(RM) Makefile pymol |
---|