{"id":571,"date":"2015-01-08T18:30:15","date_gmt":"2015-01-08T10:30:15","guid":{"rendered":"http:\/\/www.shuran.cn\/?p=571"},"modified":"2015-01-08T18:30:15","modified_gmt":"2015-01-08T10:30:15","slug":"%e6%8a%98%e8%85%bemac%e4%b8%8a%e5%ae%89%e8%a3%85nginx%e4%b8%8ephp%e7%8e%af%e5%a2%83","status":"publish","type":"post","link":"https:\/\/www.shuran.cn\/?p=571","title":{"rendered":"\u6298\u817emac\u4e0a\u5b89\u88c5nginx\u4e0ephp\u73af\u5883"},"content":{"rendered":"<p>\n\t\u95ee\u9898\u8bb0\u5f55\uff1a\n<\/p>\n<p>\n\t1\u3001\u6ca1\u6709wget\n<\/p>\n<p>\n\t&nbsp;&nbsp;&nbsp; \u7ecf\u8fc7\u641c\u7d22\uff0c\u63a8\u8350\u5b89\u88c5Homebrew\uff0c\u6216\u8005\u7528curl\n<\/p>\n<p>\n\t&nbsp;&nbsp;&nbsp;&nbsp;curl -o page.html http:\/\/www.yahoo.com\n<\/p>\n<p>\n\t&nbsp;&nbsp;&nbsp;&nbsp;Homebrew\u5b89\u88c5\u65b9\u6cd5\n<\/p>\n<pre>  ruby -e \"$(curl -fsSL https:\/\/raw.githubusercontent.com\/Homebrew\/install\/master\/install)\"\r\n&nbsp; \u7136\u540e\u8ba9\u4eba\u9ad8\u5174\u7684\u4e00\u5e55 \r\n  brew install wget\r\n\r\n2\u3001\u7f16\u8bd1nginx\r\n&nbsp;&nbsp;&nbsp;&nbsp;\r\n<pre class=\"prettyprint lang-js\">.\/configure --prefix=\/Users\/wang\/web\/nginx --conf-path=\/Users\/wang\/web\/nginx\/conf\/nginx.conf --user=nginx --group=nginx --with-http_ssl_module --with-http_flv_module --with-http_gunzip_module --with-http_gzip_static_module --with-http_stub_status_module&nbsp; --with-pcre --with-cc-opt=\"-Wno-deprecated-declarations\"<\/pre>\n<p>\u63d0\u793aaio\u4e0d\u652f\u6301\uff0c\u597d\u5427\uff0c\u53bb\u6389<\/p>\n<p>3\u3001\u5f00\u59cbmake\u602a\u4e8b\u51fa\u73b0<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<\/p>\n<pre class=\"prettyprint lang-js\">make\r\n\/Applications\/Xcode 2.app\/Contents\/Developer\/usr\/bin\/make -f objs\/Makefile\r\nmake: \/Applications\/Xcode: No such file or directory\r\nmake: *** [build] Error 1\r\nwangdeMacBook-Air:nginx-1.6.2 wang$ sudo make<\/pre>\n<p>\u4e8e\u662f\u67e5\uff0cxcode\uff1f\u6709\u4eba\u8bf4\u5b89\u88c5mac command Line Tools\uff0c\u53ef\u4ee5\u89e3\u51b3\u6ca1\u6709make\u547d\u4ee4\u95ee\u9898\u3002<br \/>\n\u5c1d\u8bd5\u65e0\u6548\uff0c\u5e94\u8be5\u662f\u88c5\u4e86xcode\uff0c\u4e14\u6709\u4e86\u547d\u4ee4\u884c\uff0c\u8fd9\u6837\u786e\u8ba4xcode\uff0d\u300bnew\uff0d\u300bproject\uff0d\u300b<\/p>\n<pre>command Line Tools<\/pre>\n<p>\u6240\u4ee5\u4e0d\u662f\u6ca1\u6709\u5b83\u5f15\u8d77\u7684\u3002<\/p>\n<p>\u518d\u641c\u7d22 \uff0c\u53d1\u73b0\u7c7b\u4f3c\u6545\u969c\uff0c\u6253\u5f00\u6807\u9898\u4e3a\u201c\u79fb\u690d\u8fc7\u6765\u7684Xcode\u8bbe\u7f6e\u8def\u5f84\u201d\u7684\u5185\u5bb9\uff0c<\/p>\n<blockquote><p>\n\t\u5982\u679c\u4f60\u7684xCode\u4e0d\u662f\u901a\u8fc7App Store\u5b89\u88c5\u7684\uff0c\u800c\u662f\u901a\u8fc7dmg\u6216\u8005\u62f7\u8d1dapp\u7684\u65b9\u5f0f\u5b89\u88c5\u3002\u6216\u8005\u4f60\u7684\u7cfb\u7edf\u91cc\u9762\u5b89\u88c5\u4e86\u591a\u4e2a\u7248\u672c\u7684Xcode\uff0c\u53ef\u80fd\u4f7f\u7528\u547d\u4ee4\u884c\u7f16\u8bd1\u7a0b\u5e8f\u7684\u65f6\u5019\u4f1a\u9047\u5230\u9ebb\u70e6\u3002<br \/>\n\u51fa\u73b0\uff1a<br \/>\ncould not stat active Xcode path \u2018\/Volumes\/Xcode\/Xcode.app\/Contents\/Developer\u2019. (No such file or directory)<br \/>\n\u89e3\u51b3\u529e\u6cd5\uff1a<br \/>\nxcode-select -switch \u65b0\u7684Xcode\u8def\u5f84<br \/>\n\u5982<br \/>\nsudo xcode-select --switch \/Applications\/Xcode.app\/Contents\/Developer <br \/>\n\u6b63\u597d\u6211\u7684\u7b26\u5408\u554a\uff0csudo find \uff0f \uff0dname make \u540e\u679c\u7136\u53d1\u73b0\u4e24\u4e2axcode\u7684app\u5e94\u7528\u3002\u679c\u65ad\u547d\u4ee4\u3002<\/p>\n<\/blockquote>\n<p>4\u3001make\u7f16\u8bd1<\/p>\n<pre class=\"prettyprint lang-js\">src\/core\/ngx_crypt.c:82:5: error: 'MD5_Init' is deprecated: first deprecated in\r\n      OS X 10.7 [-Werror,-Wdeprecated-declarations]<\/pre>\n<p>\n\u597d\uff0c\u7ed3\u679c\u9700\u8981\u5728\u7f16\u8bd1\u53c2\u6570\u4e0a\u589e\u52a0 <span style=\"background-color:#ffffff;color:#ff00ff;\">--with-cc-opt=\"-Wno-deprecated-declarations\"<\/span><br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br \/>\n5\u3001\u88c5\u4e0a\u4e86\uff0c\u8fd0\u884c\u4e4b<br \/>\n&nbsp;&nbsp;&nbsp; \u5b89\u88c5\u76ee\u5f55\u4e0b\u6267\u884c.\/nginx<br \/>\n&nbsp;&nbsp;&nbsp;&nbsp;nginx: [emerg] getgrnam() failed&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br \/>\n&nbsp;&nbsp;<br \/>\n&nbsp; <\/p>\n<p><\/p>\n<p>\n\t<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u95ee\u9898\u8bb0\u5f55\uff1a 1\u3001\u6ca1\u6709wget &nbsp;&nbsp;&nbsp; \u7ecf\u8fc7\u641c\u7d22\uff0c\u63a8\u8350\u5b89\u88c5Homebrew\uff0c\u6216\u8005\u7528\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.shuran.cn\/?p=571\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9,10],"tags":[],"class_list":["post-571","post","type-post","status-publish","format-standard","hentry","category-php","category-os"],"_links":{"self":[{"href":"https:\/\/www.shuran.cn\/index.php?rest_route=\/wp\/v2\/posts\/571","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.shuran.cn\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.shuran.cn\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.shuran.cn\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.shuran.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=571"}],"version-history":[{"count":1,"href":"https:\/\/www.shuran.cn\/index.php?rest_route=\/wp\/v2\/posts\/571\/revisions"}],"predecessor-version":[{"id":572,"href":"https:\/\/www.shuran.cn\/index.php?rest_route=\/wp\/v2\/posts\/571\/revisions\/572"}],"wp:attachment":[{"href":"https:\/\/www.shuran.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=571"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.shuran.cn\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=571"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.shuran.cn\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=571"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}