diff options
author | Karel Zak | 2009-11-26 17:11:12 +0100 |
---|---|---|
committer | Karel Zak | 2010-06-03 15:20:10 +0200 |
commit | f1cde479a3aa2659ffdee27e22d4a49a5cd9b0a5 (patch) | |
tree | 236db9914dcad35b25bd32e79d2a25c405257b22 /shlibs | |
parent | blkid: remove _ENC from ID_PART_ENTRY_{NAME,TYPE} variables (diff) | |
download | kernel-qcow2-util-linux-f1cde479a3aa2659ffdee27e22d4a49a5cd9b0a5.tar.gz kernel-qcow2-util-linux-f1cde479a3aa2659ffdee27e22d4a49a5cd9b0a5.tar.xz kernel-qcow2-util-linux-f1cde479a3aa2659ffdee27e22d4a49a5cd9b0a5.zip |
libmount: add basic dirs
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'shlibs')
-rw-r--r-- | shlibs/Makefile.am | 4 | ||||
-rw-r--r-- | shlibs/mount/.gitignore | 2 | ||||
-rw-r--r-- | shlibs/mount/Makefile.am | 9 | ||||
-rw-r--r-- | shlibs/mount/mount.pc.in | 11 | ||||
-rw-r--r-- | shlibs/mount/src/Makefile.am | 46 | ||||
-rw-r--r-- | shlibs/mount/src/mount.h.in | 34 | ||||
-rw-r--r-- | shlibs/mount/src/mount.sym | 11 |
7 files changed, 117 insertions, 0 deletions
diff --git a/shlibs/Makefile.am b/shlibs/Makefile.am index 3e757885b..84c0cefc8 100644 --- a/shlibs/Makefile.am +++ b/shlibs/Makefile.am @@ -7,3 +7,7 @@ endif if BUILD_LIBBLKID SUBDIRS += blkid endif + +if BUILD_LIBMOUNT +SUBDIRS += mount +endif diff --git a/shlibs/mount/.gitignore b/shlibs/mount/.gitignore new file mode 100644 index 000000000..1c7879deb --- /dev/null +++ b/shlibs/mount/.gitignore @@ -0,0 +1,2 @@ +test_* +mount.h diff --git a/shlibs/mount/Makefile.am b/shlibs/mount/Makefile.am new file mode 100644 index 000000000..f90eacc11 --- /dev/null +++ b/shlibs/mount/Makefile.am @@ -0,0 +1,9 @@ +include $(top_srcdir)/config/include-Makefile.am + +SUBDIRS = src + +# pkg-config stuff +pkgconfigdir = $(usrlib_execdir)/pkgconfig +pkgconfig_DATA = mount.pc + +EXTRA_DIST = mount.pc.in diff --git a/shlibs/mount/mount.pc.in b/shlibs/mount/mount.pc.in new file mode 100644 index 000000000..94051b8b6 --- /dev/null +++ b/shlibs/mount/mount.pc.in @@ -0,0 +1,11 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@usrlib_execdir@ +includedir=@includedir@ + +Name: mount +Description: mount library +Version: @LIBMOUNT_VERSION@ +Requires.private: blkid +Cflags: -I${includedir}/mount +Libs: -L${libdir} -lmount diff --git a/shlibs/mount/src/Makefile.am b/shlibs/mount/src/Makefile.am new file mode 100644 index 000000000..5d6c32df1 --- /dev/null +++ b/shlibs/mount/src/Makefile.am @@ -0,0 +1,46 @@ +include $(top_srcdir)/config/include-Makefile.am + +AM_CPPFLAGS += -I$(ul_libmount_incdir) \ + -I$(ul_libmount_srcdir) \ + -I$(ul_libblkid_incdir) + +# includes +mountincdir = $(includedir)/mount +nodist_mountinc_HEADERS = mount.h + +usrlib_exec_LTLIBRARIES = libmount.la +libmount_la_SOURCES = $(mountinc_HEADERS) + +nodist_libmount_la_SOURCES = mount.h + +libmount_la_LIBADD = $(ul_libblkid_la) + +libmount_la_DEPENDENCIES = $(libmount_la_LIBADD) mount.sym mount.h.in + +libmount_la_LDFLAGS = -Wl,--version-script=$(ul_libmount_srcdir)/mount.sym \ + -version-info $(LIBMOUNT_VERSION_INFO) + +tests = + +EXTRA_DIST = mount.sym mount.h.in +CLEANFILES = $(tests) + +tests: all $(tests) +test_%: %.c + $(COMPILE) -DTEST_PROGRAM $< .libs/libmount.a -o $@ $(BLKID_LIBS) + + +# move lib from $(usrlib_execdir) to $(libdir) if needed +install-exec-hook: + if test "$(usrlib_execdir)" != "$(libdir)"; then \ + mkdir -p $(DESTDIR)$(libdir); \ + mv $(DESTDIR)$(usrlib_execdir)/libmount.so.* $(DESTDIR)$(libdir); \ + so_img_name=$$(readlink $(DESTDIR)$(usrlib_execdir)/libmount.so); \ + so_img_rel_target=$$(echo $(usrlib_execdir) | sed 's,\(^/\|\)[^/][^/]*,..,g'); \ + (cd $(DESTDIR)$(usrlib_execdir) && \ + rm -f libmount.so && \ + $(LN_S) $$so_img_rel_target$(libdir)/$$so_img_name libmount.so); \ + fi + +uninstall-hook: + rm -f $(DESTDIR)$(libdir)/libmount.so* diff --git a/shlibs/mount/src/mount.h.in b/shlibs/mount/src/mount.h.in new file mode 100644 index 000000000..e9b0425c1 --- /dev/null +++ b/shlibs/mount/src/mount.h.in @@ -0,0 +1,34 @@ +/* + * mount.h - libmount API + * + * Copyright (C) 2008-2009 Karel Zak <kzak@redhat.com> + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ + +#ifndef _LIBMOUNT_MOUNT_H +#define _LIBMOUNT_MOUNT_H + +#ifdef __cplusplus +extern "C" { +#endif + +#define LIBMOUNT_VERSION "@LIBMOUNT_VERSION@" + +#ifdef __cplusplus +} +#endif + +#endif /* _LIBMOUNT_MOUNT_H */ diff --git a/shlibs/mount/src/mount.sym b/shlibs/mount/src/mount.sym new file mode 100644 index 000000000..5922560b1 --- /dev/null +++ b/shlibs/mount/src/mount.sym @@ -0,0 +1,11 @@ +/* + * The symbol versioning ensures that a new application requiring symbol foo() + * can't run with old libblkid.so not providing foo() - the global SONAME + * version info can't enforce this since we never change the SONAME. + */ +MOUNT_2.18 { +global: + dummy; +local: + *; +}; |