Vendor/product comparisons are too broad
[platform/upstream/multipath-tools.git] / Makefile.inc
1 # Makefile.inc
2 #
3 # Copyright (C) 2004 Christophe Varoqui, <christophe.varoqui@opensvc.com>
4
5 #
6 # Allow to force some libraries to be used statically. (Uncomment one of the
7 # following lines or define the values when calling make.)
8 #
9 # WITH_LOCAL_LIBDM      = 1
10 # WITH_LOCAL_LIBSYSFS   = 1
11
12 ifeq ($(TOPDIR),)
13         TOPDIR  = ..
14 endif
15
16 ifndef LIB
17         ifeq ($(shell test -d /lib64 && echo 1),1)
18                 LIB=lib64
19         else
20                 LIB=lib
21         endif
22 endif
23
24 prefix      = 
25 exec_prefix = $(prefix)
26 bindir      = $(exec_prefix)/sbin
27 libudevdir  = ${prefix}/lib/udev
28 multipathdir = $(TOPDIR)/libmultipath
29 mandir      = $(prefix)/usr/share/man/man8
30 man5dir     = $(prefix)/usr/share/man/man5
31 rcdir       = $(prefix)/etc/init.d
32 syslibdir   = $(prefix)/$(LIB)
33 libdir      = $(prefix)/$(LIB)/multipath
34 unitdir     = $(prefix)/lib/systemd/system
35
36 GZIP        = /bin/gzip -9 -c
37 INSTALL_PROGRAM = install
38
39 OPTFLAGS     = -pipe -g -Wall -Wunused -Wstrict-prototypes
40 CFLAGS       = $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\"
41 SHARED_FLAGS = -shared
42
43 %.o:    %.c
44         $(CC) $(CFLAGS) -c -o $@ $<
45