]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/plugins/fd/Makefile
Add src/plugins/fd/Makefile to ./configure process
[bacula/bacula] / bacula / src / plugins / fd / Makefile
1 #
2 # Simple Makefile for building test FD plugins for Bacula
3 #
4 # Version $Id: $
5 #
6 #
7 # This file is pulled in by all the Unix Bacula Makefiles
8 #   so it has all the "common" definitions
9 #
10
11 DATE="24 September 2008"
12 LSMDATE=24Sep08
13 VERSION=2.5.3
14 VERNAME=bacula-$(VERSION)#
15 MAINT=Kern Sibbald#
16 MAINTEMAIL=<kern@sibbald.com>#
17 WEBMAINT=#
18 WEBMAINTEMAIL=#
19 WEBPAGE=#
20 FTPSITENAME=#
21 FTPSITEDIR=#
22 #-------------------------------------------------------------------------
23
24 SHELL = /bin/sh
25
26 # Installation target directories & other installation stuff
27 prefix = 
28 exec_prefix = 
29 binprefix =
30 manprefix =
31 datarootdir = ${prefix}/share
32 sbindir = /home/kern/bacula/bin
33 sysconfdir = /home/kern/bacula/bin
34 scriptdir = /home/kern/bacula/bin
35 mandir = /home/kern/bacula/bin
36 manext = 8
37
38 NO_ECHO = @
39
40 # Tools & program stuff
41 CC = gcc
42 CPP = gcc -E
43 CXX = /usr/bin/g++
44 MV = /bin/mv
45 RM = /bin/rm
46 RMF = /bin/rm -f
47 CP = /bin/cp
48 SED = /bin/sed
49 AWK = /usr/bin/mawk
50 ECHO = /bin/echo
51 CMP = /usr/bin/cmp
52 TBL = /usr/bin/tbl
53 AR = /usr/bin/ar
54 RANLIB = ranlib
55 MKDIR = /home/kern/bacula/k/autoconf/mkinstalldirs
56 INSTALL = /usr/bin/install -c
57 # add the -s to the following in PRODUCTION mode
58 INSTALL_PROGRAM = /usr/bin/install -c -m 0754
59 INSTALL_DATA = /usr/bin/install -c -m 644
60 INSTALL_SCRIPT = /usr/bin/install -c -m 0754
61 INSTALL_CONFIG = /usr/bin/install -c -m 640
62
63 # Flags & libs
64 CFLAGS = -g -O2 -Wall -fno-strict-aliasing -fno-exceptions -fno-rtti 
65
66 CPPFLAGS =  -fno-strict-aliasing -fno-exceptions -fno-rtti 
67 LDFLAGS = 
68 TTOOL_LDFLAGS = 
69 #DEFS = -DHAVE_CONFIG_H 
70 LIBS = -lpthread -ldl 
71 WRAPLIBS = -lwrap
72 DINCLUDE = 
73 DLIB = 
74 DB_LIBS = -L/home/kern/bacula/depkgs/sqlite3 -lsqlite3
75 PYTHON_LIBS = -L/usr/lib/python2.5/config -lpython2.5 -lutil -lrt 
76 PYTHON_INC = -I/usr/include/python2.5
77 OPENSSL_LIBS = -lssl -lcrypto
78 BDB_CPPFLAGS = 
79 BDB_LIBS = 
80
81
82 # Windows (cygwin) flags 
83 WCFLAGS = 
84 WLDFLAGS = 
85
86 # X Include directory
87 #XINC =  @XPM_CFLAGS@
88
89 # extra libraries needed by X on some systems, X library location
90 #XLIB =  @XPM_LIBS@ -lX11 
91
92 # End of common section of the Makefile
93 #-------------------------------------------------------------------------
94
95
96 # No optimization for now for easy debugging
97
98 FDDIR=../../filed
99 SRCDIR=../..
100 LIBDIR=../../lib
101
102 .SUFFIXES:    .c .o
103 .c.o:
104         $(CXX) $(DEFS) $(DEBUG) $(CPPFLAGS) -I${SRCDIR} -I${FDDIR} -DTEST_PROGRAM -c $<
105
106 all: bpipe-fd.so
107
108 test: main example-plugin-fd.so
109
110 fd_plugins.o: ${FDDIR}/fd_plugins.h ${FDDIR}/fd_plugins.c
111         $(CXX) -I${SRCDIR} -I${FDDIR} -DTEST_PROGRAM -c ${FDDIR}/fd_plugins.c 
112
113 main: fd_plugins.o
114         $(CXX) $(LDFLAGS) -L${LIBDIR} fd_plugins.o -o main -lbac -lpthread -lssl -l crypto -ldl
115
116 example-plugin-fd.o: example-plugin-fd.c ${FDDIR}/fd_plugins.h
117         $(CXX) -fPIC -I../.. -I${FDDIR} -c example-plugin-fd.c
118
119 example-plugin-fd.so: example-plugin-fd.o 
120         $(CXX) $(LDFLAGS) -shared example-plugin-fd.o -o example-plugin-fd.so
121
122 bpipe-fd.o: bpipe-fd.c ${FDDIR}/fd_plugins.h
123         $(CXX) $(DEFS) $(DEBUG) $(CPPFLAGS) -fPIC -I../.. -I${FDDIR} -c bpipe-fd.c
124
125 bpipe-fd.so: bpipe-fd.o 
126         $(CXX) $(LDFLAGS) -shared bpipe-fd.o -o bpipe-fd.so
127
128 clean:
129         rm -f main *.so *.o 1 2 3