I'm having a RPM that contains mixed 64bit and 32bit binaries. One of the binaries depends on 32bit i686 packages. When I try to install the package yum gives me an error, noting that the package requires the 32bit packages. However when I just try to install the required packages myself it works flawless.


In my spec file I have

Requires:       glibc.i686 libstdc++.i686 device-mapper-libs.i686 lshw

When I try to install the package on a CentOS 6.3 system I get:

# yum update gamigo-kvm-tools
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Setting up Update Process
Resolving Dependencies
--> Running transaction check
---> Package gamigo-kvm-tools.x86_64 0:0.0.7-4 will be updated
---> Package gamigo-kvm-tools.x86_64 0:0.0.9-4 will be an update
--> Processing Dependency: libstdc++.i686 for package: gamigo-kvm-tools-0.0.9-4.x86_64
--> Processing Dependency: glibc.i686 for package: gamigo-kvm-tools-0.0.9-4.x86_64
--> Processing Dependency: device-mapper-libs.i686 for package: gamigo-kvm-tools-0.0.9-4.x86_64
--> Finished Dependency Resolution
Error: Package: gamigo-kvm-tools-0.0.9-4.x86_64 (gamigo-CentOS-6-x86_64-liv)
           Requires: libstdc++.i686
Error: Package: gamigo-kvm-tools-0.0.9-4.x86_64 (gamigo-CentOS-6-x86_64-liv)
           Requires: device-mapper-libs.i686
Error: Package: gamigo-kvm-tools-0.0.9-4.x86_64 (gamigo-CentOS-6-x86_64-liv)
           Requires: glibc.i686
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

However when I manually install the referenced packages, I get

# yum install libstdc++.i686 device-mapper-libs.i686 glibc.i686
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
Setting up Install Process
Package libstdc++-4.4.6-4.el6.i686 already installed and latest version
Package device-mapper-libs-1.02.74-10.el6.i686 already installed and latest version
Package glibc-2.12-1.80.el6_3.5.i686 already installed and latest version
Nothing to do

I don't quite understand why the Error occurs and what it's trying to tell me. I see that it's only occurring for the 32bit packages as the fourth required package 'lshw' seems to be no problem. Is there a special specfile syntax to reference 32bit packages?

  • Contact the packager and report the two bugs. – Michael Hampton Oct 16 '12 at 13:16
  • I am the packager myself, and it's not a bug. You just reference 32bit libraries in a spec file differently than you would on the shell. – Lukas Loesche Oct 16 '12 at 14:10
  • AFAIR, RPM has never supported "several architectures" packages. I believe your .i?86 dependencies are wrong, and perhaps are the cause of your problems. Also, libraries are autodetected as dependencies. – vonbrand Feb 25 '13 at 10:57

I just found the answer. My Requires line should be

Requires:       glibc(x86-32) libstdc++(x86-32) device-mapper-libs(x86-32)

as described in http://www.rpm.org/wiki/PackagerDocs/ArchDependencies

| improve this answer | |
  • This just shows how awesome serverfault is. You post a question and in 12 minutes you have a detailed and precise answer! – David Schwartz Oct 16 '12 at 13:17
  • 1
    Especially if you find the answer yourself :-P ...had I searched 12 min. longer before asking on serverfault, I might not have posted the question at all. Than again, it might be useful for others with the same problem. – Lukas Loesche Oct 16 '12 at 14:12
  • Should note that specifying requirement arch. using round brackets only works on rpmbuild version > 4.6... Still have not found how to do it in 4.4 – ThePracticalOne Jan 22 '15 at 0:01

Since somebody answered for answered for 4.6 -- for the 4.4 version, if you depend on a 32bit RPM a way around difficulties or lack of syntax that may work for others:

Requires:      /lib/libc.so.6

Since this file gets provided by the 32bit of glibc the installation will pull in the correct dependency.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.