From afbb1b0617f1f8c8bf3c7ff17cbdc2f638db3168 Mon Sep 17 00:00:00 2001 From: Pavel Stupnikov Date: Fri, 2 Jan 2015 04:56:11 +0300 Subject: [PATCH] update to 1.4.4 --- Makefile.grf.in | 6 +- Makefile.src.in | 4 +- bin/baseset/no_sound.obs | 3 +- build-number.txt | 6 +- changelog.txt | 117 ++ config.lib | 172 +-- docs/landscape.html | 3 +- docs/landscape_grid.html | 4 +- known-bugs.txt | 17 +- media/extra_grf/assemble_nfo.awk | 32 + os/debian/changelog | 66 + os/windows/installer/install.nsi | 4 +- projects/openttd_vs100.vcxproj | 15 - projects/openttd_vs100.vcxproj.filters | 45 - projects/openttd_vs80.vcproj | 60 - projects/openttd_vs90.vcproj | 388 +++-- readme.txt | 65 +- source.list | 6 - src/3rdparty/squirrel/squirrel/sqcompiler.cpp | 2 +- src/ai/ai_gui.cpp | 10 +- src/airport_gui.cpp | 27 +- src/articulated_vehicles.cpp | 37 +- src/autoreplace_gui.cpp | 19 +- src/base_media_func.h | 4 +- src/blitter/32bpp_anim.cpp | 45 +- src/blitter/32bpp_anim_sse4.cpp | 22 +- src/blitter/32bpp_base.hpp | 15 +- src/blitter/32bpp_optimized.cpp | 37 +- src/blitter/32bpp_simple.cpp | 13 +- src/blitter/32bpp_sse2.cpp | 3 +- src/blitter/32bpp_sse_func.hpp | 26 +- src/blitter/8bpp_optimized.cpp | 5 +- src/blitter/8bpp_simple.cpp | 3 +- src/blitter/base.hpp | 3 +- src/bootstrap_gui.cpp | 4 +- src/build_vehicle_gui.cpp | 17 +- src/cargo_table_gui.cpp | 435 +++--- src/cargo_table_gui.h | 28 +- src/cargomonitor.cpp | 10 +- src/cargomonitor.h | 9 +- src/cargopacket.h | 4 +- src/command.cpp | 23 +- src/commands_gui.cpp | 1312 ++++++++++------- src/company_cmd.cpp | 76 +- src/company_func.h | 2 +- src/company_gui.cpp | 72 +- src/console_gui.cpp | 6 +- src/core/overflowsafe_type.hpp | 4 +- src/crashlog.cpp | 14 +- src/date_gui.cpp | 8 +- src/dock_gui.cpp | 6 +- src/driver.cpp | 36 +- src/driver.h | 10 +- src/economy.cpp | 229 ++- src/engine_func.h | 3 +- src/engine_gui.cpp | 10 +- src/fileio.cpp | 51 +- src/fios.cpp | 6 +- src/fios_gui.cpp | 30 +- src/fontdetection.cpp | 4 +- src/game/game_text.cpp | 4 +- src/genworld.cpp | 8 +- src/gfx.cpp | 29 +- src/gfxinit.cpp | 8 +- src/goal_gui.cpp | 4 +- src/graph_gui.cpp | 11 +- src/ground_vehicle.cpp | 33 +- src/ground_vehicle.hpp | 6 +- src/gui.h | 3 +- src/hotkeys.cpp | 2 +- src/industry_gui.cpp | 60 +- src/ini_load.cpp | 5 +- src/lang/afrikaans.txt | 540 +++---- src/lang/arabic_egypt.txt | 93 +- src/lang/basque.txt | 176 ++- src/lang/belarusian.txt | 215 +-- src/lang/brazilian_portuguese.txt | 277 ++-- src/lang/bulgarian.txt | 135 +- src/lang/catalan.txt | 1023 ++++++------- src/lang/croatian.txt | 217 +-- src/lang/czech.txt | 217 +-- src/lang/danish.txt | 67 +- src/lang/dutch.txt | 225 +-- src/lang/english.txt | 399 +++-- src/lang/english_AU.txt | 243 +-- src/lang/english_US.txt | 292 ++-- src/lang/esperanto.txt | 409 ++--- src/lang/estonian.txt | 73 +- src/lang/faroese.txt | 67 +- src/lang/finnish.txt | 205 +-- src/lang/french.txt | 196 +-- src/lang/gaelic.txt | 267 ++-- src/lang/galician.txt | 67 +- src/lang/german.txt | 209 +-- src/lang/greek.txt | 239 +-- src/lang/hebrew.txt | 132 +- src/lang/hungarian.txt | 193 ++- src/lang/icelandic.txt | 67 +- src/lang/indonesian.txt | 86 +- src/lang/irish.txt | 80 +- src/lang/italian.txt | 241 +-- src/lang/japanese.txt | 121 +- src/lang/korean.txt | 307 ++-- src/lang/latvian.txt | 67 +- src/lang/lithuanian.txt | 578 ++++---- src/lang/luxembourgish.txt | 600 ++++---- src/lang/malay.txt | 88 +- src/lang/norwegian_bokmal.txt | 190 ++- src/lang/norwegian_nynorsk.txt | 70 +- src/lang/polish.txt | 413 +++--- src/lang/portuguese.txt | 67 +- src/lang/romanian.txt | 67 +- src/lang/russian.txt | 247 ++-- src/lang/serbian.txt | 101 +- src/lang/simplified_chinese.txt | 333 +++-- src/lang/slovak.txt | 333 +++-- src/lang/slovenian.txt | 74 +- src/lang/spanish.txt | 451 +++--- src/lang/swedish.txt | 191 +-- src/lang/tamil.txt | 69 +- src/lang/thai.txt | 67 +- src/lang/traditional_chinese.txt | 165 ++- src/lang/turkish.txt | 84 +- src/lang/ukrainian.txt | 221 +-- src/lang/unfinished/chuvash.txt | 65 +- src/lang/unfinished/frisian.txt | 66 +- src/lang/unfinished/ido.txt | 18 +- src/lang/unfinished/macedonian.txt | 66 +- src/lang/unfinished/maltese.txt | 18 +- src/lang/unfinished/marathi.txt | 65 +- src/lang/unfinished/persian.txt | 177 ++- src/lang/unfinished/urdu.txt | 139 +- src/lang/vietnamese.txt | 190 +-- src/lang/welsh.txt | 285 ++-- src/linkgraph/demands.cpp | 49 +- src/linkgraph/flowmapper.cpp | 8 +- src/linkgraph/linkgraph.cpp | 8 +- src/linkgraph/linkgraph_gui.cpp | 7 +- src/main_gui.cpp | 7 +- src/misc_gui.cpp | 303 +++- src/music/extmidi.cpp | 6 +- src/music/music_driver.hpp | 10 +- src/music_gui.cpp | 27 +- src/network/network.cpp | 7 +- src/network/network_chat_gui.cpp | 6 +- src/network/network_client.cpp | 41 +- src/network/network_func.h | 7 +- src/network/network_gui.cpp | 26 +- src/network/network_server.cpp | 49 +- src/network/network_server.h | 3 +- src/newgrf.cpp | 6 +- src/newgrf_config.cpp | 4 +- src/newgrf_gui.cpp | 7 +- src/newgrf_house.cpp | 10 +- src/newgrf_spritegroup.cpp | 8 +- src/newgrf_station.cpp | 10 +- src/newgrf_text.cpp | 12 +- src/object_gui.cpp | 5 +- src/openttd.cpp | 37 +- src/order_gui.cpp | 21 +- src/os/macosx/crashlog_osx.cpp | 4 +- src/os/macosx/osx_stdafx.h | 18 +- src/os/unix/unix.cpp | 15 +- src/os/windows/crashlog_win.cpp | 4 +- src/os/windows/ottdres.rc | 121 ++ src/os/windows/ottdres.rc.in | 6 +- src/os/windows/win32.cpp | 4 +- src/osk_gui.cpp | 4 +- src/rail_gui.cpp | 68 +- src/rev.cpp | 8 +- src/rev.cpp.in | 6 +- src/road_cmd.cpp | 7 +- src/road_gui.cpp | 104 +- src/saveload/afterload.cpp | 20 +- src/saveload/company_sl.cpp | 4 +- src/saveload/goal_sl.cpp | 6 +- src/saveload/linkgraph_sl.cpp | 4 +- src/saveload/oldloader_sl.cpp | 6 +- src/saveload/order_sl.cpp | 15 +- src/saveload/saveload.cpp | 24 +- src/saveload/station_sl.cpp | 10 +- src/saveload/town_sl.cpp | 6 + src/script/api/ai_changelog.hpp | 18 +- src/script/api/game/game_window.hpp.sq | 1 - src/script/api/game_changelog.hpp | 24 +- src/script/api/script_cargolist.cpp | 4 +- src/script/api/script_cargomonitor.cpp | 41 +- src/script/api/script_cargomonitor.hpp | 22 +- src/script/api/script_list.cpp | 9 +- src/script/api/script_window.hpp | 1 - src/settings_gui.cpp | 10 +- src/settings_type.h | 10 +- src/signs_gui.cpp | 3 +- src/smallmap_gui.cpp | 10 +- src/sound/sound_driver.hpp | 10 +- src/sound_type.h | 8 +- src/station_base.h | 21 +- src/station_cmd.cpp | 20 +- src/station_gui.cpp | 6 +- src/stdafx.h | 3 +- src/strgen/strgen.cpp | 10 +- src/strings.cpp | 4 +- src/table/settings.ini | 20 +- src/table/sprites.h | 4 +- src/terraform_gui.cpp | 8 +- src/tile_cmd.h | 1 + src/timetable_gui.cpp | 28 +- src/toolbar_gui.cpp | 39 +- src/town.h | 37 +- src/town_cmd.cpp | 80 +- src/town_gui.cpp | 192 ++- src/vehicle.cpp | 10 +- src/vehicle_gui.cpp | 5 +- src/video/cocoa/cocoa_v.mm | 8 +- src/video/cocoa/event.mm | 4 +- src/video/cocoa/fullscreen.mm | 4 +- src/video/dedicated_v.cpp | 9 +- src/video/sdl_v.cpp | 8 +- src/video/video_driver.hpp | 10 +- src/video/win32_v.cpp | 4 +- src/viewport.cpp | 4 +- src/viewport_gui.cpp | 5 + src/watch_gui.cpp | 351 ++++- src/watch_gui.h | 56 +- src/widget.cpp | 4 +- src/widget_type.h | 8 +- src/widgets/cargo_table_widget.h | 40 +- src/widgets/company_widget.h | 4 + src/widgets/dropdown.cpp | 4 +- src/widgets/story_widget.h | 4 +- src/widgets/town_widget.h | 1 + src/window.cpp | 11 +- src/window_gui.h | 3 +- src/window_type.h | 7 + src/zoning.h | 5 +- src/zoning_cmd.cpp | 410 ++---- src/zoning_gui.cpp | 225 +-- 237 files changed, 11474 insertions(+), 8031 deletions(-) create mode 100644 media/extra_grf/assemble_nfo.awk create mode 100644 src/os/windows/ottdres.rc diff --git a/Makefile.grf.in b/Makefile.grf.in index 9206bc8547..61609d0a32 100644 --- a/Makefile.grf.in +++ b/Makefile.grf.in @@ -1,4 +1,4 @@ -# $Id: Makefile.grf.in 25205 2013-04-24 20:30:02Z frosch $ +# $Id: Makefile.grf.in 26715 2014-08-03 14:06:04Z frosch $ # This file is part of OpenTTD. # OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2. @@ -75,10 +75,10 @@ $(BIN_DIR)/%.obm: $(BASESET_DIR)/%.obm $(OBJS_DIR)/langfiles.tmp $(BASESET_DIR)/ $(Q) awk -v langfiles='$(OBJS_DIR)/langfiles.tmp' -f $(BASESET_DIR)/translations.awk $< >$@ # Compile extra grf -$(BIN_DIR)/openttd.grf: $(PNG_FILES) $(NFO_FILES) $(OBJS_DIR)/sprites +$(BIN_DIR)/openttd.grf: $(PNG_FILES) $(NFO_FILES) $(OBJS_DIR)/sprites $(GRF_DIR)/assemble_nfo.awk $(E) '$(STAGE) Assembling openttd.nfo' $(Q)-cp $(PNG_FILES) $(OBJS_DIR)/sprites 2> /dev/null - $(Q) $(CC_BUILD) -nostdinc -I$(GRF_DIR) -C -E - < "$(GRF_DIR)/openttd.nfo" | sed -e '/^#/d' -e '/^$$/d' > $(OBJS_DIR)/sprites/openttd.nfo + $(Q) awk -f $(GRF_DIR)/assemble_nfo.awk $(GRF_DIR)/openttd.nfo > $(OBJS_DIR)/sprites/openttd.nfo $(Q) $(NFORENUM) -s $(OBJS_DIR)/sprites/openttd.nfo $(E) '$(STAGE) Compiling openttd.grf' $(Q) $(GRFCODEC) -n -s -e -p1 $(OBJS_DIR)/openttd.grf diff --git a/Makefile.src.in b/Makefile.src.in index 62b9d2da40..3c3002d8f0 100644 --- a/Makefile.src.in +++ b/Makefile.src.in @@ -292,8 +292,8 @@ $(ENDIAN_CHECK): $(SRC_DIR)/endian_check.cpp # Revision files -# $(SRC_DIR)/rev.cpp: $(CONFIG_CACHE_VERSION) $(SRC_DIR)/rev.cpp.in -# $(Q)cat $(SRC_DIR)/rev.cpp.in | sed "s@\!\!REVISION\!\!@$(REV_NR)@g;s@!!VERSION!!@$(REV)@g;s@!!MODIFIED!!@$(MODIFIED)@g;s@!!DATE!!@`date +%d.%m.%y`@g" > $(SRC_DIR)/rev.cpp +$(SRC_DIR)/rev.cpp: $(CONFIG_CACHE_VERSION) $(SRC_DIR)/rev.cpp.in + $(Q)cat $(SRC_DIR)/rev.cpp.in | sed "s@\!\!REVISION\!\!@$(REV_NR)@g;s@!!VERSION!!@$(REV)@g;s@!!MODIFIED!!@$(MODIFIED)@g;s@!!DATE!!@`date +%d.%m.%y`@g" > $(SRC_DIR)/rev.cpp $(SRC_DIR)/os/windows/ottdres.rc: $(CONFIG_CACHE_VERSION) $(SRC_DIR)/os/windows/ottdres.rc.in $(Q)cat $(SRC_DIR)/os/windows/ottdres.rc.in | sed "s@\!\!REVISION\!\!@$(REV_NR)@g;s@!!VERSION!!@$(REV)@g;s@!!DATE!!@`date +%d.%m.%y`@g" > $(SRC_DIR)/os/windows/ottdres.rc diff --git a/bin/baseset/no_sound.obs b/bin/baseset/no_sound.obs index b72f609b68..6c4af154ab 100644 --- a/bin/baseset/no_sound.obs +++ b/bin/baseset/no_sound.obs @@ -1,4 +1,4 @@ -; $Id: no_sound.obs 26414 2014-03-18 19:51:54Z frosch $ +; $Id: no_sound.obs 26532 2014-04-27 20:01:21Z rubidium $ ; ; This represents more or less nothingness ; @@ -22,6 +22,7 @@ description.en_AU = A sound pack without any sounds. description.en_US = A sound pack without any sounds. description.es_ES = Un conjunto de sonidos vacío. description.et_EE = Helikogu ilma helideta. +description.eu_ES = Soinurik gabeko soinu pakete bat description.fi_FI = Äänipaketti, jossa ei ole ääniä. description.fr_FR = Un pack de sons sans sons. description.gd_GB = Pacaid fhuaimean anns nach eil fuaim sam bith. diff --git a/build-number.txt b/build-number.txt index 3e86d579de..561dee4ba1 100644 --- a/build-number.txt +++ b/build-number.txt @@ -1,4 +1,4 @@ #Created by the Bamboo Continuous Integration Server -#Tue Apr 01 20:37:12 CEST 2014 -build.number=46 -build.timestamp="2014-04-01 20\:37\:12" +#Tue Oct 21 20:36:41 CEST 2014 +build.number=57 +build.timestamp="2014-10-21 20\:36\:41" diff --git a/changelog.txt b/changelog.txt index 1da7d4d1b2..979e6f58a2 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,3 +1,120 @@ +1.4.4 (2014-10-21) +------------------------------------------------------------------------ +(None) + + +1.4.4-RC1 (2014-10-08) +------------------------------------------------------------------------ +- Fix: Image widgets stored 32bit SpriteID in uint16 (r26971) +- Fix: Owner of road depot road types were not properly changed upon bankruptcy [FS#6126] (r26955) +- Fix: Compilation on HAIKU (r26922) +- Fix: Crash when enabling 'Full animation' if multiplayer chat text is on screen [FS#6096] (r26919) +- Fix: Height computation of game script text in town GUI did not consider margins [FS#6119] (r26859) +- Fix: [Squirrel] Debian lintian issues (r26853) +- Fix: Compilation of strgen on various platforms like Solaris (r26850) +- Fix: Better display of refit information for articulated vehicles [FS#6113] (r26849, r26848) +- Fix: Do not assign a next hop when returning cargo [FS#6110] (r26847) +- Fix: The ok-button in the OSK for the signs list should just close the OSK [FS#6116] (r26827) + + +1.4.3 (2014-09-23) +------------------------------------------------------------------------ +(None) + + +1.4.3-RC2 (2014-09-14) +------------------------------------------------------------------------ +- Fix: Crashes on joining a server with pending order backups [FS#6112] (r26819) +- Fix: Crashes on start due to dereferencing the -1 index of the file names array of music files (r26809) + + +1.4.3-RC1 (2014-09-07) +------------------------------------------------------------------------ +- Fix: TC_NO_SHADE did not work for 32bpp text rendering (r26792) +- Fix: Loading a game with order backups leaked Orders and left unreachable items in the pool (r26787) +- Fix: Buffer overrun in SQCompiler::Error (r26764) +- Fix: Desync due to not always properly restoring game state from the savegame (r26753) +- Fix: [Script] Crashes and infinite loops when using lists in item-descending order [FS#6085] (r26744) +- Fix: Incorrect CFLAGS when enabling gprof profiling (r26737, r26735) +- Fix: Do not reset the last selected airport or layout, unless it is really necessary [FS#6083] (r26732) +- Fix: Use the normal search path to look for xdg-open at Unix [FS#6077] (r26724) +- Fix: Properly check for cargo acceptance of houses [FS#5997] (r26723) + + +1.4.2 (2014-08-16) +------------------------------------------------------------------------ +(None) + + +1.4.2-RC2 (2014-08-03) +------------------------------------------------------------------------ +- Change: Use awk instead of trying to convince cpp to preprocess nfo files (r26708) +- Fix: CMD_CLEAR_ORDER_BACKUP should not be suppressed by pause modes (r26716) +- Fix: [NewGRF] Parameters to SCC_NEWGRF_PUSH_WORD and SCC_NEWGRF_UNPRINT were not skipped during drawing (r26713) +- Fix: [OSX] Compilation fails with some lzo2 versions, if __LP64__ is defined to 0 instead of checking whether it is defined [FS#6069] (r26709) +- Fix: Wrong breakdown sound was played for ships [FS#6015] (r26706) +- Fix: Integer overflows in acceleration code causing either too low acceleration or too high acceleration [FS#6067] (r26702) +- Fix: Discard incorrectly saved order backups when clients join [FS#6066] (r26700) +- Fix: Do not crash when trying to show an error about vehicle in a NewGRF and the NewGRF was not loaded at all (r26699) +- Fix: Slovak uses space as group separator in numbers [FS#6064] (r26695) +- Fix: Tighten parameter bound checks on GSCargoMonitor functions, and return -1 on out-of-bound parameters (r26685) + + +1.4.2-RC1 (2014-07-03) +------------------------------------------------------------------------ +- Fix: CargoPacket::SourceStation() returns a StationID (r26660) +- Fix: Days in dates are not represented by ordinal numbers in all languages [FS#6047] (r26657) +- Fix: Production cheat cannot be allowed to be active in multiplayer for desync reasons, even when activated in singleplayer previously [FS#6044] (r26656) +- Fix: Make sure an 'abs' is used that supports int64 when using 'abs' on those variables (r26651) +- Fix: Support save/load chunk lengths of up to (1 << 32) - 1 [FS#6041] (r26650) +- Fix: Incorrect usage of string commands in the base language [FS#6037] (r26642, r26640, r26639, r26632) +- Fix: Segmentation fault when encountering a .obg/.obs/.obm with empty string/zero length MD5 checksums [FS#6038] (r26637) +- Fix: The 'Load' button was not properly enabled/disabled for old savegames without NewGRF information (r26634) +- Fix: If the video driver fails to supply a list of resolutions, display an error message [FS#6012] (r26629) + + +1.4.1 (2014-06-02) +------------------------------------------------------------------------ +- Fix: First send packages about new company, then clients joining it to admin port [FS#6025] (r26616) + + +1.4.1-RC2 (2014-05-18) +------------------------------------------------------------------------ +- Fix: Save/load issues on big endian machines (r26593, r26590, r26589) +- Fix: Consider multiheaded trains in station refits [FS#5995] (r26586) +- Fix: Game script could be changed in game by double clicking [FS#5974] (r26583) +- Fix: Transfer stations also should have a cargo rating [FS#5989] (r26581, r26580) +- Fix: [Network] AIs would not reset certain network state information upon creation of their company [FS#6003] (r26578, r26576) +- Fix: [Network] Client of non-dedicated server was not correctly put into the first company for all state variables [FS#6001] (r26577) + + +1.4.1-RC1 (2014-05-04) +------------------------------------------------------------------------ +- Change: Remove demand calculation based on tiles (r26484) +- Change: Use pkg-config for libpng as well (r26435, r26433, r26432) +- Change: Use better distance metric for link graph [FS#5941] (r26411) +- Fix: [Windows] Crash when the operating system performs the "paint" callback during window creation [FS#5994] (r26539, r26538) +- Fix: OpenBSD compilation [FS#5992] (r26523) +- Fix: prevent from ever reading huge (or negative) amounts of data in strgen (r26521) +- Fix: Severity rating of dedicated server messages during world generation (r26518) +- Fix: Buffer overruns in handling of symbolic links inside tars (r26514) +- Fix: Incorrect usage of strecpy (r26505, r26485) +- Fix: Reading console input on dedicated server relied on unspecified behaviour (r26496) +- Fix: Allow single-vehicle consists to station-refit in a meaningful way (r26483) +- Fix: Prevent comparing to NULL when strndup could not allocate memory (r26476) +- Fix: Potentially undefined shifts in NewGRF code (r26475) +- Fix: Make sure there is no uninitialised sprite data (r26473) +- Fix: Draw text shadow for ellipses (r26467) +- Fix: Add special handling for PALETTE_CRASH to work for non-8bpp-mapped sprites (r26463) +- Fix: Avoid division by 0 when scaling flow values [FS#5970] (r26448) +- Fix: Draw links to match _settings_game.vehicle.road_side [FS#5961] (r26445) +- Fix: Load button for heightmap list was missing [FS#5953] (r26428) +- Fix: Do not crash when supplying an invalid filename without extension to cmd parameter -q (r26423) +- Fix: Some road constructions used the rail sound effect [FS#5946] (r26422) +- Fix: Goal GUI failed to shade [FS#5948] (r26420) +- Fix: Shares button state was not appropriately updated when switching setting or company [FS#5947] (r26416) + + 1.4.0 (2014-04-01) ------------------------------------------------------------------------ (None) diff --git a/config.lib b/config.lib index 13507f3c42..3ffd0c5ccb 100644 --- a/config.lib +++ b/config.lib @@ -1,4 +1,4 @@ -# $Id: config.lib 26440 2014-04-01 18:33:16Z frosch $ +# $Id: config.lib 27029 2014-10-21 18:33:24Z frosch $ # This file is part of OpenTTD. # OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2. @@ -1441,6 +1441,7 @@ make_cflags_and_ldflags() { make_compiler_cflags "$cc_host" "CFLAGS" "CXXFLAGS" "LDFLAGS" "FEATURES" CFLAGS="$CFLAGS -D$os" + CFLAGS_BUILD="$CFLAGS_BUILD -D$os" if [ "$enable_debug" = "0" ]; then # No debug, add default stuff @@ -1450,7 +1451,11 @@ make_cflags_and_ldflags() { LDFLAGS="$LDFLAGS -noixemul" fi - CFLAGS="-O2 -fomit-frame-pointer $CFLAGS" + if [ "$enable_profiling" = "0" ]; then + # -fomit-frame-pointer and -pg do not go well together (gcc errors they are incompatible) + CFLAGS="-fomit-frame-pointer $CFLAGS" + fi + CFLAGS="-O2 $CFLAGS" else OBJS_SUBDIR="debug" @@ -1494,7 +1499,7 @@ make_cflags_and_ldflags() { fi if [ "$enable_profiling" != "0" ]; then - CFLAGS="$CFLAGS -p" + CFLAGS="$CFLAGS -pg" LDFLAGS="$LDFLAGS -pg" fi @@ -1700,17 +1705,18 @@ make_cflags_and_ldflags() { if [ -n "$png_config" ]; then CFLAGS="$CFLAGS -DWITH_PNG" - CFLAGS="$CFLAGS `$png_config --cppflags --I_opts | tr '\n\r' ' '`" + CFLAGS="$CFLAGS `$png_config --cflags | tr '\n\r' ' '`" - # The extra flags are unneeded for latest libpng-config, but some versions are so broken... if [ "$enable_static" != "0" ]; then if [ "$os" = "OSX" ]; then - LIBS="$LIBS `$png_config --prefix`/lib/libpng.a" + # fontconfig_config goes via pkg-config on all systems, which doesn't know --prefix + # Also, despite the reason we link to the .a file ourself (because we can't use -static), we do need to ask pkg-config about possible other deps + LIBS="$LIBS `$png_config --variable=prefix`/lib/libpng.a `$png_config --libs --static | sed s@-lpng[0-9]*@@`" else - LIBS="$LIBS `$png_config --static --ldflags | tr '\n\r' ' '`" + LIBS="$LIBS `$png_config --libs --static | tr '\n\r' ' '`" fi else - LIBS="$LIBS `$png_config --ldflags | tr '\n\r' ' '`" + LIBS="$LIBS `$png_config --libs | tr '\n\r' ' '`" fi fi @@ -2715,80 +2721,64 @@ detect_libtimidity() { detect_library "$with_libtimidity" "libtimidity" "libtimidity.a" "" "timidity.h" } -detect_lzma() { - # 0 means no, 1 is auto-detect, 2 is force - if [ "$with_lzma" = "0" ]; then - log 1 "checking liblzma... disabled" +detect_pkg_config() { + # $1 - config-param ($with_lzma value) + # $2 - package name ('liblzma') + # $3 - config name ('lzma_config', sets $lzma_config) + # $4 - minimum module version ('2.3') - lzma_config="" + # 0 means no, 1 is auto-detect, 2 is force + if [ "$1" = "0" ]; then + log 1 "checking $2... disabled" + + eval "$3=\"\"" return 0 fi - if [ "$with_lzma" = "1" ] || [ "$with_lzma" = "" ] || [ "$with_lzma" = "2" ]; then - lzma_config="pkg-config liblzma" + log 2 "detecting $2" + + if [ "$1" = "1" ] || [ "$1" = "" ] || [ "$1" = "2" ]; then + pkg_config_call="pkg-config $2" else - lzma_config="$with_lzma" + pkg_config_call="$1" fi - version=`$lzma_config --modversion 2>/dev/null` + version=`$pkg_config_call --modversion 2>/dev/null` ret=$? - log 2 "executing $lzma_config --modversion" + check_version "$4" "$version" + version_ok=$? + log 2 "executing $pkg_config_call --modversion" log 2 " returned $version" log 2 " exit code $ret" - if [ -z "$version" ] || [ "$ret" != "0" ]; then - log 1 "checking liblzma... not found" + if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version_ok" != "1" ]; then + if [ -n "$version" ] && [ "$version_ok" != "1" ]; then + log 1 "checking $2... needs at least version $4, $2 NOT enabled" + else + log 1 "checking $2... not found" + fi # It was forced, so it should be found. - if [ "$with_lzma" != "1" ]; then - log 1 "configure: error: pkg-config liblzma couldn't be found" - log 1 "configure: error: you supplied '$with_lzma', but it seems invalid" + if [ "$1" != "1" ]; then + log 1 "configure: error: pkg-config $2 couldn't be found" + log 1 "configure: error: you supplied '$1', but it seems invalid" exit 1 fi - lzma_config="" + eval "$3=\"\"" return 0 fi - log 1 "checking liblzma... found" + eval "$3=\"$pkg_config_call\"" + log 1 "checking $2... found" +} + +detect_lzma() { + detect_pkg_config "$with_lzma" "liblzma" "lzma_config" "5.0" } detect_xdg_basedir() { - # 0 means no, 1 is auto-detect, 2 is force - if [ "$with_xdg_basedir" = "0" ]; then - log 1 "checking libxdg_basedir... disabled" - - xdg_basedir_config="" - return 0 - fi - - if [ "$with_xdg_basedir" = "1" ] || [ "$with_xdg_basedir" = "" ] || [ "$with_xdg_basedir" = "2" ]; then - xdg_basedir_config="pkg-config libxdg-basedir" - else - xdg_basedir_config="$with_xdg_basedir" - fi - - version=`$xdg_basedir_config --modversion 2>/dev/null` - ret=$? - log 2 "executing $xdg_basedir_config --modversion" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ]; then - log 1 "checking libxdg_basedir... not found" - - # It was forced, so it should be found. - if [ "$with_xdg_basedir" != "1" ]; then - log 1 "configure: error: pkg-config libxdg_basedir couldn't be found" - log 1 "configure: error: you supplied '$with_xdg_basedir', but it seems invalid" - exit 1 - fi - - xdg_basedir_config="" - return 0 - fi - - log 1 "checking libxdg_basedir... found" + detect_pkg_config "$with_xdg_basedir" "libxdg-basedir" "xdg_basedir_config" "1.2" } detect_png() { @@ -2815,33 +2805,7 @@ detect_png() { return 0 fi - if [ "$with_png" = "1" ] || [ "$with_png" = "" ] || [ "$with_png" = "2" ]; then - png_config="libpng-config" - else - png_config="$with_png" - fi - - version=`$png_config --version 2>/dev/null` - ret=$? - log 2 "executing $png_config --version" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ]; then - log 1 "checking libpng... not found" - - # It was forced, so it should be found. - if [ "$with_png" != "1" ]; then - log 1 "configure: error: libpng-config couldn't be found" - log 1 "configure: error: you supplied '$with_png', but it seems invalid" - exit 1 - fi - - png_config="" - return 0 - fi - - log 1 "checking libpng... found" + detect_pkg_config "$with_png" "libpng" "png_config" "1.2" } detect_freetype() { @@ -2936,39 +2900,7 @@ detect_fontconfig() { return 0 fi - if [ "$with_fontconfig" = "1" ] || [ "$with_fontconfig" = "" ] || [ "$with_fontconfig" = "2" ]; then - fontconfig_config="pkg-config fontconfig" - else - fontconfig_config="$with_fontconfig" - fi - - version=`$fontconfig_config --modversion 2>/dev/null` - ret=$? - check_version '2.3' "$version" - version_ok=$? - log 2 "executing $fontconfig_config --modversion" - log 2 " returned $version" - log 2 " exit code $ret" - - if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version_ok" != "1" ]; then - if [ -n "$version" ] && [ "$version_ok" != "1" ]; then - log 1 "checking libfontconfig... needs at least version 2.3.0, fontconfig NOT enabled" - else - log 1 "checking libfontconfig... not found" - fi - - # It was forced, so it should be found. - if [ "$with_fontconfig" != "1" ]; then - log 1 "configure: error: fontconfig-config couldn't be found" - log 1 "configure: error: you supplied '$with_fontconfig', but it seems invalid" - exit 1 - fi - - fontconfig_config="" - return 0 - fi - - log 1 "checking libfontconfig... found" + detect_pkg_config "$with_fontconfig" "fontconfig" "fontconfig_config" "2.3" } detect_icu() { diff --git a/docs/landscape.html b/docs/landscape.html index abf01c9d8b..2aa30460ec 100644 --- a/docs/landscape.html +++ b/docs/landscape.html @@ -539,6 +539,7 @@ +
  • m3 bits 7..4: owner of road type 1 (tram); OWNER_NONE (10) is stored as OWNER_TOWN (0F)
  • m5 bits 7 clear: road or level-crossing