GRF-Codec for Mac?
Moderator: Graphics Moderators
GRF-Codec for Mac?
Hi,
just a singel question:
Is there any solution to generate a .grf on a (PPC) Mac running OS X 10.4?
Greets,
DonRazzi
just a singel question:
Is there any solution to generate a .grf on a (PPC) Mac running OS X 10.4?
Greets,
DonRazzi
Best OTTD Screenshots in 2007 !!!



Re: GRF-Codec for Mac?
Yes. Download the source (svn co svn://svn.ttdpatch.net/misc/grfcodec) and compile it yourself (make grfcodec).
I'm told it works, but I have no Mac on which to test.
I'm told it works, but I have no Mac on which to test.
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: GRF-Codec for Mac?
Damnit... I don't have the developers stuff installed on my machnine. Where's the hero with the Quad Core Mac Pro or Power Mac G5 to do this little job for me?
Greets,
Don
Greets,
Don
Best OTTD Screenshots in 2007 !!!



- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: GRF-Codec for Mac?
I got a friend (who I trust as a programmer) to compile grfcodec for Mac. I have an Intel Mac running OS X Leopard (10.5.4). However when I try grfcodec -d foobar.grf, I get an error, 'Offset too large'. I've tried a range of different grfs. Very possibly I need to read the instructions again, however if anyone has an insight into potential fixes, it would be much appreciated.DaleStan wrote:Yes. Download the source (svn co svn://svn.ttdpatch.net/misc/grfcodec) and compile it yourself (make grfcodec).
If it helps, I think I would be allowed within the terms of GPL to post the compiled version here, but I'd need to check the Grfcodec notes & forum rules before doing so.
cheers,
Andy
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: GRF-Codec for Mac?
I expect that means that the endianness detection broke. If you're compiling for Intel, make sure it's compiled with __BIG_ENDIAN__ undefined, or provide a patch that makes the #ifdef __BIG_ENDIAN__ lines do the right thing.
Also, that's version 1854E. That "E" means that your friend did not compile a pristine checkout. Likely it's just makefile changes, but check to make sure.
Also, that's version 1854E. That "E" means that your friend did not compile a pristine checkout. Likely it's just makefile changes, but check to make sure.
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
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: GRF-Codec for Mac?
Ok, thanks, for the analysis. Unfortunately I can't provide a time estimate on when I might twist an arm to try compiling again for Mac (and patching if necessary).DaleStan wrote:I expect that means that the endianness detection broke. If you're compiling for Intel, make sure it's compiled with __BIG_ENDIAN__ undefined, or provide a patch that makes the #ifdef __BIG_ENDIAN__ lines do the right thing.
Also, that's version 1854E. That "E" means that your friend did not compile a pristine checkout. Likely it's just makefile changes, but check to make sure.
cheers,
Andy
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: GRF-Codec for Mac?
Intel mac? get CrossOver (6 or 7) and run grfcodec in a windows 2k bottle. no sweat, easy-peasy.
"Your mother was a lobster, and your father... was also a lobster" -- The rascal formerly known as astath -- Last.fm -- Official TT-Dave Worley Fan Club

<orudge> make love to me while I surf, dear lobster

<orudge> make love to me while I surf, dear lobster
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: GRF-Codec for Mac?
Thanks - great idea, I'll give it a go. That, or I'll try putting a Linux VM in VMWare (I neither have nor want to buy a spare Windows license).lobster wrote:Intel mac? get CrossOver (6 or 7) and run grfcodec in a windows 2k bottle. no sweat, easy-peasy.
Would be nice to have grfcodec compiled for Mac and working, but that's beyond my current abilities (or spare time).
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: GRF-Codec for Mac?
I think it should run in wine/darwine 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
- andythenorth
- Tycoon
- Posts: 5705
- Joined: 31 Mar 2007 14:23
- Location: Lost in Music
Re: GRF-Codec for Mac?
Good news - I can confirm that grfcodec will work with Crossover (using Intel Macbook, OS X 10.5 Leopard) - at least for decoding a simple grf. I can't resist showing the results - this is a decode of a test grf for Heavy Equipment:andythenorth wrote:lobster wrote:Intel mac? get CrossOver (6 or 7) and run grfcodec in a windows 2k bottle. no sweat, easy-peasy.
Mac users can find Crossover at http://www.codeweavers.com/
Grfcodec is found at http://www.ttdpatch.net/grfcodec/grfcodec.html
To use, I created a Win 2000 bottle called Grfcodec (following the easy instructions provided with Crossover).
This will provide a windows-like folder structure
"~/Library/Application Support/CrossOver/Bottles/Grfcodec/drive_c/Program\ Files"
There may be alternative methods, but I placed the grfcodec.exe, grfdiff.exe and grfmerge.exe into the Program Files folder at the path above. I also placed the grf to be decoded in the same folder.
To run grfcodec go to the "Programs" menu in Crossover, and chose "Run Command...". Use "Browse..." to find grfcodec.exe. This will place the path to grfcodec into the text input box, in double quote marks. Place the grfcodec options (such as -d) outside the quote marks. Then place the path to the grf after the options, again in quote marks.
It might be handy if this info could be added to the grfcodec page? My instructions might not be the clearest - I'm winging it slightly. Seems to work though.
Thanks for the tip, now I have NO excuses not to learn NFO.
cheers,
Andy
FIRS Industry Replacement Set (released) | HEQS Heavy Equipment Set (trucks, industrial trams and more) (finished)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Unsinkable Sam (ships) (preview released) | CHIPS Has Improved Players' Stations (finished)
Iron Horse ((trains) (released) | Termite (tracks for Iron Horse) (released) | Busy Bee (game script) (released)
Road Hog (road vehicles and trams) (released)
Re: GRF-Codec for Mac?
Then use the cheap solution: http://www.openttd.org/download-grfcodecAbsolutis wrote:That's too expensive for just GRFCodec use.
Who is online
Users browsing this forum: No registered users and 11 guests