Bug 140444 - [patch] New Traditional Chinese translation of custom-gcc
Summary: [patch] New Traditional Chinese translation of custom-gcc
Status: Open
Alias: None
Product: Documentation
Classification: Unclassified
Component: Documentation (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-doc mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-10 14:10 UTC by Denny Lin
Modified: 2018-01-03 05:16 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Denny Lin 2009-11-10 14:10:02 UTC
New Traditional Chinese translation of "Using newer version of GCC and binutils with the FreeBSD Ports Collection."

Should be put in doc/zh_TW.Big5/articles/custom-gcc.

The attached files are also available at http://security-hole.info/~dennylin93/doc/zh_TW.Big5/articles/custom-gcc/.

Fix: 

<!DOCTYPE article PUBLIC "-//FreeBSD//DTD DocBook V4.1-Based Extension//EN" [
<!ENTITY % articles.ent PUBLIC "-//FreeBSD//ENTITIES DocBook FreeBSD Articles Entity Set//EN">
%articles.ent;
]>

<article>
  <articleinfo>
    <title>éå &os; Ports Collection 使ç¨æ°çæ¬ç <application>GCC</application>
      è <application>binutils</application></title>

    <author>
      <firstname>Martin</firstname>
      <surname>Matuska</surname>
      <affiliation>
	<address><email>mm@FreeBSD.org</email></address>
      </affiliation>
    </author>

    <pubdate>$FreeBSD$</pubdate>

    <legalnotice id="trademarks" role="trademarks">
      &tm-attrib.freebsd;
      &tm-attrib.general;
    </legalnotice>

    <copyright>
      <year>2009</year>
      <holder>The &os; Documentation Project</holder>
    </copyright>

    <abstract>
      <para>æ­¤ç¯æ件說æäºå¦ä½å¾ &os; ports tree 使ç¨æ°çæ¬ç
	<application>GCC</application> 編譯å¨è
	<application>binutils</application>ã
	èªè¨ç <application>GCC</application> 設å®ä¹æ¯æ¬æ件è¨è«ç¯åã</para>
    </abstract>
  </articleinfo>

  <sect1 id="intro">
    <title>ç°¡ä»</title>

    <para>å¨ &os; 8.0 裡ï¼ç³»çµ±é è¨­ç編譯å¨çº <application>GCC</application>
      çæ¬ 4.2.1ãé¤æ­¤ä¹å¤ï¼ç³»çµ±æ¬èº«ä¹å«æ <application>binutils</application>
      çæ¬ 2.15ãéäºçæ¬å·²ç¶åºå¹¾å¹´äºï¼ä¸ä¸æ¯æ´æ°ç CPU æ令éï¼å¦
      <acronym>SSSE3</acronym>ã<acronym>SSE4.1</acronym>ã<acronym>SSE4.2</acronym>
      ç­ãç¤æ¼è¨±å¯è­çéä¿ï¼éäºç¨å¼è¼æ°ççæ¬ä¸¦ä¸æ被移æ¤å°ç³»çµ±å§ã幸好ï¼ä»ç¶å¯ä»¥éé
      &os; ports tree 使ç¨æ°çæ¬ç <application>GCC</application> 編譯å¨ï¼å¦ï¼çæ¬
      4.4ï¼ã</para>
  </sect1>

  <sect1 id="prerequisites">
    <title>åæ</title>

    <sect2 id="installing-binutils">
      <title>å¾ ports å®è£ binutils</title>

      <para>è¥è¦ä½¿ç¨ææ <application>GCC</application>
	æ°çæ¬çåè½ï¼å¿é å®è£ææ°çæ¬ç <application>binutils</application>ã
	éç¶å®è£æ°çæ¬ç <application>binutils</application>
	éå¿è¦æ¢ä»¶ï¼ä½è¥æ²æå®è£ï¼å°ç¡æ³ä½¿ç¨æ° <acronym>CPU</acronym>
	çæ令éã</para>

      <para>è¥è¦å¾ &os; ports tree å®è£ææ°çæ¬ç
	<application>binutils</application>ï¼è«ä¸ï¼

      <screen>&prompt.root; <userinput>cd /usr/ports/devel/binutils && make install</userinput></screen>
    </sect2>

    <sect2 id="installing-gcc">
      <title>å¾ ports å®è£ GCC</title>

      <para>&os; ports tree æä¾äºæ¸ç¨®æ°çæ¬ç
	<application>GCC</application>ãä¸é¢çç¯ä¾æ¯ä½¿ç¨ç©©å®ç 4.4
	çæ¬ãä½æ¯ï¼å¯ä»¥å®è£ä¹åææ´æ°ççæ¬ï¼å¦ï¼
	<filename role="package">lang/gcc43</filename> æ
	<filename role="package">lang/gcc45</filename>ï¼ã</para>

      <para>è¥è¦å®è£ä¸é¢æå°ç <application>GCC</application>
	ports ä¹ä¸ï¼è«ä¸ï¼

      <screen>&prompt.root; <userinput>cd /usr/ports/lang/<replaceable>gcc44</replaceable> && make install</userinput></screen>
    </sect2>
  </sect1>

  <sect1 id="configuring-ports-gcc">
    <title>è¨­å® ports 使ç¨èªè¨çæ¬ç
      <application>GCC</application></title>

    <para>使ç¨å¾ &os; ports tree å®è£ç <application>GCC</application>
      ä¹åï¼å¿é ååä¸äºé¡å¤ç設å®ã<para>

    <sect2 id="adjusting-make.conf">
      <title>èª¿æ´ <filename>make.conf</filename></title>

      <para>å°ä¸åå¹¾è¡å å¥
	<filename>/etc/make.conf</filename>
	æªæ¡ï¼è¦ææ³èª¿æ´ï¼ï¼</para>

      <programlisting>.if !empty(.CURDIR:M/usr/ports/*) && exists(/usr/local/bin/gcc44)
CC=gcc44
CXX=g++44
CPP=cpp44
.endif</programlisting>

      <para>æ­¤å¤ï¼å¯ä»¥æå設è®æ¸
	<envar>${CC}</envar> è <envar>${CPP}</envar>ã</para>

      <note>
	<para>ä¸é¢çç¯è£¡æ¯çµ¦ <application>GCC</application>
	  çæ¬ 4.4ãè¥è¦ä½¿ç¨ <command>gcc43</command> å°
	  <literal>ãgcc44ã</literal> æ¿ææ <literal>ãgcc43ã</literal>ã
	  <literal>ã4.4ã</literal> æ¿ææ <literal>ã4.3ã</literal>ï¼ä»¥æ­¤é¡æ¨ã</para>
      </note>
    </sect2>

    <sect2 id="adjusting-libmap.conf">
      <title>èª¿æ´ <filename>libmap.conf</filename></title>

      <para>è¨±å¤ ports çå·è¡æªè libraries æé£çµå° libgcc_s
	æ libstdc++ã系統已æå§å»ºéäº librariesï¼ä½æ¯æ¯
	å°±çæ¬ç <application>GCC</application>ï¼çæ¬ 4.2.1ï¼ã
	rtldï¼å lddï¼æ­£ç¢ºççæ¬ï¼å°ä¸åå¹¾è¡å å¥
	<filename>/etc/libmap.conf</filename> æªæ¡ï¼è¦ææ³èª¿æ´ï¼ï¼</para>

      <programlisting>libgcc_s.so.1   gcc44/libgcc_s.so.1
libgomp.so.1    gcc44/libgomp.so.1
libobjc.so.3    gcc44/libobjc.so.2
libssp.so.0     gcc44/libssp.so.0
libstdc++.so.6  gcc44/libstdc++.so.6</programlisting>

      <note>
	<para>ä¸é¢çç¯ä¾æ¯éå° <application>GCC</application>
	  çæ¬ 4.4ãè¥è¦ä½¿ç¨ <command>gcc43</command>ï¼å°
	  <literal>ãgcc44ã</literal> æ¿ææ
	  <literal>ãgcc43ã</literal>ï¼ä»¥æ­¤é¡æ¨ãå¼å¾æ³¨æçæ¯ï¼éäº
	  libraries é½è系統æ¬èº«ç libraries ç¸å®¹ã</para>
      </note>

      <warning>
	<para>æäº C++ è¥éäº libraries æ²æ設å®å¥½ï¼å¯ä»¥ç¡æ³å·è¡ã
	  è¥æ²æ辦æ³å°ææç libraries 設å®å¥½ï¼å»ºè­°è³å° libstdc++.so
	  è¦æ­£ç¢ºã</para>
      </warning>
    </sect2>

    <sect2 id="custom-cflags">
      <title>èªè¨ ports tree 使ç¨ç <literal>CFLAGS</literal></title>

      <para>è¥è¦éå° ports tree å èªè¨ï¼ç³»çµ±å§å»ºä¸æ¯æ´ï¼ç
	<literal>CFLAGS</literal>ï¼ç§èç¯ä¾èª¿æ´
	<filename>/etc/make.conf</filename>ï¼</para>

      <programlisting>.if !empty(.CURDIR:M/usr/ports/*) && exists(/usr/local/bin/gcc44)
CC=gcc44
CXX=g++44
CPP=cpp44
CFLAGS+=-mssse3
.endif</programlisting>

      <para>å¯ä»¥å®å¨å代
	<literal>CFLAGS</literal>ï¼ä¹å¯ä»¥è¨­å®èªè¨ç
	<literal>CPUTYPE</literal>ãæå建議設å®èªè¨ç
	<literal>CPUTYPE</literal> å çºè¨±å¤ ports çåªè©±åæ¸ä»¥æ­¤è®æ¸çºåºç¤ã</para>
    </sect2>

    <sect2 id="excluding-unbuildable-ports">
      <title>æé¤ç¡æ³ç¨æ°çæ¬ç <application>GCC</application>
      編譯ç portsã</title>

      <para>è¥è¦æé¤ä¸äºè·æ°çæ¬ç
	<application>GCC</application> æåé¡ç portsï¼ä¾ç§ç¯ä¾èª¿æ´
	<filename>/etc/make.conf</filename>ï¼</para>

      <programlisting>.if !empty(.CURDIR:M/usr/ports/*) && exists(/usr/local/bin/gcc44)
.if empty(.CURDIR:M/usr/ports/net/openldap*)
CC=gcc44
CXX=g++44
CPP=cpp44
.endif
.endif</programlisting>

      <para>ä¸é¢çç¯ä¾å®è£
	<filename role="package">net/openldap</filename>* ports
	æï¼ä¸æä½¿ç¨ <command>gcc</command> 4.4ãå¦å¤ï¼ä¹å¯ä»¥å¨åä¸è¡ä¸è¨­æ´å¤
	portsï¼</para>

      <programlisting>.if empty(.CURDIR:M/usr/ports/net/openldap*) && empty(.CURDIR:M/usr/ports/xxx/yyy) && ...</programlisting>
    </sect2>
  </sect1>

  <sect1 id="performance-imparct">
    <title>å°äºé²ä½å·è¡æªä¹å½±é¿</title>

    <para>ä½¿ç¨ <application>GCC</application> çæ¬ 4.4 ä¸
      <acronym>SSSE3</acronym> æ令éæç¨å°ï¼è¥ <acronym>CPU</acronym>
      æ¯æ´ï¼å¹³åä¾è¬ï¼æè½å¯è½æé« 10% ãå¨æäºæ¸¬è©¦ç¶ä¸­ï¼çµæ顯示æè½æææè¶é
      20%ï¼å¦ï¼èçå¤åªé«æï¼ã</para>

    <para>ä½æ¼<ulink
	url="http://people.freebsd.org/~mm/benchmarks/perlbench/"></ulink>
      çè¡¨æ ¼é¡¯ç¤ºäº &os; 系統å§å»ºç <application>GCC</application> çæ¬è
      <application>GCC</application> çæ¬ 4.3ã4.4 ä¹æ¯è¼ã表格åå«æå種
      <literal>CFLAGS</literal> ççµåï¼ä½¿ç¨çæ¯ perlbench
      çæè½æ¸¬è©¦å¥ä»¶ã</para>
  </sect1>
</article>
--- article.sgml ends here -----lA3jdAQsaouLi3SyTYoHpqeltSJCPon2XSlGfHHGy2j5yndO
Content-Type: text/plain; name="Makefile"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="Makefile"

# 
# $FreeBSD$
#
# Article: Using newer version of GCC and binutils with the FreeBSD Ports Collection

DOC?= article

FORMATS?= html
WITH_ARTICLE_TOC?= YES

INSTALL_COMPRESSED?= gz
INSTALL_ONLY_COMPRESSED?=

SRCS=		article.sgml

URL_RELPREFIX?=	../../../..
DOC_PREFIX?= ${.CURDIR}/../../..

.include "${DOC_PREFIX}/share/mk/doc.project.mk"
Comment 1 Denny Lin 2009-11-19 14:28:01 UTC
Forgot to add new article to doc/zh_TW.Big5/articles/Makefile.

-- 
Denny Lin
Comment 2 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:01:41 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped