]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/win32/dird/Makefile
Restore win32 dir from Branch-5.2 and update it
[bacula/bacula] / bacula / src / win32 / dird / Makefile
1 #
2 # Makefile for win32 bacula executables
3 # Using MinGW cross-compiler on GNU/Linux
4 #
5 #
6 # Author: Robert Nelson
7 # License: BSD 2-Clause; see file LICENSE-FOSS
8 #
9 #  Written by Robert Nelson, June 2006
10 #
11
12 include ../Makefile.inc
13
14 INCLUDES = \
15         -I. \
16         $(INCLUDE_PTHREADS) \
17         $(INCLUDE_BACULA) \
18         $(INCLUDE_ZLIB) \
19         $(INCLUDE_OPENSSL) \
20         $(INCLUDE_ICONS)
21
22 DEFINES = \
23         -DUSING_DLL \
24         -DUSING_CATS \
25         -DWINVER=0x500 \
26         $(HAVES)
27
28 vpath %.c $(MAINDIR)/src/dird $(BUILDDIR)/libwin32
29 vpath %.cpp $(MAINDIR)/src/dird $(BUILDDIR)/libwin32
30
31 ##########################################################################
32
33 DIRD_OBJS = \
34         $(OBJDIR)/admin.o \
35         $(OBJDIR)/authenticate.o \
36         $(OBJDIR)/autoprune.o \
37         $(OBJDIR)/backup.o \
38         $(OBJDIR)/bsr.o \
39         $(OBJDIR)/catreq.o \
40         $(OBJDIR)/dir_plugins.o \
41         $(OBJDIR)/dird.o \
42         $(OBJDIR)/dird_conf.o \
43         $(OBJDIR)/expand.o \
44         $(OBJDIR)/fd_cmds.o \
45         $(OBJDIR)/getmsg.o \
46         $(OBJDIR)/inc_conf.o \
47         $(OBJDIR)/job.o \
48         $(OBJDIR)/jobq.o \
49         $(OBJDIR)/mountreq.o \
50         $(OBJDIR)/msgchan.o \
51         $(OBJDIR)/newvol.o \
52         $(OBJDIR)/next_vol.o \
53         $(OBJDIR)/recycle.o \
54         $(OBJDIR)/restore.o \
55         $(OBJDIR)/run_conf.o \
56         $(OBJDIR)/scheduler.o \
57         $(OBJDIR)/ua_acl.o \
58         $(OBJDIR)/ua_cmds.o \
59         $(OBJDIR)/ua_dotcmds.o \
60         $(OBJDIR)/ua_input.o \
61         $(OBJDIR)/ua_label.o \
62         $(OBJDIR)/ua_output.o \
63         $(OBJDIR)/ua_prune.o \
64         $(OBJDIR)/ua_purge.o \
65         $(OBJDIR)/ua_query.o \
66         $(OBJDIR)/ua_restore.o \
67         $(OBJDIR)/ua_run.o \
68         $(OBJDIR)/ua_select.o \
69         $(OBJDIR)/ua_server.o \
70         $(OBJDIR)/ua_status.o \
71         $(OBJDIR)/ua_tree.o \
72         $(OBJDIR)/ua_update.o \
73         $(OBJDIR)/ua_dde.o \
74         $(OBJDIR)/vbackup.o \
75         $(OBJDIR)/verify.o \
76         $(OBJDIR)/service.o \
77         $(OBJDIR)/mac_sql.o \
78         $(OBJDIR)/mac.o \
79         $(OBJDIR)/main.o \
80         $(OBJDIR)/bacula.res
81
82 ALL_OBJS = $(DIRD_OBJS)
83
84
85 DIRD_LIBS = \
86         $(LIBS_PTHREADS) \
87         $(LIBS_NETWORK) \
88         -lole32 \
89         -loleaut32 \
90         -luuid \
91         -lcomctl32
92
93 ######################################################################
94
95 # Targets
96
97 .PHONY: all clean
98
99 all: $(BINDIR)/bacula-dir.exe
100
101 clean:
102         @echo "Cleaning `pwd`"
103         $(call clean_obj,$(ALL_OBJS))
104         $(call clean_exe,$(BINDIR)/bacula-dir.exe)
105         $(ECHO_CMD)rm -rf $(OBJDIRS)
106
107 #
108 # Rules
109 #
110
111 $(BINDIR)/bacula-dir.exe: $(DIRD_OBJS) $(LIBS_CATS) $(LIBS_BACULA)
112         $(call link_winapp,$(DIRD_LIBS))
113
114 $(OBJDIR)/winres.res: winres.rc
115         $(WINDRES) $(INCLUDE_ICONS) -O coff $< -o $@
116
117 include ../Makefile.rules