LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   bz2 kernel patches?? howto apply them... (https://www.linuxquestions.org/questions/linux-software-2/bz2-kernel-patches-howto-apply-them-28433/)

guerilla fighta 08-21-2002 09:19 AM

bz2 kernel patches?? howto apply them...
 
how do i patch my kernel source's (2.4.18) with the 2.4.19 patch in bz2 format ? i searched linuxquestions and came up with :

zcat patch-2.4.X.gz | patch -p1

(note: im a little unsure whether ive got the above line 100% correct :confused:)

i tried this but i couldnt get it to work. id be grateful if someone could help me.

thanks :)

Frustin 08-21-2002 09:31 AM

in future may i recomend a google search.

but for now:
cd /usr/src/linux
patch -p1 < PATCH-FILE

guerilla fighta 08-21-2002 04:00 PM

thanx Frustin. i found out what was wrong, and it was just that i didnt have the patch rpm installed. It's an easy mistake to make. :o

now ive just gotta figure out howto work patch, when i use it nothing seems to work ?! i browsed the man page for patch, but im still a little confused. could someone help me out here ??

thanks, :)

Frustin 08-27-2002 02:07 AM

you'll have to elaborate i'm afraid. i dont understand what you mean by "nothing seems to work".

doublefailure 08-27-2002 02:20 AM

i believe when u apply patch
if u don't see any error msg, u r fine,

if something goes wrong, it'll generate errors..

if i remember correct =)

Frustin 08-27-2002 02:44 AM

i concur.

if you do want to see some more infomation put the --verbose switch in.

guerilla fighta 08-27-2002 02:55 PM

Basically when i do:

patch -p1 < patch-2.4.19

its just like im pressing return. Im not seeing any message's about 'trying to allocate hunks' or anything like that, and im pretty sure that the command i typed (shown above) isnt doing anything.

Thanks for the info on the --verbose switch. I'll try that, and hopefully i should be able to work out what went wrong (if anything did go wrong) fairly quickly.

cheers :)

unSpawn 08-27-2002 03:38 PM

you can also use the "--dry-run" flag to test it, comes in handy once in a while...

doublefailure 08-28-2002 03:08 PM

what u can do is,
look at the patch file with an editor
and what file the patch will change..

save the file in a directory
apply the patch
and $diff original-file patched-file

Frustin 08-29-2002 02:07 AM

--dry-run will have the same effect. plus if you dont like it you can uninstall the patch anyway (with the -R option).

guerilla fighta 08-31-2002 04:55 AM

I tried the --verbose switch, but I'm getting this error message for nearly every file that is compared to its newer version in the 2.4.19 patch :

Hmm... Looks like a unified diff to me...
Can't find file to patch at input line 4
Perhaps you used the wrong -p or --strip option ?
The text leading up to this was :
-----------------------------------------------------------------------------
| diff -urN linux-2.4.18/COPYING linux-2.4.19/COPYING
| - - - linux-2.4.18/COPYING Tue Oct 9 15:00:06 2001
| +++ linux-2.4.19/COPYING Fri Aug 2 17:39:42 2002
-----------------------------------------------------------------------------

(BTW, the file 'COPYING' is just an example, due to the fact that its the first file that was compared)

Every time i get this error (and I'm getting it an awful lot :cry: ) i have to type in the filename and its path, which is *very* frustrating :mad: ).

What's going wrong ? Is it an error on my behalf, or something wrong with patch ??

Frustin 09-02-2002 02:04 AM

where are you running the patch? hopefully in the /usr/src/linux-2.4.18 (or the equivilent directory). that should be the correct -p option.

show us what you are doing exactly i.e. copy command lines and stuff.


All times are GMT -5. The time now is 07:29 AM.