2009-03-06 19:19:52 +03:00
#
# Copyright (C) 2001-2004 Sistina Software, Inc. All rights reserved.
2013-07-13 00:40:10 +04:00
# Copyright (C) 2004-2013 Red Hat, Inc. All rights reserved.
2009-03-06 19:19:52 +03:00
#
# This file is part of LVM2.
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions
# of the GNU General Public License v.2.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
srcdir = @srcdir@
top_srcdir = @top_srcdir@
2009-10-02 23:10:31 +04:00
top_builddir = @top_builddir@
2009-03-06 19:19:52 +03:00
SOURCES = \
2010-02-24 21:16:10 +03:00
lvm_misc.c \
2013-07-13 00:40:10 +04:00
lvm_prop.c \
2009-07-14 07:02:14 +04:00
lvm_base.c \
2009-07-24 03:40:05 +04:00
lvm_lv.c \
lvm_pv.c \
2009-07-14 07:02:14 +04:00
lvm_vg.c
2009-03-06 19:19:52 +03:00
2009-05-22 18:44:59 +04:00
LIB_NAME = liblvm2app
2009-07-23 00:12:14 +04:00
LIB_VERSION = $( LIB_VERSION_APP)
2009-03-06 19:19:52 +03:00
2009-04-08 18:04:35 +04:00
i f e q ( "@STATIC_LINK@" , "yes" )
2009-07-23 01:09:13 +04:00
LIB_STATIC = $( LIB_NAME) .a
e n d i f
2010-04-10 01:42:48 +04:00
LIB_SHARED = $( LIB_NAME) .$( LIB_SUFFIX)
2009-03-06 19:19:52 +03:00
2010-04-10 01:42:48 +04:00
CLEAN_TARGETS += liblvm.cflow $( LIB_NAME) .a
2009-03-06 19:19:52 +03:00
2010-06-25 22:17:38 +04:00
EXPORTED_HEADER = $( srcdir) /lvm2app.h
EXPORTED_FN_PREFIX = lvm
2012-02-08 14:52:45 +04:00
LDDEPS += $( top_builddir) /lib/liblvm-internal.a
2010-03-04 12:51:37 +03:00
i n c l u d e $( top_builddir ) / m a k e . t m p l
2009-03-06 19:19:52 +03:00
2010-03-04 14:12:39 +03:00
LIBS += $( LVMINTERNAL_LIBS) -ldevmapper
2009-03-08 20:06:55 +03:00
2009-09-15 02:56:27 +04:00
i f e q ( "@DMEVENTD@" , "yes" )
LIBS += -ldevmapper-event
e n d i f
2010-04-10 01:42:48 +04:00
.PHONY : install_dynamic install_static install_include install_pkgconfig
2009-07-23 01:09:13 +04:00
INSTALL_TYPE = install_dynamic
i f e q ( "@STATIC_LINK@" , "yes" )
INSTALL_TYPE += install_static
e n d i f
i f e q ( "@PKGCONFIG@" , "yes" )
INSTALL_TYPE += install_pkgconfig
e n d i f
install : $( INSTALL_TYPE ) install_include
2010-04-10 01:42:48 +04:00
install_include : $( srcdir ) /lvm 2app .h
$( INSTALL_DATA) -D $< $( includedir) /$( <F)
2009-07-23 01:09:13 +04:00
2010-04-10 01:42:48 +04:00
install_dynamic : install_lib_shared
2009-07-23 01:09:13 +04:00
install_static : $( LIB_STATIC )
2010-04-10 01:42:48 +04:00
$( INSTALL_DATA) -D $< $( usrlibdir) /$( <F)
2009-07-23 01:09:13 +04:00
2010-04-10 01:42:48 +04:00
install_pkgconfig : $( LIB_NAME ) .pc
2010-05-11 12:57:02 +04:00
$( INSTALL_DATA) -D $< $( pkgconfigdir) /lvm2app.pc
2009-07-23 01:09:13 +04:00
2009-03-06 19:19:52 +03:00
liblvm.cflow : $( SOURCES )
set -e; ( echo -n "SOURCES += " ; \
echo $( SOURCES) | \
2009-07-23 00:29:56 +04:00
sed " s/^/ /;s/ / $( top_srcdir) \/liblvm\//g;s/ $$ // " ; \
2009-03-06 19:19:52 +03:00
) > $@
cflow : liblvm .cflow
2009-07-23 01:09:13 +04:00
2010-08-03 17:00:45 +04:00
DISTCLEAN_TARGETS += $( LIB_NAME) .pc .exported_symbols_generated