Commit Graph

215 Commits

Author SHA1 Message Date
Darkvater a91c52e169 (svn r4125) - Feature: Add a general TIC() TOC() mechanism using rdtsc or something similar on non-i386 architectures to performance-tune (critical) code. Some systems are probably missing, but those can be added later. 2006-03-26 21:15:09 +00:00
celestar 3770ad0637 (svn r4113) Moved all relevant map functions for stations to station_map.[ch]
Some work with animated tiles remains. Thanks to Tron for parts of the code and lots of proof-reading and suggesting
2006-03-26 14:41:39 +00:00
tron 742e806d73 (svn r4076) Back out r4074. It doesn't work and leads to make endlessly calling itself. NOTE: Delete Makefile.config to recover. 2006-03-24 06:40:49 +00:00
bjarni 10936e7034 (svn r4074) -Feature: [Makefile] the makefile can now detect if iconv is present in the system
if detected, WITH_ICONV will be defined in the C code
	WITH_ICONV is also added to Makefile.config
	OSX do not use this flag setting in Makefile.config, as it is set at compile time based on target OS version
	the actual C code is not changed as the current iconv code is hardcoded for OSX and would break if any other OS got iconv
	This detection system is by request of Darkvater
2006-03-23 23:54:43 +00:00
bjarni 0b102f0e00 (svn r4019) -Fix: [OSX] stopped using iconv for 10.2.8, since it was added in 10.3
this have the sideeffect that 10.2.8 will still have the "failure to save with certain chars in the filename bug", but at least it can compile again
2006-03-22 13:06:50 +00:00
bjarni 5affa77822 (svn r3966) -Fix: [OSX and some linux] [ 1157244 ] Can't save game if name contains german umlauts
now it saves correctly, but the load window still display some chars wrong (fix by ln-)
2006-03-18 15:55:24 +00:00
tron 3d9c76d8b8 (svn r3887) Add a function to get the other bridge end when you're at a bridge ramp 2006-03-15 16:44:50 +00:00
bjarni a19cdf6040 (svn r3884) renamed TRIPPLE_BINARY to TRIPLE_BINARY 2006-03-15 14:11:17 +00:00
bjarni bb47ecddf4 (svn r3882) -Codechange: [OSX] changed the way universal and tripple binaries are build
Instead of compiling a binary for each arch and then join them in the end, each .o file is now compiled as a fat file
	This means that the makefile will not call itself to make a binary for each target and we don't have to make clean between each build
	it also means that if one file changed, we don't have to recompile all files
	Another benefit is since it's handled at .o level and though LDFLAGS, no special code is needed if we decide to compile more binaries (like a lot of stuff used to happen at post linking)
	We also needs much less flags to set up, so it should be even easier to get to work out of the box now
	The tradeoff in doing so is that now the binary needs at least OSX 10.3.9 to execute
	To deal with this issue, the JAGUAR flag can be used to compile for older OSes. We will release a binary for old OSes at next release to see if anybody even downloads it (not that many people use OSX 10.2 anymore)
	GPMI will not work on 10.2 anyway so we will cut support for it some day anyway
2006-03-15 14:03:09 +00:00
truelight cc2993992f (svn r3864) -Fix: small problems with make-system, making room for a wrapper-configure 2006-03-14 19:10:33 +00:00
tron f2dc736554 (svn r3777) Add some functions to handle tunnels 2006-03-06 20:55:24 +00:00
tron f007ad282c (svn r3766) Add a function to get the RoadBits from an arbitrary tile 2006-03-05 12:22:20 +00:00
bjarni f4cf9b0a91 (svn r3759) -Fix: [OSX] don't set CC_HOST to i686 gcc when compiling universal binaries on PPC without any Makefile.config. Introduced in 3674 (before that i686 used PPC as CC_HOST, but nobody noticed that) 2006-03-04 12:09:10 +00:00
bjarni d09e66eef6 (svn r3674) -Feature: [OSX] Added support for tripple binaries (binaries optimised for G3, G5 and i686)
G4 have no problems using G3 code while G5 can, but really benefit from getting their own optimised code (Apple: G5 is not just a fast G4)
	Also changed FAT_BINARY to UNIVERSAL_BINARY since Apple removed most (all?) references to fat binaries on their homepage two days after I added FAT_BINARY
2006-02-25 21:25:23 +00:00
bjarni 4ff6b2a514 (svn r3673) -Codechange: [OSX] changed the makefile to autodetect if it compiles on G5 and then adds flags to optimise for G5
This will not interfere with crosscompiling or universal binaries
2006-02-25 18:11:11 +00:00
Darkvater f112cd722c (svn r3622) - Partly revert r3214. The patch setting max_num_autosaves stays to help control PDA-troubles which the commit was intended for. Didn't revert makefile-config version since it would cause trouble. But Bjarni promised to rewrite it :) 2006-02-20 17:54:25 +00:00
bjarni 9ed8143264 (svn r3611) -Feature: [OSX profiling] Shark (Xcode's profiling tool) can now relate CPU usage to lines in the source files
Now OSX users can tell what lines in the C code that keeps the CPU busy instead of just ASM code
	Note: PROFILE needs to be enabled in Makefile.config for this to work
2006-02-17 20:24:17 +00:00
Darkvater 0755e24ce4 (svn r3574) - [Merge] [GPMI] -Fix: finally OTTD doesn't compile if you do a 'make mrproper' (TrueLight) 2006-02-07 19:34:22 +00:00
peter1138 ea4c5bbd2d (svn r3525) - Rename station_newgrf.[ch] to newgrf_station.[ch], and update project files. 2006-02-03 15:51:00 +00:00
peter1138 b88904f345 (svn r3524) - Split newgrf features from engine.[ch] into newgrf_engine.[ch], and add the new files to project files. 2006-02-03 12:55:21 +00:00
matthijs d22e2d12cf (svn r3507) - Fix: [Makefile] Make sure the ICON_DIR gets created before copying files there.
- Fix: Fix small syntactic error in the manpage.
2006-02-01 01:36:18 +00:00
truelight 9d11d11d68 (svn r3474) -Fix: don't use CXXFLAGS for DEP and CFLAGS for Compile, gives funny results ;) 2006-01-29 19:49:15 +00:00
Darkvater 4e09974975 (svn r3472) - [PBS] Remove from trunk. Anyone interested can still find it in branch/pbs. This reverts revisions r3158, r3140, r3075, r2977, r2674, r2625, r2621, r2529, r2528, r2525, r2524, r2519, r2517, r2516, r2507, r2499. (in conjunction with Tron)
- The only change is that the nsignalsw.grf file is kept and that existing nightlies with PBS signals get those signals converted to combo-signals.
2006-01-29 18:57:26 +00:00
matthijs 585b47b6c5 (svn r3456) - Feature: [Makefile] Icons can now be installed in a seperate directory. 2006-01-28 10:16:15 +00:00
bjarni 1cfabfbb09 (svn r3383) -Code cleanup: [OSX] removed SDL support from FAT binaries as it caused problems for non-SDL builds
FAT binaries now need to rely on COCOA drivers. SDL didn't work properly anyway
2006-01-07 13:13:49 +00:00
bjarni 015db8a461 (svn r3382) -Feature: [OSX] added the flag JAGUAR to crosscompile for OSX 10.2.8 on 10.4 2006-01-07 12:53:57 +00:00
tron 7e5da7d8b2 (svn r3348) Dependency checking didn't include all compile parameters, which lead to wrong results 2005-12-27 22:55:24 +00:00
tron 19d0517c71 (svn r3340) Fix dependency calculation: dependencies didn't get recalculated if a header file changed
Also really automagically create the dependency directories by deriving the directory names from $(DEPS)
2005-12-25 09:19:16 +00:00
Darkvater 97e9141c65 (svn r3326) - Fix: [ 1226832 ] Build fails if SDL is built without pthread support (dst) 2005-12-21 01:19:03 +00:00
tron b06b3e2ca2 (svn r3313) Remove GPMI related changes from trunk
Revisions in detail: 2542, 3226 (partial), 3229, 3231, 3232, 3238, 3242-3245, 3251, 3253, 3260, 3263, 3265, 3266, 3269, 3277, 3278, 3279, 3283 (partial), 3304, 3305, 3306
2005-12-18 12:10:46 +00:00
tron ce94c90a7b (svn r3296) Warn about testing an undefined macro with #if - should most probably be #ifdef 2005-12-14 06:16:34 +00:00
tron ec2675c2c5 (svn r3287) Turn the winres.o: openttd.rc special case into a normal %.o: %.rc rule 2005-12-11 07:36:49 +00:00
bjarni 6a6e145010 (svn r3281) -Feature: [OSX] added native cocoa sound and video drivers (egladil)
you can still use SDL drivers if you like and you have to run "make upgradeconf" to start using the cocoa drivers (or manually write WITH_COCOA:=1)
	since SDL breaks the cocoa drivers, you can't compile with both SDL and cocoa support
	Using cocoa drivers makes it easier to make universal binaries and it solves:
	-FS#18 [OSX] SDL is weird in universal binaries
	-FS#2  [OSX] lazy pointer crash on exit
	-FS#10 [OSX] linking error when linking statically to SDL 1.2.8 (needless to explain this, but it means it should be able to compile statically with the default settings now)
	-[ 1215073 ] Switching to large size out of fullscreen crashes
	Using SDL drivers will still have those issues though
2005-12-10 11:16:45 +00:00
tron f1877b3fe9 (svn r3280) Merge the seperate (C|CXX|OBJC)_SOURCES variables into a single variable SRCS
Now adding a new file to compile is just adding a line like SRCS += $(FIILE), regardless of type
2005-12-10 07:29:31 +00:00
bjarni 26a5e120e8 (svn r3276) reverted the last two commits. OSX 10.2 kept finding new stuff to prevent it from running OpenTTD, so now it's not supported anymore 2005-12-09 13:17:31 +00:00
bjarni 6cfdfcc4ba (svn r3275) -Fix: [OSX] removed libpng support and error dialogs from jaguar crosscompiles to fix crash 2005-12-09 13:07:21 +00:00
bjarni 111e5ef0fd (svn r3274) -Fix: [OSX] added JAGUAR flag to crosscompile for OSX 10.2 (codenamed jaguar)
JAGUAR and FAT_BINARY can't be used at the same time
	JAGUAR will disable network support due to missing libs in 10.2
2005-12-09 12:15:52 +00:00
bjarni 578883266f (svn r3273) -Fix: [OSX] PPC part of universal binaries now target 10.3 instead of 10.4
10.2 support appears to be broken right now
	Changed BUILD_UNIVERSAL_BINARY into FAT_BINARY (I got tired of typing)
2005-12-09 11:08:24 +00:00
bjarni 4bc7265b03 (svn r3267) -Codechange: [OSX] universal binary makefile code cleanup
now PPC code is always compiled before x86 code
	strgen and lng files are only compiled once, which results in shorter building time
	the makefile now assigns default values to undefined values so much less needs to be set up
	the code is now easier to maintain
2005-12-06 22:09:28 +00:00
bjarni 686da2f4e1 (svn r3264) -Codechange: [OSX] OSX targets will now always use the preprocessor to determine endianess
this means that ENDIAN_FORCE is obsolite since it's always overwritten with PREPROCESSOR
	Since the preprocessor should never be able to pick wrong, it's easier this way
	specially when compiling universal binaries as they got both endianess
2005-12-06 14:35:10 +00:00
bjarni 1a93bcb5bb (svn r3262) -Fix: [OSX] universal binaries can now include the dynamic SDL lib into the bundle 2005-12-06 09:27:42 +00:00
bjarni 2946f3c1f9 (svn r3259) -Fix: [OSX] fixed that universal binaries did not make a bundle 2005-12-04 22:43:40 +00:00
bjarni 961b71f434 (svn r3258) -Feature: [OSX] added support for universal binaries
it needs both PPC and x86 libs to compile
	due to this fact, compilation with libPNG or SDL is not tested (dedicated servers only)
	only PPC part is tested as I don't have x86 OSX
2005-12-04 17:36:19 +00:00
bjarni 8277a0651e (svn r3257) -Codechange: [OSX] removed the dynamic lib in bundle option (introduced in rev 3230)
it caused way more problems than it solved
2005-12-03 13:43:54 +00:00
truelight b8f8f3869d (svn r3231) Fix: update the GPMI implementation to the latest GPMI-API version 2005-11-23 13:45:12 +00:00
bjarni 08b990886d (svn r3230) -Feature: [OSX] OSX builds can now change where it searches for dynamic libs and can move libs into the bundle
This is not a fix for the issues with static linking, more like a workaround. Static linking still got issues
	Apple recommends to use dynamic linking anyway, so I guess this doesn't matter much
2005-11-23 12:21:54 +00:00
bjarni eba1f68439 (svn r3214) -Feature: openttd.cfg can now set how many autosaves to keep before starting to overwrite old ones
max_autosave_num in the config files sets the number of autosaves to keep (default 16)
	MAX_NUM_AUTOSAVES in Makefile.config sets the default value. 16 is used if no value is given
	this behaviour can still be overwritten by keep_all_autosave (openttd.config setting)
	Note: this is a requested behaviour for PDA ports, since they got limited storage space
2005-11-17 19:43:37 +00:00
peter1138 ff8223150a (svn r3167) - NewGRF: Start moving custom station code to separate files.
Rewrite handling of station classes.
          Allow for more than 8 station tile layouts.
          Start of code to unload custom stations.
2005-11-12 00:19:34 +00:00
truelight 8ea1639603 (svn r3113) -Fix: The Makefile had 64bit code which was obsolete, not to say wrong.
This removes all the 64bit stuff from the Makefile. Everything should 
  work just fine. Also removed the warning on amd64, 64bit OpenTTD is 
  stable. Tnx to dst for commenting and testing on this subject.
2005-10-31 18:29:21 +00:00
bjarni 477aa9f69c (svn r3088) -Fix: [OSX] fixed issue where OSX could not dynamic link to quicktime [ 1334917 ] 2005-10-25 19:41:32 +00:00