-
Notifications
You must be signed in to change notification settings - Fork 7
/
TKPermissionKit.podspec
193 lines (158 loc) · 6.21 KB
/
TKPermissionKit.podspec
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
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
#
# Be sure to run `pod spec lint TKPermissionKit.podspec' to ensure this is a
# valid spec and to remove all comments including this before submitting the spec.
#
# To learn more about Podspec attributes see https://guides.cocoapods.org/syntax/podspec.html
# To see working Podspecs in the CocoaPods repo see https://github.com/CocoaPods/Specs/
#
name = "TKPermissionKit"
version = "1.2.9"
homepage = "https://github.com/RANSAA/TKPermissionKit"
file_source = "*.{h,m,bundle}"
file_header = "*.h"
public_source = "TKPermissionKit/Public/TKPermissionPublic.{h,m}"
public_header = "TKPermissionKit/Public/TKPermissionPublic.h"
public_base = "TKPermissionKit/Public"
Pod::Spec.new do |spec|
spec.name = "#{name}"
spec.summary = 'iOS权限管理工具'
spec.homepage = "#{homepage}"
spec.version = "#{version}"
spec.source = { :git => "#{homepage}.git", :tag => "v#{spec.version}" } #对应github资源与版本
spec.license = "MIT" #开源协议方式
spec.author = { "sayaDev" => "[email protected]" } #作者
spec.requires_arc = true #支持arc
spec.platform = :ios, '9.0'
spec.source_files = "#{name}/TKPermissionKit.h"
spec.public_header_files = "#{name}/TKPermissionKit.h"
spec.subspec 'Public' do |ss|
ss.source_files = public_source
ss.public_header_files = public_header
# ss.resources = "#{name}/Public/*.bundle"
ss.resource_bundles = {
# 资源文件
'TKPermissionKit' => [
"#{name}/Public/*.bundle/*"
],
## 隐私清单 - 注意:建议与资源文件分别存放在不同的bundle中
'TKPermissionKit.Privacy' => [
"#{name}/Public/PrivacyInfo.xcprivacy"
],
}
ss.ios.frameworks = "Foundation", "UIKit"
end
spec.subspec 'Photo' do |ss|
ss.source_files = "#{name}/Photo/#{file_source}"
ss.public_header_files = "#{name}/Photo/#{file_header}"
ss.ios.frameworks = "Photos"
ss.dependency "#{public_base}" #依赖
end
spec.subspec 'Camera' do |ss|
ss.source_files = "#{name}/Camera/#{file_source}"
ss.public_header_files = "#{name}/Camera/#{file_header}"
ss.ios.frameworks = "AVFoundation"
ss.dependency "#{public_base}"
end
spec.subspec 'Media' do |ss|
ss.source_files = "#{name}/Media/#{file_source}"
ss.public_header_files = "#{name}/Media/#{file_header}"
ss.ios.frameworks = "MediaPlayer"
ss.dependency "#{public_base}"
end
spec.subspec 'Bluetooth' do |ss|
ss.source_files = "#{name}/Bluetooth/#{file_source}"
ss.public_header_files = "#{name}/Bluetooth/#{file_header}"
ss.ios.frameworks = "CoreBluetooth"
ss.dependency "#{public_base}"
end
spec.subspec 'Microphone' do |ss|
ss.source_files = "#{name}/Microphone/#{file_source}"
ss.public_header_files = "#{name}/Microphone/#{file_header}"
ss.ios.frameworks = "AVFoundation"
ss.dependency "#{public_base}"
end
spec.subspec 'LocationWhen' do |ss|
ss.source_files = "#{name}/LocationWhen/#{file_source}"
ss.public_header_files = "#{name}/LocationWhen/#{file_header}"
ss.ios.frameworks = "CoreLocation"
ss.dependency "#{public_base}"
end
spec.subspec 'LocationAlways' do |ss|
ss.source_files = "#{name}/LocationAlways/#{file_source}"
ss.public_header_files = "#{name}/LocationAlways/#{file_header}"
ss.ios.frameworks = "CoreLocation"
ss.dependency "#{public_base}"
end
spec.subspec 'Notification' do |ss|
ss.source_files = "#{name}/Notification/#{file_source}"
ss.public_header_files = "#{name}/Notification/#{file_header}"
ss.ios.frameworks = "UserNotifications"
ss.dependency "#{public_base}"
end
spec.subspec 'Speech' do |ss|
ss.source_files = "#{name}/Speech/#{file_source}"
ss.public_header_files = "#{name}/Speech/#{file_header}"
ss.ios.frameworks = "Speech"
ss.dependency "#{public_base}"
end
spec.subspec 'Contacts' do |ss|
ss.source_files = "#{name}/Contacts/#{file_source}"
ss.public_header_files = "#{name}/Contacts/#{file_header}"
# ss.ios.frameworks = "Contacts","AddressBook"
ss.ios.frameworks = "Contacts"
ss.dependency "#{public_base}"
end
spec.subspec 'Calendar' do |ss|
ss.source_files = "#{name}/Calendar/#{file_source}"
ss.public_header_files = "#{name}/Calendar/#{file_header}"
ss.ios.frameworks = "EventKit"
ss.dependency "#{public_base}"
end
spec.subspec 'Reminder' do |ss|
ss.source_files = "#{name}/Reminder/#{file_source}"
ss.public_header_files = "#{name}/Reminder/#{file_header}"
ss.ios.frameworks = "EventKit"
ss.dependency "#{public_base}"
end
spec.subspec 'Network' do |ss|
ss.source_files = "#{name}/Network/#{file_source}"
ss.public_header_files = "#{name}/Network/#{file_header}"
ss.ios.frameworks = "CoreTelephony"
ss.dependency "#{public_base}"
end
spec.subspec 'Motion' do |ss|
ss.source_files = "#{name}/Motion/#{file_source}"
ss.public_header_files = "#{name}/Motion/#{file_header}"
ss.ios.frameworks = "CoreMotion"
ss.dependency "#{public_base}"
end
spec.subspec 'Home' do |ss|
ss.source_files = "#{name}/Home/#{file_source}"
ss.public_header_files = "#{name}/Home/#{file_header}"
ss.ios.frameworks = "HomeKit"
ss.dependency "#{public_base}"
end
spec.subspec 'Health' do |ss|
ss.source_files = "#{name}/Health/#{file_source}"
ss.public_header_files = "#{name}/Health/#{file_header}"
ss.ios.frameworks = "HealthKit"
ss.dependency "#{public_base}"
end
spec.subspec 'FileAndFolders' do |ss|
ss.source_files = "#{name}/FileAndFolders/#{file_source}"
ss.public_header_files = "#{name}/FileAndFolders/#{file_header}"
ss.dependency "#{public_base}"
end
spec.subspec 'Tracking' do |ss|
ss.source_files = "#{name}/Tracking/#{file_source}"
ss.public_header_files = "#{name}/Tracking/#{file_header}"
ss.ios.frameworks = 'AppTrackingTransparency', 'AdSupport'
ss.dependency "#{public_base}"
end
spec.subspec 'Siri' do |ss|
ss.source_files = "#{name}/Siri/#{file_source}"
ss.public_header_files = "#{name}/Siri/#{file_header}"
ss.ios.frameworks = "Intents"
ss.dependency "#{public_base}"
end
end