forked from signalapp/Signal-iOS
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Podfile
150 lines (118 loc) · 5.36 KB
/
Podfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
platform :ios, '10.0'
source 'https://github.com/CocoaPods/Specs.git'
use_frameworks!
def shared_pods
###
# OWS Pods
###
pod 'SignalCoreKit', git: 'https://github.com/signalapp/SignalCoreKit.git', testspecs: ["Tests"]
# pod 'SignalCoreKit', path: '../SignalCoreKit', testspecs: ["Tests"]
pod 'AxolotlKit', git: 'https://github.com/signalapp/SignalProtocolKit.git', branch: 'master', testspecs: ["Tests"]
# pod 'AxolotlKit', path: '../SignalProtocolKit', testspecs: ["Tests"]
pod 'HKDFKit', git: 'https://github.com/signalapp/HKDFKit.git', testspecs: ["Tests"]
# pod 'HKDFKit', path: '../HKDFKit', testspecs: ["Tests"]
pod 'Curve25519Kit', git: 'https://github.com/signalapp/Curve25519Kit', testspecs: ["Tests"]
# pod 'Curve25519Kit', path: '../Curve25519Kit', testspecs: ["Tests"]
pod 'SignalMetadataKit', git: '[email protected]:signalapp/SignalMetadataKit', testspecs: ["Tests"]
# pod 'SignalMetadataKit', path: '../SignalMetadataKit', testspecs: ["Tests"]
pod 'blurhash', git: 'https://github.com/signalapp/blurhash', branch: 'addPodspec'
pod 'SignalServiceKit', path: '.', testspecs: ["Tests"]
# Project does not compile with PromiseKit 6.7.1
# see: https://github.com/mxcl/PromiseKit/issues/990
pod 'PromiseKit', "6.5.3"
###
# forked third party pods
###
# pod 'GRDB.swift/SQLCipher', path: '../GRDB.swift'
pod 'GRDB.swift/SQLCipher'
# Includes some soon to be released "unencrypted header" changes required for the Share Extension
pod 'SQLCipher', ">= 4.0.1"
# Forked for performance optimizations that are not likely to be upstreamed as they are specific
# to our limited use of Mantle
pod 'Mantle', git: 'https://github.com/signalapp/Mantle', branch: 'signal-master'
# pod 'Mantle', path: '../Mantle'
# Forked for compatibily with the ShareExtension, changes have an open PR, but have not been merged.
pod 'YapDatabase/SQLCipher', :git => 'https://github.com/signalapp/YapDatabase.git', branch: 'signal-release'
# pod 'YapDatabase/SQLCipher', path: '../YapDatabase'
# Forked to incorporate our self-built binary artifact.
pod 'GRKOpenSSLFramework', git: 'https://github.com/signalapp/GRKOpenSSLFramework', branch: 'mkirk/1.0.2t'
#pod 'GRKOpenSSLFramework', path: '../GRKOpenSSLFramework'
pod 'Starscream', git: '[email protected]:signalapp/Starscream.git', branch: 'signal-release'
# pod 'Starscream', path: '../Starscream'
###
# third party pods
####
pod 'AFNetworking', inhibit_warnings: true
pod 'PureLayout', :inhibit_warnings => true
pod 'Reachability', :inhibit_warnings => true
pod 'lottie-ios', :inhibit_warnings => true
end
target 'Signal' do
shared_pods
pod 'SSZipArchive', :inhibit_warnings => true
target 'SignalTests' do
inherit! :search_paths
end
target 'SignalPerformanceTests' do
inherit! :search_paths
end
end
target 'SignalShareExtension' do
shared_pods
end
target 'SignalMessaging' do
shared_pods
end
post_install do |installer|
enable_extension_support_for_purelayout(installer)
configure_warning_flags(installer)
configure_testable_build(installer)
disable_bitcode(installer)
end
# PureLayout by default makes use of UIApplication, and must be configured to be built for an extension.
def enable_extension_support_for_purelayout(installer)
installer.pods_project.targets.each do |target|
if target.name.end_with? "PureLayout"
target.build_configurations.each do |build_configuration|
if build_configuration.build_settings['APPLICATION_EXTENSION_API_ONLY'] == 'YES'
build_configuration.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] = ['$(inherited)', 'PURELAYOUT_APP_EXTENSIONS=1']
end
end
end
end
end
# We want some warning to be treated as errors.
#
# NOTE: We have to manually keep this list in sync with what's in our
# Signal.xcodeproj config in Xcode go to:
# Signal Project > Build Settings > Other Warning Flags
def configure_warning_flags(installer)
installer.pods_project.targets.each do |target|
target.build_configurations.each do |build_configuration|
build_configuration.build_settings['WARNING_CFLAGS'] = ['$(inherited)',
'-Werror=incompatible-pointer-types',
'-Werror=protocol',
'-Werror=incomplete-implementation',
'-Werror=objc-literal-conversion']
end
end
end
def configure_testable_build(installer)
installer.pods_project.targets.each do |target|
target.build_configurations.each do |build_configuration|
next unless ["Testable Release", "Debug"].include?(build_configuration.name)
build_configuration.build_settings['OTHER_CFLAGS'] ||= '$(inherited) -DTESTABLE_BUILD'
build_configuration.build_settings['OTHER_SWIFT_FLAGS'] ||= '$(inherited) -DTESTABLE_BUILD'
build_configuration.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= '$(inherited) TESTABLE_BUILD=1'
build_configuration.build_settings['ENABLE_TESTABILITY'] = 'YES'
build_configuration.build_settings['ONLY_ACTIVE_ARCH'] = 'YES'
end
end
end
def disable_bitcode(installer)
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['ENABLE_BITCODE'] = 'NO'
end
end
end