Commit cb2c8a72 authored by Jonathan Penn's avatar Jonathan Penn

Add support for .hh headers

Need to support .hh files as headers to use the live555 rtp library.
Followed the pattern of this commit:

https://github.com/CocoaPods/CocoaPods/commit/f7587b16ffae55138df5a62949c2cc3ff2b98fae

That fixed issue #244 solving the same situation for .hpp headers.
parent fe96a978
......@@ -240,7 +240,7 @@ module Pod
# {Specification}.
#
def source_files_by_spec
options = {:glob => '*.{h,hpp,m,mm,c,cpp}'}
options = {:glob => '*.{h,hpp,hh,m,mm,c,cpp}'}
paths_by_spec(:source_files, options)
end
......@@ -262,7 +262,7 @@ module Pod
def header_files_by_spec
result = {}
source_files_by_spec.each do |spec, paths|
headers = paths.select { |f| f.extname == '.h' || f.extname == '.hpp' }
headers = paths.select { |f| f.extname == '.h' || f.extname == '.hpp' || f.extname == '.hh' }
result[spec] = headers unless headers.empty?
end
result
......@@ -276,7 +276,7 @@ module Pod
# header files (i.e. the build ones) are intended to be public.
#
def public_header_files_by_spec
public_headers = paths_by_spec(:public_header_files, :glob => '*.{h,hpp}')
public_headers = paths_by_spec(:public_header_files, :glob => '*.{h,hpp,hh}')
build_headers = header_files_by_spec
result = {}
......@@ -379,7 +379,7 @@ module Pod
if (public_h = public_headers[spec]) && !public_h.empty?
result += public_h
elsif (source_f = source_files[spec]) && !source_f.empty?
build_h = source_f.select { |f| f.extname == '.h' || f.extname == '.hpp' }
build_h = source_f.select { |f| f.extname == '.h' || f.extname == '.hpp' || f.extname == '.hh' }
result += build_h unless build_h.empty?
end
end
......@@ -433,7 +433,7 @@ module Pod
# (the files the need to compiled) of the pod.
#
def implementation_files
relative_source_files.reject { |f| f.extname == '.h' || f.extname == '.hpp' }
relative_source_files.reject { |f| f.extname == '.h' || f.extname == '.hpp' || f.extname == '.hh' }
end
# @return [Pathname] The path of the pod relative from the sandbox.
......@@ -476,7 +476,7 @@ module Pod
# included in the linker search paths.
#
def headers_excluded_from_search_paths
options = { :glob => '*.{h,hpp}' }
options = { :glob => '*.{h,hpp,hh}' }
paths = paths_by_spec(:exclude_header_search_paths, options)
paths.values.compact.uniq
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