{"id":4590,"date":"2019-12-13T14:01:35","date_gmt":"2019-12-13T06:01:35","guid":{"rendered":"https:\/\/www.xttblog.com\/?p=4590"},"modified":"2019-12-13T14:01:35","modified_gmt":"2019-12-13T06:01:35","slug":"mac-%e4%b8%8b%e7%9a%84-ab-%e6%b5%8b%e8%af%95%e5%b7%a5%e5%85%b7%e5%ae%89%e8%a3%85%ef%bc%8c%e4%bb%a5%e5%8f%8a-configure-error-apr-not-found-%e9%97%ae%e9%a2%98%e8%a7%a3%e5%86%b3","status":"publish","type":"post","link":"https:\/\/www.xttblog.com\/?p=4590","title":{"rendered":"Mac \u4e0b\u7684 ab \u6d4b\u8bd5\u5de5\u5177\u5b89\u88c5\uff0c\u4ee5\u53ca configure: error: APR not found \u95ee\u9898\u89e3\u51b3"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Mac \u4e0b\u7684 ab \u6d4b\u8bd5\u5de5\u5177\u5b89\u88c5\uff0c\u4ee5\u53ca configure: error: APR not found \u95ee\u9898\u89e3\u51b3<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">ab \u6d4b\u8bd5\u5de5\u5177\u5f88\u591a\u4eba\u53ef\u80fd\u90fd\u542c\u8bf4\u8fc7\uff0c\u662f\u9ad8\u5e76\u53d1\u6d4b\u8bd5\u5fc5\u4f1a\u7684\u6d4b\u8bd5\u5de5\u5177\u4e86\u3002\u4eca\u5929\u6211\u5728 Mac \u4e0b\u5b89\u88c5\u8fd9\u4e2a\u5de5\u5177\u65f6\uff0c\u53d1\u751f\u4e86\u4e00\u4e9b\u9519\u8bef\uff0c\u6211\u8fd9\u91cc\u8bb0\u5f55\u4e00\u4e0b\uff0c\u65b9\u4fbf\u5176\u4ed6\u4eba\u907f\u514d\u8df3\u5751\uff01<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">ab \u6d4b\u8bd5\u5de5\u5177\u6211\u4eec\u53ef\u4ee5\u5230 http:\/\/httpd.apache.org\/download.cgi \u4e0b\u8f7d\uff0c\u4e00\u822c\u9009\u62e9\u6700\u65b0\u7a33\u5b9a\u7248\u7684 tar.gz \u5305\u5373\u53ef\u3002\u53e6\u5916\u5b89\u88c5 ab \u5de5\u5177\u8fd8\u9700\u8981\u4f9d\u8d56 3 \u4e2a\u5176\u4ed6\u7ec4\u5efa\uff1aapr\u3001apr-util\u3001pcre\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">apr \u548c apr-util \u7ec4\u4ef6\u7684\u90fd\u53ef\u4ee5\u5728\uff1ahttp:\/\/apr.apache.org\/download.cgi \u4e0a\u4e0b\u8f7d\u3002pcre \u7684\u4e0b\u8f7d\u5730\u5740\u5728 https:\/\/ftp.pcre.org\/pub\/pcre\/\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">4 \u4e2a\u5305\u90fd\u4e0b\u8f7d\u5b8c\u6210\u540e\uff0c\u6211\u4eec\u5c31\u53ef\u4ee5\u5f00\u59cb\u7f16\u8bd1\u5b89\u88c5\u4e86\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u8981\u6ce8\u610f\u7684\u662f\uff0c\u6709\u4e9b\u535a\u5ba2\u6587\u7ae0\u4e2d\u63cf\u8ff0\u5728 Mac \u4e2d\uff0c\u76f4\u63a5\u4f7f\u7528 homebrew \u6765\u5b89\u88c5\uff0c\u4f46\u662f\u8fd9\u79cd\u65b9\u5f0f\u5728 iTerm \u4e2d\u4f1a\u76f4\u63a5\u62a5\u9519\u3002\u63d0\u793a\uff1a\u201cconfigure: error: APR not found.  Please read the documentation.\u201d\u3002<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><img decoding=\"async\" src=\"https:\/\/images.weserv.nl\/?url=https:\/\/wx2.sinaimg.cn\/mw690\/8fa5dcfcgy1g9v1iz3dewj20pm0d4tas.jpg\" alt=\"\" \/><figcaption>configure: error: APR not found.  Please read the documentation.<\/figcaption><\/figure><\/div>\n\n\n\n<p class=\"wp-block-paragraph\">\u6240\u4ee5\uff0c\u6211\u8fd8\u662f\u5efa\u8bae\uff0c\u5927\u5bb6\u6309\u7167\u6211\u7684\u65b9\u5f0f\u6765\u5b89\u88c5 ab \u6d4b\u8bd5\u5de5\u5177\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u73b0\u5728\uff0c\u6211\u4eec\u9488\u5bf9\u4e0a\u9762\u7684 4 \u4e2a\u5305\u8fdb\u884c\u89e3\u538b\uff08tar -zxvf [\u5b89\u88c5\u5305\u7684\u540d\u5b57]\uff09\uff0c\u89e3\u538b\u540e\u7684\u6587\u4ef6\u5bf9\u5e94\u4f4d\u7f6e\u5206\u522b\u5982\u4e0b\uff1a<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">httpd: \/usr\/local\/httpd\/<br>apr: \/usr\/local\/apr\/<br>apr-util: \/usr\/local\/apr-util\/<br>pcre: \/usr\/local\/pcre\/<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u6ce8\u610f\uff0c\u8fd9 4 \u4e2a\u76ee\u5f55\uff0c\u4f60\u53ef\u4ee5\u5148\u8fdb\u884c\u521b\u5efa\uff0c\u540c\u65f6\u6ce8\u610f\u76ee\u5f55\u6743\u9650\u3002<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">\u7136\u540e\uff0c\u6211\u4eec\u5206\u522b\u8fdb\u5165\u8fd9 4 \u4e2a\u76ee\u5f55\u4e2d\uff0c\u8fdb\u884c\u7f16\u8bd1\u5b89\u88c5\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>#1\u3001\u8fdb\u5165apr\u89e3\u538b\u76ee\u5f55\n#--prefix \u53c2\u6570\u5c31\u662f\u6211\u4eec\u4e0a\u9762\u8981\u7f16\u8bd1\u5230\u7684\u8def\u5f84\n.\/configure --prefix=\/usr\/local\/apr \nmake\nmake install\n\n#2\u3001\u8fdb\u5165apr-util\u89e3\u538b\u76ee\u5f55,\u8fd9\u4e2a\u5b89\u88c5\u5305\u4f9d\u8d56apr\n.\/configure --prefix=\/usr\/local\/apr-util -with-apr=\/usr\/local\/apr\/\nmake\nmake install\n\n#3\u3001\u8fdb\u5165pcre\u89e3\u538b\u76ee\u5f55\n.\/configure --prefix=\/usr\/local\/apr-pcre\nmake\nmake install\n\n#4\u3001\u8fdb\u5165\u5230httpd\u7684\u89e3\u538b\u76ee\u5f55\n.\/configure --prefix=\/usr\/local\/httpd\/ -with-apr=\/usr\/local\/apr -with-apr-util=\/usr\/local\/apr-util\/ -with-pcre=\/usr\/local\/pcre\/\nmake\nmake install<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u8fd9\u6837 Mac \u4e0b\u7684 ab \u6d4b\u8bd5\u5de5\u5177\u5c31\u5b89\u88c5\u5b8c\u6210\u4e86\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>ab -n 10 -c 10 https:\/\/www.baidu.com:80\/<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\u4f7f\u7528 ab \u6d4b\u8bd5\u6a21\u62df\u5ba2\u6237\u7aef\u8fde\u7eed\u8bbf\u95ee 10 \u6b21\u767e\u5ea6\u3002<\/p>\n<!-- <audio autoplay=\"autoplay\" height=\"100\" width=\"100\" hidden=\"true\"><source src=\"https:\/\/c.coka.la\/orAvPR.mp3\" type=\"audio\/mp3\"\/><\/audio><img decoding=\"async\" src=\"https:\/\/images.weserv.nl\/?url=https:\/\/ws3.sinaimg.cn\/large\/8fa5dcfcgy1g4em3rzar5j20ib089ae0.jpg\" alt=\"\u4e1a\u4f59\u8349\u516c\u4f17\u53f7\"\/> --><p><!-- <img decoding=\"async\" src=\"https:\/\/raw.githubusercontent.com\/xmt1139057136\/xttblog\/master\/8fa5dcfcgy1g4em3rzar5j20ib089ae0.jpg\" alt=\"\u4e1a\u4f59\u8349\u516c\u4f17\u53f7\"\/>--><img decoding=\"async\" src=\"https:\/\/saas.51autoparts.cn\/api\/admin\/sys-file\/oss\/file?fileName=84db51f8561e448f9a4fda2eff0811f9.jpg\" alt=\"\u4e1a\u4f59\u8349\u516c\u4f17\u53f7\"\/><\/p><p>\u6700\u540e\uff0c\u6b22\u8fce\u5173\u6ce8\u6211\u7684\u4e2a\u4eba\u5fae\u4fe1\u516c\u4f17\u53f7\uff1a\u4e1a\u4f59\u8349\uff08yyucao\uff09\uff01<b>\u53ef\u52a0\u4f5c\u8005\u5fae\u4fe1\u53f7\uff1a<font color=\"red\">xttblog2<\/font>\u3002\u5907\u6ce8\uff1a\u201c1\u201d\uff0c\u6dfb\u52a0\u535a\u4e3b\u5fae\u4fe1\u62c9\u4f60\u8fdb\u5fae\u4fe1\u7fa4\u3002\u5907\u6ce8\u9519\u8bef\u4e0d\u4f1a\u540c\u610f\u597d\u53cb\u7533\u8bf7\u3002<\/b>\u518d\u6b21\u611f\u8c22\u60a8\u7684\u5173\u6ce8\uff01\u540e\u7eed\u6709\u7cbe\u5f69\u5185\u5bb9\u4f1a\u7b2c\u4e00\u65f6\u95f4\u53d1\u7ed9\u60a8\uff01\u539f\u521b\u6587\u7ae0\u6295\u7a3f\u8bf7\u53d1\u9001\u81f3532009913@qq.com\u90ae\u7bb1\u3002\u5546\u52a1\u5408\u4f5c\u4e5f\u53ef\u6dfb\u52a0\u4f5c\u8005\u5fae\u4fe1\u8fdb\u884c\u8054\u7cfb\uff01<\/p><p>\u672c\u6587\u539f\u6587\u51fa\u5904\uff1a<a href=\"https:\/\/www.xttblog.com\">\u4e1a\u4f59\u8349<\/a>\uff1a &raquo; <a href=\"https:\/\/www.xttblog.com\/?p=4590\">Mac \u4e0b\u7684 ab \u6d4b\u8bd5\u5de5\u5177\u5b89\u88c5\uff0c\u4ee5\u53ca configure: error: APR not found \u95ee\u9898\u89e3\u51b3<\/a><\/p><!-- <div class=\"bd-reward-stl\"><button id=\"bdRewardBtn\"><span><\/span><\/button><\/div> -->","protected":false},"excerpt":{"rendered":"<p>Mac \u4e0b\u7684 ab \u6d4b\u8bd5\u5de5\u5177\u5b89\u88c5\uff0c\u4ee5\u53ca configure: error: APR not found \u95ee\u9898\u89e3 [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,6],"tags":[169,1940,1939,568,502],"class_list":["post-4590","post","type-post","status-publish","format-standard","hentry","category-java","category-yyzt","tag-jmeter","tag-1940","tag-1939","tag-568","tag-502"],"_links":{"self":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts\/4590","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4590"}],"version-history":[{"count":1,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts\/4590\/revisions"}],"predecessor-version":[{"id":4591,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=\/wp\/v2\/posts\/4590\/revisions\/4591"}],"wp:attachment":[{"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4590"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4590"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.xttblog.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4590"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}