makefiledir/Makefile.config_writer
author rubidium
Fri, 17 Nov 2006 22:15:55 +0000
changeset 5117 a4a7fd847b77
parent 5108 dc67d70b5a45
child 5305 e07957fe871e
permissions -rw-r--r--
(svn r7196) -Feature: use fontconfig so one can set the font family name in openttd.cfg instead of the full path to the font.
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     1
# This file generates Makefile.config
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     2
# Create default config from autodetected values
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     3
# Magic at work, note that you can't use commas in arguments for this
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     4
CONFIG_LINE=@$(SHELL) -c 'echo $(1)' >> $(MAKE_CONFIG) 2> /dev/null
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     5
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
     6
$(MAKE_CONFIG):
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
     7
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
     8
	touch $(MAKE_CONFIG)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
     9
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    10
	$(call CONFIG_LINE,\# OpenTTD config file for makefile)
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    11
	$(call CONFIG_LINE,\# Set your options here - 1 for use and empty for disable)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    12
	$(call CONFIG_LINE,)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    13
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    14
	$(call CONFIG_LINE,\# User setup flags)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    15
	$(call CONFIG_LINE,\# Translator: adds TODO to any untranslated strings)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    16
	$(call CONFIG_LINE,\# MIDI: sets path to midi player)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    17
	$(call CONFIG_LINE,\# MIDI_ARG: sets an argument which is used when calling the midi player. Default off)
180
47ee14fe2b35 (svn r181) Makefile: enabled ability to supress output of missing strings in lng files
bjarni
parents: 0
diff changeset
    18
	$(call CONFIG_LINE,\# SUPRESS_LANG_ERRORS: supresses output about missing and mismatched strings)
804
06aaddf6742b (svn r1274) Makefile: networking is not longer experimental
bjarni
parents: 561
diff changeset
    19
	$(call CONFIG_LINE,\# WITH_NETWORK: makes OpenTTD able to play multiplayer using TCP and UDP)
06aaddf6742b (svn r1274) Makefile: networking is not longer experimental
bjarni
parents: 561
diff changeset
    20
	$(call CONFIG_LINE,\# DEDICATED: compiles a dedicated server. This one can only host using a CLI, but do not need SDL)
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    21
	$(call CONFIG_LINE,STATIC:=$(STATIC))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    22
	$(call CONFIG_LINE,TRANSLATOR:=$(TRANSLATOR))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    23
	$(call CONFIG_LINE,DEBUG:=$(DEBUG))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    24
	$(call CONFIG_LINE,PROFILE:=$(PROFILE))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    25
	$(call CONFIG_LINE,MIDI:=$(MIDI))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    26
	$(call CONFIG_LINE,MIDI_ARG:=$(MIDI_ARG))
180
47ee14fe2b35 (svn r181) Makefile: enabled ability to supress output of missing strings in lng files
bjarni
parents: 0
diff changeset
    27
	$(call CONFIG_LINE,SUPRESS_LANG_ERRORS:=$(SUPRESS_LANG_ERRORS))
2197
0ffe98032b29 (svn r2712) Overhaul DirectMusic MIDI backend:
tron
parents: 2033
diff changeset
    28
	$(call CONFIG_LINE,WITH_DIRECTMUSIC:=$(WITH_DIRECTMUSIC))
804
06aaddf6742b (svn r1274) Makefile: networking is not longer experimental
bjarni
parents: 561
diff changeset
    29
	$(call CONFIG_LINE,WITH_NETWORK:=$(WITH_NETWORK))
06aaddf6742b (svn r1274) Makefile: networking is not longer experimental
bjarni
parents: 561
diff changeset
    30
	$(call CONFIG_LINE,DEDICATED:=$(DEDICATED))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    31
	$(call CONFIG_LINE,)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    32
348
959f425dc282 (svn r531) Makefile: made asserts enabled by default
bjarni
parents: 347
diff changeset
    33
	$(call CONFIG_LINE,\# Disable asserts. Leave them on for easier bug finding)
959f425dc282 (svn r531) Makefile: made asserts enabled by default
bjarni
parents: 347
diff changeset
    34
	$(call CONFIG_LINE,DISABLE_ASSERTS:=$(DISABLE_ASSERTS))
4324
9c999cc382fa (svn r5978) -Add: allow a switch in Makefile.config to disable threads in OpenTTD (no matter what system you are on). Only useful for testing.
truelight
parents: 3900
diff changeset
    35
	$(call CONFIG_LINE,\# Disable threads. Useful if you do not like it and for testing)
9c999cc382fa (svn r5978) -Add: allow a switch in Makefile.config to disable threads in OpenTTD (no matter what system you are on). Only useful for testing.
truelight
parents: 3900
diff changeset
    36
	$(call CONFIG_LINE,NO_THREADS:=$(NO_THREADS))
347
892935295937 (svn r530) Makefile: added ability to switch asserts on and off
bjarni
parents: 285
diff changeset
    37
	$(call CONFIG_LINE,)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    38
285
e306da1c4ad1 (svn r291) Minor fix to english.txt
bjarni
parents: 180
diff changeset
    39
	$(call CONFIG_LINE,\# See Makefile for details on these paths)
e306da1c4ad1 (svn r291) Minor fix to english.txt
bjarni
parents: 180
diff changeset
    40
	$(call CONFIG_LINE,\# Folders should not end with /)
e306da1c4ad1 (svn r291) Minor fix to english.txt
bjarni
parents: 180
diff changeset
    41
	$(call CONFIG_LINE,INSTALL:=$(INSTALL))
e306da1c4ad1 (svn r291) Minor fix to english.txt
bjarni
parents: 180
diff changeset
    42
	$(call CONFIG_LINE,PREFIX:=$(PREFIX))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    43
	$(call CONFIG_LINE,BINARY_DIR:=$(BINARY_DIR))
285
e306da1c4ad1 (svn r291) Minor fix to english.txt
bjarni
parents: 180
diff changeset
    44
	$(call CONFIG_LINE,DATA_DIR:=$(DATA_DIR))
2901
6adc1bdca953 (svn r3456) - Feature: [Makefile] Icons can now be installed in a seperate directory.
matthijs
parents: 2835
diff changeset
    45
	$(call CONFIG_LINE,ICON_DIR:=$(ICON_DIR))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    46
	$(call CONFIG_LINE,USE_HOMEDIR:=$(USE_HOMEDIR))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    47
	$(call CONFIG_LINE,PERSONAL_DIR:=$(PERSONAL_DIR))
561
e3b9689745ab (svn r970) Added 2nd data path for all non-windows OSes
bjarni
parents: 549
diff changeset
    48
	$(call CONFIG_LINE,SECOND_DATA_PATH:=$(SECOND_DATA_PATH))
e3b9689745ab (svn r970) Added 2nd data path for all non-windows OSes
bjarni
parents: 549
diff changeset
    49
	$(call CONFIG_LINE,CUSTOM_LANG_PATH:=$(CUSTOM_LANG_PATH))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    50
	$(call CONFIG_LINE,)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    51
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    52
	$(call CONFIG_LINE,\# Flag to skip test for OS when building static)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    53
	$(call CONFIG_LINE,\# OpenTTD have only been succesfully tested with static builds on MorphOS and MacOSX)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    54
	$(call CONFIG_LINE,\# If you want to try anyway on other OSes, set this flag)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    55
	$(call CONFIG_LINE,\# Inform us if you have success)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    56
	$(call CONFIG_LINE,SKIP_STATIC_CHECK:=$(SKIP_STATIC_CHECK))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    57
	$(call CONFIG_LINE,)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    58
	$(call CONFIG_LINE,)
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    59
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    60
	$(call CONFIG_LINE,\# Everything below this line is autogenerated)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    61
	$(call CONFIG_LINE,\#)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    62
	$(call CONFIG_LINE,\# If you need to change anything below, you should run "make upgradeconf")
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    63
	$(call CONFIG_LINE,\# If that does not fix the problem, you should make a bug report.)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    64
	$(call CONFIG_LINE,\# It would really help if you could tell how to autodetect the missing setting)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    65
	$(call CONFIG_LINE,\# That info could be where the missing lib is placed)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    66
	$(call CONFIG_LINE,)
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    67
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    68
	$(call CONFIG_LINE,\# Libs)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    69
	$(call CONFIG_LINE,WITH_ZLIB:=$(WITH_ZLIB))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    70
	$(call CONFIG_LINE,WITH_SDL:=$(WITH_SDL))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    71
	$(call CONFIG_LINE,WITH_PNG:=$(WITH_PNG))
3408
313f35564673 (svn r4219) - Add support for WITH_ICONV. It is enabled by default for OSX > 10.3 for all others set it with WITH_ICONV in Makefile.config or with --with-iconv with configure. --with-config=/somedir will search for iconv include files somewhere (or in Makefile.config with WITH_ICONV_PATH). Custom library loading is not (yet) supported
Darkvater
parents: 3406
diff changeset
    72
	$(call CONFIG_LINE,WITH_ICONV:=$(WITH_ICONV))
313f35564673 (svn r4219) - Add support for WITH_ICONV. It is enabled by default for OSX > 10.3 for all others set it with WITH_ICONV in Makefile.config or with --with-iconv with configure. --with-config=/somedir will search for iconv include files somewhere (or in Makefile.config with WITH_ICONV_PATH). Custom library loading is not (yet) supported
Darkvater
parents: 3406
diff changeset
    73
	$(call CONFIG_LINE,WITH_ICONV_PATH:=$(WITH_ICONV_PATH))
3389
f26c7fc263a5 (svn r4197) reentered STATIC_ZLIB_PATH (removed in 4183) since it turned out that it's used after all
bjarni
parents: 3380
diff changeset
    74
	$(call CONFIG_LINE,STATIC_ZLIB_PATH:=$(STATIC_ZLIB_PATH))
2736
1ea068235989 (svn r3281) -Feature: [OSX] added native cocoa sound and video drivers (egladil)
bjarni
parents: 2731
diff changeset
    75
	$(call CONFIG_LINE,WITH_COCOA:=$(WITH_COCOA))
5108
dc67d70b5a45 (svn r7182) -Feature: Merge utf8 branch. This brings us support for Unicode/UTF-8 and the option for fonts rendered by FreeType. Language changes to come.
peter1138
parents: 4324
diff changeset
    76
	$(call CONFIG_LINE,WITH_FREETYPE:=$(WITH_FREETYPE))
5117
a4a7fd847b77 (svn r7196) -Feature: use fontconfig so one can set the font family name in openttd.cfg instead of the full path to the font.
rubidium
parents: 5108
diff changeset
    77
	$(call CONFIG_LINE,WITH_FONTCONFIG:=$(WITH_FONTCONFIG))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    78
	$(call CONFIG_LINE,)
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    79
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    80
	$(call CONFIG_LINE,\# OS flags)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    81
	$(call CONFIG_LINE,WIN32:=$(WIN32))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    82
	$(call CONFIG_LINE,UNIX:=$(UNIX))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    83
	$(call CONFIG_LINE,OSX:=$(OSX))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    84
	$(call CONFIG_LINE,FREEBSD:=$(FREEBSD))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    85
	$(call CONFIG_LINE,MORPHOS:=$(MORPHOS))
421
0b9bdcdfe0c5 (svn r619) Add the necessary bits to make building under BeOS using GNU Make work
tron
parents: 348
diff changeset
    86
	$(call CONFIG_LINE,BEOS:=$(BEOS))
446
20304ea8e94e (svn r655) Add the necessary bits to make building on SunOS/Solaris work
tron
parents: 421
diff changeset
    87
	$(call CONFIG_LINE,SUNOS:=$(SUNOS))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    88
	$(call CONFIG_LINE,CYGWIN:=$(CYGWIN))
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
    89
	$(call CONFIG_LINE,MINGW:=$(MINGW))
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    90
	$(call CONFIG_LINE,)
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    91
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    92
	$(call CONFIG_LINE,\# For cross-compiling)
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    93
	$(call CONFIG_LINE,CC_TARGET:=$(CC_TARGET))
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    94
	$(call CONFIG_LINE,CC_HOST:=$(CC_HOST))
3900
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents: 3408
diff changeset
    95
	$(call CONFIG_LINE,CXX_TARGET:=$(CXX_TARGET))
4984308f9125 (svn r4987) Feature: Merged YAPF into trunk. Thanks to devs for continuous support and users for testing.
KUDr
parents: 3408
diff changeset
    96
	$(call CONFIG_LINE,CXX_HOST:=$(CXX_HOST))
1692
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    97
	$(call CONFIG_LINE,CFLAGS_HOST:=$(CFLAGS_HOST))
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    98
	$(call CONFIG_LINE,WINDRES:=$(WINDRES))
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
    99
	$(call CONFIG_LINE,ENDIAN_FORCE:=$(ENDIAN_FORCE))
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
   100
	$(call CONFIG_LINE,)
2587eee1c632 (svn r2196) -Change: updated the Makefile, now it works for crossplatform compiling
TrueLight
parents: 804
diff changeset
   101
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   102
	$(call CONFIG_LINE,\# misc)
3406
514eef372355 (svn r4217) Replace SDL-CONFIG and LIBPNG-CONFIG with SDL_CONFIG and LIBPNG_CONFIG
peter1138
parents: 3389
diff changeset
   103
	$(call CONFIG_LINE,SDL_CONFIG:=$(SDL_CONFIG))
514eef372355 (svn r4217) Replace SDL-CONFIG and LIBPNG-CONFIG with SDL_CONFIG and LIBPNG_CONFIG
peter1138
parents: 3389
diff changeset
   104
	$(call CONFIG_LINE,LIBPNG_CONFIG:=$(LIBPNG_CONFIG))
5108
dc67d70b5a45 (svn r7182) -Feature: Merge utf8 branch. This brings us support for Unicode/UTF-8 and the option for fonts rendered by FreeType. Language changes to come.
peter1138
parents: 4324
diff changeset
   105
	$(call CONFIG_LINE,FREETYPE_CONFIG:=$(FREETYPE_CONFIG))
5117
a4a7fd847b77 (svn r7196) -Feature: use fontconfig so one can set the font family name in openttd.cfg instead of the full path to the font.
rubidium
parents: 5108
diff changeset
   106
	$(call CONFIG_LINE,FONTCONFIG_CONFIG:=$(FONTCONFIG_CONFIG))
421
0b9bdcdfe0c5 (svn r619) Add the necessary bits to make building under BeOS using GNU Make work
tron
parents: 348
diff changeset
   107
	$(call CONFIG_LINE,BEOS_NET_SERVER:=$(BEOS_NET_SERVER))
0
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   108
	$(call CONFIG_LINE,CONFIG_INCLUDED:=yes)
29654efe3188 (svn r1) Import of revision 975 of old (crashed) SVN
truelight
parents:
diff changeset
   109
	$(call CONFIG_LINE,PATH_SET:=$(PATH_SET))
180
47ee14fe2b35 (svn r181) Makefile: enabled ability to supress output of missing strings in lng files
bjarni
parents: 0
diff changeset
   110
	$(call CONFIG_LINE,CONFIG_VERSION:=$(MAKEFILE_VERSION))