Skip to content

Commit

Permalink
Merge pull request #127 from SSheldon/frameworks_advanced
Browse files Browse the repository at this point in the history
Fix podspec when used as a framework
  • Loading branch information
kstenerud committed Feb 29, 2016
2 parents 1244cc4 + 1585165 commit 62ddde2
Showing 1 changed file with 21 additions and 13 deletions.
34 changes: 21 additions & 13 deletions KSCrash.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Pod::Spec.new do |s|
s.frameworks = 'Foundation'
s.libraries = 'c++', 'z'
s.xcconfig = { 'GCC_ENABLE_CPP_EXCEPTIONS' => 'YES' }
s.default_subspecs = 'Installations'

s.subspec 'no-arc' do |sp|
sp.source_files = 'Source/KSCrash/Recording/**/KSZombie.{h,m}'
Expand All @@ -34,21 +35,28 @@ Pod::Spec.new do |s|
'Source/KSCrash/Recording/Sentry/KSCrashSentry.h',
'Source/KSCrash/Recording/Tools/KSArchSpecific.h',
'Source/KSCrash/Recording/Tools/KSJSONCodecObjC.h',
'Source/KSCrash/Recording/Tools/NSError+SimpleConstructor.h'

recording.subspec 'Advanced' do |advanced|
advanced.public_header_files = 'Source/KSCrash/Recording/KSCrashAdvanced.h',
'Source/KSCrash/Recording/KSCrashDoctor.h',
'Source/KSCrash/Recording/KSCrashReportFields.h',
'Source/KSCrash/Recording/KSCrashReportStore.h',
'Source/KSCrash/Recording/KSSystemInfo.h',
'Source/KSCrash/Recording/KSSystemInfoC.h'
end
'Source/KSCrash/Recording/Tools/NSError+SimpleConstructor.h',
'Source/KSCrash/Reporting/Filters/KSCrashReportFilter.h'
end

recording.subspec 'Tools' do |tools|
tools.public_header_files = 'Source/KSCrash/Recording/Tools/**/*.h'
end
# This subspec is just to optionally expose the advanced headers
s.subspec 'RecordingAdvanced' do |advanced|
advanced.dependency 'KSCrash/Recording'
# Just add .h files; the .m files are all compiled in the Recording spec
advanced.source_files = 'Source/KSCrash/Recording/KSCrashAdvanced.h',
'Source/KSCrash/Recording/KSCrashDoctor.h',
'Source/KSCrash/Recording/KSCrashReportFields.h',
'Source/KSCrash/Recording/KSCrashReportStore.h',
'Source/KSCrash/Recording/KSSystemInfo.h',
'Source/KSCrash/Recording/KSSystemInfoC.h'
end

# This subspec is just to optionally expose the tools headers
s.subspec 'RecordingTools' do |tools|
tools.dependency 'KSCrash/Recording'
# Just add .h files; the .m files are all compiled in the Recording spec
tools.source_files = 'Source/KSCrash/Recording/Tools/*.h'
tools.exclude_files = 'Source/KSCrash/Recording/Tools/KSZombie.h'
end

s.subspec 'Reporting' do |reporting|
Expand Down

0 comments on commit 62ddde2

Please sign in to comment.