dm-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Xose Vazquez Perez <xose.vazquez@gmail.com>
Cc: device-mapper development <dm-devel@redhat.com>,
	Xose Vazquez Perez <xose.vazquez@gmail.com>
Subject: [PATCH 3/5] multipath-tools: replace ln with a variable in makefiles
Date: Fri,  1 Jul 2016 19:17:30 +0200	[thread overview]
Message-ID: <1467393452-1032-4-git-send-email-xose.vazquez@gmail.com> (raw)
In-Reply-To: <1467393452-1032-1-git-send-email-xose.vazquez@gmail.com>

Cc: Christophe Varoqui <christophe.varoqui@opensvc.com>
Cc: device-mapper development <dm-devel@redhat.com>
Signed-off-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
---
 Makefile.inc             | 1 +
 libmpathcmd/Makefile     | 4 ++--
 libmpathpersist/Makefile | 4 ++--
 libmultipath/Makefile    | 2 +-
 4 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/Makefile.inc b/Makefile.inc
index e5d8704..01d743c 100644
--- a/Makefile.inc
+++ b/Makefile.inc
@@ -57,6 +57,7 @@ mpathcmddir = $(TOPDIR)/libmpathcmd
 
 GZIP        = gzip -9 -c
 RM          = rm -f
+LN          = ln -sf
 INSTALL_PROGRAM = install
 
 OPTFLAGS     = -Wunused -Wstrict-prototypes -O2 -g -pipe -Wformat-security -Wall \
diff --git a/libmpathcmd/Makefile b/libmpathcmd/Makefile
index 92cdd82..44c221d 100644
--- a/libmpathcmd/Makefile
+++ b/libmpathcmd/Makefile
@@ -12,12 +12,12 @@ all: $(LIBS)
 
 $(LIBS): $(OBJS)
 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -Wl,-soname=$@ $(CFLAGS) -o $@ $(OBJS) $(LIBDEPS)
-	ln -sf $@ $(DEVLIB)
+	$(LN) $@ $(DEVLIB)
 
 install: $(LIBS)
 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(syslibdir)
 	$(INSTALL_PROGRAM) -m 755 $(LIBS) $(DESTDIR)$(syslibdir)/$(LIBS)
-	ln -sf $(LIBS) $(DESTDIR)$(syslibdir)/$(DEVLIB)
+	$(LN) $(LIBS) $(DESTDIR)$(syslibdir)/$(DEVLIB)
 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(incdir)
 	$(INSTALL_PROGRAM) -m 644 mpath_cmd.h $(DESTDIR)$(incdir)
 
diff --git a/libmpathpersist/Makefile b/libmpathpersist/Makefile
index 6afd3a8..d22bcdd 100644
--- a/libmpathpersist/Makefile
+++ b/libmpathpersist/Makefile
@@ -22,7 +22,7 @@ all: $(LIBS)
 $(LIBS):
 	$(CC) -Wall -fPIC -c $(CFLAGS) *.c
 	$(CC)  -shared $(LIBDEPS) -Wl,-soname=$@ $(CFLAGS) -o $@ $(OBJS)
-	ln -s $(LIBS) $(DEVLIB)
+	$(LN) $(LIBS) $(DEVLIB)
 	$(GZIP) mpath_persistent_reserve_in.3 > mpath_persistent_reserve_in.3.gz
 	$(GZIP) mpath_persistent_reserve_out.3 > mpath_persistent_reserve_out.3.gz
 
@@ -32,7 +32,7 @@ install: $(LIBS)
 	$(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)$(syslibdir)
 	$(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)$(man3dir)
 	$(INSTALL_PROGRAM) -m 755 -d $(DESTDIR)$(incdir)
-	ln -sf $(DESTDIR)$(syslibdir)/$(LIBS) $(DESTDIR)$(syslibdir)/$(DEVLIB)
+	$(LN) $(DESTDIR)$(syslibdir)/$(LIBS) $(DESTDIR)$(syslibdir)/$(DEVLIB)
 	$(INSTALL_PROGRAM) -m 644 mpath_persistent_reserve_in.3.gz $(DESTDIR)$(man3dir)
 	$(INSTALL_PROGRAM) -m 644 mpath_persistent_reserve_out.3.gz $(DESTDIR)$(man3dir)
 	$(INSTALL_PROGRAM) -m 644 mpath_persist.h $(DESTDIR)$(incdir)
diff --git a/libmultipath/Makefile b/libmultipath/Makefile
index ba1cfa7..de13e47 100644
--- a/libmultipath/Makefile
+++ b/libmultipath/Makefile
@@ -57,7 +57,7 @@ all: $(LIBS)
 
 $(LIBS): $(OBJS)
 	$(CC) $(LDFLAGS) $(SHARED_FLAGS) -Wl,-soname=$@ $(CFLAGS) -o $@ $(OBJS) $(LIBDEPS)
-	ln -sf $@ $(DEVLIB)
+	$(LN) $@ $(DEVLIB)
 
 install:
 	$(INSTALL_PROGRAM) -d $(DESTDIR)$(syslibdir)
-- 
2.7.4

  parent reply	other threads:[~2016-07-01 17:17 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-01 17:17 [PATCH 0/5] Makefiles housekeeping II Xose Vazquez Perez
2016-07-01 17:17 ` [PATCH 1/5] multipath-tools: replace rm with a variable in makefiles Xose Vazquez Perez
2016-07-01 17:17 ` [PATCH 2/5] multipath-tools: replace install with its " Xose Vazquez Perez
2016-07-01 17:17 ` Xose Vazquez Perez [this message]
2016-07-01 17:17 ` [PATCH 4/5] multipath-tools: link libmpathcmd.so with full path Xose Vazquez Perez
2016-07-01 17:17 ` [PATCH 5/5] multipath-tools: add a link for libmultipath.so Xose Vazquez Perez
2016-07-08  7:16 ` [PATCH 0/5] Makefiles housekeeping II Christophe Varoqui
2016-07-08 13:02   ` Xose Vazquez Perez
2016-07-08 13:17     ` Christophe Varoqui

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=1467393452-1032-4-git-send-email-xose.vazquez@gmail.com \
    --to=xose.vazquez@gmail.com \
    --cc=dm-devel@redhat.com \
    /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).