diff --git a/.buckconfig b/.buckconfig index 5c472b0f9e..739cb939f6 100644 --- a/.buckconfig +++ b/.buckconfig @@ -40,8 +40,4 @@ config = debug optimization = -Onone config_swift_compiler_flags = -DDEBUG -enable-testing -g - code_coverage_cflags = -fprofile-instr-generate -fcoverage-mapping - code_coverage_cxxflags = -fprofile-instr-generate -fcoverage-mapping - code_coverage_ldflags = -fprofile-instr-generate - code_coverage_swift_compiler_flags = -profile-generate -profile-coverage-mapping \ No newline at end of file diff --git a/App/App.xcodeproj/project.pbxproj b/App/App.xcodeproj/project.pbxproj index d63822a561..5b40766415 100644 --- a/App/App.xcodeproj/project.pbxproj +++ b/App/App.xcodeproj/project.pbxproj @@ -250,6 +250,19 @@ B401C9792F7F325000000000 + 1DD70E29FC2E5C0800000000 + + isa + PBXFileReference + name + EmojiFramework.framework + path + EmojiFramework.framework + sourceTree + BUILT_PRODUCTS_DIR + explicitFileType + wrapper.framework + 1DD70E297ADFB9F200000000 isa @@ -263,32 +276,6 @@ explicitFileType archive.ar - 1DD70E29A59C927400000000 - - isa - PBXFileReference - name - libEmoji.a - path - libEmoji.a - sourceTree - BUILT_PRODUCTS_DIR - explicitFileType - archive.ar - - 1DD70E29C4DF1A6D00000000 - - isa - PBXFileReference - name - libMtProtoKit.a - path - libMtProtoKit.a - sourceTree - BUILT_PRODUCTS_DIR - explicitFileType - archive.ar - B401C97968022A5500000000 isa @@ -299,9 +286,8 @@ ]]> children + 1DD70E29FC2E5C0800000000 1DD70E297ADFB9F200000000 - 1DD70E29A59C927400000000 - 1DD70E29C4DF1A6D00000000 1DD70E2933D47CB400000000 @@ -377,6 +363,13 @@ E7A30F046ABF6A1200000000 + E7A30F04FC2E5C0800000000 + + isa + PBXBuildFile + fileRef + 1DD70E29FC2E5C0800000000 + E7A30F047ADFB9F200000000 isa @@ -384,31 +377,44 @@ fileRef 1DD70E297ADFB9F200000000 - E7A30F04A59C927400000000 - - isa - PBXBuildFile - fileRef - 1DD70E29A59C927400000000 - - E7A30F04C4DF1A6D00000000 - - isa - PBXBuildFile - fileRef - 1DD70E29C4DF1A6D00000000 - 4F426D880000000000000000 isa PBXFrameworksBuildPhase files + E7A30F04FC2E5C0800000000 E7A30F047ADFB9F200000000 - E7A30F04A59C927400000000 - E7A30F04C4DF1A6D00000000 + E7A30F04FC2E5C0800000001 + + isa + PBXBuildFile + fileRef + 1DD70E29FC2E5C0800000000 + settings + + ATTRIBUTES + + CodeSignOnCopy + RemoveHeadersOnCopy + + + + FAF5FAC90000000000000000 + + isa + PBXCopyFilesBuildPhase + files + + E7A30F04FC2E5C0800000001 + + dstSubfolderSpec + 10 + dstPath + + 4952437303EDA63300000000 isa @@ -477,6 +483,7 @@ 1870857F0000000000000000 4F426D880000000000000000 + FAF5FAC90000000000000000 buildConfigurationList 218C37090000000000000000 @@ -505,27 +512,27 @@ E7A30F048FA05E8C00000000 - E7A30F04A59C927400000001 + E7A30F04FC2E5C0800000002 isa PBXBuildFile fileRef - 1DD70E29A59C927400000000 + 1DD70E29FC2E5C0800000000 - FAF5FAC90000000000000000 + FAF5FAC90000000000000001 isa PBXCopyFilesBuildPhase files - E7A30F04A59C927400000001 + E7A30F04FC2E5C0800000002 name Fake Swift Dependencies (Copy Files Phase) runOnlyForDeploymentPostprocessing - 1 + 1 dstSubfolderSpec - 16 + 16 dstPath @@ -596,7 +603,7 @@ buildPhases 1870857F0000000000000001 - FAF5FAC90000000000000000 + FAF5FAC90000000000000001 buildConfigurationList 218C37090000000000000001 diff --git a/App/App.xcworkspace/buck-project.meta.json b/App/App.xcworkspace/buck-project.meta.json index d321a6041c..cd9335add6 100644 --- a/App/App.xcworkspace/buck-project.meta.json +++ b/App/App.xcworkspace/buck-project.meta.json @@ -1 +1 @@ -{"required-targets":["//submodules/MtProtoKit:openssl_libs"],"xcconfig-paths":["buck-out/gen/App/App-Debug.xcconfig","buck-out/gen/App/App-Profile.xcconfig","buck-out/gen/App/App-Release.xcconfig","buck-out/gen/App/AppLibrary-Debug.xcconfig","buck-out/gen/App/AppLibrary-Profile.xcconfig","buck-out/gen/App/AppLibrary-Release.xcconfig","buck-out/gen/submodules/Emoji/Emoji-Debug.xcconfig","buck-out/gen/submodules/Emoji/Emoji-Profile.xcconfig","buck-out/gen/submodules/Emoji/Emoji-Release.xcconfig","buck-out/gen/submodules/MtProtoKit/MtProtoKit-Debug.xcconfig","buck-out/gen/submodules/MtProtoKit/MtProtoKit-Profile.xcconfig","buck-out/gen/submodules/MtProtoKit/MtProtoKit-Release.xcconfig","buck-out/gen/submodules/MtProtoKit/openssl-Debug.xcconfig","buck-out/gen/submodules/MtProtoKit/openssl-Profile.xcconfig","buck-out/gen/submodules/MtProtoKit/openssl-Release.xcconfig"],"copy-in-xcode":[]} \ No newline at end of file +{"required-targets":[],"xcconfig-paths":["buck-out/gen/App/App-Debug.xcconfig","buck-out/gen/App/App-Profile.xcconfig","buck-out/gen/App/App-Release.xcconfig","buck-out/gen/App/AppLibrary-Debug.xcconfig","buck-out/gen/App/AppLibrary-Profile.xcconfig","buck-out/gen/App/AppLibrary-Release.xcconfig","buck-out/gen/submodules/Emoji/EmojiFramework#iphonesimulator-x86_64-Debug.xcconfig","buck-out/gen/submodules/Emoji/EmojiFramework#iphonesimulator-x86_64-Profile.xcconfig","buck-out/gen/submodules/Emoji/EmojiFramework#iphonesimulator-x86_64-Release.xcconfig"],"copy-in-xcode":[]} \ No newline at end of file diff --git a/App/App.xcworkspace/contents.xcworkspacedata b/App/App.xcworkspace/contents.xcworkspacedata index 9d9843e511..f43dd2832e 100644 --- a/App/App.xcworkspace/contents.xcworkspacedata +++ b/App/App.xcworkspace/contents.xcworkspacedata @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/App/App.xcworkspace/xcshareddata/xcschemes/App.xcscheme b/App/App.xcworkspace/xcshareddata/xcschemes/App.xcscheme index ca1f27f58a..ca41432aa1 100644 --- a/App/App.xcworkspace/xcshareddata/xcschemes/App.xcscheme +++ b/App/App.xcworkspace/xcshareddata/xcschemes/App.xcscheme @@ -1 +1,110 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/App/BUCK b/App/BUCK index a1929143a4..4e2bdf24a4 100644 --- a/App/BUCK +++ b/App/BUCK @@ -1,4 +1,4 @@ -load("//Config:configs.bzl", "app_binary_configs", "library_configs", "pretty", "info_plist_substitutions", "bundle_identifier", "DEVELOPMENT_LANGUAGE") +load("//Config:configs.bzl", "app_binary_configs", "library_configs", "pretty", "info_plist_substitutions", "app_info_plist_substitutions", "DEVELOPMENT_LANGUAGE") load("//Config:buck_rule_macros.bzl", "apple_lib", "framework_binary_dependencies", "framework_bundle_dependencies") '''apple_asset_catalog( @@ -20,7 +20,7 @@ ui_tests = [ static_library_dependencies = [ ] framework_dependencies = [ - '//submodules/MtProtoKit:MtProtoKit', + #'//submodules/MtProtoKit:MtProtoKit', '//submodules/Emoji:Emoji', ] @@ -60,7 +60,7 @@ apple_binary( ], deps = [ ":AppLibrary", - ], + ] ) xcode_workspace_config( @@ -78,7 +78,7 @@ apple_bundle( binary = ":AppBinary", product_name = "App", info_plist = "Info.plist", - info_plist_substitutions = info_plist_substitutions("App"), + info_plist_substitutions = app_info_plist_substitutions("App"), deps = [ ] + framework_bundle_dependencies(framework_dependencies), diff --git a/App/Sources/Temp.swift b/App/Sources/Temp.swift index 8d02a25460..dd25694e8a 100644 --- a/App/Sources/Temp.swift +++ b/App/Sources/Temp.swift @@ -1,8 +1,8 @@ import Foundation import Emoji -@objc(AppDelegate) -public final class AppDelegate: NSObject { +@objc(AppDelegate1) +public final class AppDelegate1: NSObject { override init() { super.init() diff --git a/App/Sources/TempMain.m b/App/Sources/TempMain.m index 1a5dcd2485..ef24fc1604 100644 --- a/App/Sources/TempMain.m +++ b/App/Sources/TempMain.m @@ -1,6 +1,29 @@ +#import +#import //#import +@interface AppDelegate : NSObject + +@property (nonatomic, strong) UIWindow *window; + +@end + +@implementation AppDelegate + +- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + _window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] applicationFrame]]; + _window.rootViewController = [[UIViewController alloc] init]; + _window.rootViewController.view.backgroundColor = [UIColor blueColor]; + [_window makeKeyAndVisible]; + return true; +} + +@end + int main(int argc, const char **argv) { //MTProto *mtProto = [[MTProto alloc] init]; - return 0; + @autoreleasepool { + return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); + } } + diff --git a/Config/buck_rule_macros.bzl b/Config/buck_rule_macros.bzl index 9567d6f76d..92b4be682f 100644 --- a/Config/buck_rule_macros.bzl +++ b/Config/buck_rule_macros.bzl @@ -56,16 +56,16 @@ def apple_lib( swift_compiler_flags = swift_compiler_flags, preferred_linkage = "shared", link_style = "static", - linker_flags = ["-Wl,-install_name,@rpath/lib%s.dylib" % (name)], + linker_flags = ["-Wl,-install_name,@rpath/%sFramework.framework/%sFramework" % (name, name)], ) - '''native.apple_bundle( + native.apple_bundle( name = name + "Framework", visibility = visibility, binary = ":" + name + "#shared", extension = "framework", info_plist = "Info.plist", info_plist_substitutions = info_plist_substitutions(name), - )''' + ) else: native.apple_library( name = name, @@ -82,9 +82,9 @@ def apple_lib( modular = modular, compiler_flags = compiler_flags, swift_compiler_flags = swift_compiler_flags, - #preferred_linkage = "shared", - #link_style = "static", - #linker_flags = ["-Wl,-install_name,@rpath/%sFramework.framework/%sFramework" % (name, name)], + preferred_linkage = "shared", + link_style = "static", + linker_flags = ["-Wl,-install_name,@rpath/%sFramework.framework/%sFramework" % (name, name)], ) native.apple_bundle( name = name + "Framework", @@ -213,20 +213,20 @@ def framework_binary_dependencies(names): result = [] if native.read_config("custom", "mode") == "project": for name in names: - result.append(name + "#shared") + result.append(name + "Framework") else: for name in names: - result.append(name + "") + result.append(name + "#shared") return result def framework_bundle_dependencies(names): result = [] if native.read_config("custom", "mode") == "project": for name in names: - #result.append(name + "Framework") + result.append(name + "Framework") pass else: for name in names: - #result.append(name + "Framework") + result.append(name + "Framework") pass return result diff --git a/Config/configs.bzl b/Config/configs.bzl index db751cd97c..f735c1cda4 100644 --- a/Config/configs.bzl +++ b/Config/configs.bzl @@ -41,7 +41,7 @@ def optimization_config(): ALL_LOAD_LINKER_FLAG = "-all_load" def bundle_identifier(name): - return "org.Telegram.%s" % name + return "org.telegram.%s" % name def library_configs(): lib_specific_config = { @@ -86,7 +86,10 @@ def app_binary_configs(name): binary_specific_config = { "ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES": "YES", "DEVELOPMENT_LANGUAGE": DEVELOPMENT_LANGUAGE, - "PRODUCT_BUNDLE_IDENTIFIER": bundle_identifier(name), + "PRODUCT_BUNDLE_IDENTIFIER": "org.telegram.Telegram-iOS", + "CODE_SIGN_IDENTITY": "iPhone Developer: Peter Iakovlev (9J4EJ3F97G)", + "DEVELOPMENT_TEAM": "X834Q8SBVP", + "PROVISIONING_PROFILE_SPECIFIER": "match Development org.telegram.Telegram-iOS", } binary_config = merge_dict(SHARED_CONFIGS, binary_specific_config) binary_config = merge_dict(binary_config, optimization_config()) @@ -102,3 +105,14 @@ def info_plist_substitutions(name): "CURRENT_PROJECT_VERSION": "1", } return substitutions + +def app_info_plist_substitutions(name): + substitutions = { + "DEVELOPMENT_LANGUAGE": DEVELOPMENT_LANGUAGE, + "EXECUTABLE_NAME": name, + "PRODUCT_BUNDLE_IDENTIFIER": "org.telegram.Telegram-iOS", + "PRODUCT_NAME": name, + "CURRENT_PROJECT_VERSION": "1", + "CODE_SIGN_IDENTITY": "iPhone Developer: Peter Iakovlev (9J4EJ3F97G)", + } + return substitutions diff --git a/Makefile b/Makefile index b7bb196560..b9e62ca30f 100644 --- a/Makefile +++ b/Makefile @@ -1,8 +1,6 @@ - .PHONY : install_buck build targets audit project clean -# Use local version of Buck -BUCK=tools/buck +BUCK=/Users/peter/build/buck/buck-out/gen/programs/buck.pex log: echo "Make" @@ -11,6 +9,9 @@ install_buck: curl https://jitpack.io/com/github/airbnb/buck/457ebb73fcd8f86be0112dc74948d022b6969dbd/buck-457ebb73fcd8f86be0112dc74948d022b6969dbd.pex --output tools/buck chmod u+x tools/buck +build_buck: + sh build_buck.sh + build: $(BUCK) build //App:AppPackage diff --git a/Watch/BUCK b/Watch/BUCK deleted file mode 100644 index 57366e6538..0000000000 --- a/Watch/BUCK +++ /dev/null @@ -1,76 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'WatchUtils', - srcs = [ - 'Bridge/TGBridgeCommon.m', - 'Bridge/TGBridgeContactMediaAttachment.m', - 'Bridge/TGBridgeVideoMediaAttachment.m', - 'Bridge/TGBridgeSubscriptions.m', - 'Bridge/TGBridgeLocationVenue.m', - 'Bridge/TGBridgeImageMediaAttachment.m', - 'Bridge/TGBridgeBotInfo.m', - 'Bridge/TGBridgeChatMessages.m', - 'Bridge/TGBridgeMessage.m', - 'Bridge/TGBridgeUnsupportedMediaAttachment.m', - 'Bridge/TGBridgeChat.m', - 'Bridge/TGBridgeForwardedMessageMediaAttachment.m', - 'Bridge/TGBridgeMessageEntities.m', - 'Bridge/TGBridgeLocationMediaAttachment.m', - 'Bridge/TGBridgeMessageEntitiesAttachment.m', - 'Bridge/TGBridgeReplyMarkupMediaAttachment.m', - 'Bridge/TGBridgeWebPageMediaAttachment.m', - 'Bridge/TGBridgeDocumentMediaAttachment.m', - 'Bridge/TGBridgeActionMediaAttachment.m', - 'Bridge/TGBridgeContext.m', - 'Bridge/TGBridgeMediaAttachment.m', - 'Bridge/TGBridgeUser.m', - 'Bridge/TGBridgeBotCommandInfo.m', - 'Bridge/TGBridgeAudioMediaAttachment.m', - 'Bridge/TGBridgeReplyMessageMediaAttachment.m', - ], - headers = glob([ - 'Bridge/*.h', - 'Extension/*.h', - ]), - header_namespace = 'WatchUtils', - exported_headers = [ - 'Bridge/TGBridgeCommon.h', - 'Bridge/TGBridgeContactMediaAttachment.h', - 'Bridge/TGBridgeVideoMediaAttachment.h', - 'Bridge/TGBridgeSubscriptions.h', - 'Bridge/TGBridgeLocationVenue.h', - 'Bridge/TGBridgeImageMediaAttachment.h', - 'Bridge/TGBridgeBotInfo.h', - 'Bridge/TGBridgeChatMessages.h', - 'Bridge/TGBridgeMessage.h', - 'Bridge/TGBridgeUnsupportedMediaAttachment.h', - 'Bridge/TGBridgeChat.h', - 'Bridge/TGBridgeForwardedMessageMediaAttachment.h', - 'Bridge/TGBridgeMessageEntities.h', - 'Bridge/TGBridgeLocationMediaAttachment.h', - 'Bridge/TGBridgeMessageEntitiesAttachment.h', - 'Bridge/TGBridgeReplyMarkupMediaAttachment.h', - 'Bridge/TGBridgeWebPageMediaAttachment.h', - 'Bridge/TGBridgeDocumentMediaAttachment.h', - 'Bridge/TGBridgeActionMediaAttachment.h', - 'Bridge/TGBridgeContext.h', - 'Bridge/TGBridgeMediaAttachment.h', - 'Bridge/TGBridgeUser.h', - 'Bridge/TGBridgeBotCommandInfo.h', - 'Bridge/TGBridgeAudioMediaAttachment.h', - 'Bridge/TGBridgeReplyMessageMediaAttachment.h', - ], - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - compiler_flags = [ - '-w', - ], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - ], -) diff --git a/build_buck.sh b/build_buck.sh new file mode 100644 index 0000000000..f055eb0fbb --- /dev/null +++ b/build_buck.sh @@ -0,0 +1,4 @@ +DIR="$(pwd)" +cd "$HOME/build/buck" +buck-out/gen/programs/buck.pex build buck +cd "$DIR" diff --git a/submodules/AsyncDisplayKit/BUCK b/submodules/AsyncDisplayKit/BUCK deleted file mode 100755 index 2f5686da4b..0000000000 --- a/submodules/AsyncDisplayKit/BUCK +++ /dev/null @@ -1,64 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'combined_config', 'configs_with_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -COMMON_PREPROCESSOR_FLAGS = [ - '-fobjc-arc', - '-DMINIMAL_ASDK', - '-fno-exceptions', - '-fno-objc-arc-exceptions' -] - -COMMON_LANG_PREPROCESSOR_FLAGS = { - 'C': ['-std=gnu99'], - 'CXX': ['-std=c++11', '-stdlib=libc++'], - 'OBJCXX': ['-std=c++11', '-stdlib=libc++'], -} - -COMMON_LINKER_FLAGS = ['-ObjC++'] - -ASYNCDISPLAYKIT_EXPORTED_HEADERS = glob([ - 'Source/*.h', - 'Source/Details/**/*.h', - 'Source/Layout/*.h', - 'Source/Base/*.h', - 'Source/Debug/AsyncDisplayKit+Debug.h', - # Most TextKit components are not public because the C++ content - # in the headers will cause build errors when using - # `use_frameworks!` on 0.39.0 & Swift 2.1. - # See https://github.com/facebook/AsyncDisplayKit/issues/1153 - 'Source/TextKit/ASTextNodeTypes.h', - 'Source/TextKit/ASTextKitComponents.h' -]) - -ASYNCDISPLAYKIT_PRIVATE_HEADERS = glob([ - 'Source/**/*.h' - ], - exclude = ASYNCDISPLAYKIT_EXPORTED_HEADERS, -) - -apple_library( - name = "AsyncDisplayKit", - header_path_prefix = 'AsyncDisplayKit', - exported_headers = ASYNCDISPLAYKIT_EXPORTED_HEADERS, - headers = ASYNCDISPLAYKIT_PRIVATE_HEADERS, - srcs = glob([ - 'Source/**/*.m', - 'Source/**/*.mm', - 'Source/Base/*.m' - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - preprocessor_flags = COMMON_PREPROCESSOR_FLAGS, - lang_preprocessor_flags = COMMON_LANG_PREPROCESSOR_FLAGS, - linker_flags = COMMON_LINKER_FLAGS, - modular = True, - compiler_flags = ['-w'], - visibility = ["PUBLIC"], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - '$SDKROOT/System/Library/Frameworks/QuartzCore.framework', - '$SDKROOT/System/Library/Frameworks/CoreMedia.framework', - '$SDKROOT/System/Library/Frameworks/CoreText.framework', - '$SDKROOT/System/Library/Frameworks/CoreGraphics.framework', - ] -) diff --git a/submodules/Display/BUCK b/submodules/Display/BUCK deleted file mode 100644 index d073d26cc1..0000000000 --- a/submodules/Display/BUCK +++ /dev/null @@ -1,53 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'DisplayPrivate', - srcs = glob([ - 'Display/*.m', - ]), - headers = glob([ - 'Display/*.h', - ]), - header_namespace = 'DisplayPrivate', - exported_headers = glob([ - 'Display/*.h', - ], exclude = ['Display/Display.h']), - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - compiler_flags = ['-w'], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['//submodules/Display:Display'], - deps = [ - '//submodules/AsyncDisplayKit:AsyncDisplayKit', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - ], -) - -apple_library( - name = 'Display', - srcs = glob([ - 'Display/*.swift', - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - swift_compiler_flags = [ - '-suppress-warnings', - '-application-extension', - ], - visibility = ['PUBLIC'], - deps = [ - ':DisplayPrivate', - '//submodules/AsyncDisplayKit:AsyncDisplayKit', - '//submodules/SSignalKit:SwiftSignalKit', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - '$SDKROOT/System/Library/Frameworks/QuartzCore.framework', - '$SDKROOT/System/Library/Frameworks/CoreText.framework', - '$SDKROOT/System/Library/Frameworks/CoreGraphics.framework', - ], -) diff --git a/submodules/Emoji/BUCK b/submodules/Emoji/BUCK index 06e08005ea..75f05b54fa 100644 --- a/submodules/Emoji/BUCK +++ b/submodules/Emoji/BUCK @@ -10,5 +10,6 @@ framework( frameworks = [ "$SDKROOT/System/Library/Frameworks/Foundation.framework", "$SDKROOT/System/Library/Frameworks/CoreText.framework", + "$SDKROOT/System/Library/Frameworks/AVFoundation.framework", ], ) diff --git a/submodules/Emoji/Emoji.xcodeproj/project.pbxproj b/submodules/Emoji/Emoji.xcodeproj/project.pbxproj index b9c4156b4b..1da395e946 100644 --- a/submodules/Emoji/Emoji.xcodeproj/project.pbxproj +++ b/submodules/Emoji/Emoji.xcodeproj/project.pbxproj @@ -11,40 +11,40 @@ 46 objects - 1DD70E29CCF717CF00000000 + 1DD70E292187879500000000 isa PBXFileReference name - Emoji-Debug.xcconfig + EmojiFramework#iphonesimulator-x86_64-Debug.xcconfig path - ../../buck-out/gen/submodules/Emoji/Emoji-Debug.xcconfig + ../../buck-out/gen/submodules/Emoji/EmojiFramework#iphonesimulator-x86_64-Debug.xcconfig sourceTree SOURCE_ROOT explicitFileType text.xcconfig - 1DD70E2950B2F77900000000 + 1DD70E29C2E68DBF00000000 isa PBXFileReference name - Emoji-Profile.xcconfig + EmojiFramework#iphonesimulator-x86_64-Profile.xcconfig path - ../../buck-out/gen/submodules/Emoji/Emoji-Profile.xcconfig + ../../buck-out/gen/submodules/Emoji/EmojiFramework#iphonesimulator-x86_64-Profile.xcconfig sourceTree SOURCE_ROOT explicitFileType text.xcconfig - 1DD70E29C449A2DB00000000 + 1DD70E29367D392100000000 isa PBXFileReference name - Emoji-Release.xcconfig + EmojiFramework#iphonesimulator-x86_64-Release.xcconfig path - ../../buck-out/gen/submodules/Emoji/Emoji-Release.xcconfig + ../../buck-out/gen/submodules/Emoji/EmojiFramework#iphonesimulator-x86_64-Release.xcconfig sourceTree SOURCE_ROOT explicitFileType @@ -60,9 +60,9 @@ ]]> children - 1DD70E29CCF717CF00000000 - 1DD70E2950B2F77900000000 - 1DD70E29C449A2DB00000000 + 1DD70E292187879500000000 + 1DD70E29C2E68DBF00000000 + 1DD70E29367D392100000000 B401C979B781F65D00000000 @@ -102,6 +102,19 @@ sourceTree SOURCE_ROOT + 1DD70E2906C06BEE00000000 + + isa + PBXFileReference + name + Info.plist + path + Info.plist + sourceTree + ]]> + explicitFileType + text.plist + B401C979EAB5339800000000 isa @@ -113,14 +126,15 @@ children 1DD70E29C4C3D69000000000 + 1DD70E2906C06BEE00000000 - B401C97903FF902600000000 + B401C97920924D2000000000 isa PBXGroup name - Emoji + EmojiFramework#iphonesimulator-x86_64 sourceTree ]]> children @@ -129,18 +143,72 @@ B401C979EAB5339800000000 - 1DD70E29A59C927400000000 + 1DD70E291188565800000000 isa PBXFileReference name - libEmoji.a + AVFoundation.framework path - libEmoji.a + System/Library/Frameworks/AVFoundation.framework + sourceTree + SDKROOT + explicitFileType + wrapper.framework + + 1DD70E29A179AC1C00000000 + + isa + PBXFileReference + name + CoreText.framework + path + System/Library/Frameworks/CoreText.framework + sourceTree + SDKROOT + explicitFileType + wrapper.framework + + 1DD70E29AE317AA300000000 + + isa + PBXFileReference + name + Foundation.framework + path + System/Library/Frameworks/Foundation.framework + sourceTree + SDKROOT + explicitFileType + wrapper.framework + + B401C97968022A5500000000 + + isa + PBXGroup + name + Frameworks + sourceTree + ]]> + children + + 1DD70E291188565800000000 + 1DD70E29A179AC1C00000000 + 1DD70E29AE317AA300000000 + + + 1DD70E29FC2E5C0800000000 + + isa + PBXFileReference + name + EmojiFramework.framework + path + EmojiFramework.framework sourceTree BUILT_PRODUCTS_DIR explicitFileType - archive.ar + wrapper.framework B401C979C806358400000000 @@ -152,7 +220,7 @@ ]]> children - 1DD70E29A59C927400000000 + 1DD70E29FC2E5C0800000000 B401C979EFB6AC4600000000 @@ -166,7 +234,8 @@ children B401C979B781F65D00000000 - B401C97903FF902600000000 + B401C97920924D2000000000 + B401C97968022A5500000000 B401C979C806358400000000 @@ -186,6 +255,38 @@ E7A30F04C4C3D69000000000 + E7A30F041188565800000000 + + isa + PBXBuildFile + fileRef + 1DD70E291188565800000000 + + E7A30F04A179AC1C00000000 + + isa + PBXBuildFile + fileRef + 1DD70E29A179AC1C00000000 + + E7A30F04AE317AA300000000 + + isa + PBXBuildFile + fileRef + 1DD70E29AE317AA300000000 + + 4F426D880000000000000000 + + isa + PBXFrameworksBuildPhase + files + + E7A30F041188565800000000 + E7A30F04A179AC1C00000000 + E7A30F04AE317AA300000000 + + 4952437303EDA63300000000 isa @@ -196,7 +297,7 @@ baseConfigurationReference - 1DD70E29CCF717CF00000000 + 1DD70E292187879500000000 4952437350C7218900000000 @@ -208,7 +309,7 @@ baseConfigurationReference - 1DD70E2950B2F77900000000 + 1DD70E29C2E68DBF00000000 49524373A439BFE700000000 @@ -220,7 +321,7 @@ baseConfigurationReference - 1DD70E29C449A2DB00000000 + 1DD70E29367D392100000000 218C37090000000000000000 @@ -235,24 +336,25 @@ defaultConfigurationIsVisible - E66DC04E03FF902600000000 + E66DC04E20924D2000000000 isa PBXNativeTarget name - Emoji + EmojiFramework#iphonesimulator-x86_64 productName - Emoji + EmojiFramework productReference - 1DD70E29A59C927400000000 + 1DD70E29FC2E5C0800000000 productType - com.apple.product-type.library.static + com.apple.product-type.framework dependencies buildPhases 1870857F0000000000000000 + 4F426D880000000000000000 buildConfigurationList 218C37090000000000000000 @@ -308,7 +410,7 @@ B401C979EFB6AC4600000000 targets - E66DC04E03FF902600000000 + E66DC04E20924D2000000000 buildConfigurationList 218C37090000000000000001 diff --git a/submodules/Emoji/Emoji.xcodeproj/xcshareddata/xcschemes/Emoji.xcscheme b/submodules/Emoji/Emoji.xcodeproj/xcshareddata/xcschemes/Emoji.xcscheme index c4eb6b0a83..c038b187d4 100644 --- a/submodules/Emoji/Emoji.xcodeproj/xcshareddata/xcschemes/Emoji.xcscheme +++ b/submodules/Emoji/Emoji.xcodeproj/xcshareddata/xcschemes/Emoji.xcscheme @@ -1 +1,71 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/submodules/Emoji/Sources/EmojiUtils.swift b/submodules/Emoji/Sources/EmojiUtils.swift index 9d3c799fcd..023019d5d4 100644 --- a/submodules/Emoji/Sources/EmojiUtils.swift +++ b/submodules/Emoji/Sources/EmojiUtils.swift @@ -1,5 +1,6 @@ import Foundation import CoreText +import AVFoundation public extension UnicodeScalar { var isEmoji: Bool { @@ -52,6 +53,7 @@ public extension String { } var isSingleEmoji: Bool { + let _ = try? AVFoundation.AVAudioFile(forReading: URL(string: "")!) return self.emojis.count == 1 && self.containsEmoji } diff --git a/submodules/HockeySDK-iOS/BUCK b/submodules/HockeySDK-iOS/BUCK deleted file mode 100644 index 1921be1a0d..0000000000 --- a/submodules/HockeySDK-iOS/BUCK +++ /dev/null @@ -1,93 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'combined_config', 'configs_with_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'LIB_SPECIFIC_CONFIG') - -genrule( - name = 'CrashReporter_lib_file', - srcs = [ - 'Vendor/libCrashReporter.a', - ], - bash = 'mkdir -p $OUT; cp $SRCS $OUT/', - out = 'CrashReporter_lib_file', - visibility = [ - '//submodules/HockeySDK-iOS:...', - ] -) - -apple_library( - name = 'CrashReporter', - visibility = [ - '//submodules/HockeySDK-iOS:...' - ], - header_namespace = 'CrashReporter', - exported_headers = glob([ - 'Vendor/include/**/*.h', - ]), - exported_linker_flags = [ - '-lCrashReporter', - '-L$(location :CrashReporter_lib_file)', - ], -) - -'''apple_library( - name = 'CrashReporter', - framework = 'Vendor/CrashReporter.framework', - preferred_linkage = 'static', - visibility = ['//submodules/HockeySDK-iOS:...'] -)''' - -apple_library( - name = 'HockeySDK', - srcs = glob([ - 'Classes/*.m', - 'Classes/*.mm', - ]), - headers = glob([ - 'Classes/*.h', - ]), - header_namespace = 'HockeySDK', - exported_headers = [ - 'Classes/HockeySDKFeatureConfig.h', - 'Classes/HockeySDKEnums.h', - 'Classes/HockeySDKNullability.h', - 'Classes/BITAlertAction.h', - - 'Classes/BITHockeyManager.h', - - 'Classes/BITHockeyAttachment.h', - - 'Classes/BITHockeyBaseManager.h', - 'Classes/BITCrashManager.h', - 'Classes/BITCrashAttachment.h', - 'Classes/BITCrashManagerDelegate.h', - 'Classes/BITCrashDetails.h', - 'Classes/BITCrashMetaData.h', - - 'Classes/BITUpdateManager.h', - 'Classes/BITUpdateManagerDelegate.h', - 'Classes/BITUpdateViewController.h', - 'Classes/BITHockeyBaseViewController.h', - 'Classes/BITHockeyManagerDelegate.h', - ], - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, LIB_SPECIFIC_CONFIG])), - compiler_flags = [ - '-w', - '-DBITHOCKEY_VERSION=@\"5.1.2\"', - '-DBITHOCKEY_C_VERSION="5.1.2"', - '-DBITHOCKEY_C_BUILD="108"', - '-DHOCKEYSDK_FEATURE_CRASH_REPORTER=1', - '-DHOCKEYSDK_FEATURE_UPDATES=1', - '-DHOCKEYSDK_FEATURE_FEEDBACK=0', - '-DHOCKEYSDK_FEATURE_AUTHENTICATOR=0', - '-DHOCKEYSDK_FEATURE_METRICS=0', - ], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - deps = [ - ':CrashReporter', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - ], -) diff --git a/submodules/LegacyComponents/BUCK b/submodules/LegacyComponents/BUCK deleted file mode 100644 index ebbb5bf479..0000000000 --- a/submodules/LegacyComponents/BUCK +++ /dev/null @@ -1,373 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'combined_config', 'configs_with_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_resource( - name = "LegacyComponentsResources", - dirs = [ - "LegacyComponents/Resources/LegacyComponentsResources.bundle", - ], -) - -apple_library( - name = 'LegacyComponents', - srcs = glob([ - 'LegacyComponents/*.m', - 'LegacyComponents/*.mm', - 'LegacyComponents/*.c', - 'LegacyComponents/*.cpp', - ]), - headers = glob([ - 'LegacyComponents/*.h', - ]), - header_namespace = 'LegacyComponents', - exported_headers = [ - 'LegacyComponents/LegacyComponentsGlobals.h', - 'LegacyComponents/LegacyComponentsContext.h', - 'LegacyComponents/TGLocalization.h', - 'LegacyComponents/TGPluralization.h', - 'LegacyComponents/TGStringUtils.h', - 'LegacyComponents/TGPhoneUtils.h', - 'LegacyComponents/NSObject+TGLock.h', - 'LegacyComponents/RMPhoneFormat.h', - 'LegacyComponents/NSInputStream+TL.h', - 'LegacyComponents/TGFont.h', - 'LegacyComponents/TGImageUtils.h', - 'LegacyComponents/TGDateUtils.h', - 'LegacyComponents/Freedom.h', - 'LegacyComponents/FreedomUIKit.h', - 'LegacyComponents/TGHacks.h', - 'LegacyComponents/TGImageBlur.h', - 'LegacyComponents/UIDevice+PlatformInfo.h', - 'LegacyComponents/TGObserverProxy.h', - 'LegacyComponents/TGModernCache.h', - 'LegacyComponents/TGMemoryImageCache.h', - 'LegacyComponents/LegacyComponentsAccessChecker.h', - 'LegacyComponents/TGTimerTarget.h', - 'LegacyComponents/TGKeyCommand.h', - 'LegacyComponents/TGKeyCommandController.h', - 'LegacyComponents/TGWeakDelegate.h', - 'LegacyComponents/TGCache.h', - 'LegacyComponents/TGLiveUploadInterface.h', - - 'LegacyComponents/JNWSpringAnimation.h', - 'LegacyComponents/POPAnimationEvent.h', - 'LegacyComponents/POPAnimationTracer.h', - 'LegacyComponents/POPAnimation.h', - 'LegacyComponents/POPBasicAnimation.h', - 'LegacyComponents/POPCustomAnimation.h', - 'LegacyComponents/POPDecayAnimation.h', - 'LegacyComponents/POPPropertyAnimation.h', - 'LegacyComponents/POPSpringAnimation.h', - 'LegacyComponents/POPGeometry.h', - 'LegacyComponents/POPAnimatableProperty.h', - - 'LegacyComponents/lmdb.h', - 'LegacyComponents/PSLMDBTable.h', - 'LegacyComponents/PSLMDBKeyValueStore.h', - 'LegacyComponents/PSLMDBKeyValueReaderWriter.h', - 'LegacyComponents/PSLMDBKeyValueCursor.h', - - 'LegacyComponents/PSCoding.h', - 'LegacyComponents/PSData.h', - 'LegacyComponents/PSKeyValueCoder.h', - 'LegacyComponents/PSKeyValueDecoder.h', - 'LegacyComponents/PSKeyValueEncoder.h', - 'LegacyComponents/PSKeyValueReader.h', - 'LegacyComponents/PSKeyValueStore.h', - 'LegacyComponents/PSKeyValueWriter.h', - - 'LegacyComponents/TGPeerIdAdapter.h', - 'LegacyComponents/TGUser.h', - 'LegacyComponents/TGBotInfo.h', - 'LegacyComponents/TGBotComandInfo.h', - 'LegacyComponents/TGConversation.h', - - 'LegacyComponents/TGModernConversationAssociatedInputPanel.h', - 'LegacyComponents/TGModernConversationHashtagsAssociatedPanel.h', - 'LegacyComponents/TGModernConversationMentionsAssociatedPanel.h', - 'LegacyComponents/TGModernConversationAlphacodeAssociatedPanel.h', - 'LegacyComponents/TGSuggestionContext.h', - 'LegacyComponents/TGAlphacode.h', - - 'LegacyComponents/TGTextCheckingResult.h', - 'LegacyComponents/TGChannelBannedRights.h', - 'LegacyComponents/TGChannelAdminRights.h', - 'LegacyComponents/TGDatabaseMessageDraft.h', - 'LegacyComponents/TGMessageGroup.h', - 'LegacyComponents/TGMessageHole.h', - 'LegacyComponents/TGMessageViewCountContentProperty.h', - 'LegacyComponents/TGAuthorSignatureMediaAttachment.h', - 'LegacyComponents/TGWebDocument.h', - 'LegacyComponents/TGInvoiceMediaAttachment.h', - 'LegacyComponents/TGGameMediaAttachment.h', - 'LegacyComponents/TGViaUserAttachment.h', - 'LegacyComponents/TGBotContextResultAttachment.h', - 'LegacyComponents/TGMessageEntity.h', - 'LegacyComponents/TGMessageEntityBold.h', - 'LegacyComponents/TGMessageEntityBotCommand.h', - 'LegacyComponents/TGMessageEntityCode.h', - 'LegacyComponents/TGMessageEntityEmail.h', - 'LegacyComponents/TGMessageEntityHashtag.h', - 'LegacyComponents/TGMessageEntityItalic.h', - 'LegacyComponents/TGMessageEntityMention.h', - 'LegacyComponents/TGMessageEntityMentionName.h', - 'LegacyComponents/TGMessageEntityPre.h', - 'LegacyComponents/TGMessageEntityTextUrl.h', - 'LegacyComponents/TGMessageEntityUrl.h', - 'LegacyComponents/TGMessageEntitiesAttachment.h', - 'LegacyComponents/TGBotReplyMarkup.h', - 'LegacyComponents/TGBotReplyMarkupButton.h', - 'LegacyComponents/TGBotReplyMarkupRow.h', - 'LegacyComponents/TGReplyMarkupAttachment.h', - 'LegacyComponents/TGInstantPage.h', - 'LegacyComponents/TGWebPageMediaAttachment.h', - 'LegacyComponents/TGAudioMediaAttachment.h', - 'LegacyComponents/TGAudioWaveform.h', - 'LegacyComponents/TGStickerPackReference.h', - 'LegacyComponents/TGDocumentAttributeFilename.h', - 'LegacyComponents/TGDocumentAttributeImageSize.h', - 'LegacyComponents/TGDocumentAttributeSticker.h', - 'LegacyComponents/TGDocumentAttributeVideo.h', - 'LegacyComponents/TGDocumentAttributeAnimated.h', - 'LegacyComponents/TGDocumentAttributeAudio.h', - 'LegacyComponents/TGDocumentMediaAttachment.h', - 'LegacyComponents/TGUnsupportedMediaAttachment.h', - 'LegacyComponents/TGForwardedMessageMediaAttachment.h', - 'LegacyComponents/TGContactMediaAttachment.h', - 'LegacyComponents/TGVideoInfo.h', - 'LegacyComponents/TGVideoMediaAttachment.h', - 'LegacyComponents/TGLocalMessageMetaMediaAttachment.h', - 'LegacyComponents/TGLocationMediaAttachment.h', - 'LegacyComponents/TGImageMediaAttachment.h', - 'LegacyComponents/TGMediaAttachment.h', - 'LegacyComponents/TGImageInfo.h', - 'LegacyComponents/TGMediaOriginInfo.h', - 'LegacyComponents/TGMessage.h', - 'LegacyComponents/TGStickerPack.h', - 'LegacyComponents/TGStickerAssociation.h', - 'LegacyComponents/TGPhotoMaskPosition.h', - - 'LegacyComponents/ActionStage.h', - 'LegacyComponents/ASActor.h', - 'LegacyComponents/ASHandle.h', - 'LegacyComponents/ASQueue.h', - 'LegacyComponents/ASWatcher.h', - 'LegacyComponents/SGraphListNode.h', - 'LegacyComponents/SGraphNode.h', - 'LegacyComponents/SGraphObjectNode.h', - - 'LegacyComponents/TGLabel.h', - 'LegacyComponents/TGToolbarButton.h', - 'LegacyComponents/UIScrollView+TGHacks.h', - 'LegacyComponents/TGAnimationBlockDelegate.h', - 'LegacyComponents/TGBackdropView.h', - 'LegacyComponents/UIImage+TG.h', - 'LegacyComponents/TGStaticBackdropAreaData.h', - 'LegacyComponents/TGStaticBackdropImageData.h', - 'LegacyComponents/TGImageLuminanceMap.h', - 'LegacyComponents/TGFullscreenContainerView.h', - 'LegacyComponents/TGDoubleTapGestureRecognizer.h', - 'LegacyComponents/TGModernButton.h', - 'LegacyComponents/TGModernToolbarButton.h', - 'LegacyComponents/TGModernBackToolbarButton.h', - 'LegacyComponents/UIControl+HitTestEdgeInsets.h', - 'LegacyComponents/TGMenuView.h', - 'LegacyComponents/TGImageView.h', - 'LegacyComponents/UICollectionView+Utils.h', - 'LegacyComponents/TGMessageImageViewOverlayView.h', - 'LegacyComponents/TGLetteredAvatarView.h', - 'LegacyComponents/TGGradientLabel.h', - 'LegacyComponents/TGRemoteImageView.h', - - 'LegacyComponents/TGProgressSpinnerView.h', - 'LegacyComponents/TGProgressWindow.h', - - 'LegacyComponents/TGMenuSheetController.h', - 'LegacyComponents/TGMenuSheetButtonItemView.h', - 'LegacyComponents/TGMenuSheetCollectionView.h', - 'LegacyComponents/TGMenuSheetItemView.h', - 'LegacyComponents/TGMenuSheetTitleItemView.h', - 'LegacyComponents/TGMenuSheetView.h', - - 'LegacyComponents/HPGrowingTextView.h', - 'LegacyComponents/HPTextViewInternal.h', - 'LegacyComponents/TGInputTextTag.h', - - 'LegacyComponents/TGStickerKeyboardTabPanel.h', - - 'LegacyComponents/TGItemPreviewController.h', - 'LegacyComponents/TGItemPreviewView.h', - 'LegacyComponents/TGItemMenuSheetPreviewView.h', - - 'LegacyComponents/TGImageManager.h', - 'LegacyComponents/TGDataResource.h', - 'LegacyComponents/TGImageDataSource.h', - 'LegacyComponents/TGImageManagerTask.h', - - 'LegacyComponents/TGRTLScreenEdgePanGestureRecognizer.h', - 'LegacyComponents/TGPopoverController.h', - 'LegacyComponents/TGNavigationController.h', - 'LegacyComponents/TGNavigationBar.h', - 'LegacyComponents/TGViewController.h', - 'LegacyComponents/TGViewController+TGRecursiveEnumeration.h', - 'LegacyComponents/TGOverlayController.h', - 'LegacyComponents/TGOverlayControllerWindow.h', - - 'LegacyComponents/TGMediaAssetsLibrary.h', - 'LegacyComponents/TGMediaAssetsModernLibrary.h', - 'LegacyComponents/TGMediaAsset.h', - 'LegacyComponents/TGMediaAssetFetchResult.h', - 'LegacyComponents/TGMediaAssetFetchResultChange.h', - 'LegacyComponents/TGMediaAssetGroup.h', - 'LegacyComponents/TGMediaAssetMoment.h', - 'LegacyComponents/TGMediaAssetMomentList.h', - 'LegacyComponents/TGMediaAssetImageSignals.h', - 'LegacyComponents/TGMediaSelectionContext.h', - 'LegacyComponents/TGMediaEditingContext.h', - - 'LegacyComponents/TGModernGalleryZoomableItemViewContent.h', - 'LegacyComponents/TGModernGalleryZoomableScrollView.h', - 'LegacyComponents/TGModernGalleryZoomableScrollViewSwipeGestureRecognizer.h', - 'LegacyComponents/TGModernGalleryVideoView.h', - 'LegacyComponents/TGModernGalleryScrollView.h', - 'LegacyComponents/TGModernGalleryItem.h', - 'LegacyComponents/TGModernGalleryItemView.h', - 'LegacyComponents/TGModernGalleryImageItem.h', - 'LegacyComponents/TGModernGalleryImageItemView.h', - 'LegacyComponents/TGModernGalleryImageItemImageView.h', - 'LegacyComponents/TGModernGalleryEditableItemView.h', - 'LegacyComponents/TGModernGallerySelectableItem.h', - 'LegacyComponents/TGModernGalleryDefaultFooterAccessoryView.h', - 'LegacyComponents/TGModernGalleryDefaultFooterView.h', - 'LegacyComponents/TGModernGalleryDefaultHeaderView.h', - 'LegacyComponents/TGModernGalleryDefaultInterfaceView.h', - 'LegacyComponents/TGModernGalleryInterfaceView.h', - 'LegacyComponents/TGModernGalleryImageItemContainerView.h', - 'LegacyComponents/TGModernGalleryZoomableItemView.h', - 'LegacyComponents/TGModernGalleryModel.h', - 'LegacyComponents/TGModernGalleryTransitionView.h', - 'LegacyComponents/TGModernGalleryView.h', - 'LegacyComponents/TGModernGalleryContainerView.h', - 'LegacyComponents/TGModernGalleryEmbeddedStickersHeaderView.h', - 'LegacyComponents/TGModernGalleryController.h', - - 'LegacyComponents/TGPhotoToolbarView.h', - 'LegacyComponents/TGMediaPickerGalleryModel.h', - 'LegacyComponents/TGMediaPickerGalleryInterfaceView.h', - 'LegacyComponents/TGPhotoEditorController.h', - 'LegacyComponents/TGMediaAvatarEditorTransition.h', - - 'LegacyComponents/TGPhotoEditorUtils.h', - 'LegacyComponents/PGPhotoEditorValues.h', - 'LegacyComponents/TGVideoEditAdjustments.h', - 'LegacyComponents/AVURLAsset+TGMediaItem.h', - 'LegacyComponents/UIImage+TGMediaEditableItem.h', - 'LegacyComponents/TGMediaVideoConverter.h', - 'LegacyComponents/TGGifConverter.h', - - 'LegacyComponents/TGPhotoEditorAnimation.h', - - 'LegacyComponents/TGPaintingData.h', - 'LegacyComponents/TGPaintUtils.h', - 'LegacyComponents/TGPhotoPaintEntity.h', - 'LegacyComponents/TGPhotoPaintStickerEntity.h', - 'LegacyComponents/TGPaintUndoManager.h', - - 'LegacyComponents/PGCamera.h', - 'LegacyComponents/PGCameraCaptureSession.h', - 'LegacyComponents/PGCameraDeviceAngleSampler.h', - 'LegacyComponents/PGCameraMomentSegment.h', - 'LegacyComponents/PGCameraMomentSession.h', - 'LegacyComponents/PGCameraMovieWriter.h', - 'LegacyComponents/PGCameraShotMetadata.h', - 'LegacyComponents/PGCameraVolumeButtonHandler.h', - 'LegacyComponents/TGCameraPreviewView.h', - 'LegacyComponents/TGCameraMainPhoneView.h', - 'LegacyComponents/TGCameraMainTabletView.h', - 'LegacyComponents/TGCameraMainView.h', - 'LegacyComponents/TGCameraFlashActiveView.h', - 'LegacyComponents/TGCameraFlashControl.h', - 'LegacyComponents/TGCameraFlipButton.h', - 'LegacyComponents/TGCameraInterfaceAssets.h', - 'LegacyComponents/TGCameraModeControl.h', - 'LegacyComponents/TGCameraSegmentsView.h', - 'LegacyComponents/TGCameraShutterButton.h', - 'LegacyComponents/TGCameraTimeCodeView.h', - 'LegacyComponents/TGCameraZoomView.h', - 'LegacyComponents/TGCameraPhotoPreviewController.h', - 'LegacyComponents/TGCameraController.h', - 'LegacyComponents/TGCameraCapturedPhoto.h', - 'LegacyComponents/TGCameraCapturedVideo.h', - 'LegacyComponents/TGPhotoVideoEditor.h', - - 'LegacyComponents/TGModernConversationTitleActivityIndicator.h', - 'LegacyComponents/TGEmbedPIPButton.h', - 'LegacyComponents/TGEmbedPIPPullArrowView.h', - 'LegacyComponents/TGEmbedPlayerState.h', - 'LegacyComponents/TGAttachmentCameraView.h', - 'LegacyComponents/TGMediaAvatarMenuMixin.h', - 'LegacyComponents/TGPassportAttachMenu.h', - 'LegacyComponents/TGPassportScanController.h', - 'LegacyComponents/TGPassportOCR.h', - 'LegacyComponents/TGPassportMRZ.h', - 'LegacyComponents/TGPassportICloud.h', - 'LegacyComponents/TGEmbedPlayerView.h', - 'LegacyComponents/LegacyHTTPRequestOperation.h', - - 'LegacyComponents/TGAttachmentCarouselItemView.h', - 'LegacyComponents/TGMediaAssetsController.h', - - 'LegacyComponents/TGLocationVenue.h', - 'LegacyComponents/TGLocationMapViewController.h', - 'LegacyComponents/TGLocationPickerController.h', - 'LegacyComponents/TGLocationViewController.h', - 'LegacyComponents/TGListsTableView.h', - 'LegacyComponents/TGSearchBar.h', - 'LegacyComponents/TGSearchDisplayMixin.h', - - 'LegacyComponents/TGPhotoEditorSliderView.h', - - 'LegacyComponents/TGClipboardGalleryMixin.h', - 'LegacyComponents/TGClipboardGalleryPhotoItem.h', - 'LegacyComponents/TGVideoMessageCaptureController.h', - 'LegacyComponents/TGModernConversationInputMicButton.h', - - 'LegacyComponents/TGLocationPulseView.h', - 'LegacyComponents/TGLocationWavesView.h', - 'LegacyComponents/TGLocationLiveElapsedView.h', - 'LegacyComponents/TGLocationLiveSessionItemView.h', - - 'LegacyComponents/TGTooltipView.h', - - 'LegacyComponents/TGCheckButtonView.h', - 'LegacyComponents/TGClipboardMenu.h', - 'LegacyComponents/TGImagePickerController.h', - 'LegacyComponents/TGLegacyCameraController.h', - 'LegacyComponents/TGProxyWindow.h', - 'LegacyComponents/TGIconSwitchView.h', - - 'LegacyComponents/TGModernGalleryEditableItem.h', - 'LegacyComponents/TGPhotoEditorButton.h', - - 'LegacyComponents/TGActionMediaAttachment.h', - 'LegacyComponents/TGReplyMessageMediaAttachment.h', - 'LegacyComponents/TGMessageEntityPhone.h', - 'LegacyComponents/TGMessageEntityCashtag.h', - 'LegacyComponents/TGPIPAblePlayerView.h', - 'LegacyComponents/TGEmbedPlayerControls.h', - ], - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - compiler_flags = ['-w'], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - deps = [ - ':LegacyComponentsResources', - '//submodules/SSignalKit:SSignalKit', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - '$SDKROOT/System/Library/Frameworks/Vision.framework', - ], -) diff --git a/submodules/Postbox/BUCK b/submodules/Postbox/BUCK deleted file mode 100644 index d1c6ee49da..0000000000 --- a/submodules/Postbox/BUCK +++ /dev/null @@ -1,44 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'sqlcipher', - srcs = glob([ - 'Postbox/**/*.m', - 'Postbox/**/*.c', - ]), - headers = glob([ - 'Postbox/**/*.h', - ]), - header_namespace = 'sqlcipher', - exported_headers = glob([ - 'Postbox/**/*.h', - ], exclude = ['Postbox/Postbox.h']), - compiler_flags = [ - '-DNDEBUG', - '-DSQLCIPHER_CRYPTO_CC=1', - '-DSQLITE_ENABLE_FTS5', - '-DSQLITE_DEFAULT_MEMSTATUS=0', - '-DSQLITE_MAX_MMAP_SIZE=0', - '-DSQLITE_HAS_CODEC', - ], - modular = True, - visibility = ['//submodules/Postbox:Postbox'], -) - -apple_library( - name = 'Postbox', - srcs = glob([ - 'Postbox/**/*.swift' - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - swift_compiler_flags = [ - '-suppress-warnings', - '-application-extension', - ], - visibility = ['PUBLIC'], - deps = [ - ':sqlcipher', - '//submodules/SSignalKit:SwiftSignalKit' - ], -) diff --git a/submodules/SSignalKit/BUCK b/submodules/SSignalKit/BUCK deleted file mode 100644 index 415648422d..0000000000 --- a/submodules/SSignalKit/BUCK +++ /dev/null @@ -1,37 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'SwiftSignalKit', - srcs = glob([ - 'SwiftSignalKit/*.swift' - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - modular = True, - visibility = ['PUBLIC'], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - ], -) - -apple_library( - name = 'SSignalKit', - srcs = glob([ - 'SSignalKit/*.m', - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - headers = glob([ - 'SSignalKit/*.h', - ]), - header_namespace = 'SSignalKit', - exported_headers = glob([ - 'SSignalKit/*.h', - ]), - modular = True, - compiler_flags = ['-w'], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - ], -) diff --git a/submodules/TelegramApi/BUCK b/submodules/TelegramApi/BUCK deleted file mode 100644 index 8b3f29bce6..0000000000 --- a/submodules/TelegramApi/BUCK +++ /dev/null @@ -1,20 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'TelegramApi', - srcs = glob([ - 'Sources/*.swift', - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - swift_compiler_flags = [ - '-suppress-warnings', - '-application-extension', - ], - visibility = ['PUBLIC'], - deps = [ - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - ], -) diff --git a/submodules/TelegramCore/BUCK b/submodules/TelegramCore/BUCK deleted file mode 100644 index 082b468dfc..0000000000 --- a/submodules/TelegramCore/BUCK +++ /dev/null @@ -1,44 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'TelegramCorePrivateModule', - srcs = glob([ - 'TelegramCore/**/*.m', - 'TelegramCore/**/*.c', - 'third-party/libphonenumber-iOS/*.m', - ]), - headers = glob([ - 'TelegramCore/**/*.h', - 'third-party/libphonenumber-iOS/*.h', - ]), - header_namespace = 'TelegramCorePrivateModule', - exported_headers = glob([ - 'TelegramCore/**/*.h', - 'third-party/libphonenumber-iOS/*.h', - ], exclude = ['TelegramCore/TelegramCore.h']), - modular = True, - visibility = ['//submodules/TelegramCore:TelegramCore'], - deps = [ - '//submodules/MtProtoKit:MtProtoKit', - ], -) - -apple_library( - name = 'TelegramCore', - srcs = glob([ - 'TelegramCore/**/*.swift' - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - swift_compiler_flags = [ - '-suppress-warnings', - '-application-extension', - ], - visibility = ['PUBLIC'], - deps = [ - ':TelegramCorePrivateModule', - '//submodules/SSignalKit:SwiftSignalKit', - '//submodules/MtProtoKit:MtProtoKit', - '//submodules/Postbox:Postbox', - ], -) diff --git a/submodules/TelegramUI/BUCK b/submodules/TelegramUI/BUCK deleted file mode 100644 index d1176c0a40..0000000000 --- a/submodules/TelegramUI/BUCK +++ /dev/null @@ -1,148 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'merge_maps', 'glob_map', 'glob_sub_map', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'TelegramUIPrivateModule', - srcs = glob([ - 'TelegramUI/**/*.m', - 'TelegramUI/**/*.mm', - 'TelegramUI/**/*.c', - 'TelegramUI/**/*.cpp', - 'third-party/opusenc/*.c', - 'third-party/opusenc/*.m', - 'third-party/opusfile/*.c', - 'third-party/ogg/ogg/*.c', - 'third-party/RMIntro/3rdparty/*.h', - 'third-party/RMIntro/core/*.c', - 'third-party/RMIntro/platform/common/*.c', - 'third-party/RMIntro/platform/ios/RMGeometry.m', - 'third-party/RMIntro/platform/ios/RMIntroPageView.m', - 'third-party/RMIntro/platform/ios/RMIntroViewController.m', - 'third-party/RMIntro/platform/ios/RMLoginViewController.m', - 'third-party/RMIntro/platform/ios/RMIntroViewController.m', - 'third-party/RMIntro/platform/ios/texture_helper.m', - ]), - headers = merge_maps([ - glob_map(glob([ - 'TelegramUI/**/*.h', - 'third-party/opusenc/*.h', - 'third-party/opusfile/*.h', - 'third-party/RMIntro/3rdparty/**/*.h', - 'third-party/RMIntro/core/*.h', - 'third-party/RMIntro/platform/common/*.h', - 'third-party/RMIntro/platform/ios/platform_gl.h', - 'third-party/RMIntro/platform/ios/RMGeometry.h', - 'third-party/RMIntro/platform/ios/RMIntroPageView.h', - 'third-party/RMIntro/platform/ios/RMIntroViewController.h', - 'third-party/RMIntro/platform/ios/RMLoginViewController.h', - 'third-party/RMIntro/platform/ios/texture_helper.h', - ])), - glob_sub_map('third-party/ogg/', [ - 'third-party/ogg/**/*.h', - ]), - ]), - header_namespace = 'TelegramUIPrivateModule', - exported_headers = [ - 'third-party/opusenc/opusenc.h', - 'TelegramUI/TGDataItem.h', - 'TelegramUI/FastBlur.h', - 'TelegramUI/RingBuffer.h', - 'TelegramUI/TelegramUIIncludes.h', - 'third-party/RMIntro/platform/ios/RMIntroViewController.h', - 'TelegramUI/STPPaymentCardTextField.h', - 'TelegramUI/STPAPIClient.h', - 'TelegramUI/STPAPIClient+ApplePay.h', - 'TelegramUI/STPPaymentConfiguration.h', - 'TelegramUI/STPCard.h', - 'TelegramUI/STPToken.h', - 'TelegramUI/STPBlocks.h', - 'TelegramUI/STPCardBrand.h', - 'TelegramUI/STPCardParams.h', - 'TelegramUI/STPCustomer.h', - 'TelegramUI/STPFormEncoder.h', - 'TelegramUI/STPFormEncodable.h', - 'TelegramUI/STPAddress.h', - 'TelegramUI/STPAPIResponseDecodable.h', - 'TelegramUI/STPPaymentMethod.h', - 'TelegramUI/STPSource.h', - 'TelegramUI/STPBackendAPIAdapter.h', - 'TelegramUI/OngoingCallThreadLocalContext.h', - 'TelegramUI/SecretChatKeyVisualization.h', - 'TelegramUI/NumberPluralizationForm.h', - 'TelegramUI/DeviceProximityManager.h', - 'TelegramUI/RaiseToListenActivator.h', - 'TelegramUI/TGMimeTypeMap.h', - 'TelegramUI/EDSunriseSet.h', - 'TelegramUI/TGBridgeAudioDecoder.h', - 'TelegramUI/TGBridgeAudioEncoder.h', - 'TelegramUI/GZip.h', - ], - modular = True, - #visibility = ['//submodules/TelegramUI:TelegramUI'], - visibility = ['PUBLIC'], - deps = [ - '//submodules/SSignalKit:SSignalKit', - '//submodules/LegacyComponents:LegacyComponents', - '//submodules/ffmpeg:opus', - '//submodules/MtProtoKit:MtProtoKit', - '//submodules/libtgvoip:tgvoip', - ], -) - -apple_resource( - name = "TelegramUIResources", - files = glob([ - "TelegramUI/Resources/**/*", - ]), -) - -apple_asset_catalog( - name = 'Images', - dirs = [ - 'Images.xcassets', - ], -) - -apple_library( - name = 'TelegramUI', - srcs = glob([ - 'TelegramUI/**/*.swift' - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - #swift_compiler_flags = [ - # '-application-extension', - #], - visibility = ['PUBLIC'], - deps = [ - ':TelegramUIResources', - ':Images', - ':TelegramUIPrivateModule', - '//submodules/SSignalKit:SwiftSignalKit', - '//submodules/SSignalKit:SSignalKit', - '//submodules/Postbox:Postbox', - '//submodules/TelegramCore:TelegramCore', - '//submodules/MtProtoKit:MtProtoKit', - '//submodules/ffmpeg:FFMpeg', - '//submodules/AsyncDisplayKit:AsyncDisplayKit', - '//submodules/Display:Display', - '//submodules/LegacyComponents:LegacyComponents', - '//submodules/lottie-ios:Lottie', - '//submodules/webp:WebPImage', - ], -) - -apple_bundle( - name = "TelegramUIFramework", - extension = "framework", - binary = ":TelegramUI#shared", - info_plist = 'TelegramUI/Info.plist', - info_plist_substitutions = { - 'DEVELOPMENT_LANGUAGE': 'en-us', - 'APP_NAME': 'Telegram', - 'EXECUTABLE_NAME': 'TelegramUI', - 'PRODUCT_BUNDLE_IDENTIFIER': 'org.telegram.TelegramUI', - 'PRODUCT_NAME': 'Telegram UI', - 'CURRENT_PROJECT_VERSION': '5.8', - }, - visibility = ['PUBLIC'], -) diff --git a/submodules/ffmpeg/BUCK b/submodules/ffmpeg/BUCK deleted file mode 100644 index ef306715d6..0000000000 --- a/submodules/ffmpeg/BUCK +++ /dev/null @@ -1,212 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'combined_config', 'configs_with_config', 'gen_header_targets', 'lib_basename', 'get_build_variant') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -genrule( - name = 'opus_lib', - srcs = [ - 'opus/lib/libopus.a', - ], - bash = 'mkdir -p $OUT; cp $SRCS $OUT/', - out = 'opus_lib', - visibility = [ - '//submodules/ffmpeg:opus', - ] -) - -apple_library( - name = 'opus', - visibility = [ - 'PUBLIC', - ], - header_namespace = 'opus', - exported_headers = glob([ - 'opus/include/opus/*.h', - ]), - exported_linker_flags = [ - '-lopus', - '-L$(location :opus_lib)', - ], -) - -ffmpeg_header_paths = [ - 'libavutil/hwcontext.h', - 'libavutil/time.h', - 'libavutil/hwcontext_cuda.h', - 'libavutil/intfloat.h', - 'libavutil/error.h', - 'libavutil/fifo.h', - 'libavutil/blowfish.h', - 'libavutil/hwcontext_mediacodec.h', - 'libavutil/replaygain.h', - 'libavutil/version.h', - 'libavutil/murmur3.h', - 'libavutil/stereo3d.h', - 'libavutil/samplefmt.h', - 'libavutil/pixdesc.h', - 'libavutil/base64.h', - 'libavutil/rational.h', - 'libavutil/sha.h', - 'libavutil/motion_vector.h', - 'libavutil/avconfig.h', - 'libavutil/lfg.h', - 'libavutil/avutil.h', - 'libavutil/xtea.h', - 'libavutil/crc.h', - 'libavutil/hwcontext_vdpau.h', - 'libavutil/frame.h', - 'libavutil/file.h', - 'libavutil/md5.h', - 'libavutil/cast5.h', - 'libavutil/hwcontext_vaapi.h', - 'libavutil/spherical.h', - 'libavutil/ffversion.h', - 'libavutil/audio_fifo.h', - 'libavutil/tree.h', - 'libavutil/threadmessage.h', - 'libavutil/attributes.h', - 'libavutil/adler32.h', - 'libavutil/hwcontext_d3d11va.h', - 'libavutil/timecode.h', - 'libavutil/sha512.h', - 'libavutil/hwcontext_dxva2.h', - 'libavutil/display.h', - 'libavutil/buffer.h', - 'libavutil/camellia.h', - 'libavutil/pixelutils.h', - 'libavutil/hwcontext_drm.h', - 'libavutil/common.h', - 'libavutil/hmac.h', - 'libavutil/eval.h', - 'libavutil/dict.h', - 'libavutil/random_seed.h', - 'libavutil/opt.h', - 'libavutil/mastering_display_metadata.h', - 'libavutil/log.h', - 'libavutil/aes.h', - 'libavutil/macros.h', - 'libavutil/bswap.h', - 'libavutil/rc4.h', - 'libavutil/tea.h', - 'libavutil/cpu.h', - 'libavutil/lzo.h', - 'libavutil/des.h', - 'libavutil/channel_layout.h', - 'libavutil/encryption_info.h', - 'libavutil/twofish.h', - 'libavutil/imgutils.h', - 'libavutil/hwcontext_videotoolbox.h', - 'libavutil/mem.h', - 'libavutil/parseutils.h', - 'libavutil/ripemd.h', - 'libavutil/bprint.h', - 'libavutil/hwcontext_qsv.h', - 'libavutil/pixfmt.h', - 'libavutil/aes_ctr.h', - 'libavutil/timestamp.h', - 'libavutil/downmix_info.h', - 'libavutil/avassert.h', - 'libavutil/hash.h', - 'libavutil/mathematics.h', - 'libavutil/intreadwrite.h', - 'libavutil/avstring.h', - 'libavformat/version.h', - 'libavformat/avio.h', - 'libavformat/avformat.h', - 'libavcodec/adts_parser.h', - 'libavcodec/avcodec.h', - 'libavcodec/version.h', - 'libavcodec/vdpau.h', - 'libavcodec/qsv.h', - 'libavcodec/vaapi.h', - 'libavcodec/videotoolbox.h', - 'libavcodec/xvmc.h', - 'libavcodec/mediacodec.h', - 'libavcodec/d3d11va.h', - 'libavcodec/avfft.h', - 'libavcodec/jni.h', - 'libavcodec/dirac.h', - 'libavcodec/avdct.h', - 'libavcodec/ac3_parser.h', - 'libavcodec/vorbis_parser.h', - 'libavcodec/dxva2.h', - 'libavcodec/dv_profile.h', - 'libswresample/version.h', - 'libswresample/swresample.h', -] - -build_variant = get_build_variant() -library_archs = 'arm64 armv7' if build_variant == 'release' else 'arm64 armv7 x86_64 i386' - -genrule( - name = 'libffmpeg_build', - srcs = glob([ - "FFMpeg/**/*", - ]), - bash = '$SRCDIR/FFMpeg/build-ffmpeg.sh release "' + library_archs + '" $OUT $SRCDIR/FFMpeg', - out = 'libffmpeg', - visibility = [ - '//submodules/ffmpeg:FFMpeg', - '//submodules/ffmpeg:libffmpeg', - ] -) - -ffmpeg_header_targets = gen_header_targets(ffmpeg_header_paths, 'ffmpeg_header_', '', 'libffmpeg_build', 'FFmpeg-iOS/include') - -apple_library( - name = 'libffmpeg', - visibility = [ - '//submodules/ffmpeg:FFMpeg' - ], - header_namespace = 'ffmpeg', - exported_headers = ffmpeg_header_targets, - linker_flags = [ - '-L$(location :libffmpeg_build)/FFmpeg-iOS/lib', - '-lavutil', - '-lavcodec', - '-lavformat', - '-lswresample', - '-lbz2', - '-liconv', - '-lz', - ], - exported_linker_flags = [ - '-L$(location :libffmpeg_build)/FFmpeg-iOS/lib', - '-lavutil', - '-lavcodec', - '-lavformat', - '-lswresample', - '-lbz2', - '-liconv', - '-lz', - ], - deps = [ - ':libffmpeg_build', - ':opus', - ], -) - -apple_library( - name = "FFMpeg", - srcs = glob([ - "FFMpeg/*.m", - ]), - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - header_namespace = 'FFMpeg', - headers = ffmpeg_header_targets, - exported_headers = glob([ - "FFMpeg/*.h", - ]), - modular = True, - swift_compiler_flags = ['-suppress-warnings'], - visibility = ["PUBLIC"], - deps = [ - ':libffmpeg_build', - ':libffmpeg', - ':opus', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - '$SDKROOT/System/Library/Frameworks/CoreMedia.framework', - ], -) diff --git a/submodules/libtgvoip/BUCK b/submodules/libtgvoip/BUCK deleted file mode 100644 index eed22e6082..0000000000 --- a/submodules/libtgvoip/BUCK +++ /dev/null @@ -1,76 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'combined_config', 'configs_with_config', 'glob_map', 'merge_maps', 'glob_sub_map') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'tgvoip', - srcs = glob([ - '*.m', - '*.cpp', - 'audio/*.cpp', - 'video/*.cpp', - 'os/darwin/*.m', - 'os/darwin/*.mm', - 'os/darwin/*.cpp', - 'os/posix/*.cpp', - 'webrtc_dsp/**/*.c', - 'webrtc_dsp/**/*.cc', - 'webrtc_dsp/**/*.cpp', - ], exclude = ['os/darwin/*OSX*']), - headers = merge_maps([ - glob_map(glob([ - '*.h', - 'audio/*.h', - 'video/*.h', - ])), - glob_map(glob([ - 'os/darwin/*.h', - ], exclude = ['os/darwin/*OSX*'])), - glob_sub_map('webrtc_dsp/', [ - 'webrtc_dsp/**/*.h', - ]), - ]), - header_namespace = 'tgvoip', - exported_headers = glob([ - '*.h' - ]), - exported_linker_flags = [ - '-lc++', - ], - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - platform_compiler_flags = [ - ('arm.*', [ - '-w', - '-DTGVOIP_USE_CUSTOM_CRYPTO', - '-DWEBRTC_APM_DEBUG_DUMP=0', - '-DWEBRTC_POSIX', - '-DTGVOIP_HAVE_TGLOG', - '-DWEBRTC_NS_FLOAT', - '-DWEBRTC_IOS', - '-DWEBRTC_HAS_NEON', - ]), - ('.*', [ - '-w', - '-DTGVOIP_USE_CUSTOM_CRYPTO', - '-DWEBRTC_APM_DEBUG_DUMP=0', - '-DWEBRTC_POSIX', - '-DTGVOIP_HAVE_TGLOG', - '-DWEBRTC_NS_FLOAT', - '-DWEBRTC_IOS', - ]), - ], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - deps = [ - '//submodules/ffmpeg:opus', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - '$SDKROOT/System/Library/Frameworks/AudioToolbox.framework', - '$SDKROOT/System/Library/Frameworks/VideoToolbox.framework', - '$SDKROOT/System/Library/Frameworks/CoreTelephony.framework', - '$SDKROOT/System/Library/Frameworks/CoreMedia.framework', - '$SDKROOT/System/Library/Frameworks/AVFoundation.framework', - ], -) diff --git a/submodules/lottie-ios/BUCK b/submodules/lottie-ios/BUCK deleted file mode 100644 index 0da5c4de49..0000000000 --- a/submodules/lottie-ios/BUCK +++ /dev/null @@ -1,29 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -apple_library( - name = 'Lottie', - srcs = glob([ - 'lottie-ios/Classes/**/*.m', - ]), - headers = glob([ - 'lottie-ios/Classes/**/*.h', - ]), - header_namespace = 'HockeySDK', - exported_headers = glob([ - 'lottie-ios/Classes/PublicHeaders/*.h' - ]), - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - compiler_flags = [ - '-w' - ], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - deps = [ - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - ], -) diff --git a/submodules/webp/BUCK b/submodules/webp/BUCK deleted file mode 100644 index 3b4d5be107..0000000000 --- a/submodules/webp/BUCK +++ /dev/null @@ -1,55 +0,0 @@ -load('//tools:buck_utils.bzl', 'config_with_updated_linker_flags', 'configs_with_config', 'glob_sub_map', 'combined_config') -load('//tools:buck_defs.bzl', 'SHARED_CONFIGS', 'EXTENSION_LIB_SPECIFIC_CONFIG') - -genrule( - name = 'webp_lib_file', - srcs = [ - 'lib/libwebp.a', - ], - bash = 'mkdir -p $OUT; cp $SRCS $OUT/', - out = 'webp_lib_file', - visibility = [ - '//submodules/webp:...', - ] -) - -apple_library( - name = 'webp_lib', - visibility = [ - '//submodules/webp:...' - ], - header_namespace = 'webp', - exported_headers = glob_sub_map('include/', glob([ - 'include/**/*.h', - ])), - exported_linker_flags = [ - '-lwebp', - '-L$(location :webp_lib_file)', - ], -) - -apple_library( - name = 'WebPImage', - srcs = glob([ - 'WebP/*.m', - ]), - headers = glob([ - 'WebP/*.h', - ], exclude = ['WebP/WebP.h']), - header_namespace = 'WebPImage', - exported_headers = glob([ - 'WebP/*.h', - ], exclude = ['WebP/WebP.h']), - modular = True, - configs = configs_with_config(combined_config([SHARED_CONFIGS, EXTENSION_LIB_SPECIFIC_CONFIG])), - compiler_flags = ['-w'], - preprocessor_flags = ['-fobjc-arc'], - visibility = ['PUBLIC'], - deps = [ - ':webp_lib', - ], - frameworks = [ - '$SDKROOT/System/Library/Frameworks/Foundation.framework', - '$SDKROOT/System/Library/Frameworks/UIKit.framework', - ], -)