{"action":"created","issue":{"url":"https://api.github.com/repos/jedisct1/libsodium/issues/308","labels_url":"https://api.github.com/repos/jedisct1/libsodium/issues/308/labels{/name}","comments_url":"https://api.github.com/repos/jedisct1/libsodium/issues/308/comments","events_url":"https://api.github.com/repos/jedisct1/libsodium/issues/308/events","html_url":"https://github.com/jedisct1/libsodium/issues/308","id":112825617,"number":308,"title":"Libsodium does not compile for Solaris CC compiler","user":{"login":"dtorelliitrsgroup","id":13622316,"avatar_url":"https://avatars.githubusercontent.com/u/13622316?v=3","gravatar_id":"","url":"https://api.github.com/users/dtorelliitrsgroup","html_url":"https://github.com/dtorelliitrsgroup","followers_url":"https://api.github.com/users/dtorelliitrsgroup/followers","following_url":"https://api.github.com/users/dtorelliitrsgroup/following{/other_user}","gists_url":"https://api.github.com/users/dtorelliitrsgroup/gists{/gist_id}","starred_url":"https://api.github.com/users/dtorelliitrsgroup/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dtorelliitrsgroup/subscriptions","organizations_url":"https://api.github.com/users/dtorelliitrsgroup/orgs","repos_url":"https://api.github.com/users/dtorelliitrsgroup/repos","events_url":"https://api.github.com/users/dtorelliitrsgroup/events{/privacy}","received_events_url":"https://api.github.com/users/dtorelliitrsgroup/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-10-22T15:14:49Z","updated_at":"2015-10-22T15:40:25Z","closed_at":null,"body":"I have downloaded the version 1.0.4 and realize that does not compile for Solaris CC compiler due to the following problems:\r\n\r\n*export.h*\r\n**__global attribute should be defined as __attribute__(visibility(__global))**\r\npatch for export:\r\n```c\r\n#  if defined(__SUNPRO_C)\r\n#   ifndef __GNU_C__\r\n#    define SODIUM_EXPORT __attribute__(visibility(__global))\r\n#   else\r\n#    define SODIUM_EXPORT __attribute__ __global\r\n#   endif\r\n#  elif defined(_MSG_VER)\r\n#   define SODIUM_EXPORT extern __declspec(dllexport)\r\n#  else\r\n#   define SODIUM_EXPORT __attribute__ ((visibility (\"default\")))\r\n#  endif\r\n# endif\r\n```\r\n\r\n*blake2.h and crypto_generichash_blake2b.h*\r\n**pragma pack only takes one argument for Solaris CC compiler**\r\npatch for pragma push\r\n```c\r\n#ifndef __sun\r\n#pragma pack(push, 1)\r\n#else\r\n# ifndef __GNU_C__\r\n#pragma pack(1)\r\n# else\r\n#pragma pack(push, 1)\r\n# endif\r\n#endif\r\n```\r\npatch for pragma pop\r\n```c\r\n#ifndef __sun\r\n#pragma pack(pop)\r\n#else\r\n# ifndef __GNU_C__\r\n#  pragma pack()\r\n# else\r\n#  pragma pack(pop)\r\n# endif\r\n#endif\r\n```"},"comment":{"url":"https://api.github.com/repos/jedisct1/libsodium/issues/comments/150266024","html_url":"https://github.com/jedisct1/libsodium/issues/308#issuecomment-150266024","issue_url":"https://api.github.com/repos/jedisct1/libsodium/issues/308","id":150266024,"user":{"login":"jedisct1","id":124872,"avatar_url":"https://avatars.githubusercontent.com/u/124872?v=3","gravatar_id":"","url":"https://api.github.com/users/jedisct1","html_url":"https://github.com/jedisct1","followers_url":"https://api.github.com/users/jedisct1/followers","following_url":"https://api.github.com/users/jedisct1/following{/other_user}","gists_url":"https://api.github.com/users/jedisct1/gists{/gist_id}","starred_url":"https://api.github.com/users/jedisct1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jedisct1/subscriptions","organizations_url":"https://api.github.com/users/jedisct1/orgs","repos_url":"https://api.github.com/users/jedisct1/repos","events_url":"https://api.github.com/users/jedisct1/events{/privacy}","received_events_url":"https://api.github.com/users/jedisct1/received_events","type":"User","site_admin":false},"created_at":"2015-10-22T15:40:25Z","updated_at":"2015-10-22T15:40:25Z","body":"This is a bit confusing:\r\n\r\n```c\r\n#  if defined(__SUNPRO_C)\r\n#   ifndef __GNU_C__\r\n```\r\n\r\nDoes that compiler also define `__GNU_C__` ?\r\n"}}