{"action":"created","issue":{"url":"https://api.github.com/repos/android-ndk/ndk/issues/656","repository_url":"https://api.github.com/repos/android-ndk/ndk","labels_url":"https://api.github.com/repos/android-ndk/ndk/issues/656/labels{/name}","comments_url":"https://api.github.com/repos/android-ndk/ndk/issues/656/comments","events_url":"https://api.github.com/repos/android-ndk/ndk/issues/656/events","html_url":"https://github.com/android-ndk/ndk/issues/656","id":306401675,"number":656,"title":"NDK headers could validate __ANDROID_API__","user":{"login":"alexcohn","id":736435,"avatar_url":"https://avatars1.githubusercontent.com/u/736435?v=4","gravatar_id":"","url":"https://api.github.com/users/alexcohn","html_url":"https://github.com/alexcohn","followers_url":"https://api.github.com/users/alexcohn/followers","following_url":"https://api.github.com/users/alexcohn/following{/other_user}","gists_url":"https://api.github.com/users/alexcohn/gists{/gist_id}","starred_url":"https://api.github.com/users/alexcohn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexcohn/subscriptions","organizations_url":"https://api.github.com/users/alexcohn/orgs","repos_url":"https://api.github.com/users/alexcohn/repos","events_url":"https://api.github.com/users/alexcohn/events{/privacy}","received_events_url":"https://api.github.com/users/alexcohn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-03-19T10:15:51Z","updated_at":"2018-05-03T17:37:57Z","closed_at":null,"author_association":"NONE","body":"#### To avoid some common mistakes, extra compiler checks may be helpful\r\n\r\nFor example, [this question](https://stackoverflow.com/q/49311595/192373) has a subtle and quite understandable mistake: they used ` -D__ANDROID_API__=android-21` instead of ` -D__ANDROID_API__=21`. \r\n\r\nThe Unified Header logic relies heavily on this define. It could be rather easy to perform a quick check that **__ANDROID_API__** is defined and is one of numbers supported by the current NDK release (e.g., at least 14 for r16; maybe, at least 21 for r16 for 64-bit toolchain).\r\n\r\n#### Environment Details\r\n\r\n* NDK Version: 16 and up"},"comment":{"url":"https://api.github.com/repos/android-ndk/ndk/issues/comments/386376505","html_url":"https://github.com/android-ndk/ndk/issues/656#issuecomment-386376505","issue_url":"https://api.github.com/repos/android-ndk/ndk/issues/656","id":386376505,"user":{"login":"DanAlbert","id":315852,"avatar_url":"https://avatars3.githubusercontent.com/u/315852?v=4","gravatar_id":"","url":"https://api.github.com/users/DanAlbert","html_url":"https://github.com/DanAlbert","followers_url":"https://api.github.com/users/DanAlbert/followers","following_url":"https://api.github.com/users/DanAlbert/following{/other_user}","gists_url":"https://api.github.com/users/DanAlbert/gists{/gist_id}","starred_url":"https://api.github.com/users/DanAlbert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DanAlbert/subscriptions","organizations_url":"https://api.github.com/users/DanAlbert/orgs","repos_url":"https://api.github.com/users/DanAlbert/repos","events_url":"https://api.github.com/users/DanAlbert/events{/privacy}","received_events_url":"https://api.github.com/users/DanAlbert/received_events","type":"User","site_admin":false},"created_at":"2018-05-03T17:37:57Z","updated_at":"2018-05-03T17:37:57Z","author_association":"OWNER","body":"I don't remember for sure, but probably r14 or r15?"}}
{"actor":{"display_login":"DanAlbert"}}