You are not logged in.
Pages: 1
Hi,
In reference to this post: http://forum.eeeuser.com/viewtopic.php?pid=30515#p30515
Please could someone explain to me how to apply the patch to the source code?
I tried: cat patch_file | patch -p0 where patch_file contained the patch code,
[jack@tmain L2-linux-driver_new]$ cat patch_file | patch -p0
can't find file to patch at input line 5
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Only in l2.fixed: Module.symvers
|diff -u l2/at_ethtool.c l2.fixed/at_ethtool.c
|--- l2/at_ethtool.c 2007-04-20 09:34:48.000000000 +0200
|+++ l2.fixed/at_ethtool.c 2007-11-25 01:58:24.000000000 +0100
--------------------------
My directory structure is as follows:
[jack@tmain L2-linux-driver_new]$ ls -R
.:
COPYING atl2.spec patch_file release_note.txt
atl2.7 ldistrib.txt readme src
./src:
Makefile at_ethtool.c at_hw.h at_osdep.h kcompat.c kcompat_ethtool.c
at.h at_hw.c at_main.c at_param.c kcompat.h
I tried renaming src to l2, but that gave me further errors.
Any ideas?
Thanks alot,
Jack
Last edited by tntcoda (2007-12-25 23:55:43)
Offline
The comment "Perhaps you used the wrong -p or --strip option?" is you clue here. Try "patch -Np1 -i <patch file>".
Offline
Thanks, that gave me:
[jack@tmain l2]$ patch -Np1 -i patch_file
can't find file to patch at input line 5
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|Only in l2.fixed: Module.symvers
|diff -u l2/at_ethtool.c l2.fixed/at_ethtool.c
|--- l2/at_ethtool.c 2007-04-20 09:34:48.000000000 +0200
|+++ l2.fixed/at_ethtool.c
Thats the same even if i rename src to l2, so that l2/at_ethtool.c exists.
Offline
[jack@tmain l2]$ patch -Np1 -i patch_file
Do this one directory down (i.e. cd .. from that directory). If that does not work, just adjust the number after p to 0 or 2 and try it.
Offline
Thanks again, afraid that still results in the same errors, even with increasing the number of strips
Offline
try
[jack@tmain L2-linux-driver_new]$ patch -p0 -i patch_file src/at_ethtool.c
Offline
Thanks, that results in:
patching file src/at_ethtool.c
patch: **** malformed patch at line 7: #endif
Any ideas?
Offline
Pages: 1