Sample Header Ad - 728x90

How to build a RPM with circular dependencies?

0 votes
0 answers
71 views
I am trying to build mesa-7.6-0.1.fc11.src from source.
$ yumdownloader --source mesa
$ cd rpmbuild/SPECS
$ rpmbuild -ba mesa.spec
error: Failed build dependencies:
        freeglut-devel is needed by mesa-7.6-0.1.fc11.src
No problem. I will download this dependency from source and build that first.
$ yumdownloader --source freeglut-devel
$ rpm -ivh freeglut-2.4.0-16.fc11.src.rpm
$ cd rpmbuild/SPECS
$ rpmbuild -ba freeglut.spec
error: Failed build dependencies:
    libGLU-devel is needed by freeglut-2.4.0-16.fc11.src
It looks like I need another package. Let's see which source RPM is needed to build it.
$ yumdownloader --source mesa-libGLU-devel
Loaded plugins: refresh-packagekit
mesa-7.6-0.1.fc11.src.rpm                       | 7.1 MB     00:00
Alright... so mesa needs freeglut-devel which needs libGLU-devel which is built by mesa. This is a circular dependency. When considering only building from source and not installing a prebuilt package, how can this circular build dependency be resolved? libGLU-devel is only one of several RPMs that is built by mesa. Is it possible to build only that one RPM instead of all of them to see if this avoids the dependency on freeglut? Even if I try to download the freeglut-devel package, it ends up resolving dependencies for the same package I am trying to build.
Dependencies Resolved

======================================================================================================================================
 Package                               Arch                     Version                             Repository                   Size
======================================================================================================================================
Installing:
 freeglut-devel                        i586                     2.4.0-16.fc11                       fedora                      111 k
Installing for dependencies:
 freeglut                              i586                     2.4.0-16.fc11                       fedora                      148 k
 mesa-dri-drivers                      i586                     7.6-0.1.fc11                        updates                     2.2 M
 mesa-libGL                            i586                     7.6-0.1.fc11                        updates                     174 k
 mesa-libGL-devel                      i586                     7.6-0.1.fc11                        updates                     485 k
 mesa-libGLU                           i586                     7.6-0.1.fc11                        updates                     204 k
 mesa-libGLU-devel                     i586                     7.6-0.1.fc11                        updates                     108 k

Transaction Summary
======================================================================================================================================
Install       7 Package(s)
Upgrade       0 Package(s)
What is the correct way to resolve this circular build dependency? For context, I am building packages from Fedora 11 from source for testing DRI drivers that only exist for very old kernels.
Asked by Zhro (2831 rep)
Sep 24, 2024, 04:27 AM
Last activity: Mar 27, 2025, 09:47 AM