Commit f7587b16 authored by Fabio Pelosin's avatar Fabio Pelosin

[LocalPod] Added support for .hpp headers.

Closes #244.
parent 67541e5e
## Master ## Master
[CocoaPods](https://github.com/CocoaPods/CocoaPods/compare/0.14.0...master) [CocoaPods](https://github.com/CocoaPods/CocoaPods/compare/0.14.0...master)[Xcodeproj](https://github.com/CocoaPods/Xcodeproj/compare/0.3.3...master)
###### Enhancements ###### Enhancements
- Pod `install` will update the specs repo only if needed. - Pod `install` will update the specs repo only if needed.
...@@ -34,6 +34,8 @@ ...@@ -34,6 +34,8 @@
[#514](https://github.com/CocoaPods/CocoaPods/issues/514) [#514](https://github.com/CocoaPods/CocoaPods/issues/514)
- Forcing UTF-8 encoding on licenses generation in Ruby 1.9. - Forcing UTF-8 encoding on licenses generation in Ruby 1.9.
[#530](https://github.com/CocoaPods/CocoaPods/issues/530) [#530](https://github.com/CocoaPods/CocoaPods/issues/530)
- Added support for `.hpp` headers.
[#244](https://github.com/CocoaPods/CocoaPods/issues/244)
## 0.14.0 ## 0.14.0
......
...@@ -238,7 +238,7 @@ module Pod ...@@ -238,7 +238,7 @@ module Pod
# {Specification}. # {Specification}.
# #
def source_files_by_spec def source_files_by_spec
options = {:glob => '*.{h,m,mm,c,cpp}'} options = {:glob => '*.{h,hpp,m,mm,c,cpp}'}
paths_by_spec(:source_files, options) paths_by_spec(:source_files, options)
end end
...@@ -260,7 +260,7 @@ module Pod ...@@ -260,7 +260,7 @@ module Pod
def header_files_by_spec def header_files_by_spec
result = {} result = {}
source_files_by_spec.each do |spec, paths| source_files_by_spec.each do |spec, paths|
headers = paths.select { |f| f.extname == '.h' } headers = paths.select { |f| f.extname == '.h' || f.extname == '.hpp' }
result[spec] = headers unless headers.empty? result[spec] = headers unless headers.empty?
end end
result result
...@@ -274,7 +274,7 @@ module Pod ...@@ -274,7 +274,7 @@ module Pod
# header files (i.e. the build ones) are intended to be public. # header files (i.e. the build ones) are intended to be public.
# #
def public_header_files_by_spec def public_header_files_by_spec
public_headers = paths_by_spec(:public_header_files, :glob => '*.h') public_headers = paths_by_spec(:public_header_files, :glob => '*.{h,hpp}')
build_headers = header_files_by_spec build_headers = header_files_by_spec
result = {} result = {}
...@@ -377,7 +377,7 @@ module Pod ...@@ -377,7 +377,7 @@ module Pod
if (public_h = public_headers[spec]) && !public_h.empty? if (public_h = public_headers[spec]) && !public_h.empty?
result += public_h result += public_h
elsif (source_f = source_files[spec]) && !source_f.empty? elsif (source_f = source_files[spec]) && !source_f.empty?
build_h = source_f.select { |f| f.extname == '.h' } build_h = source_f.select { |f| f.extname == '.h' || f.extname == '.hpp' }
result += build_h unless build_h.empty? result += build_h unless build_h.empty?
end end
end end
...@@ -431,7 +431,7 @@ module Pod ...@@ -431,7 +431,7 @@ module Pod
# (the files the need to compiled) of the pod. # (the files the need to compiled) of the pod.
# #
def implementation_files def implementation_files
relative_source_files.select { |f| f.extname != '.h' } relative_source_files.reject { |f| f.extname == '.h' || f.extname == '.hpp' }
end end
# @return [Pathname] The path of the pod relative from the sandbox. # @return [Pathname] The path of the pod relative from the sandbox.
...@@ -474,7 +474,7 @@ module Pod ...@@ -474,7 +474,7 @@ module Pod
# included in the linker search paths. # included in the linker search paths.
# #
def headers_excluded_from_search_paths def headers_excluded_from_search_paths
options = { :glob => '*.h' } options = { :glob => '*.{h,hpp}' }
paths = paths_by_spec(:exclude_header_search_paths, options) paths = paths_by_spec(:exclude_header_search_paths, options)
paths.values.compact.uniq paths.values.compact.uniq
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment