Re: prepatch-2.0.34

Michael H. Warfield (mhw@wittsend.com)
Sat, 23 May 1998 08:57:05 -0400 (EDT)


Olaf Titz enscribed thusly:

> > I`ve downloaded the prepratch for 2.0.34pre16 and tried to apply it with patch
> > < /tmp/patch2034pre ...
> > After applying the patch I found tons of .c, .h and .orig files in
> > /usr/src/linux.

> You _must_ apply patches with -p1 or -p0, otherwise patch isn't able
> to create new files in the right directory. This is not mentioned (at
> least not prominently enough) in the man page.

Just to add a little detail here (if they didn't figure out to
use a -p option, they might not realize the difference between -p0 and -p1).

If you are in /usr/src - use -p0
If you are in /usr/src/linux - use -p1

The first option says to use the full and complete path, stripping no
path elements. The second option says to use the paths in the patch stripping
one element off of the front. Kernel patches are normally relative to the
parent directory of the linux source tree and include "linux" as the first
element. The -p1 will strip the leading "linux" off of that path. If you
are in /usr/src/linux and use -p0 you will end up with a bunch of files in
/usr/src/linux/linux/... and get errors saying that it can not find certain
files to patch.

> olaf

Mike

-- 
 Michael H. Warfield    |  (770) 985-6132   |  mhw@WittsEnd.com
  (The Mad Wizard)      |  (770) 925-8248   |  http://www.wittsend.com/mhw/
  NIC whois:  MHW9      |  An optimist believes we live in the best of all
 PGP Key: 0xDF1DD471    |  possible worlds.  A pessimist is sure of it!

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu