Reorganize GYP files.

This commit is contained in:
John Preston 2019-09-16 17:52:19 +03:00
parent 849deb57e2
commit 673072ea5b
56 changed files with 374 additions and 430 deletions

View file

@ -1,60 +0,0 @@
<RCC>
<qresource prefix="/export">
<file alias="css/style.css">../export_html/css/style.css</file>
<file alias="images/back.png">../export_html/images/back.png</file>
<file alias="images/back@2x.png">../export_html/images/back@2x.png</file>
<file alias="images/media_call.png">../export_html/images/media_call.png</file>
<file alias="images/media_call@2x.png">../export_html/images/media_call@2x.png</file>
<file alias="images/media_contact.png">../export_html/images/media_contact.png</file>
<file alias="images/media_contact@2x.png">../export_html/images/media_contact@2x.png</file>
<file alias="images/media_file.png">../export_html/images/media_file.png</file>
<file alias="images/media_file@2x.png">../export_html/images/media_file@2x.png</file>
<file alias="images/media_game.png">../export_html/images/media_game.png</file>
<file alias="images/media_game@2x.png">../export_html/images/media_game@2x.png</file>
<file alias="images/media_location.png">../export_html/images/media_location.png</file>
<file alias="images/media_location@2x.png">../export_html/images/media_location@2x.png</file>
<file alias="images/media_music.png">../export_html/images/media_music.png</file>
<file alias="images/media_music@2x.png">../export_html/images/media_music@2x.png</file>
<file alias="images/media_photo.png">../export_html/images/media_photo.png</file>
<file alias="images/media_photo@2x.png">../export_html/images/media_photo@2x.png</file>
<file alias="images/media_shop.png">../export_html/images/media_shop.png</file>
<file alias="images/media_shop@2x.png">../export_html/images/media_shop@2x.png</file>
<file alias="images/media_video.png">../export_html/images/media_video.png</file>
<file alias="images/media_video@2x.png">../export_html/images/media_video@2x.png</file>
<file alias="images/media_voice.png">../export_html/images/media_voice.png</file>
<file alias="images/media_voice@2x.png">../export_html/images/media_voice@2x.png</file>
<file alias="images/section_calls.png">../export_html/images/section_calls.png</file>
<file alias="images/section_calls@2x.png">../export_html/images/section_calls@2x.png</file>
<file alias="images/section_chats.png">../export_html/images/section_chats.png</file>
<file alias="images/section_chats@2x.png">../export_html/images/section_chats@2x.png</file>
<file alias="images/section_contacts.png">../export_html/images/section_contacts.png</file>
<file alias="images/section_contacts@2x.png">../export_html/images/section_contacts@2x.png</file>
<file alias="images/section_frequent.png">../export_html/images/section_frequent.png</file>
<file alias="images/section_frequent@2x.png">../export_html/images/section_frequent@2x.png</file>
<file alias="images/section_other.png">../export_html/images/section_other.png</file>
<file alias="images/section_other@2x.png">../export_html/images/section_other@2x.png</file>
<file alias="images/section_photos.png">../export_html/images/section_photos.png</file>
<file alias="images/section_photos@2x.png">../export_html/images/section_photos@2x.png</file>
<file alias="images/section_sessions.png">../export_html/images/section_sessions.png</file>
<file alias="images/section_sessions@2x.png">../export_html/images/section_sessions@2x.png</file>
<file alias="images/section_web.png">../export_html/images/section_web.png</file>
<file alias="images/section_web@2x.png">../export_html/images/section_web@2x.png</file>
<file alias="js/script.js">../export_html/js/script.js</file>
</qresource>
<qresource prefix="/gui">
<file alias="art/bg.jpg">../art/bg.jpg</file>
<file alias="art/bg_initial.jpg">../art/bg_initial.jpg</file>
<file alias="art/logo_256.png">../art/logo_256.png</file>
<file alias="art/logo_256_no_margin.png">../art/logo_256_no_margin.png</file>
<file alias="art/sunrise.jpg">../art/sunrise.jpg</file>
<file alias="day-blue.tdesktop-theme">../day-blue.tdesktop-theme</file>
<file alias="night.tdesktop-theme">../night.tdesktop-theme</file>
<file alias="night-green.tdesktop-theme">../night-green.tdesktop-theme</file>
</qresource>
<qresource prefix="/qt-project.org">
<file>qmime/freedesktop.org.xml</file>
</qresource>
<qresource prefix="/misc">
<file alias="default_shortcuts-custom.json">../default_shortcuts-custom.json</file>
</qresource>
</RCC>

View file

@ -0,0 +1,10 @@
<RCC>
<qresource prefix="/sounds">
<file alias="msg_incoming.mp3">../../sounds/msg_incoming.mp3</file>
<file alias="call_busy.mp3">../../sounds/call_busy.mp3</file>
<file alias="call_connect.mp3">../../sounds/call_connect.mp3</file>
<file alias="call_end.mp3">../../sounds/call_end.mp3</file>
<file alias="call_incoming.mp3">../../sounds/call_incoming.mp3</file>
<file alias="call_outgoing.mp3">../../sounds/call_outgoing.mp3</file>
</qresource>
</RCC>

View file

@ -0,0 +1,60 @@
<RCC>
<qresource prefix="/export">
<file alias="css/style.css">../../export_html/css/style.css</file>
<file alias="images/back.png">../../export_html/images/back.png</file>
<file alias="images/back@2x.png">../../export_html/images/back@2x.png</file>
<file alias="images/media_call.png">../../export_html/images/media_call.png</file>
<file alias="images/media_call@2x.png">../../export_html/images/media_call@2x.png</file>
<file alias="images/media_contact.png">../../export_html/images/media_contact.png</file>
<file alias="images/media_contact@2x.png">../../export_html/images/media_contact@2x.png</file>
<file alias="images/media_file.png">../../export_html/images/media_file.png</file>
<file alias="images/media_file@2x.png">../../export_html/images/media_file@2x.png</file>
<file alias="images/media_game.png">../../export_html/images/media_game.png</file>
<file alias="images/media_game@2x.png">../../export_html/images/media_game@2x.png</file>
<file alias="images/media_location.png">../../export_html/images/media_location.png</file>
<file alias="images/media_location@2x.png">../../export_html/images/media_location@2x.png</file>
<file alias="images/media_music.png">../../export_html/images/media_music.png</file>
<file alias="images/media_music@2x.png">../../export_html/images/media_music@2x.png</file>
<file alias="images/media_photo.png">../../export_html/images/media_photo.png</file>
<file alias="images/media_photo@2x.png">../../export_html/images/media_photo@2x.png</file>
<file alias="images/media_shop.png">../../export_html/images/media_shop.png</file>
<file alias="images/media_shop@2x.png">../../export_html/images/media_shop@2x.png</file>
<file alias="images/media_video.png">../../export_html/images/media_video.png</file>
<file alias="images/media_video@2x.png">../../export_html/images/media_video@2x.png</file>
<file alias="images/media_voice.png">../../export_html/images/media_voice.png</file>
<file alias="images/media_voice@2x.png">../../export_html/images/media_voice@2x.png</file>
<file alias="images/section_calls.png">../../export_html/images/section_calls.png</file>
<file alias="images/section_calls@2x.png">../../export_html/images/section_calls@2x.png</file>
<file alias="images/section_chats.png">../../export_html/images/section_chats.png</file>
<file alias="images/section_chats@2x.png">../../export_html/images/section_chats@2x.png</file>
<file alias="images/section_contacts.png">../../export_html/images/section_contacts.png</file>
<file alias="images/section_contacts@2x.png">../../export_html/images/section_contacts@2x.png</file>
<file alias="images/section_frequent.png">../../export_html/images/section_frequent.png</file>
<file alias="images/section_frequent@2x.png">../../export_html/images/section_frequent@2x.png</file>
<file alias="images/section_other.png">../../export_html/images/section_other.png</file>
<file alias="images/section_other@2x.png">../../export_html/images/section_other@2x.png</file>
<file alias="images/section_photos.png">../../export_html/images/section_photos.png</file>
<file alias="images/section_photos@2x.png">../../export_html/images/section_photos@2x.png</file>
<file alias="images/section_sessions.png">../../export_html/images/section_sessions.png</file>
<file alias="images/section_sessions@2x.png">../../export_html/images/section_sessions@2x.png</file>
<file alias="images/section_web.png">../../export_html/images/section_web.png</file>
<file alias="images/section_web@2x.png">../../export_html/images/section_web@2x.png</file>
<file alias="js/script.js">../../export_html/js/script.js</file>
</qresource>
<qresource prefix="/gui">
<file alias="art/bg.jpg">../../art/bg.jpg</file>
<file alias="art/bg_initial.jpg">../../art/bg_initial.jpg</file>
<file alias="art/logo_256.png">../../art/logo_256.png</file>
<file alias="art/logo_256_no_margin.png">../../art/logo_256_no_margin.png</file>
<file alias="art/sunrise.jpg">../../art/sunrise.jpg</file>
<file alias="day-blue.tdesktop-theme">../../day-blue.tdesktop-theme</file>
<file alias="night.tdesktop-theme">../../night.tdesktop-theme</file>
<file alias="night-green.tdesktop-theme">../../night-green.tdesktop-theme</file>
</qresource>
<qresource prefix="/qt-project.org">
<file>../qmime/freedesktop.org.xml</file>
</qresource>
<qresource prefix="/misc">
<file alias="default_shortcuts-custom.json">../../default_shortcuts-custom.json</file>
</qresource>
</RCC>

View file

@ -1,10 +0,0 @@
<RCC>
<qresource prefix="/sounds">
<file alias="msg_incoming.mp3">../sounds/msg_incoming.mp3</file>
<file alias="call_busy.mp3">../sounds/call_busy.mp3</file>
<file alias="call_connect.mp3">../sounds/call_connect.mp3</file>
<file alias="call_end.mp3">../sounds/call_end.mp3</file>
<file alias="call_incoming.mp3">../sounds/call_incoming.mp3</file>
<file alias="call_outgoing.mp3">../sounds/call_outgoing.mp3</file>
</qresource>
</RCC>

View file

@ -1,6 +1,5 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
@ -66,16 +65,3 @@ END
#endif // English (United States) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View file

@ -1,6 +1,5 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource1.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
@ -57,16 +56,3 @@ END
#endif // English (United States) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

Binary file not shown.

View file

@ -1,14 +0,0 @@
//{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
// Used by Updater.rc
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 101
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1001
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif

View file

@ -6,163 +6,7 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
'telegram/telegram.gypi',
],
'targets': [{
'target_name': 'Telegram',
'variables': {
'variables': {
'libs_loc': '../../../Libraries',
},
'libs_loc': '<(libs_loc)',
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'submodules_loc': '../ThirdParty',
'minizip_loc': '<(submodules_loc)/minizip',
'sp_media_key_tap_loc': '<(submodules_loc)/SPMediaKeyTap',
'emoji_suggestions_loc': '<(submodules_loc)/emoji_suggestions',
'style_files': [
'<(src_loc)/boxes/boxes.style',
'<(src_loc)/calls/calls.style',
'<(src_loc)/dialogs/dialogs.style',
'<(src_loc)/export/view/export.style',
'<(src_loc)/history/history.style',
'<(src_loc)/info/info.style',
'<(src_loc)/intro/intro.style',
'<(src_loc)/media/view/mediaview.style',
'<(src_loc)/media/player/media_player.style',
'<(src_loc)/overview/overview.style',
'<(src_loc)/passport/passport.style',
'<(src_loc)/profile/profile.style',
'<(src_loc)/settings/settings.style',
'<(src_loc)/chat_helpers/chat_helpers.style',
'<(src_loc)/window/window.style',
],
'dependent_style_files': [
'<(res_loc)/colors.palette',
'<(res_loc)/basic.style',
'<(src_loc)/ui/widgets/widgets.style',
],
'style_timestamp': '<(SHARED_INTERMEDIATE_DIR)/update_dependent_styles.timestamp',
'langpacks': [
'en',
'de',
'es',
'it',
'nl',
'ko',
'pt-BR',
],
'build_defines%': '',
'list_sources_command': 'python <(DEPTH)/list_sources.py --input <(DEPTH)/telegram_sources.txt --replace src_loc=<(src_loc)',
'pch_source': '<(src_loc)/stdafx.cpp',
'pch_header': '<(src_loc)/stdafx.h',
},
'includes': [
'common_executable.gypi',
'telegram_qrc.gypi',
'telegram_win.gypi',
'telegram_mac.gypi',
'telegram_linux.gypi',
'openssl.gypi',
'qt.gypi',
'qt_moc.gypi',
'qt_rcc.gypi',
'codegen_styles_rule.gypi',
'codegen_rules.gypi',
'pch.gypi',
],
'dependencies': [
'codegen.gyp:codegen_emoji',
'codegen.gyp:codegen_lang',
'codegen.gyp:codegen_numbers',
'codegen.gyp:codegen_style',
'tests/tests.gyp:tests',
'utils.gyp:Updater',
'../ThirdParty/libtgvoip/libtgvoip.gyp:libtgvoip',
'crl.gyp:crl',
'lib_base.gyp:lib_base',
'lib_export.gyp:lib_export',
'lib_storage.gyp:lib_storage',
'lib_lottie.gyp:lib_lottie',
'lib_ffmpeg.gyp:lib_ffmpeg',
'lib_mtproto.gyp:lib_mtproto',
'lib_ui.gyp:lib_ui',
],
'defines': [
'AL_LIBTYPE_STATIC',
'AL_ALEXT_PROTOTYPES',
'TGVOIP_USE_CXX11_LIB',
'XXH_INLINE_ALL',
'TDESKTOP_API_ID=<(api_id)',
'TDESKTOP_API_HASH=<(api_hash)',
'<!@(python -c "for s in \'<(build_defines)\'.split(\',\'): print(s)")',
],
'include_dirs': [
'<(src_loc)',
'<(SHARED_INTERMEDIATE_DIR)',
'<(libs_loc)/breakpad/src',
'<(libs_loc)/lzma/C',
'<(libs_loc)/zlib',
'<(libs_loc)/ffmpeg',
'<(libs_loc)/openal-soft/include',
'<(libs_loc)/opus/include',
'<(libs_loc)/range-v3/include',
'<(minizip_loc)',
'<(sp_media_key_tap_loc)',
'<(emoji_suggestions_loc)',
'<(submodules_loc)/GSL/include',
'<(submodules_loc)/variant/include',
'<(submodules_loc)/crl/src',
'<(submodules_loc)/xxHash',
],
'sources': [
'<@(qrc_files)',
'<@(style_files)',
'<!@(<(list_sources_command) <(qt_moc_list_sources_arg))',
'telegram_sources.txt',
'<(res_loc)/langs/cloud_lang.strings',
'<(res_loc)/export_html/css/style.css',
'<(res_loc)/export_html/js/script.js',
'<(res_loc)/export_html/images/back.png',
'<(res_loc)/export_html/images/back@2x.png',
],
'sources!': [
'<!@(<(list_sources_command) <(qt_moc_list_sources_arg) --exclude_for <(build_os))',
],
'conditions': [
[ '"<(official_build_target)" != ""', {
'defines': [
'TDESKTOP_OFFICIAL_TARGET=<(official_build_target)',
'TDESKTOP_FORCE_GTK_FILE_DIALOG',
],
'dependencies': [
'utils.gyp:Packer',
],
}], [ 'build_mac', {
'mac_hardened_runtime': 1,
'mac_bundle': '1',
'mac_bundle_resources': [
'<!@(python -c "for s in \'<@(langpacks)\'.split(\' \'): print(\'<(res_loc)/langs/\' + s + \'.lproj/Localizable.strings\')")',
'../Telegram/Images.xcassets',
],
'xcode_settings': {
'ENABLE_HARDENED_RUNTIME': 'YES',
},
'sources': [
'../Telegram/Telegram.entitlements',
],
}], [ 'build_macstore', {
'mac_sandbox': 1,
'mac_sandbox_development_team': '6N38VWS5BX',
'product_name': 'Telegram Desktop',
'sources': [
'../Telegram/Telegram Desktop.entitlements',
],
}],
],
}],
}

View file

@ -6,7 +6,7 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'codegen_lang',
@ -15,8 +15,8 @@
'mac_target': '10.10',
},
'includes': [
'common_executable.gypi',
'qt.gypi',
'common/executable.gypi',
'modules/qt.gypi',
],
'include_dirs': [
@ -52,8 +52,8 @@
'mac_target': '10.10',
},
'includes': [
'common_executable.gypi',
'qt.gypi',
'common/executable.gypi',
'modules/qt.gypi',
],
'dependencies': [
'lib_base.gyp:lib_base',
@ -95,8 +95,8 @@
'mac_target': '10.10',
},
'includes': [
'common_executable.gypi',
'qt.gypi',
'common/executable.gypi',
'modules/qt.gypi',
],
'include_dirs': [
@ -132,8 +132,8 @@
'mac_target': '10.10',
},
'includes': [
'common_executable.gypi',
'qt.gypi',
'common/executable.gypi',
'modules/qt.gypi',
],
'include_dirs': [

View file

@ -6,9 +6,9 @@
{
'includes': [
'settings_win.gypi',
'settings_mac.gypi',
'settings_linux.gypi',
'win.gypi',
'mac.gypi',
'linux.gypi',
],
'variables': {
'variables': {
@ -48,6 +48,7 @@
'official_build_target%': '',
'build_standard_win%': 'c++17',
'libs_loc%': '<(DEPTH)/../../../Libraries',
},
'build_os%': '<(build_os)',
'build_win%': '<(build_win)',
@ -55,6 +56,7 @@
'build_linux%': '<(build_linux)',
'official_build_target%': '<(official_build_target)',
'build_standard_win%': '<(build_standard_win)',
'libs_loc%': '<(libs_loc)',
# GYP does not support per-configuration libraries :(
# So they will be emulated through additional link flags,

View file

@ -0,0 +1,12 @@
# This file is part of Telegram Desktop,
# the official desktop application for the Telegram messaging service.
#
# For license and copyright information please follow this link:
# https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
{
'type': 'static_library',
'includes': [
'common.gypi',
],
}

View file

@ -26,7 +26,30 @@
'-Wno-error=class-memaccess',
'-Wno-error=parentheses',
],
'linux_path_ffmpeg%': '/usr/local',
'linux_path_openal%': '/usr/local',
'linux_path_va%': '/usr/local',
'linux_path_vdpau%': '/usr/local',
'linux_path_breakpad%': '/usr/local',
'linux_path_opus_include%': '<(libs_loc)/opus/include',
'linux_path_range%': '/usr/local',
},
'include_dirs': [
'/usr/local/include',
'<(linux_path_ffmpeg)/include',
'<(linux_path_openal)/include',
'<(linux_path_breakpad)/include/breakpad',
'<(linux_path_opus_include)',
'<(linux_path_range)/include',
],
'library_dirs': [
'/usr/local/lib',
'<(linux_path_ffmpeg)/lib',
'<(linux_path_openal)/lib',
'<(linux_path_va)/lib',
'<(linux_path_vdpau)/lib',
'<(linux_path_breakpad)/lib',
],
'conditions': [
[ '"<!(uname -m)" == "x86_64" or "<!(uname -m)" == "aarch64"', {
'defines': [

View file

@ -6,16 +6,15 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'crl',
'type': 'static_library',
'dependencies': [
],
'includes': [
'common.gypi',
'qt.gypi',
'common/library.gypi',
'modules/qt.gypi',
],
'defines': [
],
@ -33,7 +32,6 @@
},
'include_dirs': [
'../ThirdParty/crl/src',
'../SourceFiles',
],
'sources': [
'<(crl_src_loc)/common/crl_common_config.h',

View file

@ -6,22 +6,19 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_base',
'type': 'static_library',
'includes': [
'common.gypi',
'openssl.gypi',
'qt.gypi',
'telegram_linux.gypi',
'pch.gypi',
'common/library.gypi',
'modules/openssl.gypi',
'modules/qt.gypi',
'modules/pch.gypi',
],
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'libs_loc': '../../../Libraries',
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
'pch_source': '<(src_loc)/base/base_pch.cpp',

View file

@ -6,21 +6,19 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_export',
'type': 'static_library',
'includes': [
'common.gypi',
'qt.gypi',
'telegram_linux.gypi',
'pch.gypi',
'common/library.gypi',
'modules/qt.gypi',
'modules/pch.gypi',
],
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'libs_loc': '../../../Libraries',
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
'pch_source': '<(src_loc)/export/export_pch.cpp',

View file

@ -6,20 +6,17 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_ffmpeg',
'type': 'static_library',
'includes': [
'common.gypi',
'qt.gypi',
'telegram_linux.gypi',
'common/library.gypi',
'modules/qt.gypi',
],
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'libs_loc': '../../../Libraries',
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
},

View file

@ -6,21 +6,18 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_lottie',
'type': 'static_library',
'includes': [
'common.gypi',
'openssl.gypi',
'qt.gypi',
'telegram_linux.gypi',
'common/library.gypi',
'modules/openssl.gypi',
'modules/qt.gypi',
],
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'libs_loc': '../../../Libraries',
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
'rlottie_loc': '<(submodules_loc)/rlottie/inc',

View file

@ -6,19 +6,16 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_lz4',
'type': 'static_library',
'includes': [
'common.gypi',
'telegram_linux.gypi',
'common/library.gypi',
],
'variables': {
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
'libs_loc': '../../../Libraries',
'lz4_loc': '<(submodules_loc)/lz4/lib',
},
'defines': [

View file

@ -6,22 +6,19 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_mtproto',
'type': 'static_library',
'includes': [
'common.gypi',
'qt.gypi',
'telegram_linux.gypi',
'pch.gypi',
'openssl.gypi',
'common/library.gypi',
'modules/qt.gypi',
'modules/pch.gypi',
'modules/openssl.gypi',
],
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'libs_loc': '../../../Libraries',
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
'pch_source': '<(src_loc)/mtproto/mtp_pch.cpp',

View file

@ -6,23 +6,20 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'variables': {
'build_standard_win': 'c++14',
},
'targets': [{
'target_name': 'lib_rlottie',
'type': 'static_library',
'includes': [
'common.gypi',
'telegram_linux.gypi',
'common/library.gypi',
],
'variables': {
'official_build_target%': '',
'build_standard_win': 'c++14',
'submodules_loc': '../ThirdParty',
'libs_loc': '../../../Libraries',
'rlottie_loc': '<(submodules_loc)/rlottie',
'rlottie_src': '<(rlottie_loc)/src',
},

View file

@ -6,15 +6,14 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_scheme',
'type': 'static_library',
'hard_dependency': 1,
'includes': [
'common.gypi',
'qt.gypi',
'common/library.gypi',
'modules/qt.gypi',
],
'variables': {
'src_loc': '../SourceFiles',

View file

@ -6,22 +6,19 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_storage',
'type': 'static_library',
'includes': [
'common.gypi',
'openssl.gypi',
'qt.gypi',
'telegram_linux.gypi',
'pch.gypi',
'common/library.gypi',
'modules/openssl.gypi',
'modules/qt.gypi',
'modules/pch.gypi',
],
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'libs_loc': '../../../Libraries',
'official_build_target%': '',
'submodules_loc': '../ThirdParty',
'pch_source': '<(src_loc)/storage/storage_pch.cpp',

View file

@ -6,20 +6,19 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'lib_ui',
'type': 'static_library',
'hard_dependency': 1,
'includes': [
'common.gypi',
'qt.gypi',
'qt_moc.gypi',
'codegen_styles_rule.gypi',
'codegen_rules_ui.gypi',
'pch.gypi',
'openssl.gypi',
'common/library.gypi',
'modules/qt.gypi',
'modules/qt_moc.gypi',
'modules/pch.gypi',
'modules/openssl.gypi',
'codegen/styles_rule.gypi',
'codegen/rules_ui.gypi',
],
'dependencies': [
'codegen.gyp:codegen_emoji',
@ -27,10 +26,6 @@
'crl.gyp:crl',
],
'variables': {
'variables': {
'libs_loc': '../../../Libraries',
},
'libs_loc': '<(libs_loc)',
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'official_build_target%': '',
@ -44,7 +39,7 @@
'dependent_style_files': [
],
'style_timestamp': '<(SHARED_INTERMEDIATE_DIR)/update_dependent_styles_ui.timestamp',
'list_sources_command': 'python <(DEPTH)/list_sources.py --input <(DEPTH)/lib_ui_sources.txt --replace src_loc=<(src_loc)',
'list_sources_command': 'python <(DEPTH)/list_sources.py --input <(DEPTH)/lib_ui/sources.txt --replace src_loc=<(src_loc)',
'pch_source': '<(src_loc)/ui/ui_pch.cpp',
'pch_header': '<(src_loc)/ui/ui_pch.h',
},
@ -62,7 +57,7 @@
'sources': [
'<@(style_files)',
'<!@(<(list_sources_command) <(qt_moc_list_sources_arg))',
'lib_ui_sources.txt',
'<(DEPTH)/lib_ui/sources.txt',
],
'sources!': [
'<!@(<(list_sources_command) <(qt_moc_list_sources_arg) --exclude_for <(build_os))',

View file

@ -6,7 +6,7 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'linux_glibc_wraps',

View file

@ -18,51 +18,28 @@
# QApplication() -> createPlatformIntegration -> QXcbIntegrationPlugin::create
#'xkbcommon',
],
'linux_path_ffmpeg%': '/usr/local',
'linux_path_openal%': '/usr/local',
'linux_path_va%': '/usr/local',
'linux_path_vdpau%': '/usr/local',
'linux_path_breakpad%': '/usr/local',
'linux_path_opus_include%': '<(libs_loc)/opus/include',
'linux_path_range%': '/usr/local',
},
'include_dirs': [
'/usr/local/include',
'<(linux_path_ffmpeg)/include',
'<(linux_path_openal)/include',
'<(linux_path_breakpad)/include/breakpad',
'<(linux_path_opus_include)',
'<(linux_path_range)/include',
],
'library_dirs': [
'/usr/local/lib',
'<(linux_path_ffmpeg)/lib',
'<(linux_path_openal)/lib',
'<(linux_path_va)/lib',
'<(linux_path_vdpau)/lib',
'<(linux_path_breakpad)/lib',
],
'libraries': [
'breakpad_client',
'composeplatforminputcontextplugin',
'ibusplatforminputcontextplugin',
'fcitxplatforminputcontextplugin',
'himeplatforminputcontextplugin',
'nimfplatforminputcontextplugin',
'liblzma.a',
'libopenal.a',
'libavformat.a',
'libavcodec.a',
'libswresample.a',
'libswscale.a',
'libavutil.a',
'libopus.a',
'libva-x11.a',
'libva-drm.a',
'libva.a',
'libvdpau.a',
'libdrm.a',
'libz.a',
'-lbreakpad_client',
'-lcomposeplatforminputcontextplugin',
'-libusplatforminputcontextplugin',
'-lfcitxplatforminputcontextplugin',
'-lhimeplatforminputcontextplugin',
'-lnimfplatforminputcontextplugin',
'-llzma',
'-lopenal',
'-lavformat',
'-lavcodec',
'-lswresample',
'-lswscale',
'-lavutil',
'-lopus',
'-lva-x11',
'-lva-drm',
'-lva',
'-lvdpau',
'-ldrm',
'-lz',
# '<!(pkg-config 2> /dev/null --libs <@(pkgconfig_libs))',
],
'cflags_cc': [
@ -74,6 +51,7 @@
'-Wl,-wrap,secure_getenv',
'-Wl,-wrap,clock_gettime',
'-Wl,--no-as-needed,-lrt',
'-Wl,-Bstatic',
],
'configurations': {
'Release': {

View file

@ -7,36 +7,36 @@
{
'variables': {
'qrc_files': [
'<(res_loc)/qrc/telegram.qrc',
'<(res_loc)/qrc/telegram_fonts.qrc',
'<(res_loc)/qrc/telegram_emoji_1.qrc',
'<(res_loc)/qrc/telegram_emoji_2.qrc',
'<(res_loc)/qrc/telegram_emoji_3.qrc',
'<(res_loc)/qrc/telegram_emoji_4.qrc',
'<(res_loc)/qrc/telegram_emoji_5.qrc',
'<(res_loc)/qrc/telegram_emoji_preview.qrc',
'<(res_loc)/qrc/telegram_sounds.qrc',
'<(res_loc)/qrc/fonts.qrc',
'<(res_loc)/qrc/emoji_1.qrc',
'<(res_loc)/qrc/emoji_2.qrc',
'<(res_loc)/qrc/emoji_3.qrc',
'<(res_loc)/qrc/emoji_4.qrc',
'<(res_loc)/qrc/emoji_5.qrc',
'<(res_loc)/qrc/emoji_preview.qrc',
'<(res_loc)/qrc/telegram/telegram.qrc',
'<(res_loc)/qrc/telegram/sounds.qrc',
],
},
'conditions': [
[ 'build_linux', {
'variables': {
'qrc_files': [
'<(res_loc)/qrc/telegram_linux.qrc',
'<(res_loc)/qrc/linux.qrc',
],
}
}],
[ 'build_mac', {
'variables': {
'qrc_files': [
'<(res_loc)/qrc/telegram_mac.qrc',
'<(res_loc)/qrc/mac.qrc',
],
},
}],
[ 'build_win', {
'variables': {
'qrc_files': [
'<(res_loc)/qrc/telegram_wnd.qrc',
'<(res_loc)/qrc/wnd.qrc',
],
}
}],

View file

@ -0,0 +1,161 @@
# This file is part of Telegram Desktop,
# the official desktop application for the Telegram messaging service.
#
# For license and copyright information please follow this link:
# https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
{
'targets': [{
'target_name': 'Telegram',
'variables': {
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
'submodules_loc': '../ThirdParty',
'minizip_loc': '<(submodules_loc)/minizip',
'sp_media_key_tap_loc': '<(submodules_loc)/SPMediaKeyTap',
'emoji_suggestions_loc': '<(submodules_loc)/emoji_suggestions',
'style_files': [
'<(src_loc)/boxes/boxes.style',
'<(src_loc)/calls/calls.style',
'<(src_loc)/dialogs/dialogs.style',
'<(src_loc)/export/view/export.style',
'<(src_loc)/history/history.style',
'<(src_loc)/info/info.style',
'<(src_loc)/intro/intro.style',
'<(src_loc)/media/view/mediaview.style',
'<(src_loc)/media/player/media_player.style',
'<(src_loc)/overview/overview.style',
'<(src_loc)/passport/passport.style',
'<(src_loc)/profile/profile.style',
'<(src_loc)/settings/settings.style',
'<(src_loc)/chat_helpers/chat_helpers.style',
'<(src_loc)/window/window.style',
],
'dependent_style_files': [
'<(res_loc)/colors.palette',
'<(res_loc)/basic.style',
'<(src_loc)/ui/widgets/widgets.style',
],
'style_timestamp': '<(SHARED_INTERMEDIATE_DIR)/update_dependent_styles.timestamp',
'langpacks': [
'en',
'de',
'es',
'it',
'nl',
'ko',
'pt-BR',
],
'build_defines%': '',
'list_sources_command': 'python <(DEPTH)/list_sources.py --input <(DEPTH)/telegram/sources.txt --replace src_loc=<(src_loc)',
'pch_source': '<(src_loc)/stdafx.cpp',
'pch_header': '<(src_loc)/stdafx.h',
},
'includes': [
'../common/executable.gypi',
'qrc.gypi',
'win.gypi',
'mac.gypi',
'linux.gypi',
'../modules/openssl.gypi',
'../modules/qt.gypi',
'../modules/qt_moc.gypi',
'../modules/qt_rcc.gypi',
'../modules/pch.gypi',
'../codegen/styles_rule.gypi',
'../codegen/rules.gypi',
],
'dependencies': [
'codegen.gyp:codegen_emoji',
'codegen.gyp:codegen_lang',
'codegen.gyp:codegen_numbers',
'codegen.gyp:codegen_style',
'tests/tests.gyp:tests',
'utils.gyp:Updater',
'../ThirdParty/libtgvoip/libtgvoip.gyp:libtgvoip',
'crl.gyp:crl',
'lib_base.gyp:lib_base',
'lib_export.gyp:lib_export',
'lib_storage.gyp:lib_storage',
'lib_lottie.gyp:lib_lottie',
'lib_ffmpeg.gyp:lib_ffmpeg',
'lib_mtproto.gyp:lib_mtproto',
'lib_ui.gyp:lib_ui',
],
'defines': [
'AL_LIBTYPE_STATIC',
'AL_ALEXT_PROTOTYPES',
'TGVOIP_USE_CXX11_LIB',
'XXH_INLINE_ALL',
'TDESKTOP_API_ID=<(api_id)',
'TDESKTOP_API_HASH=<(api_hash)',
'<!@(python -c "for s in \'<(build_defines)\'.split(\',\'): print(s)")',
],
'include_dirs': [
'<(src_loc)',
'<(SHARED_INTERMEDIATE_DIR)',
'<(libs_loc)/breakpad/src',
'<(libs_loc)/lzma/C',
'<(libs_loc)/zlib',
'<(libs_loc)/ffmpeg',
'<(libs_loc)/openal-soft/include',
'<(libs_loc)/opus/include',
'<(libs_loc)/range-v3/include',
'<(minizip_loc)',
'<(sp_media_key_tap_loc)',
'<(emoji_suggestions_loc)',
'<(submodules_loc)/GSL/include',
'<(submodules_loc)/variant/include',
'<(submodules_loc)/crl/src',
'<(submodules_loc)/xxHash',
],
'sources': [
'<@(qrc_files)',
'<@(style_files)',
'<(res_loc)/langs/cloud_lang.strings',
'<(res_loc)/export_html/css/style.css',
'<(res_loc)/export_html/js/script.js',
'<(res_loc)/export_html/images/back.png',
'<(res_loc)/export_html/images/back@2x.png',
'<(DEPTH)/telegram/sources.txt',
'<!@(<(list_sources_command) <(qt_moc_list_sources_arg))',
],
'sources!': [
'<!@(<(list_sources_command) <(qt_moc_list_sources_arg) --exclude_for <(build_os))',
],
'conditions': [
[ '"<(official_build_target)" != ""', {
'defines': [
'TDESKTOP_OFFICIAL_TARGET=<(official_build_target)',
'TDESKTOP_FORCE_GTK_FILE_DIALOG',
],
'dependencies': [
'utils.gyp:Packer',
],
}], [ 'build_mac', {
'mac_hardened_runtime': 1,
'mac_bundle': '1',
'mac_bundle_resources': [
'<!@(python -c "for s in \'<@(langpacks)\'.split(\' \'): print(\'<(res_loc)/langs/\' + s + \'.lproj/Localizable.strings\')")',
'../Telegram/Images.xcassets',
],
'xcode_settings': {
'ENABLE_HARDENED_RUNTIME': 'YES',
},
'sources': [
'../Telegram/Telegram.entitlements',
],
}], [ 'build_macstore', {
'mac_sandbox': 1,
'mac_sandbox_development_team': '6N38VWS5BX',
'product_name': 'Telegram Desktop',
'sources': [
'../Telegram/Telegram Desktop.entitlements',
],
}],
],
}],
}

View file

@ -16,9 +16,6 @@
'-lDbgHelp',
'-lOpenAL32',
'-lopus',
'windows/common',
'windows/handler/exception_handler',
'windows/crash_generation/crash_generation_client',
],
'msvs_settings': {
'VCLinkerTool': {
@ -28,6 +25,9 @@
'libavutil/libavutil.a',
'libswresample/libswresample.a',
'libswscale/libswscale.a',
'windows/common.lib',
'windows/handler/exception_handler.lib',
'windows/crash_generation/crash_generation_client.lib',
],
},
'VCManifestTool': {

View file

@ -6,8 +6,8 @@
{
'includes': [
'../common_executable.gypi',
'../qt.gypi',
'../common/executable.gypi',
'../modules/qt.gypi',
],
'include_dirs': [
'<(src_loc)',

View file

@ -6,10 +6,9 @@
{
'includes': [
'../common.gypi',
'../common/common.gypi',
],
'variables': {
'libs_loc': '../../../../Libraries',
'src_loc': '../../SourceFiles',
'submodules_loc': '../../ThirdParty',
'mac_target': '10.10',
@ -19,7 +18,7 @@
'target_name': 'tests',
'type': 'none',
'includes': [
'../common.gypi',
'../common/common.gypi',
],
'dependencies': [
'<!@(<(list_tests_command))',
@ -122,7 +121,7 @@
'target_name': 'tests_storage',
'includes': [
'common_test.gypi',
'../openssl.gypi',
'../modules/openssl.gypi',
],
'dependencies': [
'../lib_storage.gyp:lib_storage',

View file

@ -6,17 +6,16 @@
{
'includes': [
'common.gypi',
'common/common.gypi',
],
'targets': [{
'target_name': 'Updater',
'variables': {
'libs_loc': '../../../Libraries',
'src_loc': '../SourceFiles',
'res_loc': '../Resources',
},
'includes': [
'common_executable.gypi',
'common/executable.gypi',
],
'include_dirs': [
@ -57,13 +56,12 @@
}, {
'target_name': 'Packer',
'variables': {
'libs_loc': '../../../Libraries',
'src_loc': '../SourceFiles',
'mac_target': '10.10',
},
'includes': [
'common_executable.gypi',
'qt.gypi',
'common/executable.gypi',
'modules/qt.gypi',
],
'conditions': [
[ 'build_win', {