Bug 114385 - RFE: Non-vendor value for _topdir
Summary: RFE: Non-vendor value for _topdir
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Red Hat Raw Hide
Classification: Retired
Component: rpm
Version: 1.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Paul Nasrat
QA Contact: Mike McLean
URL:
Whiteboard:
: 118973 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-01-27 15:30 UTC by Michael Jennings (KainX)
Modified: 2007-04-18 17:02 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2005-10-25 23:49:50 UTC
Embargoed:


Attachments (Terms of Use)
Fix hardcode redhat in %_topdir (563 bytes, patch)
2005-05-02 15:45 UTC, Nanar
no flags Details | Diff

Description Michael Jennings (KainX) 2004-01-27 15:30:50 UTC
RPM uses a vendor-specific value, "redhat," for the last portion of
the %{_topdir} path.  This usually causes each vendor to create its
own variation of %{_topdir}, resulting in significant compatibility
issues.

I propose that RPM use %{_usrsrc}/rpm instead of %{_usrsrc}/redhat as
its default value for %{_topdir}.  This provides a vendor-agnostic
mechanism which does not depend on, or potentially violate the
trademark of, any particular company or distributor.  Also, it follows
the previously-established standard of /usr/src/<pkgname>.

Comment 1 R P Herrold 2004-01-27 16:10:22 UTC
it looks as though a patch/edit on the line:
   macros:%_topdir         %{_usrsrc}/redhat
in /usr/lib/rpm/macros  would attain that state; some breakage of
habituated expectation may exist (just as some still complain when
trying to build with 'rpm -ba'), there are undoubtedly people still
building as root within /usr/src/redhat/ tree.

As such, adding a transition %post process which adds a back-compat
link, while the release notes provide a transition interval, may be in
order.

------------------

on the broader topic of 'agnostic' changes, in that same directory, 
'macros' has constructs like:

macros:%_vendor         redhat
which is probably already better solved elsewhere by distribution
packagers, and might be set to 'unspecificed' more properly.

macros:#%_solve_dbpath   \
    /usr/lib/rpmdb/%{_arch}-%{_vendor}-%{_os}/redhat
(which, while presently commented out) are candidates for cleanup
before roll-in

ditto, this appears to be the artifact of some long lost buildsystem's
mountpoints in macros:
#%_solve_pkgsdir /mnt/redhat/test/latest-i386/RedHat/RPMS/

and what in the world is this piece of cruft:
cross-build:    if [ -r /usr/src/redhat/RPMS/sh/`echo $pkg | sed -e
"s:/tmp/srpms/::" -e "s/.src.rpm/.sh.rpm/"` ]; then

--- obvious grist for a cleanup.

-- Russ Herrold

Comment 2 Jeff Johnson 2004-03-24 01:07:00 UTC
*** Bug 118973 has been marked as a duplicate of this bug. ***

Comment 3 Mark Hatle 2005-05-02 15:43:36 UTC
Just a quick comment..  we (MontaVista) are for changing the default _topdir to:

%{_usrsrc}/rpm

Comment 4 Nanar 2005-05-02 15:45:16 UTC
Created attachment 113926 [details]
Fix hardcode redhat in %_topdir

Comment 5 Nanar 2005-05-02 15:47:39 UTC
Comment on attachment 113926 [details]
Fix hardcode redhat in %_topdir

Over the political choice between using /usr/src/rpm or /usr/src/%_vendor, 
there is currently technical typo making %_topdir not working: 

The Makefile.am install the tree in /usr/src/$(RPMCANONVENDOR) but the 
macros.in has an hardcore path to 'redhat'. 

The patch fixed this to have coherent setting.

Comment 6 Jeff Johnson 2005-10-25 23:49:50 UTC
Fixed (by using /usr/src/rpm for %_topdir) in rpm-4.4.3-0.22.


Note You need to log in before you can comment on or make changes to this bug.