{"id":297,"date":"2023-02-04T14:08:25","date_gmt":"2023-02-04T06:08:25","guid":{"rendered":"http:\/\/39.104.58.144\/?p=297"},"modified":"2023-02-07T19:35:02","modified_gmt":"2023-02-07T11:35:02","slug":"gcc-12-2-0","status":"publish","type":"post","link":"http:\/\/www.algmain.com\/index.php\/2023\/02\/04\/gcc-12-2-0\/","title":{"rendered":"\u5347\u7ea7\u81f3Gcc-12.2.0"},"content":{"rendered":"\n<p>\u9996\u5148<a href=\"https:\/\/ftp.gnu.org\/gnu\/gcc\/gcc-12.2.0\/gcc-12.2.0.tar.gz\">\u4e0b\u8f7dGcc-12.2.0.tar.gz<\/a>\u6570\u636e\u5305\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#cd \/usr\/local\/src\n......\n#wget https:\/\/ftp.gnu.org\/gnu\/gcc\/gcc-12.2.0\/gcc-12.2.0.tar.gz\n......\n<\/pre><\/div>\n\n\n<p>\u89e3\u538b\u7f29\u6570\u636e\u5305\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#tar xf gcc-12.2.0.tar.gz\n......\n<\/pre><\/div>\n\n\n<p>\u8bbe\u7f6e\u7f16\u8bd1\u73af\u5883\u548c\u9009\u9879\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#cd gcc-12.2.0\n......\n#.\/contrib \/download_prerequisties\n......\n\n#mkdir build\n......\n#cd build\n......\n#.\/configure --enable-languages=c,c++ --disable-multilib\n......\n<\/pre><\/div>\n\n\n<p>\u7531\u4e8e\u901f\u5ea6\u8f83\u6162\uff0c\u9700\u8981\u8010\u5fc3\u7b49\u5f85\u6240\u6709\u547d\u4ee4\u5b8c\u6210\u3002<\/p>\n\n\n\n<p><em>\u6ce8\u610f\uff1a\u8fd9\u91cc\u4f7f\u7528\u7684\u662f\u7f3a\u7701\u76ee\u5f55\u9879\u914d\u7f6e\u3002\u5982\u679c\u5bf9Linux\u4e0d\u719f\u6089\uff0c\u8bf7\u5c3d\u91cf\u4f7f\u7528\u7f3a\u7701\u914d\u7f6e\u3002<\/em><\/p>\n\n\n\n<p>\u5f00\u59cb\u7f16\u8bd1\u548c\u5b89\u88c5\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#make\n......\n#make install\n......\n<\/pre><\/div>\n\n\n<p>\u8fd9\u4e2a\u8fc7\u7a0b\u5341\u5206\u6f2b\u957f\uff0c\u53ef\u80fd\u4f1a\u8017\u65f68\u4e2a\u5c0f\u65f6\u5de6\u53f3\u3002\u9700\u8981\u8010\u5fc3\u7b49\u5f85\u6240\u6709\u547d\u4ee4\u6267\u884c\u5b8c\u6bd5\u3002<\/p>\n\n\n\n<p>\u5148\u5efa\u7acb\u4e00\u4e2a\u5907\u4efd\u76ee\u5f55\uff0c\u5c06\u539f\u6709\u7684\u6307\u4ee4\u79fb\u52a8\u5230\u5907\u4efd\u76ee\u5f55\u4e2d\u3002<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#mkdir \/usr\/bin\/backup\n......\n#mv \/usr\/bin\/gcc \/usr\/bin\/backup\/\n......\n#mv \/usr\/bin\/g++ \/usr\/bin\/backup\/\n......\n<\/pre><\/div>\n\n\n<p>\u5efa\u7acb\u8f6f\u94fe\u63a5\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#ln -s \/usr\/local\/bin\/gcc \/usr\/bin\/gcc\n......\n#ln -s \/usr\/local\/bin\/g++ \/usr\/bin\/g++\n......\n<\/pre><\/div>\n\n\n<p>\u68c0\u67e5\u8f6f\u94fe\u63a5\uff1a<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n# gcc --version\ngcc (GCC) 12.2.0\nCopyright (C) 2022 Free Software Foundation, Inc.\nThis is free software; see the source for copying conditions.  There is NO\nwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n\n......\n# g++ --version\ng++ (GCC) 12.2.0\nCopyright (C) 2022 Free Software Foundation, Inc.\nThis is free software; see the source for copying conditions.  There is NO\nwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.\n......\n<\/pre><\/div>\n\n\n<p>\u6b64\u65f6\u6253\u5370\u7684\u7248\u672c\u53f7\uff0c\u5e94\u662f\u6700\u65b0\u7684Gcc\u7248\u672c\u53f7\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u9996\u5148\u4e0b\u8f7dGcc-12.2.0.tar.gz\u6570\u636e\u5305\uff1a \u89e3\u538b\u7f29\u6570\u636e\u5305\uff1a \u8bbe\u7f6e\u7f16\u8bd1\u73af\u5883\u548c\u9009\u9879\uff1a \u7531\u4e8e\u901f\u5ea6\u8f83\u6162\uff0c\u9700\u8981\u8010 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[11,29,28,10],"class_list":["post-297","post","type-post","status-publish","format-standard","hentry","category-technology","tag-centos","tag-g","tag-gcc","tag-linux"],"_links":{"self":[{"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/posts\/297"}],"collection":[{"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/comments?post=297"}],"version-history":[{"count":3,"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/posts\/297\/revisions"}],"predecessor-version":[{"id":734,"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/posts\/297\/revisions\/734"}],"wp:attachment":[{"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/media?parent=297"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/categories?post=297"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.algmain.com\/index.php\/wp-json\/wp\/v2\/tags?post=297"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}