need help to compile wine with patches

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
tedem82
Newbie
Newbie
Posts: 2
Joined: Sun May 24, 2009 6:47 pm

need help to compile wine with patches

Post by tedem82 »

hello,
i have a problem to patch wine.
it's about this bug : http://bugs.winehq.org/show_bug.cgi?id=13335,
and concerning mmap.patch.
here is the command line that i tried : patch -p1 < mmap.patch

but here is the result :

Code: Select all

teddy@tedportable:~/wine/wine-1.1.18$ patch -p1 < mmap.patch 
patching file dlls/ntdll/ntdll_misc.h
Hunk #1 FAILED at 139.
1 out of 1 hunk FAILED -- saving rejects to file dlls/ntdll/ntdll_misc.h.rej
can't find file to patch at input line 34
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/dlls/ntdll/pthread.c b/dlls/ntdll/pthread.c
|index 60b6033..e2c3aa6 100644
|--- a/dlls/ntdll/pthread.c
|+++ b/dlls/ntdll/pthread.c
--------------------------
[b]File to patch: [/b]
Skip this patch? [y] n
File to patch: pthread.c
pthread.c: No such file or directory
Skip this patch? [y] 
Skipping patch.
1 out of 1 hunk ignored
patching file dlls/ntdll/virtual.c
Hunk #1 FAILED at 53.
Hunk #2 succeeded at 149 (offset 1 line).
Hunk #3 succeeded at 362 (offset 1 line).
Hunk #4 succeeded at 389 (offset 1 line).
1 out of 10 hunks FAILED -- saving rejects to file dlls/ntdll/virtual.c.rej
patching file include/wine/pthread.h
Hunk #1 FAILED at 77.
Hunk #2 succeeded at 61 (offset -51 lines).
1 out of 2 hunks FAILED -- saving rejects to file include/wine/pthread.h.rej
patching file libs/wine/mmap.c
patching file libs/wine/port.c
can't find file to patch at input line 519
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/loader/kthread.c b/loader/kthread.c
|index c791ef6..3d62ddf 100644
|--- a/loader/kthread.c
|+++ b/loader/kthread.c
--------------------------
File to patch: 
Skip this patch? [y] 
Skipping patch.
4 out of 4 hunks ignored
patching file loader/pthread.c
Hunk #1 succeeded at 63 with fuzz 1 (offset 11 lines).
Hunk #2 succeeded at 73 (offset 11 lines).
Hunk #3 succeeded at 213 (offset 22 lines).
Hunk #4 succeeded at 272 (offset 22 lines).
Hunk #5 succeeded at 281 (offset 22 lines).
what do i make with the question "File to patch:" ?



PS: sorry for my english, i'm french.
John Drescher

need help to compile wine with patches

Post by John Drescher »

On Sun, May 24, 2009 at 7:52 PM, tedem82 <[email protected]> wrote:
hello,
i have a problem to patch wine.
it's about this bug : http://bugs.winehq.org/show_bug.cgi?id=13335,
and concerning mmap.patch.
here is the command line that i tried : patch -p1 < mmap.patch

but here is the result :


Code:
teddy@tedportable:~/wine/wine-1.1.18$ patch -p1 < mmap.patch
patching file dlls/ntdll/ntdll_misc.h
Hunk #1 FAILED at 139.
1 out of 1 hunk FAILED -- saving rejects to file dlls/ntdll/ntdll_misc.h.rej
can't find file to patch at input line 34
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/dlls/ntdll/pthread.c b/dlls/ntdll/pthread.c
|index 60b6033..e2c3aa6 100644
|--- a/dlls/ntdll/pthread.c
|+++ b/dlls/ntdll/pthread.c
--------------------------
File to patch:
Skip this patch? [y] n
File to patch: pthread.c
pthread.c: No such file or directory
Skip this patch? [y]
Skipping patch.
1 out of 1 hunk ignored
patching file dlls/ntdll/virtual.c
Hunk #1 FAILED at 53.
Hunk #2 succeeded at 149 (offset 1 line).
Hunk #3 succeeded at 362 (offset 1 line).
Hunk #4 succeeded at 389 (offset 1 line).
1 out of 10 hunks FAILED -- saving rejects to file dlls/ntdll/virtual.c.rej
patching file include/wine/pthread.h
Hunk #1 FAILED at 77.
Hunk #2 succeeded at 61 (offset -51 lines).
1 out of 2 hunks FAILED -- saving rejects to file include/wine/pthread.h.rej
patching file libs/wine/mmap.c
patching file libs/wine/port.c
can't find file to patch at input line 519
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/loader/kthread.c b/loader/kthread.c
|index c791ef6..3d62ddf 100644
|--- a/loader/kthread.c
|+++ b/loader/kthread.c
--------------------------
File to patch:
Skip this patch? [y]
Skipping patch.
4 out of 4 hunks ignored
patching file loader/pthread.c
Hunk #1 succeeded at 63 with fuzz 1 (offset 11 lines).
Hunk #2 succeeded at 73 (offset 11 lines).
Hunk #3 succeeded at 213 (offset 22 lines).
Hunk #4 succeeded at 272 (offset 22 lines).
Hunk #5 succeeded at 281 (offset 22 lines).




what do i make with the question "File to patch:" ?

From what I see there are 2 patches 1 patch for 1.1.19 and the other
for 1.1.15. If you use wine at the same version the patch was made for
you should not have these problems. My suggestion is to download wine
1.1.19 and try the final patch labeled "Forward port of proposed patch
to 1.1.19"

John
tedem82
Newbie
Newbie
Posts: 2
Joined: Sun May 24, 2009 6:47 pm

Post by tedem82 »

thanks, it works with wine 1.1.19 :)

but i have a question with the patch for warhammer online ( which works with wine 1.1.18 ) , i have this result :

Code: Select all

teddy@tedportable:~/wine/wine-1.1.19$ patch -p0 < war-wine-1.1.18.patch 
patching file dlls/wined3d/device.c
Hunk #1 succeeded at 3800 (offset -4 lines).
patching file dlls/wined3d/directx.c
Hunk #1 succeeded at 3470 (offset 28 lines).
patching file dlls/wined3d/state.c
Hunk #1 succeeded at 3460 (offset -4 lines).
Hunk #2 succeeded at 3471 (offset -4 lines).
Hunk #3 succeeded at 3551 (offset -4 lines).
patching file dlls/wined3d/texture.c
patching file dlls/wined3d/wined3d_private.h
Hunk #1 succeeded at 1223 (offset 85 lines).
so, it's ok or there are errors ?
John Drescher

need help to compile wine with patches

Post by John Drescher »

On Mon, May 25, 2009 at 4:52 AM, tedem82 <[email protected]> wrote:
thanks, it works with wine 1.1.19 :)

but i have a question with the patch for warhammer online,
with wine 1.1.18, i have this result :

Code:
teddy@tedportable:~/wine/wine-1.1.19$ patch -p0 < war-wine-1.1.18.patch
patching file dlls/wined3d/device.c
Hunk #1 succeeded at 3800 (offset -4 lines).
patching file dlls/wined3d/directx.c
Hunk #1 succeeded at 3470 (offset 28 lines).
patching file dlls/wined3d/state.c
Hunk #1 succeeded at 3460 (offset -4 lines).
Hunk #2 succeeded at 3471 (offset -4 lines).
Hunk #3 succeeded at 3551 (offset -4 lines).
patching file dlls/wined3d/texture.c
patching file dlls/wined3d/wined3d_private.h
Hunk #1 succeeded at 1223 (offset 85 lines).
Its good that all were succeeded. When you see an offset it means that
the file with the offset was changed from the the version that the
patch was from and that patch program automatically was able to
account for the change. This is caused when the developers worked a
file after a patch was released. So this may or may have not broken
the patch. The only way to tell is to test the application.

John
Locked