On Thu, 12 Aug 2010 13:30:51 -0400, Jeff Mahoney
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 08/09/2010 10:43 AM, doiggl@velocitynet.com.au wrote:
Hello, I need help to combine this shell script [1] and .spec file [2]into one .spec file to do the whole job and run from obs.
I've just added a section to README.SUSE to describe the process involved in adding custom patches.
Here it is.
- -Jeff
HOW TO ADD CUSTOM PATCHES
Typically patches are added to the appropriate patches.* directory (e.g. patches.fixes) and to series.conf. When the kernel-source package is exported from the git repository, the patch will be automatically added to the appropriate patch tarball.
If your goal is to create a kernel with only a few additional patches and you don't want to be bothered with using the git repository, there is an easier way.
The kernel-source SRPM ships with two empty archives that can be be filled and automatically expanded when building the kernel. You can use these to add your own patches and config options without disturbing the rest of the kernel package. This is useful if you are using the openSUSE Build Service and link to the main kernel-source project instead of creating your own branch. The advantage to this is that your project will automatically receive all the changes that go into the main project without any further effort.
To add a patch using this mechanism, just add it to the patches.addon.tar.bz2 archive and add an entry to the series.conf file. The archive will be expanded automatically with the other kernel patches when the source tree is constructed.
Some patches may add new Kconfig options. The config.addon.tar.bz2 archive contains the same hierarchy as config.tar.bz2, but is under config.addon. You can add your new config options to files named after their config/ counterparts.
For example, the file used to configure the i386 default kernel is named config/i386/default. To add config options to that kernel, you would create a new file called config.addon/i386/default with the options as formatted in a normal Linux kernel .config file. This is important because the kernel build is non-interactive and will fail if it encounters new config options without entries in the config file.
- -- Jeff Mahoney SUSE Labs
Hello, Thanks for the info. I want to use this option with one patch. Referring to: The kernel-source SRPM ships with two empty archives that can be be filled and automatically expanded when building the kernel. You can use these to add your own patches and config options without disturbing the rest of the kernel package. This is useful if you are using the openSUSE Build Service and link to the main kernel-source project instead of creating your own branch. The advantage to this is that your project will automatically receive all the changes that go into the main project without any further effort. To add a patch using this mechanism, just add it to the patches.addon.tar.bz2 archive and add an entry to the series.conf file. The archive will be expanded automatically with the other kernel patches when the source tree is constructed. Using the readme info and the spec file [1] from 11.3 with these files[2]. - This is what I've done so far. # tar -cvf patches.addon.tar patches.addon patches.addon/ patches.addon/reiser4-for-2.6.34.patch # bzip2 -v patches.addon.tar patches.addon.tar: 5.316:1, 1.505 bits/byte, 81.19% saved, 2396160 in, 450745 out. I will use a copy of series.conf [3] for (x86 and x86_84 architecture). Questions - Which line/section do I add the extra reiser4-for-2.6.34.patch line to and what should the line look like? - If I cannot use that series.conf [3] what should series.conf look with the reiser4-for-2.6.34.patch line added in ? [1] https://build.opensuse.org/package/view_file?file=kernel-vanilla.spec&package=kernel-vanilla&project=home%3Adoiggl [2] https://build.opensuse.org/package/files?package=kernel-vanilla&project=home%3Adoiggl [3] https://build.opensuse.org/package/view_file?file=series.conf&package=kernel-vanilla&project=home%3Adoiggl Cheers Glenn -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-kernel+help@opensuse.org