mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: John Kacur <jkacur@redhat.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH] trace-cmd: Makefile: Determine install in lib or lib64
Date: Fri, 13 Nov 2015 16:51:17 +0100 (CET)	[thread overview]
Message-ID: <alpine.LFD.2.20.1511131649410.23209@riemann> (raw)

>From 89ca0b6a2c278435d16e1f23ac7cd355553515f9 Mon Sep 17 00:00:00 
2001
From: Jon Stanley <jonstanley@gmail.com>
Date: Fri, 13 Nov 2015 15:22:58 +0100
Subject: [PATCH] trace-cmd: Makefile: Determine whether to install to lib or
 lib64

Determine whether an arch is 64 or 32 bit in order to determine
whether to install to lib or lib64

Original patch from Jon Stanley found in Fedora git repo, modified to
omit extraneous parts and simplifiy it a bit.

Signed-off-by: John Kacur <jkacur@redhat.com>
---
 Makefile | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 507af59bef69..8459204346fa 100644
--- a/Makefile
+++ b/Makefile
@@ -31,6 +31,12 @@ $(call allow-override,AR,$(CROSS_COMPILE)ar)
 EXT = -std=gnu99
 INSTALL = install
 
+# figure out what arch we are on and install to right place
+ARCH = $(shell getconf LONG_BIT)
+LIBDIR_32 = lib
+LIBDIR_64 = lib64
+LIBDIR=$(LIBDIR_$(ARCH))
+
 # Use DESTDIR for installing into a different root directory.
 # This is useful for building a package. The program will be
 # installed in this directory as if it was the root directory.
@@ -47,7 +53,7 @@ html_install = $(prefix)/share/kernelshark/html
 html_install_SQ = '$(subst ','\'',$(html_install))'
 img_install = $(prefix)/share/kernelshark/html/images
 img_install_SQ = '$(subst ','\'',$(img_install))'
-libdir ?= lib
+libdir ?= $(LIBDIR)
 
 export man_dir man_dir_SQ html_install html_install_SQ INSTALL
 export img_install img_install_SQ
-- 
2.4.3


                 reply	other threads:[~2015-11-13 15:51 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=alpine.LFD.2.20.1511131649410.23209@riemann \
    --to=jkacur@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rostedt@goodmis.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

all inboxes | Powered by JetHome®