From owner-FreeBSD-users-jp@jp.freebsd.org  Tue Feb 13 14:05:12 1996
Received: by mail.jp.freebsd.org (8.7.3+2.6Wbeta5/8.7.3) id OAA09216
	Tue, 13 Feb 1996 14:05:12 +0900 (JST)
Received: by mail.jp.freebsd.org (8.7.3+2.6Wbeta5/8.7.3) with SMTP id OAA09211
	for <FreeBSD-users-jp@jp.freebsd.org>; Tue, 13 Feb 1996 14:05:10 +0900 (JST)
Received: from bird.scphys.kyoto-u.ac.jp (hakucho.scphys.kyoto-u.ac.jp [130.54.56.2]) by tancho.scphys.kyoto-u.ac.jp (8.6.10+2.4W/3.3W) with ESMTP id OAA12340 for <FreeBSD-users-jp@jp.freebsd.org>; Tue, 13 Feb 1996 14:05:09 +0900
Message-Id: <199602130505.OAA12340@tancho.scphys.kyoto-u.ac.jp>
To: FreeBSD-users-jp@jp.freebsd.org
Mime-Version: 1.0
Content-Type: Text/Plain; charset=iso-2022-jp
X-Mailer: Mew version 1.02 on Emacs 19.28.1, Mule 2.3
Date: Tue, 13 Feb 1996 14:05:08 +0900
From: Akio Morita <amorita@bird.scphys.kyoto-u.ac.jp>
Reply-To: FreeBSD-users-jp@jp.freebsd.org
X-Distribute: distribute [version 2.1 (Alpha) patchlevel=19]
X-Sequence: FreeBSD-users-jp 300
Subject: [FreeBSD-users-jp 300] about gcc-2.7.2p
Errors-To: owner-FreeBSD-users-jp@jp.freebsd.org
Sender: owner-FreeBSD-users-jp@jp.freebsd.org

$B?9ED!w5~Bg$G$9(B

$B$7$P$i$/A0$KOCBj$K$J$C$F$$$?(Bgcc-2.7.2p$B$r%$%s%9%H!<%k$7$?$H$3$m!"(B
$B0lIt$KLdBj$,$"$C$?$N$G%Q%C%A$r:n$j$^$7$?(B

$B$=$N#1(B
$B%3%s%Q%$%i%I%i%$%P(Bg++$B$KLdBj$,$"$j(B/cp/g++.c$B$r=$@5$9$k(B
$B>l=j$O#G#N#U(B $B#C!\!\%i%$%V%i%j!<$HI8=`#C!\!\%i%$%V%i%j!<$r(B
$B8F=P;~$N>r7o$GA*Br$9$kItJ,$G!"85$N$^$^$@$H(Bg++$B$r;H$&$H$-(B
-lg++$B$H(B-lstdc++$B$NN>J}$,;XDj$5$l$F$7$^$&(B

$B$=$N#2(B
gcc-2.7.2p-FreeBSD.patch$B$N(Bconfig/i386/freebsd.h$B$N(B
ASM_WEAKEN_LABEL$B$X$N%Q%C%A$,$&$^$/Ev$?$i$J$$$N$G=$@5$9$k(B

$B0J>e$G$9(B
$B$b$C$H$b<j:n6H$G=PMh$k%l%Y%k$+$bCN$l$^$;$s$,(B

$B$3$l0J30$O!"2?$NLdBj$b$J$/%$%s%9%H!<%k$G$-$^$7$F(B
$B;29M$^$G$K;d$N>l9g$O(B

$B%=!<%9E83+$H%Q%C%AEv$F(B
cd /usr/local/src
tar zxvf ./arcive/gcc-2.7.2/gcc-2.7.2.tgz
cd gcc-2.7.2
gzip -dc ../arcive/gcc-2.7.2/gcc-2.7.2-2.7.2p-pl7.diff.gz | patch -p1
cat ../arcive/gcc-2.7.2/gcc-2.7.2p-FreeBSD.patch | patch -p
cat ../arcive/gcc-2.7.2/gcc-2.7.2p-fix.patch | patch -p
			^^^^^^^^^^^^^^^^^^^^
			$B;d$N:n$C$?%Q%C%A$G$9(B

$B%3%s%Q%$%k(B
./configure --build=pentium--freebsd
gmake CFLAGS="-g -O" LANGUAGES="C C++"
gmake stage1
gmake CC="stage1/xgcc -Bstage1/" CFLAGS="-g -O2" LANGUAGES="C C++"
gmake stage2
gmake CC="stage2/xgcc -Bstage2/" CFLAGS="-g -O2" LANGUAGES="C C++"
gmake compare

$BHf3S$7$FLdBj$J$+$C$?$N$G!"%$%s%9%H!<%k(B
gmake install CC="stage2/xgcc -Bstage2/" CFLAGS="-g -O2" LANGUAGES="C C++"

$B$G!"$9$s$J$j%$%s%9%H!<%k$G$-$^$7$?(B

$B$=$l$G$O!"%Q%C%A$G$9(B

--- BEGIN PATCH ---
*** cp/g++.c~	Tue Feb 13 02:13:23 1996
--- cp/g++.c	Tue Feb 13 02:19:23 1996
***************
*** 542,548 ****
        /* Add `-lg++' if we haven't already done so.  */
        if (library == 2)
  	arglist[j++] = "-lg++";
!       if (library)
  	arglist[j++] = "-lstdc++";
        if (saw_math)
  	arglist[j++] = saw_math;
--- 542,548 ----
        /* Add `-lg++' if we haven't already done so.  */
        if (library == 2)
  	arglist[j++] = "-lg++";
!       else if (library)
  	arglist[j++] = "-lstdc++";
        if (saw_math)
  	arglist[j++] = saw_math;
*** config/i386/freebsd.h~	Tue Feb 13 02:13:23 1996
--- config/i386/freebsd.h	Tue Feb 13 02:15:53 1996
***************
*** 121,131 ****
  #define SIZE_ASM_OP	".size"
  
  /* This is how we tell the assembler that a symbol is weak.  */
! 
  #define ASM_WEAKEN_LABEL(FILE,NAME) \
    do { fputs ("\t.weak\t", FILE); assemble_name (FILE, NAME); \
         fputc ('\n', FILE); } while (0)
! 
  /* The following macro defines the format used to output the second
     operand of the .type assembler directive.  Different svr4 assemblers
     expect various different forms for this operand.  The one given here
--- 121,131 ----
  #define SIZE_ASM_OP	".size"
  
  /* This is how we tell the assembler that a symbol is weak.  */
! /*
  #define ASM_WEAKEN_LABEL(FILE,NAME) \
    do { fputs ("\t.weak\t", FILE); assemble_name (FILE, NAME); \
         fputc ('\n', FILE); } while (0)
! */
  /* The following macro defines the format used to output the second
     operand of the .type assembler directive.  Different svr4 assemblers
     expect various different forms for this operand.  The one given here
--- END PATCH ---

#   Akio Morita ( $B?9ED(B $B><IW(B -- $B5~ETBg3XM}3XItJ*M}2J3X7O(B3$B2s@8(B )   #
#         E-Mail: amorita@bird.scphys.kyoto-u.ac.jp		 #
