From: Stewart M. <smm...@gm...> - 2011-02-21 19:17:31
|
Hi all, I'd like to try to compile SD4L from source. I figure it's time given the fact that now every time there's even a minor update to the kernel, it breaks SD4L. (This would be for Ubuntu 10.04, 2.6-32-28 kernel. I know I can install it from the recent .deb file release if everything else fails, but I'd hate to bug Hans-Ulrich every time there's a kernel update). *And*, if there's an easy way for me to do so while doing all this, I could make the corresponding .deb files for distribution. I've been looking at the Scramdisk documentation, and this: https://help.ubuntu.com/community/CompilingEasyHowTo https://help.ubuntu.com/community/Kernel/Compile The latter because apparently I have to need the kernel sources to compile scramdisk. I've installed gcc and g++ via Synaptic. As I currently run scramdisk, I would suppose that I have no dependency issues to resolve (the libraries being already in-place, right?). I've also installed the Ubuntu packages build-essential and checkinstall. Question 1: But should I also install the following, which is recommended by the page on kernel source building? sudo apt-get install fakeroot build-essential crash kexec-tools makedumpfile kernel-wedge sudo apt-get build-dep linux sudo apt-get install git-core libncurses5 libncurses5-dev libelf-dev asciidoc binutils-dev Question 2: I read also in the Scramdisk documentationo that I need to obtain the source code for 2.6.32-28. This would be: sudo apt-get build-dep --no-install-recommends linux-image-2.6.32-28 apt-get source linux-image-2.6.32-28. Right? (The Ubuntu help page recommends using the "git" command as preferable but the above seems simpler). And what directly will this source code be downloaded to? Question 3: As I understand it, then I create a directory usr/src/linux and give my user account privileges to it: sudo chown $USER /usr/src/linux sudo chmod u+rwx /usr/src/linux Then I put the linux kernel source code I've downloaded into that (along with the file /boot/config-Version) and issue the commands: cd /usr/src/linux make oldconfig Is this right? Question 4: Then I unpackage the Scramdisk tarball into the directory /usr/src/linux. (That creates the subdirectory /usr/src/linux/Scramdisk-2.1, right?). Then I do the following: cd /usr/src/linux/ScramDisk-2.1 make sudo make install (or would sudo checkinstall be preferable for the last step?). Please clear up any misconceptions I have displayed. I have read the documentation, and I'm murky on some things. I've not done this before, but I'm sure once I do it successfully it will be easy. Also, if there's some way (as a friend has told me) to make the corresponding .deb package for distribution while doing this I'd be happy to do so. He says it would be simple, but the documentation I've seen indicates otherwise. Stewart |