Howto apply a patch/diff file
Moderator: OpenTTD Developers
-
- Engineer
- Posts: 5
- Joined: 25 Jun 2007 23:24
Problem installing patch
I've just discovered openTTD recently and like it really much, but I've got one problem, oil refineries can only be build close to the edge (while using fund new industry). For large maps, this is insane. Now I've found a .diff file to solve this problem, but I cannot instal it.
I am a total noob when it comes to installing patches for openTTD, so I followed the instructions given by MeusH. When I follow this method I get the message that there are unresolved conflicts. I tried to solve them by indicating which version (theirs or mine in SVNTortoise) I prefer.
Now I think I did it right, but still it doesn't work in openTTD. Is there some final step which should be made, because I can't inmagine how openTTD knows that it should check this new made folder. Is there a way to update the instal files used by openTTD
Thanks, Mathijs Jansen
I am a total noob when it comes to installing patches for openTTD, so I followed the instructions given by MeusH. When I follow this method I get the message that there are unresolved conflicts. I tried to solve them by indicating which version (theirs or mine in SVNTortoise) I prefer.
Now I think I did it right, but still it doesn't work in openTTD. Is there some final step which should be made, because I can't inmagine how openTTD knows that it should check this new made folder. Is there a way to update the instal files used by openTTD
Thanks, Mathijs Jansen
- Digitalfox
- Chief Executive
- Posts: 710
- Joined: 28 Oct 2004 04:42
- Location: Catch the Fox if you can...
Re: Problem installing patch
Have you tried with this:mathijsjansen wrote:I've just discovered openTTD recently and like it really much, but I've got one problem, oil refineries can only be build close to the edge (while using fund new industry). For large maps, this is insane. Now I've found a .diff file to solve this problem, but I cannot instal it.
I am a total noob when it comes to installing patches for openTTD, so I followed the instructions given by MeusH. When I follow this method I get the message that there are unresolved conflicts. I tried to solve them by indicating which version (theirs or mine in SVNTortoise) I prefer.
Now I think I did it right, but still it doesn't work in openTTD. Is there some final step which should be made, because I can't inmagine how openTTD knows that it should check this new made folder. Is there a way to update the instal files used by openTTD
Thanks, Mathijs Jansen
BuildOTTD
http://www.tt-forums.net/viewtopic.php?t=31823&start=0
-
- Engineer
- Posts: 5
- Joined: 25 Jun 2007 23:24
I've tried this program and it works easily, but when I try to patch openTTD I get the following error message:
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:
--------------------------
|Index: industry_cmd.c
|===================================================================
|--- industry_cmd.c (revision 1787)
|+++ industry_cmd.c (working copy)
--------------------------
No file to patch. Skipping patch.
1 out of 1 hunk ignored
I got the patch from:
http://sourceforge.net/tracker/index.ph ... tid=636367
Thanks, Mathijs
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:
--------------------------
|Index: industry_cmd.c
|===================================================================
|--- industry_cmd.c (revision 1787)
|+++ industry_cmd.c (working copy)
--------------------------
No file to patch. Skipping patch.
1 out of 1 hunk ignored
I got the patch from:
http://sourceforge.net/tracker/index.ph ... tid=636367
Thanks, Mathijs
Probably you are applying the patch in the wrong directory
What's the output of:
What's the output of:
Code: Select all
$ ls industry_cmd.c
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Ah. Yes. That could be a problem too.
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Re: Howto apply a patch/diff file
I just can't figure this out. I can't use TortoiseSVN (something about not having the right version to install it with or something) and every other SVN thing seems impossible to work out. Tutorials aren't helpful, because they're written by people who know how to use it and expect everyone else to know what they're talking about. And typing that code in the console doesn't seem to work at all. In fact, whether the patch I'm trying to install exists or not (I tried with non-existant ones just to see) I get this message:
And then nothing happens. In fact, I even get that message if I just type "patch". So I tried the following:
No meaningless message there, but still, no working patch. So then I tried to see if the second line of that message was true and tried:
Turns out that...
Isn't that nice. Do I just have my .patch file in the wrong folder? I put it in the root of my OTTD installation.
Code: Select all
- Change patch variables for all players. Usage: 'patch <name> [<value>]'
- Omitting <value> will print out the current value of the patch-setting.
Code: Select all
patch filename.patch [-p0]
Code: Select all
patch filename.patch
Code: Select all
'filename.patch' is an unknown patch setting.
Re: Howto apply a patch/diff file
You have wrong "patch.exe" binary.Mattastic wrote:I just can't figure this out. I can't use TortoiseSVN (something about not having the right version to install it with or something) and every other SVN thing seems impossible to work out. Tutorials aren't helpful, because they're written by people who know how to use it and expect everyone else to know what they're talking about. And typing that code in the console doesn't seem to work at all. In fact, whether the patch I'm trying to install exists or not (I tried with non-existant ones just to see) I get this message:
And then nothing happens. In fact, I even get that message if I just type "patch". So I tried the following:Code: Select all
- Change patch variables for all players. Usage: 'patch <name> [<value>]' - Omitting <value> will print out the current value of the patch-setting.
No meaningless message there, but still, no working patch. So then I tried to see if the second line of that message was true and tried:Code: Select all
patch filename.patch [-p0]
Turns out that...Code: Select all
patch filename.patch
Isn't that nice. Do I just have my .patch file in the wrong folder? I put it in the root of my OTTD installation.Code: Select all
'filename.patch' is an unknown patch setting.
First, the correct syntax is "patch -p0 <filename.patch"
Second - you need to get different patch frogram. Rename patch.exe to something else, then get MSYS from http://www.mingw.org/download.shtml#hdr8 - it includes the correct patch you need
If you need something, do it yourself or it will be never done.
My patches: Extra large maps (1048576 high, 1048576 wide) (FS#1059), Vehicle + Town + Industry console commands (FS#1060), few minor patches (FS#2820, FS#1521, FS#2837, FS#2843), AI debugging facility
Other: Very large ships NewGRF, Bilbo's multiplayer patch pack v5 (for OpenTTD 0.7.3)
My patches: Extra large maps (1048576 high, 1048576 wide) (FS#1059), Vehicle + Town + Industry console commands (FS#1060), few minor patches (FS#2820, FS#1521, FS#2837, FS#2843), AI debugging facility
Other: Very large ships NewGRF, Bilbo's multiplayer patch pack v5 (for OpenTTD 0.7.3)
Re: Howto apply a patch/diff file
Well, I never had a patch.exe anyway. No such file comes with OTTD. But I got MSYS and copied over the patch.exe from that. Since I didn't have any reference as to where it goes, I placed it under my root OTTD folder. However, the same problems persist. 

Re: Howto apply a patch/diff file
Looks to my as if you are running patch from the OpenTTD console. Am I right about that?
Re: Howto apply a patch/diff file
Yeah. That's what the tutorial on the wiki said to do, and the one here doesn't specify.
Re: Howto apply a patch/diff file
If so, the wiki's tutorial is wrong. Which page says that, please?
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Re: Howto apply a patch/diff file
The offending page is here. The bit in question is at the bottom.
Right, I'm now guessing I'm meant to put the text in the config file. First I tried putting it at the extreme top of the file, which got me the message: "ini: 'patch -p0 < filename.patch' outside of group" on loading and closing OTTD, after which the addition was removed by the program. I've tried putting it under the groups in the config file, but so far none of those have seemed appropriate and failed to achieve any result.
I ask only this: where do I put that one line of text, and what folder does the actual patch file go in. Those seem to be the only questions that never get answered anywhere.
Right, I'm now guessing I'm meant to put the text in the config file. First I tried putting it at the extreme top of the file, which got me the message: "ini: 'patch -p0 < filename.patch' outside of group" on loading and closing OTTD, after which the addition was removed by the program. I've tried putting it under the groups in the config file, but so far none of those have seemed appropriate and failed to achieve any result.
I ask only this: where do I put that one line of text, and what folder does the actual patch file go in. Those seem to be the only questions that never get answered anywhere.
Re: Howto apply a patch/diff file
Well "a console" means a terminal, not the openttd ingame console.wiki wrote:Linux: Type the following line into a console (replace patch_name with the filename of the patch):
Re: Howto apply a patch/diff file
Okay. What console/terminal/whatever do I type this into?
Re: Howto apply a patch/diff file
The same one where you'd type "./configure && make" to build OpenTTD.
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
- kilo.dollar
- Traffic Manager
- Posts: 161
- Joined: 02 Jul 2007 08:45
- Location: Harare
Re: Howto apply a patch/diff file
I seem unable to proceed. What should I do in this instance?
See attached error message.
See attached error message.
- Attachments
-
- svn.error.png (10.98 KiB) Viewed 3340 times
I think that I may never see,
A billboard as lovely as a tree.
Perhaps, unless the billboards start to fall,
I may never see a tree at all.
A billboard as lovely as a tree.
Perhaps, unless the billboards start to fall,
I may never see a tree at all.
- kilo.dollar
- Traffic Manager
- Posts: 161
- Joined: 02 Jul 2007 08:45
- Location: Harare
Re: Howto apply a patch/diff file
What files are modified by applying a patch, and if I get someone's patched files and replace mine, is my game already patched that way?
I think that I may never see,
A billboard as lovely as a tree.
Perhaps, unless the billboards start to fall,
I may never see a tree at all.
A billboard as lovely as a tree.
Perhaps, unless the billboards start to fall,
I may never see a tree at all.
Re: Howto apply a patch/diff file
please avoid double posting kilo.dollar..
to answer your questions:
1) the correct url is (IIRC) svn://svn.openttd.org
2) yes, if you replace your files with the files you've received/copied n' pasted your game will be patched
to answer your questions:
1) the correct url is (IIRC) svn://svn.openttd.org
2) yes, if you replace your files with the files you've received/copied n' pasted your game will be patched
- kilo.dollar
- Traffic Manager
- Posts: 161
- Joined: 02 Jul 2007 08:45
- Location: Harare
Re: Howto apply a patch/diff file
Thanks, Rav, since I am failing is anyone willing to patch for me with the do_not_build_inconnective_roads_r10722.patch?
I think that I may never see,
A billboard as lovely as a tree.
Perhaps, unless the billboards start to fall,
I may never see a tree at all.
A billboard as lovely as a tree.
Perhaps, unless the billboards start to fall,
I may never see a tree at all.
Who is online
Users browsing this forum: Bing [Bot] and 29 guests