# using patch

## filter69

how do you use path to patch a kernel  i have never tried this b4

and its turning out to be more than i wanna read  :Smile: 

thanks

----------

## filter69

in my haste and drinking i misspelled patch as path

and changed the whole meaning of the post 

i need to patch my kernel and i cant seem to figure it out its killing me

since i really not a newbie to this .....

just never had to use patch b4 heh he  :Smile: 

----------

## steveD

1/Copy the patch file to /usr/src/linux (or the the folder containing your linux source).

2/Go to /usr/src/linux

gzip -cd patch-file.gz |patch -p1

OR

bzip2 -cd patch-file.bz2 |patch -p1

(if the patch file is bz2 format).

----------

## Malakin

The patch you're applying may expect linux to be in a certain directory. For example if you're trying to use the preempt patch for 2.4.19-pre7 it expects the directory to be named 2.4.19-pre7. You can open the patch file in a text editor and the directory name is obvious.

----------

