[opensuse-buildservice] How to setup OBS to support multilib builing
Hi, I have setup a local OBS (2.3.0), and I'm working on some packages that requires both 32 and 64 bit packages for building, I don't find a way to make this work. It seems OBS does not support building packages this way. I have put both 32 and 64 bit packages in the repository, but when I use package.i386 or package.x86_64 in the requires of the package to be built, the whole string include the arch name will be treated as a package name and OBS will complain that the package is unresolvable. Any help on this will be appreciated! Thank you! -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-buildservice+owner@opensuse.org
On 2012-06-11 22:44:29 +0000, He Zhenxing said:
Hi,
I have setup a local OBS (2.3.0), and I'm working on some packages that requires both 32 and 64 bit packages for building, I don't find a way to make this work. It seems OBS does not support building packages this way. I have put both 32 and 64 bit packages in the repository, but when I use package.i386 or package.x86_64 in the requires of the package to be built, the whole string include the arch name will be treated as a package name and OBS will complain that the package is unresolvable.
I can say that 32/64 bit packaging is absolutely possible with OBS; I do it daily. First question: What OS distribution are you using? This is important. - Red Hat derived distributions (RHEL, Fedora, CentOS, Scientific Linux, etc.) handle 32 bit libraries differently than what SUSE derived distributions. - RedHat distributions simply have two packages - an x86_64 and an i386 package. - I'll admit some ignorance in how to "correctly" manage 32-bit packages with 64-bit RedHat; my experience has largely been that the RedHat-style is a PITA in comparison. - In contrast, SUSE distros typically have x86_64 packages - but there is a -32bit package (such as glibc-32bit). I've found it to be far simpler to understand and manage 32 bit packages on a 64-bit system with the "SUSE way". I'd love for somebody to correct me with a better way (PLEASE!) - but with Red Hat derived distributions, I've made it a practice to create a "32bitsupport" package - where I've simply unpacked & re-packed the 32-bit binaries. Then I require the "32bitsupport" package. By doing that, I have no issues at all building a package that has both 32 and 64-bit binaries. On the other hand, with a SUSE-derived distribution, it's a piece of cake to handle the dependencies - just require the "-32bit" pakages, and you're on your way. -- Troy Telford -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-buildservice+owner@opensuse.org
Troy Telford wrote:
On 2012-06-11 22:44:29 +0000, He Zhenxing said:
Hi,
I have setup a local OBS (2.3.0), and I'm working on some packages that requires both 32 and 64 bit packages for building, I don't find a way to make this work. It seems OBS does not support building packages this way. I have put both 32 and 64 bit packages in the repository, but when I use package.i386 or package.x86_64 in the requires of the package to be built, the whole string include the arch name will be treated as a package name and OBS will complain that the package is unresolvable.
I can say that 32/64 bit packaging is absolutely possible with OBS; I do it daily.
First question: What OS distribution are you using? This is important.
RHEL 5
- Red Hat derived distributions (RHEL, Fedora, CentOS, Scientific Linux, etc.) handle 32 bit libraries differently than what SUSE derived distributions. - RedHat distributions simply have two packages - an x86_64 and an i386 package. - I'll admit some ignorance in how to "correctly" manage 32-bit packages with 64-bit RedHat; my experience has largely been that the RedHat-style is a PITA in comparison. - In contrast, SUSE distros typically have x86_64 packages - but there is a -32bit package (such as glibc-32bit). I've found it to be far simpler to understand and manage 32 bit packages on a 64-bit system with the "SUSE way".
Yes, the SUSE way is much simpler, but unfortunately we have to deal with the RedHat way :(
I'd love for somebody to correct me with a better way (PLEASE!) - but with Red Hat derived distributions, I've made it a practice to create a "32bitsupport" package - where I've simply unpacked & re-packed the 32-bit binaries. Then I require the "32bitsupport" package. By doing that, I have no issues at all building a package that has both 32 and 64-bit binaries.
Repacking should work, but I'd like to see if there are other ways.
On the other hand, with a SUSE-derived distribution, it's a piece of cake to handle the dependencies - just require the "-32bit" pakages, and you're on your way.
-- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-buildservice+owner@opensuse.org
On Tue, Jun 12, 2012 at 06:44:29AM +0800, He Zhenxing wrote:
I have setup a local OBS (2.3.0), and I'm working on some packages that requires both 32 and 64 bit packages for building, I don't find a way to make this work. It seems OBS does not support building packages this way. I have put both 32 and 64 bit packages in the repository, but when I use package.i386 or package.x86_64 in the requires of the package to be built, the whole string include the arch name will be treated as a package name and OBS will complain that the package is unresolvable.
Yes, that's currently pretty much hardcoded in the "build" package used for package building. It's because on SUSE you don't need multiple packages with the same name and different architectures installed, the "32bit" versions get repackaged into <name>-32bit packages, thus they don't conflict. To make Fedora/RedHat style multilib work, we need to change two things: - the way the build service stores the packages in the "full" tree (:full on disk, _repository over the API) - the way the "build" package deals with the packages OBS-2.3 won't support it, though. Sorry. Cheers, Michael. -- Michael Schroeder mls@suse.de SUSE LINUX Products GmbH, GF Jeff Hawn, HRB 16746 AG Nuernberg main(_){while(_=~getchar())putchar(~_-1/(~(_|32)/13*2-11)*13);} -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-buildservice+owner@opensuse.org
participants (3)
-
He Zhenxing
-
Michael Schroeder
-
Troy Telford