Bug 106844 - %_solve_dbpath macro is wrong / rpmdb-fedora package
Summary: %_solve_dbpath macro is wrong / rpmdb-fedora package
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: rpmdb-redhat
Version: rawhide
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Elliot Lee
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks: CambridgeBlocker 107852
TreeView+ depends on / blocked
 
Reported: 2003-10-11 17:52 UTC by Michael Schwendt
Modified: 2007-11-30 22:10 UTC (History)
2 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2003-10-25 18:42:00 UTC


Attachments (Terms of Use)

Description Michael Schwendt 2003-10-11 17:52:59 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225

Description of problem:
In /etc/rpm/macros.solve is defined

  %_solve_dbpath /usr/lib/rpmdb/i386-redhat-linux/redhat

but the RPM database files have been moved to

  %_solve_dbpath /usr/lib/rpmdb/i386-redhat-linux/fedora

[...]

I stumbled upon this when I examined why --redhatprovides and --redhatrequires
no longer work. Cross reference: bug #106843


Version-Release number of selected component (if applicable):
rpmdb-fedora-0.95-0.20031010

Comment 1 Michael Schwendt 2003-10-15 02:25:04 UTC
Ooops! This also breaks rpm's --aid option.


Comment 2 Gene Czarcinski 2003-10-23 19:35:42 UTC
With rpmdb-fedora-0.95-0.20031022 in raawhide, the /etc/rpm/macros.solve appears
fixed.

Comment 3 Chris Ricker 2003-10-23 19:50:32 UTC
--redhatprovides still doesn't work:

[kaboom@skuld kaboom]$ rpm -q --redhatprovides xpdf
error: cannot open Packages index using db3 - No such file or directory (2)
error: cannot open Packages database in /usr/lib/rpmdb/i386-redhat-linux/redhat
no package provides xpdf
[kaboom@skuld kaboom]$ 


Comment 4 Chris Ricker 2003-10-23 19:57:54 UTC
There needs to be a s/rpmdb-redhat/rpmdb-fedora/g run against
/etc/rpm/macros.solve but other than that it looks good

Hmm, the bug isn't in macros.solve after all;

/usr/lib/rpm/rpmpopt-4.2.1 defines:

rpm alias --redhatprovides -q --define '_dbpath
/usr/lib/rpmdb/%{_arch}-%{_vendor}-%{_os}/redhat' --whatprovides \
    --POPTdesc=$"find package name that contains a provided capability (needs
rpmdb-redhat package installed)"

rpm alias --redhatrequires -q --define '_dbpath
/usr/lib/rpmdb/%{_arch}-%{_vendor}-%{_os}/redhat' --whatrequires \
    --POPTdesc=$"find package name that contains a required capability (needs
rpmdb-redhat package installed)"

changing those paths to /usr/lib/rpmdb/%{_arch}-%{_vendor}-%{_os}/fedora gets
further, but then it dies trying to open
/usr/lib/rpmdb/%{_arch}-%{_vendor}-%{_os}/fedora/Providename, which doesn't exist

Comment 5 Chris Ricker 2003-10-23 20:02:41 UTC
Interesting. Providename gets created once you run the rpm -q --redhat* as root.
It still doesn't work after that, though

Comment 6 Chris Ricker 2003-10-23 20:11:10 UTC
Looks like the problem is that the alternate rpm db files in fedora are empty:

[kaboom@skuld fedora]$ db_dump Packages 
VERSION=3
format=bytevalue
type=hash
db_pagesize=4096
HEADER=END
DATA=END
[kaboom@skuld fedora]$ ls -l
total 412
-rw-r--r--    1 root     root        16384 Oct 23 14:01 __db.001
-rw-r--r--    1 root     root      1318912 Oct 23 14:01 __db.002
-rw-r--r--    1 root     root       458752 Oct 23 14:01 __db.003
-rw-r--r--    1 root     root        12288 Oct 22 03:03 Packages
-rw-r--r--    1 root     root        12288 Oct 23 14:01 Providename
-rw-r--r--    1 root     root        12288 Oct 23 14:02 Requirename
[kaboom@skuld fedora]$ 

Comment 7 Gene Czarcinski 2003-10-23 21:37:02 UTC
I am not sure if the new package in rawhide is correct of not but the list of
files provided by rpmdb-fedora-0.95-0.20031010.i386.rpm which is on the test3
isos and the package now in rawhide differ significantly:

 rpm -qlp /home/redhat/severn/i386/RedHat/RPMS/rpmdb-fedora-0.95-0.20031010.i386.rpm
/etc/rpm/macros.solve
/usr/lib/rpmdb/i386-redhat-linux/fedora
/usr/lib/rpmdb/i386-redhat-linux/fedora/Basenames
/usr/lib/rpmdb/i386-redhat-linux/fedora/Conflictname
/usr/lib/rpmdb/i386-redhat-linux/fedora/Dirnames
/usr/lib/rpmdb/i386-redhat-linux/fedora/Filemd5s
/usr/lib/rpmdb/i386-redhat-linux/fedora/Group
/usr/lib/rpmdb/i386-redhat-linux/fedora/Installtid
/usr/lib/rpmdb/i386-redhat-linux/fedora/Name
/usr/lib/rpmdb/i386-redhat-linux/fedora/Packages
/usr/lib/rpmdb/i386-redhat-linux/fedora/Providename
/usr/lib/rpmdb/i386-redhat-linux/fedora/Provideversion
/usr/lib/rpmdb/i386-redhat-linux/fedora/Pubkeys
/usr/lib/rpmdb/i386-redhat-linux/fedora/Requirename
/usr/lib/rpmdb/i386-redhat-linux/fedora/Requireversion
/usr/lib/rpmdb/i386-redhat-linux/fedora/Sha1header
/usr/lib/rpmdb/i386-redhat-linux/fedora/Sigmd5
/usr/lib/rpmdb/i386-redhat-linux/fedora/Triggername


rpm -ql rpmdb-fedora
/etc/rpm/macros.solve
/usr/lib/rpmdb/i386-redhat-linux/fedora
/usr/lib/rpmdb/i386-redhat-linux/fedora/Packages


Comment 8 Michael Schwendt 2003-10-24 00:46:04 UTC
For --redhat{provides,requires} see bug #106843.

Comment 9 Michael Schwendt 2003-10-25 18:42:00 UTC
rpmdb-fedora-0.95-0.20031024 fixes this for me:

* macros.solve: %_solve_dbpath is correct
* --aid: works again



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