[opensuse-packaging] How to specify a version of kernel-syms to use?
Hi: I am trying to build a KMP package for SLES 11 SP3 using IBS. I am modeling my package after ocfs2, if that helps answer my question. My package patches the rbd device driver, patching rbd.c, then builds the rbd.ko kernel module. I can get this to work on my local system using rpmbuild. My local system is SLES 11 SP3, and the kernel on it is 3.0.101-0.35-default. But when I specify SLES 11 SP3 as a build target in IBS, it seems to get kernel-syms-3.0.76-0.11.1. This causes patch errors because the 3.0.76 kernel had an older version of rbd.c. In my spec file, I have: BuildRequires: kernel-syms I have also tried: BuildRequires: kernel-syms = 3.0.101 and BuildRequires: kernel-syms >= 3.0.101 I have several questions: - Why does my system have a newer 3.0.101 kernel and the build service have an older one? - Can I specify 3.0.101, or should I just patch against 3.0.76? - How do I know what kernel a particular OS flavor will use in general? -- Lee Duncan SUSE Labs -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Wednesday 2014-07-23 21:57, Lee Duncan wrote:
My package patches the rbd device driver, patching rbd.c, then builds the rbd.ko kernel module.
[...]This causes patch errors because the 3.0.76 kernel had an older version of rbd.c.
I have also tried: BuildRequires: kernel-syms = 3.0.101
kernel-syms does not give you rbd.c. In fact, the source is normally not installed anymore. So, in light of future compatibility, the only sensible way is to ship rbd.c in your own package and not depend on a preexisting one. -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Jul 23, 2014, at 2:57 PM, Lee Duncan <lduncan@suse.com> wrote:
I have several questions:
- Why does my system have a newer 3.0.101 kernel and the build service have an older one? The build service is only enabling the SLES11-SP3-Pool repo (the complete repo as of the time SP3 shipped, and a superset of the DVD), not SLES11-SP3-Updates. There have of course been several kernel updates since the release of SP3.
Perhaps someone else can explain how to enable the SP3-Updates repo for your build, or if it is even possible to do so with OBS. I myself don't know, but would also like to learn...
- Can I specify 3.0.101, or should I just patch against 3.0.76? If you can get the updates repo enabled, then you can build against the latest version, but if you can patch against the older version (and the kernel ABI hasn't changed since [1]), that might be preferable, since you'd have one package that would work with all kernel versions for a given OS/SP release. Of course, getting your patch mainlined might be the better option...
- How do I know what kernel a particular OS flavor will use in general? Look at the kernel packages in the SLES-SPn-Pool repo, or the oss repo for opensuse (or a DVD ISO for either). Without update repos this is what will be used.
-Andrew [1] See https://www.novell.com/developer/Kmpm-code11.pdf -- kernel packages have RPM provides/requires for some driver symbols. This is why some kmp RPMs get updated with some kernel updates, but not all.-- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
I figured this out. Answer below (if anybody else has the problem). On 07/23/2014 12:57 PM, Lee Duncan wrote:
Hi:
I am trying to build a KMP package for SLES 11 SP3 using IBS.
I am modeling my package after ocfs2, if that helps answer my question.
My package patches the rbd device driver, patching rbd.c, then builds the rbd.ko kernel module.
I can get this to work on my local system using rpmbuild. My local system is SLES 11 SP3, and the kernel on it is 3.0.101-0.35-default.
But when I specify SLES 11 SP3 as a build target in IBS, it seems to get kernel-syms-3.0.76-0.11.1.
This causes patch errors because the 3.0.76 kernel had an older version of rbd.c.
In my spec file, I have:
BuildRequires: kernel-syms
I have also tried:
BuildRequires: kernel-syms = 3.0.101
and
BuildRequires: kernel-syms >= 3.0.101
I have several questions:
- Why does my system have a newer 3.0.101 kernel and the build service have an older one?
Because I was using SLE 11 SP3, and I needed to use SLE 11 SP3 Update:Test, under the "Advanced" tab in the repository.
- Can I specify 3.0.101, or should I just patch against 3.0.76?
- How do I know what kernel a particular OS flavor will use in general?
I know I can check the git tags in the kernel source repository to find out what driver each kernel version has, but I still don't know where a list of release-vs-kernel-version exists.
-- Lee Duncan SUSE Labs -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Quoting Lee Duncan <lduncan@suse.com>:
- How do I know what kernel a particular OS flavor will use in general?
I know I can check the git tags in the kernel source repository to find out what driver each kernel version has, but I still don't know where a list of release-vs-kernel-version exists.
At least for SLE/OES, you should be able to refer to: http://www.novell.com/support/kb/doc.php?id=3594951 Cheers, Dominique -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
participants (4)
-
Andrew Daugherity
-
Dominique Leuenberger a.k.a. Dimstar
-
Jan Engelhardt
-
Lee Duncan