mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@rjwysocki.net>
To: Josh Boyer <jwboyer@fedoraproject.org>
Cc: Thomas Renninger <trenn@suse.de>,
	"sriram@marirs.net.in" <sriram@marirs.net.in>,
	Linux PM list <linux-pm@vger.kernel.org>,
	"Linux-Kernel@Vger. Kernel. Org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] Revert "cpupower Makefile change to help run the tool without 'make install'"
Date: Thu, 12 Mar 2015 23:38:14 +0100	[thread overview]
Message-ID: <2850879.eZiuZCSV0J@vostro.rjw.lan> (raw)
In-Reply-To: <20150311002635.GC8393@hansolo.redhat.com>

On Tuesday, March 10, 2015 08:26:36 PM Josh Boyer wrote:
> This reverts commit 5c1de006e8e66b0be05be422416629e344c71652.
> 
> While the original commit makes it easier to run cpupower from the local build
> directory, it also leaves the binary with a rather poor rpath of './' in it
> after it is installed on a system via 'make install'.
> 
> This is considered bad practice and can cause cpupower to fail in rpmbuild
> with the following error:
> 
> ERROR   0004: file '/usr/bin/cpupower' contains an insecure rpath './' in [./]
> error: Bad exit status from /var/tmp/rpm-tmp.A6u26r (%install)
>     Bad exit status from /var/tmp/rpm-tmp.A6u26r (%install)
> 
> Developers should be able to use LD_LIBRARY_PATH to achieve the same effect
> and not introduce rpath into the binary.
> 
> Signed-off-by: Josh Boyer <jwboyer@feoraproject.org>

Queued up for 4.0-rc4, thanks!

> ---
>  tools/power/cpupower/Makefile | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/power/cpupower/Makefile b/tools/power/cpupower/Makefile
> index 3ed7c0476d48..2e2ba2efa0d9 100644
> --- a/tools/power/cpupower/Makefile
> +++ b/tools/power/cpupower/Makefile
> @@ -209,7 +209,7 @@ $(OUTPUT)%.o: %.c
>  
>  $(OUTPUT)cpupower: $(UTIL_OBJS) $(OUTPUT)libcpupower.so.$(LIB_MAJ)
>  	$(ECHO) "  CC      " $@
> -	$(QUIET) $(CC) $(CFLAGS) $(LDFLAGS) $(UTIL_OBJS) -lcpupower -Wl,-rpath=./ -lrt -lpci -L$(OUTPUT) -o $@
> +	$(QUIET) $(CC) $(CFLAGS) $(LDFLAGS) $(UTIL_OBJS) -lcpupower -lrt -lpci -L$(OUTPUT) -o $@
>  	$(QUIET) $(STRIPCMD) $@
>  
>  $(OUTPUT)po/$(PACKAGE).pot: $(UTIL_SRC)
> 

-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

      reply	other threads:[~2015-03-12 22:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-11  0:26 Josh Boyer
2015-03-12 22:38 ` Rafael J. Wysocki [this message]

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=2850879.eZiuZCSV0J@vostro.rjw.lan \
    --to=rjw@rjwysocki.net \
    --cc=jwboyer@fedoraproject.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=sriram@marirs.net.in \
    --cc=trenn@suse.de \
    /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®