All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Jackson <ian.jackson@eu.citrix.com>
To: xen-devel@lists.xenproject.org
Cc: Wei Liu <wei.liu2@citrix.com>, Ian Jackson <ian.jackson@eu.citrix.com>
Subject: [PATCH 10/12] tools/libfsimage: Add `xen' to .h names and principal .so name
Date: Fri, 12 Oct 2018 16:12:13 +0100	[thread overview]
Message-ID: <20181012151215.32455-11-ian.jackson@eu.citrix.com> (raw)
In-Reply-To: <20181012151215.32455-1-ian.jackson@eu.citrix.com>

`fsimage' is rather general.  And we do not expect this library to be
very useful out of tree because of its unstable ABI.

So add the word `xen'.  This will avoid naming conflicts with anyone
else's fsimage library.

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
---
v2: New in this version of the series
---
 tools/libfsimage/Rules.mk                   |  2 +-
 tools/libfsimage/common/Makefile            | 34 ++++++++++++++---------------
 tools/libfsimage/common/fsimage_grub.c      |  2 +-
 tools/libfsimage/common/fsimage_plugin.c    |  2 +-
 tools/libfsimage/common/fsimage_priv.h      |  4 ++--
 tools/libfsimage/common/xenfsimage_grub.h   |  4 ++--
 tools/libfsimage/common/xenfsimage_plugin.h |  2 +-
 tools/libfsimage/ext2fs-lib/ext2fs-lib.c    |  2 +-
 tools/libfsimage/ext2fs/fsys_ext2fs.c       |  2 +-
 tools/libfsimage/fat/fsys_fat.c             |  2 +-
 tools/libfsimage/iso9660/fsys_iso9660.c     |  2 +-
 tools/libfsimage/reiserfs/fsys_reiserfs.c   |  2 +-
 tools/libfsimage/ufs/fsys_ufs.c             |  2 +-
 tools/libfsimage/xfs/fsys_xfs.c             |  2 +-
 tools/libfsimage/zfs/fsi_zfs.c              |  2 +-
 tools/libfsimage/zfs/fsi_zfs.h              |  2 +-
 tools/pygrub/setup.py                       |  2 +-
 tools/pygrub/src/fsimage/fsimage.c          |  2 +-
 18 files changed, 36 insertions(+), 36 deletions(-)

diff --git a/tools/libfsimage/Rules.mk b/tools/libfsimage/Rules.mk
index eab4ecb35e..2a29d9ef2b 100644
--- a/tools/libfsimage/Rules.mk
+++ b/tools/libfsimage/Rules.mk
@@ -26,7 +26,7 @@ fs-uninstall:
 	fi
 
 $(FSLIB): $(PIC_OBJS)
-	$(CC) $(LDFLAGS) $(SHLIB_LDFLAGS) -o $@ $^ -lfsimage $(FS_LIBDEPS) $(APPEND_LDFLAGS)
+	$(CC) $(LDFLAGS) $(SHLIB_LDFLAGS) -o $@ $^ -lxenfsimage $(FS_LIBDEPS) $(APPEND_LDFLAGS)
 
 clean distclean::
 	rm -f $(PIC_OBJS) $(FSLIB) $(DEPS_RM)
diff --git a/tools/libfsimage/common/Makefile b/tools/libfsimage/common/Makefile
index beda8f5f3a..f20e1394a8 100644
--- a/tools/libfsimage/common/Makefile
+++ b/tools/libfsimage/common/Makefile
@@ -15,7 +15,7 @@ LIB_SRCS-y = fsimage.c fsimage_plugin.c fsimage_grub.c
 
 PIC_OBJS := $(patsubst %.c,%.opic,$(LIB_SRCS-y))
 
-LIB = libfsimage.so libfsimage.so.$(MAJOR) libfsimage.so.$(MAJOR).$(MINOR)
+LIB = libxenfsimage.so libxenfsimage.so.$(MAJOR) libxenfsimage.so.$(MAJOR).$(MINOR)
 
 .PHONY: all
 all: $(LIB)
@@ -24,32 +24,32 @@ all: $(LIB)
 install: all
 	$(INSTALL_DIR) $(DESTDIR)$(libdir)
 	$(INSTALL_DIR) $(DESTDIR)$(includedir)
-	$(INSTALL_PROG) libfsimage.so.$(MAJOR).$(MINOR) $(DESTDIR)$(libdir)
-	ln -sf libfsimage.so.$(MAJOR).$(MINOR) $(DESTDIR)$(libdir)/libfsimage.so.$(MAJOR)
-	ln -sf libfsimage.so.$(MAJOR) $(DESTDIR)$(libdir)/libfsimage.so
-	$(INSTALL_DATA) fsimage.h $(DESTDIR)$(includedir)
-	$(INSTALL_DATA) fsimage_plugin.h $(DESTDIR)$(includedir)
-	$(INSTALL_DATA) fsimage_grub.h $(DESTDIR)$(includedir)
+	$(INSTALL_PROG) libxenfsimage.so.$(MAJOR).$(MINOR) $(DESTDIR)$(libdir)
+	ln -sf libxenfsimage.so.$(MAJOR).$(MINOR) $(DESTDIR)$(libdir)/libxenfsimage.so.$(MAJOR)
+	ln -sf libxenfsimage.so.$(MAJOR) $(DESTDIR)$(libdir)/libxenfsimage.so
+	$(INSTALL_DATA) xenfsimage.h $(DESTDIR)$(includedir)
+	$(INSTALL_DATA) xenfsimage_plugin.h $(DESTDIR)$(includedir)
+	$(INSTALL_DATA) xenfsimage_grub.h $(DESTDIR)$(includedir)
 
 .PHONY: uninstall
 uninstall:
-	rm -f $(DESTDIR)$(includedir)/fsimage_grub.h
-	rm -f $(DESTDIR)$(includedir)/fsimage_plugin.h
-	rm -f $(DESTDIR)$(includedir)/fsimage.h
-	rm -f $(DESTDIR)$(libdir)/libfsimage.so
-	rm -f $(DESTDIR)$(libdir)/libfsimage.so.$(MAJOR)
-	rm -f $(DESTDIR)$(libdir)/libfsimage.so.$(MAJOR).$(MINOR)
+	rm -f $(DESTDIR)$(includedir)/xenfsimage_grub.h
+	rm -f $(DESTDIR)$(includedir)/xenfsimage_plugin.h
+	rm -f $(DESTDIR)$(includedir)/xenfsimage.h
+	rm -f $(DESTDIR)$(libdir)/libxenfsimage.so
+	rm -f $(DESTDIR)$(libdir)/libxenfsimage.so.$(MAJOR)
+	rm -f $(DESTDIR)$(libdir)/libxenfsimage.so.$(MAJOR).$(MINOR)
 
 clean distclean::
 	rm -f $(LIB)
 
-libfsimage.so: libfsimage.so.$(MAJOR)
+libxenfsimage.so: libxenfsimage.so.$(MAJOR)
 	ln -sf $< $@
-libfsimage.so.$(MAJOR): libfsimage.so.$(MAJOR).$(MINOR)
+libxenfsimage.so.$(MAJOR): libxenfsimage.so.$(MAJOR).$(MINOR)
 	ln -sf $< $@
 
-libfsimage.so.$(MAJOR).$(MINOR): $(PIC_OBJS)
-	$(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libfsimage.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(PTHREAD_LIBS) $(APPEND_LDFLAGS)
+libxenfsimage.so.$(MAJOR).$(MINOR): $(PIC_OBJS)
+	$(CC) $(LDFLAGS) -Wl,$(SONAME_LDFLAG) -Wl,libxenfsimage.so.$(MAJOR) $(SHLIB_LDFLAGS) -o $@ $^ $(PTHREAD_LIBS) $(APPEND_LDFLAGS)
 
 -include $(DEPS_INCLUDE)
 
diff --git a/tools/libfsimage/common/fsimage_grub.c b/tools/libfsimage/common/fsimage_grub.c
index ef71d6cceb..258d48bfbb 100644
--- a/tools/libfsimage/common/fsimage_grub.c
+++ b/tools/libfsimage/common/fsimage_grub.c
@@ -28,7 +28,7 @@
 #include <strings.h>
 #include <errno.h>
 
-#include "fsimage_grub.h"
+#include "xenfsimage_grub.h"
 #include "fsimage_priv.h"
 
 static char *disk_read_junk;
diff --git a/tools/libfsimage/common/fsimage_plugin.c b/tools/libfsimage/common/fsimage_plugin.c
index 0744e7b3ca..44ebcf3142 100644
--- a/tools/libfsimage/common/fsimage_plugin.c
+++ b/tools/libfsimage/common/fsimage_plugin.c
@@ -29,7 +29,7 @@
 #include <dlfcn.h>
 #include <errno.h>
 
-#include "fsimage_plugin.h"
+#include "xenfsimage_plugin.h"
 #include "fsimage_priv.h"
 
 static fsi_plugin_t *plugins;
diff --git a/tools/libfsimage/common/fsimage_priv.h b/tools/libfsimage/common/fsimage_priv.h
index 57a0826dee..2274403557 100644
--- a/tools/libfsimage/common/fsimage_priv.h
+++ b/tools/libfsimage/common/fsimage_priv.h
@@ -30,8 +30,8 @@ extern C {
 
 #include <sys/types.h>
 
-#include "fsimage.h"
-#include "fsimage_plugin.h"
+#include "xenfsimage.h"
+#include "xenfsimage_plugin.h"
 
 struct fsi_plugin {
 	const char *fp_name;
diff --git a/tools/libfsimage/common/xenfsimage_grub.h b/tools/libfsimage/common/xenfsimage_grub.h
index 534c346b23..38fb4f620e 100644
--- a/tools/libfsimage/common/xenfsimage_grub.h
+++ b/tools/libfsimage/common/xenfsimage_grub.h
@@ -33,8 +33,8 @@ extern C {
 #include <stdlib.h>
 #include <ctype.h>
 
-#include "fsimage.h"
-#include "fsimage_plugin.h"
+#include "xenfsimage.h"
+#include "xenfsimage_plugin.h"
 
 typedef struct fsig_plugin_ops {
 	int fpo_version;
diff --git a/tools/libfsimage/common/xenfsimage_plugin.h b/tools/libfsimage/common/xenfsimage_plugin.h
index a682719a63..4135769018 100644
--- a/tools/libfsimage/common/xenfsimage_plugin.h
+++ b/tools/libfsimage/common/xenfsimage_plugin.h
@@ -30,7 +30,7 @@ extern C {
 
 #include <sys/types.h>
 
-#include "fsimage.h"
+#include "xenfsimage.h"
 
 #define	FSIMAGE_PLUGIN_VERSION 1
 
diff --git a/tools/libfsimage/ext2fs-lib/ext2fs-lib.c b/tools/libfsimage/ext2fs-lib/ext2fs-lib.c
index 84b6d1e9c3..864a15b349 100644
--- a/tools/libfsimage/ext2fs-lib/ext2fs-lib.c
+++ b/tools/libfsimage/ext2fs-lib/ext2fs-lib.c
@@ -21,7 +21,7 @@
  * Use is subject to license terms.
  */
 
-#include <fsimage_plugin.h>
+#include <xenfsimage_plugin.h>
 #include INCLUDE_EXTFS_H
 #include <errno.h>
 #include <inttypes.h>
diff --git a/tools/libfsimage/ext2fs/fsys_ext2fs.c b/tools/libfsimage/ext2fs/fsys_ext2fs.c
index ba53ff4ca6..a4ed10419c 100644
--- a/tools/libfsimage/ext2fs/fsys_ext2fs.c
+++ b/tools/libfsimage/ext2fs/fsys_ext2fs.c
@@ -16,7 +16,7 @@
  *  along with this program; If not, see <http://www.gnu.org/licenses/>.
  */
 
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 
 #define	mapblock1 (*fsig_int1(ffi))
 #define	mapblock2 (*fsig_int2(ffi))
diff --git a/tools/libfsimage/fat/fsys_fat.c b/tools/libfsimage/fat/fsys_fat.c
index b8129a8c04..b89354a872 100644
--- a/tools/libfsimage/fat/fsys_fat.c
+++ b/tools/libfsimage/fat/fsys_fat.c
@@ -17,7 +17,7 @@
  */
 
 #include <limits.h>
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 #include "fat.h"
 
 struct fat_superblock 
diff --git a/tools/libfsimage/iso9660/fsys_iso9660.c b/tools/libfsimage/iso9660/fsys_iso9660.c
index 5dbf100dfe..6e767357bf 100644
--- a/tools/libfsimage/iso9660/fsys_iso9660.c
+++ b/tools/libfsimage/iso9660/fsys_iso9660.c
@@ -28,7 +28,7 @@
  *	Leonid Lisovskiy   <lly@pisem.net>	2003
  */
 
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 #include <limits.h>
 
 #include "iso9660.h"
diff --git a/tools/libfsimage/reiserfs/fsys_reiserfs.c b/tools/libfsimage/reiserfs/fsys_reiserfs.c
index 92c3b2bbfb..916eb15292 100644
--- a/tools/libfsimage/reiserfs/fsys_reiserfs.c
+++ b/tools/libfsimage/reiserfs/fsys_reiserfs.c
@@ -17,7 +17,7 @@
  *  along with this program; If not, see <http://www.gnu.org/licenses/>.
  */
 
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 
 #undef REISERDEBUG
 
diff --git a/tools/libfsimage/ufs/fsys_ufs.c b/tools/libfsimage/ufs/fsys_ufs.c
index cf7e22ad0b..a545bc9f65 100644
--- a/tools/libfsimage/ufs/fsys_ufs.c
+++ b/tools/libfsimage/ufs/fsys_ufs.c
@@ -22,7 +22,7 @@
 
 /* From Solaris usr/src/stand/lib/fs/ufs/ufsops.c */
 
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 
 #include "ufs.h"
 
diff --git a/tools/libfsimage/xfs/fsys_xfs.c b/tools/libfsimage/xfs/fsys_xfs.c
index f39d096ba2..d735a88e55 100644
--- a/tools/libfsimage/xfs/fsys_xfs.c
+++ b/tools/libfsimage/xfs/fsys_xfs.c
@@ -17,7 +17,7 @@
  *  along with this program; If not, see <http://www.gnu.org/licenses/>.
  */
 
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 #include "xfs.h"
 
 #define MAX_LINK_COUNT	8
diff --git a/tools/libfsimage/zfs/fsi_zfs.c b/tools/libfsimage/zfs/fsi_zfs.c
index 75145875fd..187a8bc6b2 100644
--- a/tools/libfsimage/zfs/fsi_zfs.c
+++ b/tools/libfsimage/zfs/fsi_zfs.c
@@ -22,7 +22,7 @@
 
 #ifdef	FSYS_ZFS
 
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 #include <fsimage_priv.h>
 #include <stdio.h>
 #include <inttypes.h>
diff --git a/tools/libfsimage/zfs/fsi_zfs.h b/tools/libfsimage/zfs/fsi_zfs.h
index fb4dc23bbf..980ce8f304 100644
--- a/tools/libfsimage/zfs/fsi_zfs.h
+++ b/tools/libfsimage/zfs/fsi_zfs.h
@@ -27,7 +27,7 @@
 #include <sys/types.h>
 #include <stdio.h>
 #include <string.h>
-#include <fsimage_grub.h>
+#include <xenfsimage_grub.h>
 
 
 /*** START FROM shared.h ****/
diff --git a/tools/pygrub/setup.py b/tools/pygrub/setup.py
index 711bbbd499..b58cc1c4e6 100644
--- a/tools/pygrub/setup.py
+++ b/tools/pygrub/setup.py
@@ -11,7 +11,7 @@ fsimage = Extension("fsimage",
     extra_compile_args = extra_compile_args,
     include_dirs = [ XEN_ROOT + "/tools/libfsimage/common/" ],
     library_dirs = [ XEN_ROOT + "/tools/libfsimage/common/" ],
-    libraries = ["fsimage"],
+    libraries = ["xenfsimage"],
     sources = ["src/fsimage/fsimage.c"])
 
 pkgs = [ 'grub' ]
diff --git a/tools/pygrub/src/fsimage/fsimage.c b/tools/pygrub/src/fsimage/fsimage.c
index 8ec0dec346..47940572a8 100644
--- a/tools/pygrub/src/fsimage/fsimage.c
+++ b/tools/pygrub/src/fsimage/fsimage.c
@@ -23,7 +23,7 @@
 
 #include <Python.h>
 
-#include <fsimage.h>
+#include <xenfsimage.h>
 #include <stdlib.h>
 
 #if (PYTHON_API_VERSION >= 1011)
-- 
2.11.0


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

  parent reply	other threads:[~2018-10-12 15:12 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-12 15:12 [PATCH v2 00/12] Miscellaneous fixes from Debian Ian Jackson
2018-10-12 15:12 ` [PATCH 01/12] tools/Rules.mk: Honour PREPEND_LDFLAGS_XEN_TOOLS Ian Jackson
2018-10-12 15:38   ` Wei Liu
2018-10-12 15:12 ` [PATCH 02/12] INSTALL: Mention kconfig Ian Jackson
2018-10-12 15:12 ` [PATCH 03/12] gdbsx: Honour LDFLAGS when linking Ian Jackson
2018-10-12 15:38   ` Wei Liu
2018-10-12 17:15   ` Elena Ufimtseva
2018-10-12 15:12 ` [PATCH 04/12] pygrub fsimage.so: Honour LDFLAGS when building Ian Jackson
2018-10-12 15:38   ` Wei Liu
2018-10-12 15:12 ` [PATCH 05/12] xenmon: Install as xenmon, not xenmon.py Ian Jackson
2018-10-12 15:12 ` [PATCH 06/12] tools/debugger/kdd: Install as `xen-kdd', not just `kdd' Ian Jackson
2018-10-12 15:12 ` [PATCH 07/12] tools/xenstore: Re-introduce (fake) xs_restrict call to preserve ABI Ian Jackson
2018-10-12 15:38   ` Wei Liu
2018-10-12 21:47   ` Hans van Kranenburg
2018-10-15 13:47     ` Ian Jackson
2018-10-12 15:12 ` [PATCH 08/12] xenstore.h: Put ( ) around XS_* define shifts Ian Jackson
2018-10-12 15:38   ` Wei Liu
2018-10-12 15:12 ` [PATCH 09/12] tools/libfsimage: Bump soname to 4.12 Ian Jackson
2018-10-12 15:35   ` Wei Liu
2018-10-12 15:12 ` Ian Jackson [this message]
2018-10-12 15:38   ` [PATCH 10/12] tools/libfsimage: Add `xen' to .h names and principal .so name Wei Liu
2018-10-12 16:34     ` Ian Jackson
2018-10-12 15:12 ` [PATCH 11/12] tools/pygrub: Add `xen' to fsimage python module name Ian Jackson
2018-10-12 15:39   ` Wei Liu
2018-10-12 15:12 ` [PATCH 12/12] tools/libfsimage: Rename /usr/lib/fs to /usr/lib/xenfsimage Ian Jackson
2018-10-12 15:40   ` Wei Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181012151215.32455-11-ian.jackson@eu.citrix.com \
    --to=ian.jackson@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.