{"id":986,"date":"2023-03-12T00:21:40","date_gmt":"2023-03-11T16:21:40","guid":{"rendered":"https:\/\/www.appblog.cn\/?p=986"},"modified":"2023-04-29T13:23:07","modified_gmt":"2023-04-29T05:23:07","slug":"android-compile-openssl-library-error-ui-openssl-c-function-read-string-inner","status":"publish","type":"post","link":"https:\/\/www.appblog.cn\/index.php\/2023\/03\/12\/android-compile-openssl-library-error-ui-openssl-c-function-read-string-inner\/","title":{"rendered":"Android\u7f16\u8bd1OpenSSL\u5e93\u62a5\u9519ui_openssl.c:function read_string_inner"},"content":{"rendered":"<p>\u53c2\u8003\uff1a<a target=\"_blank\" rel=\"noopener\" href=\"https:\/\/wiki.openssl.org\/index.php\/Android\">https:\/\/wiki.openssl.org\/index.php\/Android<\/a><\/p>\n<p>\u5728Android NDK\u73af\u5883\u4e0b\u7f16\u8bd1OpenSSL\uff0c\u57fa\u672c\u6ca1\u6709\u9047\u5230\u4ec0\u4e48\u95ee\u9898\uff0c\u4f46\u662f\u5728\u4f7f\u7528\u7f16\u8bd1\u7684OpenSSL\u5e93\u65f6\uff0c\u9047\u5230\u5982\u4e0b\u9519\u8bef\uff1a<\/p>\n<pre><code>ui_openssl.c:function read_string_inner: error: undefined reference to &#039;signal&#039;<\/code><\/pre>\n<p><!-- more --><\/p>\n<p>\u89e3\u51b3\u529e\u6cd5\uff1a<\/p>\n<pre><code>APP_PLATFORM := android-21<\/code><\/pre>\n<p>\u5982\u679c\u60f3\u57284.x\u4e0a\u4e5f\u53ef\u4ee5\u4f7f\u7528\uff0c\u7ecf\u8fc7\u4e00\u756a\u641c\u7d22\uff0c<a target=\"_blank\" rel=\"noopener\" href=\"http:\/\/stackoverflow.com\/questions\/28740315\/android-ndk-getting-java-lang-unsatisfiedlinkerror-dlopen-failed-cannot-loca#answer-28769262\" title=\"stackoverflow.com\">\u8fd9\u91cc<\/a><br \/>\n\u8bf4\u5230\u4e86\u95ee\u9898\u7684\u5173\u952e\uff0c\u539f\u6765\u5728API 21\u4e4b\u524d\uff0csignal\u662finline\u65b9\u5f0f\u7684\uff0cAPI 21\u4e4b\u540e\u624d\u4e0d\u662finline\u3002\u5982\u4e0b\uff1a<\/p>\n<pre><code>\/\/ android-19\n\n\/* the default is bsd *\/\nstatic __inline__ __sighandler_t signal(int s, __sighandler_t f)\n{\n    return bsd_signal(s,f);\n}\n\n\/\/android-21\nextern sighandler_t signal(int, sighandler_t);<\/code><\/pre>\n<p>\u627e\u5230\u4e86\u539f\u56e0\uff0c\u90a3\u4e48\u89e3\u51b3\u529e\u6cd5\u5c31\u662f\uff0c\u5c06OpenSSL\u4f7f\u7528\u4f4e\u7248\u672c\u7684API\u65b9\u5f0f\u7f16\u8bd1\uff0c\u8fd9\u6837\u5c31\u4f1a\u4f7f\u7528inline\u65b9\u5f0f\uff0c\u540e\u7eed\u518d\u5f15\u7528\u65f6\uff0c\u4e0d\u4f1a\u518d\u8fdb\u884c\u94fe\u63a5\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u53c2\u8003\uff1ahttps:\/\/wiki.openssl.org\/index.php\/Android \u5728Android  [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[146],"class_list":["post-986","post","type-post","status-publish","format-standard","hentry","category-android-ndk","tag-openssl"],"_links":{"self":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/986","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/comments?post=986"}],"version-history":[{"count":0,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/986\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=986"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=986"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=986"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}