io-uring.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Metzmacher <metze@samba.org>
To: io-uring@vger.kernel.org
Cc: Stefan Metzmacher <metze@samba.org>
Subject: [PATCH v2] Fix liburing.so symlink source if libdir != libdevdir
Date: Fri,  7 Feb 2020 15:42:12 +0100	[thread overview]
Message-ID: <20200207144212.4212-1-metze@samba.org> (raw)
In-Reply-To: <35cb2c1e-5985-13a8-1719-1bfa9aeb65a4@samba.org>

Signed-off-by: Stefan Metzmacher <metze@samba.org>
---
 Makefile         | 6 +++++-
 configure        | 8 +++++++-
 debian/changelog | 6 ++++++
 src/Makefile     | 2 +-
 4 files changed, 19 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index 3b582f1..05d5879 100644
--- a/Makefile
+++ b/Makefile
@@ -43,7 +43,11 @@ endif
 	    $< >$@
 
 install: $(NAME).pc
-	@$(MAKE) -C src install prefix=$(DESTDIR)$(prefix) includedir=$(DESTDIR)$(includedir) libdir=$(DESTDIR)$(libdir)  libdevdir=$(DESTDIR)$(libdevdir)
+	@$(MAKE) -C src install prefix=$(DESTDIR)$(prefix) \
+		includedir=$(DESTDIR)$(includedir) \
+		libdir=$(DESTDIR)$(libdir) \
+		libdevdir=$(DESTDIR)$(libdevdir) \
+		relativelibdir=$(relativelibdir)
 	$(INSTALL) -D -m 644 $(NAME).pc $(DESTDIR)$(libdevdir)/pkgconfig/$(NAME).pc
 	$(INSTALL) -m 755 -d $(DESTDIR)$(mandir)/man2
 	$(INSTALL) -m 644 man/*.2 $(DESTDIR)$(mandir)/man2
diff --git a/configure b/configure
index 9fb43b3..2fa393f 100755
--- a/configure
+++ b/configure
@@ -48,7 +48,7 @@ if test -z "$libdir"; then
   libdir="$prefix/lib"
 fi
 if test -z "$libdevdir"; then
-  libdevdir="$libdir"
+  libdevdir="$prefix/lib"
 fi
 if test -z "$mandir"; then
   mandir="$prefix/man"
@@ -57,6 +57,11 @@ if test -z "$datadir"; then
   datadir="$prefix/share"
 fi
 
+if test x"$libdir" = x"$libdevdir"; then
+  relativelibdir=""
+else
+  relativelibdir="$libdir/"
+fi
 
 if test "$show_help" = "yes"; then
 cat <<EOF
@@ -178,6 +183,7 @@ print_and_output_mak "prefix" "$prefix"
 print_and_output_mak "includedir" "$includedir"
 print_and_output_mak "libdir" "$libdir"
 print_and_output_mak "libdevdir" "$libdevdir"
+print_and_output_mak "relativelibdir" "$relativelibdir"
 print_and_output_mak "mandir" "$mandir"
 print_and_output_mak "datadir" "$datadir"
 
diff --git a/debian/changelog b/debian/changelog
index b9ee85c..f01b3a4 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+liburing (0.4-2) stable; urgency=low
+
+  * Fix /usr/lib/*/liburing.so symlink to /lib/*/liburing.so.1.0.4
+
+ -- Stefan Metzmacher <metze@samba.org>  Fri, 07 Feb 2020 15:30:00 +0100
+
 liburing (0.4-1) stable; urgency=low
 
   * Package liburing-0.4 using a packaging layout similar to libaio1
diff --git a/src/Makefile b/src/Makefile
index 1466dd4..5d13c09 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -61,7 +61,7 @@ install: $(all_targets)
 ifeq ($(ENABLE_SHARED),1)
 	install -D -m 755 $(libname) $(libdir)/$(libname)
 	ln -sf $(libname) $(libdir)/$(soname)
-	ln -sf $(libname) $(libdevdir)/liburing.so
+	ln -sf $(relativelibdir)$(libname) $(libdevdir)/liburing.so
 endif
 
 $(liburing_objs): include/liburing.h
-- 
2.17.1


  reply	other threads:[~2020-02-07 14:42 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-06 17:07 [PATCH v1 1/3] configure/Makefile: introduce libdevdir defaults to $(libdir) Stefan Metzmacher
2020-02-06 17:07 ` [PATCH v1 2/3] debian: package liburing-0.4 and use a layout as the libaio package Stefan Metzmacher
2020-02-06 17:07 ` [PATCH v1 3/3] liburing.spec move to liburing-0.4 Stefan Metzmacher
2020-02-07 14:19 ` [PATCH v1 1/3] configure/Makefile: introduce libdevdir defaults to $(libdir) Stefan Metzmacher
2020-02-07 14:42   ` Stefan Metzmacher [this message]
2020-02-07 16:24     ` [PATCH v2] Fix liburing.so symlink source if libdir != libdevdir Jens Axboe

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=20200207144212.4212-1-metze@samba.org \
    --to=metze@samba.org \
    --cc=io-uring@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).