Subject: Re: xsrc/29401: Makefiles warnings while compiling X from xsrc
To: None <tsutsui@netbsd.org, gnats-admin@netbsd.org,>
From: Izumi Tsutsui <tsutsui@ceres.dti.ne.jp>
List: netbsd-bugs
Date: 02/17/2005 09:05:02
The following reply was made to PR xsrc/29401; it has been noted by GNATS.

From: Izumi Tsutsui <tsutsui@ceres.dti.ne.jp>
To: gnats-bugs@netbsd.org
Cc: xsrc-manager@netbsd.org, gnats-admin@netbsd.org,
	tsutsui@ceres.dti.ne.jp
Subject: Re: xsrc/29401: Makefiles warnings while compiling X from xsrc
Date: Thu, 17 Feb 2005 18:04:40 +0900

 > >Synopsis:       Makefiles warnings while compiling X from xsrc
  :
 > >Description:
 > I'm getting many warnings during xsrc Makefiles generation on amd64 :
  :
 
 Hmm, I'd like to move the definition of -D__AMD64__ in NetBSDMachineDefines
 from MACHINE dependent part to MACHINE_CPU part because:
 - __AMD64__ is also used in some libraries (not only by Xserver)
 - share/mk/bsd.x11.mk implicitly add -D__AMD64__ if MACHINE_ARCH == x86_64
 - currently amd64 is the only MACHINE which have x86_64 MACHINE_CPU anyway
 (though the real fix is to add "defined(__x86_64__)" where appropriate, IMO)
 
 Would you please confirm if the attached version properly works?
 
 Index: NetBSD.cf
 ===================================================================
 RCS file: /cvsroot/xsrc/xfree/xc/config/cf/NetBSD.cf,v
 retrieving revision 1.75
 diff -u -r1.75 NetBSD.cf
 --- NetBSD.cf	10 Feb 2005 16:16:24 -0000	1.75
 +++ NetBSD.cf	17 Feb 2005 08:52:36 -0000
 @@ -315,6 +315,7 @@
  /* x86_64 */
  #if defined(x86_64Architecture)
  # define OptimizedCDebugFlags	-O2	/* XXX not needed anymore? */
 +# define NetBSDMachineDefines	-D__AMD64__
  #endif
  
  /* set default */
 @@ -656,7 +657,6 @@
  # define BuildServer		YES
  # define ServerOSDefines	XFree86ServerOSDefines -DDDXTIME
  # define ServerExtraDefines	GccGasOption XFree86ServerDefines -D_XSERVER64
 -# define NetBSDMachineDefines	-D__AMD64__
  # ifndef XFree86ConsoleDefines
  # define XFree86ConsoleDefines	-DWSCONS_SUPPORT -DPCVT_SUPPORT
  # endif