{"issue":{"created_at":"2011-11-03T10:36:36Z","state":"open","updated_at":"2011-11-20T21:56:31Z","user":{"gravatar_id":"424a9ce662b059c35063b405e160461d","id":2320,"url":"https://api.github.com/users/alloy","login":"alloy","avatar_url":"https://secure.gravatar.com/avatar/424a9ce662b059c35063b405e160461d?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"comments":2,"body":"```\r\n10:31 kommen: alloy: got to talk to 2 xcode guys\r\n10:32 kommen: we eventually got the headers thing to work\r\n10:34 kommen: so the things we did:\r\n10:35 kommen: * set the headers in the pods xcode project to be \"public\"\r\n10:35 kommen: * use the header search path, not the user search path\r\n10:36 kommen: * then use #include <bla.h> instead of \"bla.h\"\r\n10:38 kommen: * override the ALWAYS_SEARCH_USER_PATHS to be YES on the target level\r\n10:38 kommen: for some reason xcode doesn't inherit it from the xcconfig down to the targets for us\r\n10:40 alloy: Hmm, I wonder if Xcode just checks the xcodeproj for headers with the ‘public’ attr or in the header search paths, because we do set the public attr\r\n10:41 kommen: oh.\r\n10:41 kommen: hmm, but they weren't public\r\n10:41 alloy checking an actual project to see if it actually works ;)\r\n10:45 alloy: Hmm, I forgot, where in Xcode 4 did you set the role again?\r\n10:46 alloy: This is where we set the attr when generating the project btw: https://github.com/alloy/cocoapods/blob/master/lib/cocoapods/xcode/project.rb#L79\r\n10:46 alloy: But maybe the fact that we don’t actually use the ‘headers build phase’ but a general ‘copy files build phase’ might have to do something with that?\r\n10:49 alloy: I think the second and fourth are mutually exclusive. I.e. Not using the user search paths but still setting searching it to YES _seems_ as if it won't matter much.\r\n10:49 alloy: Also, I wonder what the exact diff is between the regular search paths and the user’s search paths.\r\n10:50 alloy: Finally, regarding ‘#include <bla.h> instead of \"bla.h\"’, is it important to use ‘include’ vs ‘import’? Or just the angle brackets vs the quotes?\r\n10:50 kommen: don't know the difference. but the guys suggested it we should use the regular header search path, cause this is intended for libraries\r\n10:51 kommen: well, it seems like a convention to use \" for your own things, and <> for 3rd party stuff\r\n10:51 alloy: Yeah indeed, I have been using it that way myself, but I was wondering more if the include vs import mattered too\r\n10:52 alloy: Ok I see, well then we should probably change it to use the regular header search paths indeed.\r\n10:54 alloy: Man, it’s too bad that we still don't have a full grasp on what xcode does…\r\n10:55 kommen: the suggested that we let a user include a pod header in his files like <Pods/AFNetworking/AFNetworking.h>, though that's a matter of taste\r\n10:55 kommen: the = they\r\n10:55 kommen: (man, my spelling is shit today)\r\n10:56 kommen needs moar coffeez\r\n10:59 alloy: Just checked a project and what is weird is that the ALWAYS_SEARCH_USER_PATHS setting is explicitly set to NO in the global project configuration, but on the app target it is not set and inherits YES.\r\n11:00 kommen: yeah, something is off with the this one\r\n11:01 alloy: Ugh, I know the feeling… More coffee ftw, up till a certain point ;)\r\n11:03 alloy: With regards ot the extra namespacing, was there a technical reason for it, or just as extra indication to the reader where the header is located?\r\n11:03 alloy: *to\r\n11:03 kommen: I just feel really embarrassed... i didn't even know there's a #include *and* and #import :/\r\n11:04 alloy: Hehehe. A day not having learned stuff is a day wasted!\r\n11:04 kommen: as far as i understood, there's no technical reason, just more clarity where stuff comes from\r\n11:05 kommen: (thats why they do #import <Foundation/Foundation.h> instead of only Foundation.h)\r\n11:05 alloy: Fair enough, so if that doesn't work yet then we can add that search path.\r\n11:06 alloy: Right, but my idea (or actually jweinberg’s) was that we do that grouped by pod only. I.e. <AFNetworkin/AFNetworking.h>\r\n11:07 alloy: But it doesn't hurt to add the root to search path too I guess\r\n11:07 alloy: So people can choose which way they want to use it.\r\n11:16 kommen: yeah, true\r\n11:18 alloy: So where in Xcode 4 did you mark the headers as public?\r\n11:18 alloy: Or is it just a matter of adding them to the right section of the ‘copy headers’ build phase?\r\n11:22 kommen: alloy: honestly, i can't find the public setting right now either...\r\n11:25 alloy: I know there used to be a place where you could set a checkbox, but I can’t find that, nor do suggestions from the web work (select headers, right click => change role).\r\n11:25 alloy: So knowing now what Xcode actually does in the project data, I’m guessing that adding a header to the ‘public’ section of the ‘copy headers’ build phase sets the attribute.\r\n11:26 alloy: But we don’t use that build phase at all atm, because of a bug during archiving, so we just copy them all with a normal copy files phase.\r\n```","assignee":null,"id":2131071,"pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"number":42,"labels":[],"title":"Discussion log from IRC regarding Xcode and header indexing.","closed_at":null,"html_url":"https://github.com/CocoaPods/CocoaPods/issues/42","milestone":{"created_at":"2011-11-07T15:10:27Z","state":"open","due_on":null,"closed_issues":0,"creator":{"gravatar_id":"424a9ce662b059c35063b405e160461d","id":2320,"url":"https://api.github.com/users/alloy","login":"alloy","avatar_url":"https://secure.gravatar.com/avatar/424a9ce662b059c35063b405e160461d?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"number":5,"title":"0.5.0","description":"Website, guides, etc.","url":"https://api.github.com/repos/CocoaPods/CocoaPods/milestones/5","open_issues":6},"url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/42"},"action":"created","comment":{"created_at":"2011-11-20T21:56:31Z","updated_at":"2011-11-20T21:56:31Z","user":{"gravatar_id":"c11579192bd480035b95d6cc82a79907","id":258,"url":"https://api.github.com/users/kommen","login":"kommen","avatar_url":"https://secure.gravatar.com/avatar/c11579192bd480035b95d6cc82a79907?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png"},"body":"See #25 for some more info about the indexing issue and for a workaround.","id":2808808,"url":"https://api.github.com/repos/CocoaPods/CocoaPods/issues/comments/2808808"}}