Why won't the 11.0 source package install? (And other q's)

This is driving me batty.

I installed 11.0 from the DVD .iso. Everything is fine, it works great. However, I want to compile a new kernel so I can turn on support for additional hardware (a wireless USB dongle, in this case). I downloaded the package “kernel-source-2.6.25.5-1.1.src.rpm” but when I install it (yes, as root) using “rpm -i ./kernel-source-2.6.25.5-1.1.src.rpm” nothing happens. If I do “rpm -q kernel-source-2.6.25.5-1.1” or “rpm -q kernel-source-2.6.25.5-1.1.src” rpm says it’s not installed. What’s going on? There’s no log messages, and if I

Also, once I manage to get this installed, is there a script that will probe my machine and generate a baseline .config? There’s a million options in there and I’m not even sure what some of them do.

Thanks!
Jim

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

First, get some verboseness out of your RPM command:

rpm -ivh ./kernel-source-2.6.25.5-1.1.src.rpm

Second, after doing that, you’ll likely see that it is installing. RPM
spits out errors if there are problems by by default it doesn’t output
tons of data just for kicks. Look in /usr/src/linux to see if you have
the source. Also when querying I typically take a bit of a performance
hit and query with grep to avoid pain with exact package name matches:

rpm -qa | grep -i kernel-source

Anyway, give those a shot.

Good luck.

jimberke wrote:
> This is driving me batty.
>
> I installed 11.0 from the DVD .iso. Everything is fine, it works
> great. However, I want to compile a new kernel so I can turn on support
> for additional hardware (a wireless USB dongle, in this case). I
> downloaded the package “kernel-source-2.6.25.5-1.1.src.rpm” but when I
> install it (yes, as root) using “rpm -i
> ./kernel-source-2.6.25.5-1.1.src.rpm” nothing happens. If I do “rpm -q
> kernel-source-2.6.25.5-1.1” or “rpm -q kernel-source-2.6.25.5-1.1.src”
> rpm says it’s not installed. What’s going on? There’s no log messages,
> and if I
>
> Also, once I manage to get this installed, is there a script that will
> probe my machine and generate a baseline .config? There’s a million
> options in there and I’m not even sure what some of them do.
>
> Thanks!
> Jim
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJGHs33s42bA80+9kRApheAJ9+Vy8Rt8USy47py5nlrZqYrLekSwCeMu6D
VmQgydUpAm6yHHSIJS8zGNE=
=b2Li
-----END PGP SIGNATURE-----

Thanks for the suggestions! Rpm is definitely doing something. Using -v and -vv I can see it putting a bunch of stuff in /usr/src/packages/SOURCES, but I’m at a loss for what to do next. There’s no Makefile and the README.SUSE doesn’t seem to have been written for this package. Any ideas?

Thanks!
Jim

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

<quote>
Look in /usr/src/linux…
</quote>

Also, rpm -ql kernel-source to see what files were installed as part
of that package.

Good luck.

jimberke wrote:
> Thanks for the suggestions! Rpm is definitely doing something. Using
> -v and -vv I can see it putting a bunch of stuff in
> /usr/src/packages/SOURCES, but I’m at a loss for what to do next.
> There’s no Makefile and the README.SUSE doesn’t seem to have been
> written for this package. Any ideas?
>
> Thanks!
> Jim
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJGIvX3s42bA80+9kRAu9qAKCK2DUIGW4kse54oOwJ4tnB+f31VACghUmQ
eaNMxFmPiVwBTC6MAqsgmnc=
=nW9z
-----END PGP SIGNATURE-----

I think I’m ok now. Something is strange with the 2.6.25.5-1.1 kernel source package at download.opensuse.com. I used Yast to install the source package for 2.6.25.18-0.2 and that seems to have put things in the right place.

I also learned about “make oldconfig”. Compiling now…

Thanks!
Jim

Just FYI, .src.rpms don’t show up in rpm listings. They just get unpacked in /usr/src/packages/. However the kernel sources can also be had as a kernel-source normal RPM. That one will register and unpack in /usr/src/linux

Why not? Doesn’t the fact that it’s an .rpm imply that it should be added to the database? And what are you then supposed to do with them in /usr/src/packages?

All I want to do is put the full source tree on my 2.6.26.5-1.1 Suse 11.0 distro so I can compile against it. Since I wasn’t having much luck with that I installed kernel-source-2.6.25.18-0.2, which seemed to work as expected. Unfortunately, using “make oldconfig” (which seemed to be the safest bet for the first try) the compile bombs halfway through.

There aren’t precompiled Suse kernels, are there?

Argh… I’m seriously starting to consider another distro…

Thanks.
Jim

Hi
You use rpmbuild -bb <name_of_spec_file> to build the rpm, or just
download the actual src rpm and use rpmbuild --rebuild
<name_of_source_rpm>.

What you need to do is just install the kernel-source kernel-syms and
kernel-headers for recompiling then look in /usr/src/linux (note, the
linux is just a softlink to the kernel).

I use the following to prepare this system for rebuilding my patched
toshiba_acpi module;


make clean
make oldconfig
make prepare
make scripts
cp /usr/src/linux-obj/i386/default/Module.symvers /usr/src/linux/

Yes there are precompiled ones, have a search here on kernel…
Get It


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 11.0 x86 Kernel 2.6.25.18-0.2-default
up 2 days 3:05, 1 user, load average: 0.51, 0.15, 0.04
GPU GeForce 6600 TE/6200 TE - Driver Version: 177.80

Hi
You might also want to peruse this;
How To Compile A
Kernel - The SuSE Way


Cheers Malcolm °¿° (Linux Counter #276890)
openSUSE 11.0 x86 Kernel 2.6.25.18-0.2-default
up 2 days 3:26, 1 user, load average: 0.71, 0.20, 0.08
GPU GeForce 6600 TE/6200 TE - Driver Version: 177.80

Because, and this is the way it always has been for all RPM based distros, source RPMs are not really part of the installed software base of a machine. Source RPMs are merely a convenient way to package the, um, sources and patches for building a binary RPM. So they do not have prerequisites, nor are they tracked in the package database. However they may have build dependencies, usually -devel package that are needed to compile the sources. Others have already posted how to build the unpacked contents in /usr/src/packages/SOURCE starting from the package, or from the spec file.

If you are really interested there are tutorials on how the RPM build ecology works.

But as I’ve already pointed out, there is a “binary” RPM for the kernel sources that is intended for building packages against, and that is the kernel-source RPM. If you just want to build something against a particular kernel version, rather than build the kernel itself, this is what you want. It’s what the PUEL version of VirtualBox needs for example, and it’s the right choice because it does have dependencies and will be updated in the normal way when the kernel packages are updated.