Howto apply a patch/diff file
Moderator: OpenTTD Developers
Re: Howto apply a patch/diff file
Ah! Thank you. So as long as I'm careful as to which .diffs I apply, I should have no problems.
Re: Howto apply a patch/diff file
so i followed instruction as meush sayed in page 1.
i didn't had to click any openttd file or any ather ttd file. so how do i know it is inplanted in my game now?
i didn't had to click any openttd file or any ather ttd file. so how do i know it is inplanted in my game now?
Re: Howto apply a patch/diff file
Can anyone help me, please?
I want to patch my "r12042" with "passenger-dest-11810.patch". Is this possible?
I've folow problem by patching:
I don't know what do I have to type by "File to patch:"
Hope anyone can help me.
I want to patch my "r12042" with "passenger-dest-11810.patch". Is this possible?
I've folow problem by patching:
I don't know what do I have to type by "File to patch:"

Hope anyone can help me.
- Attachments
-
- What do I have to type here?
- passenger-dest.png (20.12 KiB) Viewed 4901 times
Re: Howto apply a patch/diff file
It depends on how different r12042 is from r11810, and on how invasive that patch is.gutsy wrote:I want to patch my "r12042" with "passenger-dest-11810.patch". Is this possible?
You shouldn't need to type anything. When patch asks for the file to patch, it means that it hasn't found the file itself. There are two main causes for that:gutsy wrote:I don't know what do I have to type by "File to patch:"
1. You're trying to apply the patch from the wrong directory (that's the hint that patch gives you about the -p option).
2. The code you're trying to apply the patch to is so different from the original that the file to patch no longer exists.
In your case, the most likely reason is 1. (You seem to have erased the shell prompt in the top line of your image, so I can't tell for sure.) Perhaps you're trying to apply the patch from the wrong directory? Your working directory should be the root directory of the distribution (the one containing the configure script).
Re: Howto apply a patch/diff file
I agree with cirdan and if you get this error, you should try other numbers with the -p option e.g. -p1
230 revisions apart, that's quite a lot in my opinion.. I doubt it will work completely.
230 revisions apart, that's quite a lot in my opinion.. I doubt it will work completely.
Re: Howto apply a patch/diff file
I'm sorry.
I didn't have a src file in my folder.
My problem is now that I can't configure any source files of OTTD-source-nightly-rxx.. .
My Terminal says follow: (go to #1)
If I try to install g++ (go to #2)
Sorry, it's all in german. I tryied to install the following packages, but not one is istallable.
By the last package I got follow message:
"Die folgenden Pakete haben nichterfüllte Abhängigkeiten:
libc6-dev: Hängt ab: libc6 (= 2.6.1-1ubuntu9) aber 2.6.1-1ubuntu10 soll installiert werden
E: Kaputte Pakete"
But I need libc6. How can I install g++, when it isn't compatible?
Has anyone an idee?
I didn't have a src file in my folder.
My problem is now that I can't configure any source files of OTTD-source-nightly-rxx.. .
My Terminal says follow: (go to #1)
If I try to install g++ (go to #2)
Sorry, it's all in german. I tryied to install the following packages, but not one is istallable.
By the last package I got follow message:
"Die folgenden Pakete haben nichterfüllte Abhängigkeiten:
libc6-dev: Hängt ab: libc6 (= 2.6.1-1ubuntu9) aber 2.6.1-1ubuntu10 soll installiert werden
E: Kaputte Pakete"
But I need libc6. How can I install g++, when it isn't compatible?
Has anyone an idee?
- Attachments
-
- #1
- configure_error.png (47.78 KiB) Viewed 4836 times
-
- #2
- install_error.png (48.34 KiB) Viewed 4841 times
Re: Howto apply a patch/diff file
Get the output to appear in English so we can read it?gutsy wrote:Has anyone an idee?
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 important part translates roughly as:
"The following packages have not fullfilled dependencies:
g++: depends on: g++-4.1 (>= 4.1.2-1), but is not requested to be installed"
or something like this..
I guess it means that you need the package "g++-4.1", but didn't select it to be installed as well... maybe there's an option that all packages that are needed are automatically installed as well? I'm not really familiar with linux..
"The following packages have not fullfilled dependencies:
g++: depends on: g++-4.1 (>= 4.1.2-1), but is not requested to be installed"
or something like this..
I guess it means that you need the package "g++-4.1", but didn't select it to be installed as well... maybe there's an option that all packages that are needed are automatically installed as well? I'm not really familiar with linux..
Re: Howto apply a patch/diff file
How can I get the output in english?
Re: Howto apply a patch/diff file
Try this:
(if you don't need the original TTD music to play, remove timidity from there, it's a CPU waster)
Code: Select all
$ sudo apt-get install build-essential libsdl1.2-dev subversion zlib1g-dev timidity dpatch
Re: Howto apply a patch/diff file
Thanks for your help,
but if I try to do this my consol says that it needs:
libc6-dev, libc-dev, libglu1-xorg-dev, libglu-dev
I already have libc6 but in the
same line is written 2.6.1-.ubuntu10
for ttd it needs, I think, 2.6.1-.ubuntu9
Is this correct?
Can I uninstall 2.6.1-.ubuntu10?
But I do not want that my system after this is not more working,
because I have to uninstall 1156 packages and I get 2227 MB more space on harddisk
Someone an Idee?
but if I try to do this my consol says that it needs:
libc6-dev, libc-dev, libglu1-xorg-dev, libglu-dev
I already have libc6 but in the
same line is written 2.6.1-.ubuntu10
for ttd it needs, I think, 2.6.1-.ubuntu9
Is this correct?
Can I uninstall 2.6.1-.ubuntu10?
But I do not want that my system after this is not more working,
because I have to uninstall 1156 packages and I get 2227 MB more space on harddisk
Someone an Idee?
Re: Howto apply a patch/diff file
Try prepending 'LANGUAGE=en' to your commands, like this:gutsy wrote:How can I get the output in english?
Code: Select all
~$ LANGUAGE=en ls /aaaa
/bin/ls: cannot access /aaaa: No such file or directory
~$ LANGUAGE=de ls /aaaa
/bin/ls: Zugriff auf /aaaa nicht möglich: Datei oder Verzeichnis nicht gefunden
~$ LANGUAGE=fr ls /aaaa
/bin/ls: ne peut accéder /aaaa: Aucun fichier ou répertoire de ce type
That's normal. You seem to lack the complete toolchain, plus development headers and libraries. Most probably you didn't select them when you first installed your distribution.gutsy wrote:Thanks for your help,
but if I try to do this my consol says that it needs:
libc6-dev, libc-dev, libglu1-xorg-dev, libglu-dev
I don't have much experience with distributions (ubuntu in your case), as I abandoned them long ago, but you shouldn't have to uninstall anything (unless the package manager is broken). If I understand correctly, you have libc-2.6.1-ubuntu10 installed, but some package says that it requires libc-2.6.1-ubuntu9, right? This is weird: a package should not require a version older than the installed one (but, again, I've seen such things happen).gutsy wrote:I already have libc6 but in the
same line is written 2.6.1-.ubuntu10
for ttd it needs, I think, 2.6.1-.ubuntu9
Is this correct?
Can I uninstall 2.6.1-.ubuntu10?
But I do not want that my system after this is not more working,
because I have to uninstall 1156 packages and I get 2227 MB more space on harddisk
I'd suggest that you try to install whatever packages are required (libc-devel, etc.), as per Desolator's advice. Don't uninstall anything, and don't pay much attention at first to version mismatches (those can be fixed later).
Re: Howto apply a patch/diff file
Thanks a lot, but I didn't tried again.
Because this patch is not working in multi player.
Because this patch is not working in multi player.
Re: Howto apply a patch/diff file
I have a question (I'm new to this):
Are these patch/diff files the same as the patches described there:
http://wiki.openttd.org/index.php/Patches
?
If someone uploads a patch/diff file, is there a chance that this will be a built-in feature in the future (so no patch anymore)? Or will it stay always a patch that the user has to apply and compile for himself?
Are these patch/diff files the same as the patches described there:
http://wiki.openttd.org/index.php/Patches
?
If someone uploads a patch/diff file, is there a chance that this will be a built-in feature in the future (so no patch anymore)? Or will it stay always a patch that the user has to apply and compile for himself?
Re: Howto apply a patch/diff file
No, they are different things with an unfortunate name coincidence.maststef wrote:I have a question (I'm new to this):
Are these patch/diff files the same as the patches described there:
http://wiki.openttd.org/index.php/Patches
?
Patch/diff files contain a "set of changes" that have to be applied to some code (as in the OpenTTD source code). Usually their goal is to fix a bug, add a feature, etc.
The patches described at http://wiki.openttd.org/index.php/Patches are more like options that can be configured in the game.
The former. In fact, most of us who write patches hope that they become part of the official source code ("getting them into trunk"). However, that depends on the developers' accepting them, so, as you say, it's just a possibility.maststef wrote:If someone uploads a patch/diff file, is there a chance that this will be a built-in feature in the future (so no patch anymore)? Or will it stay always a patch that the user has to apply and compile for himself?
How to apply a patch/diff file?
Hello everyone!
I've been lurking on these forums for several months now, but I feel it's time for me to join the community, as I have my first problem with OpenTTD. A problem with compiling. I've got a notebook with Ubuntu 7.10 installed. Now, this is what I do:
1. I download OpenTTD source, r12179 to be precise, and unpack it.
2. I apply Gonozal's patch with "patch -p0 < gonozal_patch_r12180.patch"
3. So far it goes without any problems. Now it's time to begin compiling. I begin with "./configure". It ends after generating makefile, but when I look through what it did, I see these lines among others:
Then I compile it with "make". After it's done, I try to run it and, not so surprisingly, it doesn't do anything.
It looks like something is incomptible with my video driver. I have Radeon Xpress 200M and I'm using fglrx, version 8.452.1. If you need more informations, jusk ask. I'm neither Linux nor C(++) expert, so I might have problems doing anything advanced, but I'll gladly learn something new, if necessary.
Thank you for your time,
Robbie
I've been lurking on these forums for several months now, but I feel it's time for me to join the community, as I have my first problem with OpenTTD. A problem with compiling. I've got a notebook with Ubuntu 7.10 installed. Now, this is what I do:
1. I download OpenTTD source, r12179 to be precise, and unpack it.
2. I apply Gonozal's patch with "patch -p0 < gonozal_patch_r12180.patch"
3. So far it goes without any problems. Now it's time to begin compiling. I begin with "./configure". It ends after generating makefile, but when I look through what it did, I see these lines among others:
Code: Select all
checking SDL... not found
checking COCOA... not OSX, skipping
checking GDI video driver... not Windows, skipping
WARNING: no video driver found, building dedicated only
checking dedicated... found
checking network... found
It looks like something is incomptible with my video driver. I have Radeon Xpress 200M and I'm using fglrx, version 8.452.1. If you need more informations, jusk ask. I'm neither Linux nor C(++) expert, so I might have problems doing anything advanced, but I'll gladly learn something new, if necessary.
Thank you for your time,
Robbie
Re: How to apply a patch/diff file?
Welcome to the forums.
You seem to be lacking SDL support in your system. As you are using a distribution, I assume that, even if you installed the actual SDL libraries, you didn't install the development headers, which are required to compile code against the libraries. The configure script detects this, and tells you so ("no video driver found"), but lets you go on, only that you will be building a "dedicated server", which cannot be used to actually play the game.
Check the documentation that came with your distribution to see how to install the missing packages. They should be called "SDL" and "SDL-devel", or similar; you need both of them installed to compile OpenTTD.
You seem to be lacking SDL support in your system. As you are using a distribution, I assume that, even if you installed the actual SDL libraries, you didn't install the development headers, which are required to compile code against the libraries. The configure script detects this, and tells you so ("no video driver found"), but lets you go on, only that you will be building a "dedicated server", which cannot be used to actually play the game.
Check the documentation that came with your distribution to see how to install the missing packages. They should be called "SDL" and "SDL-devel", or similar; you need both of them installed to compile OpenTTD.
Re: Howto apply a patch/diff file
Thank you for help, Cirdan!
You were right. After installing a package named "libsdl1.2-dev" everything is running smoothly.
You were right. After installing a package named "libsdl1.2-dev" everything is running smoothly.
Robbie
Re: Howto apply a patch/diff file
Starting to get angry and it won't take long begore this PC will get some flying lessons.
I have no clue what I'm doing wrong.
Downloaded the sourcefiles, and the tortoise SVN , but what then? I'm quite new to this and I start to understand that I don't understand anything of it at all.....
What I have now:
Map with OTTD
Map with sourcefile
some patches... like the yapp/PBS
Please tell me how to get things working as I start to get mad.
I have no clue what I'm doing wrong.
Downloaded the sourcefiles, and the tortoise SVN , but what then? I'm quite new to this and I start to understand that I don't understand anything of it at all.....

What I have now:
Map with OTTD
Map with sourcefile
some patches... like the yapp/PBS
Please tell me how to get things working as I start to get mad.

Re: Howto apply a patch/diff file
What was the last step you performed successfully, and what error messages are generated when you attempt the following step?
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
Who is online
Users browsing this forum: Google [Bot] and 23 guests