driver.h
author bjarni
Sat, 29 Apr 2006 14:38:21 +0000
branch0.4
changeset 9973 72d7f7f30746
parent 9959 984493ab6fff
permissions -rw-r--r--
(svn r4624) -Backported r4149 from trunk
main reason is that it fixes the load/save issue for OSX 10.3.9, but the other stuff in this commit can't be taken as it's a result of the fix

full commit log entry:
-Codechange: [OSX] rewrite of how universal binaries are compiled

Now OSX stores object files in .OSX and instead of making FAT object files, there are one for each architecture
Each architecture got their own targets to make a non-FAT binary and in the end, lipo will merge them into one binary

It's now possible to select which architectures you want to support by defining OTTD_PPC, OTTD_PPC970 (G5) and/or OTTD_i386
All combos are supported. UNIVERSAL_BINARY and TRIPLE_BINARY can still be used even though it's possible to gain the same result by using the new flags
Making a universal build when you already got part of it compiled (say the PPC part), it will reuse it and only compile the i386 part to save time
Note: in some cases when you switch flags, you risk that openttd is not updated. Delete it and try again. The Makefile can't solve this except if it forces linking each time

This fixes: FS#87 universal binary building borked in 0.4.7
Now universal binaries work on OSX 10.3.9 again

Building universal binaries no longer needs to store flags in Makefile.config as the new design makes it possible to figure everything out automatically
9959
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     1
/* $Id$ */
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     2
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     3
#ifndef DRIVER_H
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     4
#define DRIVER_H
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     5
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     6
void LoadDriver(int driver, const char *name);
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     7
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     8
bool GetDriverParamBool(const char* const* parm, const char* name);
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
     9
int GetDriverParamInt(const char* const* parm, const char* name, int def);
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
    10
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
    11
char *GetDriverList(char* p);
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
    12
984493ab6fff (svn r4044) Rename 0.4.5 branch to 0.4. Further minor releases will be in the 0.4 range, to prevent enormously long version numbers.
matthijs
parents: -1
diff changeset
    13
#endif /* DRIVER_H */