From: Guido Trentalancia <guido@trentalancia.com>
To: selinux@tycho.nsa.gov
Subject: [PATCH]: fix symbolic links creation to the shared libraries
Date: Sat, 21 Jul 2012 15:13:44 +0200 [thread overview]
Message-ID: <1342876424.2430.7.camel@vortex> (raw)
Hello.
The current Makefiles for the userspace libraries only install correct
symbolic links to the shared libraries when a two-level (relatively to
the root directory) SHLIBDIR is used.
The attached patch can be easily modified to avoid using sed at no
functional difference (it would not be able to remove multiple
consecutive slash).
Fix the creation of symbolic links to the shared libraries during installation.
Signed-off-by: Guido Trentalancia <guido@trentalancia.com>
---
libselinux/src/Makefile | 2 +-
libsemanage/src/Makefile | 2 +-
libsepol/src/Makefile | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
--- selinux-20072012-new/libselinux/src/Makefile 2012-07-20 17:53:02.813866482 +0200
+++ selinux-20072012/libselinux/src/Makefile 2012-07-21 15:03:10.021932875 +0200
@@ -153,7 +153,7 @@ install: all
install -m 755 $(LIBSO) $(SHLIBDIR)
test -d $(LIBDIR)/pkgconfig || install -m 755 -d $(LIBDIR)/pkgconfig
install -m 644 $(LIBPC) $(LIBDIR)/pkgconfig
- cd $(LIBDIR) && ln -sf ../../`basename $(SHLIBDIR)`/$(LIBSO) $(TARGET)
+ cd $(LIBDIR) && ln -sf `echo $(SHLIBDIR)/$(LIBSO) | sed 's/\/\/\{1,\}/\//g'` $(TARGET)
install-pywrap: pywrap
test -d $(PYLIBDIR)/site-packages/selinux || install -m 755 -d $(PYLIBDIR)/site-packages/selinux
--- selinux-20072012-new/libsepol/src/Makefile 2012-06-18 18:54:45.693499604 +0200
+++ selinux-20072012/libsepol/src/Makefile 2012-07-21 15:03:26.511290822 +0200
@@ -43,7 +43,7 @@ install: all
install -m 755 $(LIBSO) $(SHLIBDIR)
test -d $(LIBDIR)/pkgconfig || install -m 755 -d $(LIBDIR)/pkgconfig
install -m 644 $(LIBPC) $(LIBDIR)/pkgconfig
- cd $(LIBDIR) && ln -sf ../../`basename $(SHLIBDIR)`/$(LIBSO) $(TARGET)
+ cd $(LIBDIR) && ln -sf `echo $(SHLIBDIR)/$(LIBSO) | sed 's/\/\/\{1,\}/\//g'` $(TARGET)
relabel:
/sbin/restorecon $(SHLIBDIR)/$(LIBSO)
--- selinux-20072012-new/libsemanage/src/Makefile 2012-07-20 17:59:42.522639128 +0200
+++ selinux-20072012/libsemanage/src/Makefile 2012-07-21 15:03:39.064560974 +0200
@@ -146,7 +146,7 @@ install: all
test -d $(LIBDIR)/pkgconfig || install -m 755 -d $(LIBDIR)/pkgconfig
install -m 644 $(LIBPC) $(LIBDIR)/pkgconfig
test -f $(DEFAULT_SEMANAGE_CONF_LOCATION) || install -m 644 -D semanage.conf $(DEFAULT_SEMANAGE_CONF_LOCATION)
- cd $(LIBDIR) && ln -sf ../../`basename $(SHLIBDIR)`/$(LIBSO) $(TARGET)
+ cd $(LIBDIR) && ln -sf `echo $(SHLIBDIR)/$(LIBSO) | sed 's/\/\/\{1,\}/\//g'` $(TARGET)
install-pywrap: pywrap
test -d $(PYLIBDIR)/site-packages || install -m 755 -d $(PYLIBDIR)/site-packages
--
This message was distributed to subscribers of the selinux mailing list.
If you no longer wish to subscribe, send mail to majordomo@tycho.nsa.gov with
the words "unsubscribe selinux" without quotes as the message.
reply other threads:[~2012-07-21 13:13 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1342876424.2430.7.camel@vortex \
--to=guido@trentalancia.com \
--cc=selinux@tycho.nsa.gov \
/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.