diff --git a/indexer/classificator_loader.cpp b/indexer/classificator_loader.cpp index 6c11be5646..8056597f22 100644 --- a/indexer/classificator_loader.cpp +++ b/indexer/classificator_loader.cpp @@ -55,7 +55,7 @@ namespace classificator void Load() { - LOG(LINFO, ("Reading of classificator started")); + LOG(LDEBUG, ("Reading of classificator started")); Platform & p = GetPlatform(); @@ -66,23 +66,20 @@ namespace classificator //LOG(LINFO, ("Reading of drawing rules")); drule::RulesHolder & rules = drule::rules(); - try - { - // Load from proto buffer binary file. - ReaderStreamBuf buffer(p.GetReader(DRAWING_RULES_BIN_FILE)); +#if defined(OMIM_PRODUCTION) || defined(USE_BINARY_STYLES) + // Load from proto buffer binary file. + ReaderStreamBuf buffer(p.GetReader(DRAWING_RULES_BIN_FILE)); - istream s(&buffer); - rules.LoadFromBinaryProto(s); - } - catch (FileAbsentException const &) - { - // Load from proto buffer text file. - string buffer; - ModelReaderPtr(p.GetReader(DRAWING_RULES_TXT_FILE)).ReadAsString(buffer); + istream s(&buffer); + rules.LoadFromBinaryProto(s); +#else + // Load from proto buffer text file. + string buffer; + ModelReaderPtr(p.GetReader(DRAWING_RULES_TXT_FILE)).ReadAsString(buffer); - rules.LoadFromTextProto(buffer); - } + rules.LoadFromTextProto(buffer); +#endif - LOG(LINFO, ("Reading of classificator finished")); + LOG(LDEBUG, ("Reading of classificator finished")); } } diff --git a/qt/qt.pro b/qt/qt.pro index 9699fb62aa..5dfb5263c3 100644 --- a/qt/qt.pro +++ b/qt/qt.pro @@ -34,33 +34,37 @@ macx* { PLIST_PATH = $${DESTDIR}/$${TARGET}.app/Contents/$${PLIST_FILE} QMAKE_POST_LINK = $${IN_PWD}/../tools/unix/process_plist.sh $${IN_PWD}/.. $$VERSION_MAJOR $$VERSION_MINOR $$PLIST_PATH -# CONFIG(production) { - # Bundle Resouces - OTHER_RES.path = Contents/Resources - OTHER_RES.files = ../data/about-travelguide-desktop.html ../data/eula.html ../data/welcome.html \ - ../data/countries.txt \ - ../data/languages.txt ../data/categories.txt \ - ../data/packed_polygons.bin - CLASSIFICATOR_RES.path = Contents/Resources - CLASSIFICATOR_RES.files = ../data/classificator.txt ../data/visibility.txt \ - ../data/types.txt ../data/drules_proto.txt - SKIN_RES.path = Contents/Resources - SKIN_RES.files = ../data/basic_ldpi.skn ../data/symbols_ldpi.png - FONT_RES.path = Contents/Resources - FONT_RES.files = ../data/01_dejavusans.ttf \ - ../data/02_wqy-microhei.ttf \ - ../data/03_jomolhari-id-a3d.ttf \ - ../data/04_padauk.ttf \ - ../data/05_khmeros.ttf \ - ../data/06_code2000.ttf \ - ../data/fonts_blacklist.txt \ - ../data/fonts_whitelist.txt \ - ../data/unicode_blocks.txt - MWM_RES.path = Contents/Resources - MWM_RES.files = ../data/World.mwm ../data/WorldCoasts.mwm - QMAKE_BUNDLE_DATA += OTHER_RES CLASSIFICATOR_RES SKIN_RES FONT_RES MWM_RES -# } + # Bundle Resouces + OTHER_RES.path = Contents/Resources + OTHER_RES.files = ../data/about-travelguide-desktop.html ../data/eula.html ../data/welcome.html \ + ../data/countries.txt \ + ../data/languages.txt ../data/categories.txt \ + ../data/packed_polygons.bin + CLASSIFICATOR_RES.path = Contents/Resources + CLASSIFICATOR_RES.files = ../data/classificator.txt ../data/visibility.txt \ + ../data/types.txt + CONFIG(production) { + CLASSIFICATOR_RES.files += ../data/drules_proto.bin + } else { + CLASSIFICATOR_RES.files += ../data/drules_proto.txt + } + SKIN_RES.path = Contents/Resources + SKIN_RES.files = ../data/basic_ldpi.skn ../data/symbols_ldpi.png + FONT_RES.path = Contents/Resources + FONT_RES.files = ../data/01_dejavusans.ttf \ + ../data/02_wqy-microhei.ttf \ + ../data/03_jomolhari-id-a3d.ttf \ + ../data/04_padauk.ttf \ + ../data/05_khmeros.ttf \ + ../data/06_code2000.ttf \ + ../data/fonts_blacklist.txt \ + ../data/fonts_whitelist.txt \ + ../data/unicode_blocks.txt + MWM_RES.path = Contents/Resources + MWM_RES.files = ../data/World.mwm ../data/WorldCoasts.mwm + + QMAKE_BUNDLE_DATA += OTHER_RES CLASSIFICATOR_RES SKIN_RES FONT_RES MWM_RES } SOURCES += \