rpath issues with 64-bit package

From: Steve Jenkins <stevejenkins_at_gmail.com>
Date: Mon, 15 Aug 2011 19:30:54 -0700

Nobody's awake in IRC right now, so I'll blurt this here and see if
anyone has any ideas.

When building the 2.4.2 package in CentOS 5 x86_64, I get:

+ /usr/lib/rpm/check-rpaths /usr/lib/rpm/check-buildroot
*******************************************************************************
*
* WARNING: 'check-rpaths' detected a broken RPATH and will cause 'rpmbuild'
* to fail. To ignore these errors, you can set the '$QA_RPATHS'
* environment variable which is a bitmask allowing the values
* below. The current value of QA_RPATHS is 0x0000.
*
* 0x0001 ... standard RPATHs (e.g. /usr/lib); such RPATHs are a minor
* issue but are introducing redundant searchpaths without
* providing a benefit. They can also cause errors in multilib
* environments.
* 0x0002 ... invalid RPATHs; these are RPATHs which are neither absolute
* nor relative filenames and can therefore be a SECURITY risk
* 0x0004 ... insecure RPATHs; these are relative RPATHs which are a
* SECURITY risk
* 0x0008 ... the special '$ORIGIN' RPATHs are appearing after other
* RPATHs; this is just a minor issue but usually unwanted
* 0x0010 ... the RPATH is empty; there is no reason for such RPATHs
* and they cause unneeded work while loading libraries
* 0x0020 ... an RPATH references '..' of an absolute path; this will break
* the functionality when the path before '..' is a symlink
*
*
* Examples:
* - to ignore standard and empty RPATHs, execute 'rpmbuild' like
* $ QA_RPATHS=$[ 0x0001|0x0010 ] rpmbuild my-package.src.rpm
* - to check existing files, set $RPM_BUILD_ROOT and execute check-rpaths like
* $ RPM_BUILD_ROOT=<top-dir> /usr/lib/rpm/check-rpaths
*
*******************************************************************************
ERROR 0001: file '/usr/sbin/opendkim' contains a standard rpath
'/usr/lib64' in [/usr/lib64]
ERROR 0001: file '/usr/bin/opendkim-genzone' contains a standard
rpath '/usr/lib64' in [/usr/lib64]
ERROR 0001: file '/usr/bin/opendkim-testkey' contains a standard
rpath '/usr/lib64' in [/usr/lib64]
ERROR 0001: file '/usr/bin/opendkim-stats' contains a standard rpath
'/usr/lib64' in [/usr/lib64]
ERROR 0001: file '/usr/bin/opendkim-testadsp' contains a standard
rpath '/usr/lib64' in [/usr/lib64]

The configure line from the spec file is:

./configure --prefix=%{_prefix} --localstatedir=%{_localstatedir}
--sysconfdir=%{_sysconfdir} --libdir=%{_libdir} --mandir=%{_mandir}
--enable-stats CPPFLAGS="$INCLUDES"

and I believe the libdir is contributing to the problem, but I'm not
sure how to fix it.

Reading here:

http://fedoraproject.org/wiki/RPath_Packaging_Draft

told me to try adding '--disable-rpath' to the configure, but that
didn't fix it.

Ideas???

SteveJ
Received on Tue Aug 16 2011 - 02:31:06 PST

This archive was generated by hypermail 2.3.0 : Mon Oct 29 2012 - 23:33:11 PST