hmap files


(Jon Rafkind) #1

What are hmap files and how do they relate to the swift compilation
process? It seems that they are a clang thing, but I can't find any
documentation on them.


(Daniel Dunbar) #2

They are "header map" files and you are right they are very poorly documented.

Xcode uses them to provide the compiler with a mapping of textual include names to actual file paths.

What are you specifically looking into?

- Daniel

ยทยทยท

On Apr 26, 2016, at 11:42 AM, Rafkind, Jon via swift-dev <swift-dev@swift.org> wrote:

What are hmap files and how do they relate to the swift compilation
process? It seems that they are a clang thing, but I can't find any
documentation on them.
_______________________________________________
swift-dev mailing list
swift-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-dev


(Jon Rafkind) #3

Well I'm wondering what to do with them since I am writing a program
that directly invokes the swift compiler code. Meaning, I create a
swift::Module*, call swift::parseIntoSourceFile,
swift::performTypeChecking, etc. So far it doesn't seem that I need to
pass along the hmap files to anything in the swift codebase, perhaps the
hmap files I see xcode adding to the swiftc lines so far are all
superfluous.

ยทยทยท

On 04/26/2016 11:46 AM, Daniel Dunbar wrote:

They are "header map" files and you are right they are very poorly documented.

Xcode uses them to provide the compiler with a mapping of textual include names to actual file paths.

What are you specifically looking into?

- Daniel

On Apr 26, 2016, at 11:42 AM, Rafkind, Jon via swift-dev <swift-dev@swift.org> wrote:

What are hmap files and how do they relate to the swift compilation
process? It seems that they are a clang thing, but I can't find any
documentation on them.
_______________________________________________
swift-dev mailing list
swift-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-dev


(Daniel Dunbar) #4

Yes, you should avoid passing header map files.

They should only be used when trying to integrate with existing Xcode projects, when invoking swiftc yourself you should use the simpler header search path options (-I, -F).

- Daniel

ยทยทยท

On Apr 26, 2016, at 11:51 AM, Rafkind, Jon <jon.rafkind@hpe.com> wrote:

Well I'm wondering what to do with them since I am writing a program
that directly invokes the swift compiler code. Meaning, I create a
swift::Module*, call swift::parseIntoSourceFile,
swift::performTypeChecking, etc. So far it doesn't seem that I need to
pass along the hmap files to anything in the swift codebase, perhaps the
hmap files I see xcode adding to the swiftc lines so far are all
superfluous.

On 04/26/2016 11:46 AM, Daniel Dunbar wrote:

They are "header map" files and you are right they are very poorly documented.

Xcode uses them to provide the compiler with a mapping of textual include names to actual file paths.

What are you specifically looking into?

- Daniel

On Apr 26, 2016, at 11:42 AM, Rafkind, Jon via swift-dev <swift-dev@swift.org> wrote:

What are hmap files and how do they relate to the swift compilation
process? It seems that they are a clang thing, but I can't find any
documentation on them.
_______________________________________________
swift-dev mailing list
swift-dev@swift.org
https://lists.swift.org/mailman/listinfo/swift-dev