From gvs@road.demos.su  Fri Mar 14 09:48:51 2003
Return-Path: <gvs@road.demos.su>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 9D98037B401
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 14 Mar 2003 09:48:51 -0800 (PST)
Received: from road.demos.su (road.demos.su [194.87.2.211])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 876F443F3F
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 14 Mar 2003 09:48:50 -0800 (PST)
	(envelope-from gvs@road.demos.su)
Received: from road.demos.su (localhost [127.0.0.1])
	by road.demos.su (8.12.8/8.12.8) with ESMTP id h2EHrVed049816
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 14 Mar 2003 20:53:31 +0300 (MSK)
	(envelope-from gvs@road.demos.su)
Received: (from gvs@localhost)
	by road.demos.su (8.12.8/8.12.8/Submit) id h2EHrVUC049813;
	Fri, 14 Mar 2003 20:53:31 +0300 (MSK)
Message-Id: <200303141753.h2EHrVUC049813@road.demos.su>
Date: Fri, 14 Mar 2003 20:53:31 +0300 (MSK)
From: Seva Gluschenko <gvs@rinet.ru>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject:
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         50009
>Category:       ports
>Synopsis:       
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    anholt
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Mar 14 09:50:05 PST 2003
>Closed-Date:    Sun Apr 06 01:03:13 PST 2003
>Last-Modified:  Sun Apr 06 01:03:13 PST 2003
>Originator:     Seva Gluschenko
>Release:        FreeBSD 4.8-RC i386
>Organization:
>Environment:
System: FreeBSD road.demos.su 4.8-RC FreeBSD 4.8-RC #2: Tue Mar 4 15:43:13 MSK 2003 gvs@road.demos.su:/usr/local/obj/usr/local/src/sys/ROAD i386


	
>Description:
	While updating XFree86-4* ports for XFree86 4.3.0 several important things
	were missed, e.g. expat, and freetype related site definitions. It results
	to older and outdated libexpat and libfreetype to be built and installed into
	/usr/X11R6 tree causing a bit of inconvenience and mesh.
>How-To-Repeat:
	cvs/cvsup your ports/x11, cd ports/x11/XFree86-4-libraries and type make.
	After build is done, try

	find work/xc -name libexpat* -ls

	and the same for freetype. As far as you can see, They ARE built and will be
	installed into /usr/X11R6/lib tree. Moreover, the related X apps and libs
	can be (and some already) linked against those oldies.
>Fix:

	Apply patch below, rebuild and reinstall libraries.


--- scripts/configure.orig	Fri Mar 14 20:40:36 2003
+++ scripts/configure	Fri Mar 14 20:42:30 2003
@@ -55,6 +55,11 @@
 echo "#define FreeBSDBuildXlib YES"		>> $LOCALDEF
 echo "#define FreeBSDBuildXbin NO"		>> $LOCALDEF
 echo "#define UseInstalledPrograms YES"		>> $LOCALDEF
+echo '#define HasExpat YES
+#define HasFreetype2    YES
+#define Freetype2Dir    /usr/local
+#define PreloadXFTSetup LD_PRELOAD="`(cd $(XENVLIBDIR); echo libXft.so.? libXrender.so.? libfontconfig.so.?)`'					    >> $LOCALDEF
+
 
 # Copy ORIGDEF to DESTDEF
 rm -f $DESTDEF


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->anholt 
Responsible-Changed-By: arved 
Responsible-Changed-When: Fri Mar 14 09:53:57 PST 2003 
Responsible-Changed-Why:  
Over to Maintainer 

http://www.freebsd.org/cgi/query-pr.cgi?pr=50009 

From: Seva Gluschenko <gvs@rinet.ru>
To: FreeBSD-gnats-submit@FreeBSD.org, freebsd-ports-bugs@FreeBSD.org
Cc:  
Subject: Re: ports/50009: 
Date: Mon, 17 Mar 2003 19:37:05 +0300 (MSK)

 Well, actually I was incomplete in my research regarding XFree86,
 because a problem is a bit bigger than it might seem. XFree86 4.3.0
 has bundled expat, Xft, fontconfig, freetype, they all are outdated,
 they all are in dependencies chains. So, the correct patch should be
 
 --- scripts/configure.orig	Fri Mar 14 20:40:36 2003
 +++ scripts/configure	Mon Mar 17 19:31:28 2003
 @@ -55,6 +55,15 @@
  echo "#define FreeBSDBuildXlib YES"		>> $LOCALDEF
  echo "#define FreeBSDBuildXbin NO"		>> $LOCALDEF
  echo "#define UseInstalledPrograms YES"		>> $LOCALDEF
 +echo '#define HasExpat YES
 +#define HasFreetype2    YES
 +#define Freetype2Dir    /usr/local
 +#define BuildXft1Library	NO
 +#define HasXft		YES
 +#define HasFontconfig	YES
 +#define FontconfigDir	/usr/X11R6
 +#define PreloadXFTSetup LD_PRELOAD="`(cd $(XENVLIBDIR); echo libXft.so.? libXrender.so.? libfontconfig.so.?)`'					    >> $LOCALDEF
 +
 
  # Copy ORIGDEF to DESTDEF
  rm -f $DESTDEF
 
 The xc/config/cf/X11.tmpl should be extra patched, too. I hope, the
 patch below instead of attached file won't cause too much trouble:
 
 --- config/cf/X11.tmpl.orig	Tue Mar  4 18:21:10 2003
 +++ config/cf/X11.tmpl	Mon Mar 17 15:16:49 2003
 @@ -569,19 +569,19 @@
  #define BuildRenderLibrary	!BuildServersOnly
  #endif
  #ifndef BuildXftLibrary
 -#define BuildXftLibrary		BuildRenderLibrary
 +#define BuildXftLibrary		BuildRenderLibrary && !HasXft
  #endif
  #ifndef BuildXft1Library
  #define BuildXft1Library	BuildRenderLibrary
  #endif
  #ifndef UseFontconfig
 -#define UseFontconfig		BuildXftLibrary
 +#define UseFontconfig		(BuildXftLibrary || BuildXft1Library || HasXft)
  #endif
  #ifndef BuildFontconfigLibrary
  #define BuildFontconfigLibrary	(UseFontconfig && !HasFontconfig)
  #endif
  #ifndef UseFreetype2
 -#define UseFreetype2		(BuildXftLibrary || BuildXft1Library)
 +#define UseFreetype2		(BuildXftLibrary || BuildXft1Library || HasXft)
  #endif
  #ifndef HasExpat
  #define HasExpat		NO
 @@ -3189,7 +3199,7 @@
  #define XftClientLibs $(XFTLIB) FontconfigClientLibs $(XRENDERLIB)
  #endif
 
 -XFTINCLUDES=$(FONTCONFIGINCLUDES) $(FREETYPE2INCLUDES)
 +XFTINCLUDES=$(FONTCONFIGINCLUDES) $(FREETYPE2INCLUDES) -I$(INCROOT)
 
  #if UseFontconfig
 
 
 There's also a diff for programs/x11perf/Imakefile which depends on
 Xft, I include it here not to open the separate PR on the related
 issue:
 
 --- programs/x11perf/Imakefile.orig	Mon Mar 17 15:12:52 2003
 +++ programs/x11perf/Imakefile	Mon Mar 17 15:13:41 2003
 @@ -18,7 +18,7 @@
      XRENDERLIBS = $(XRENDERLIB)
      XRENDERINCS = $(XRENDERINCLUDES)
  #endif
 -#if BuildXftLibrary
 +#if BuildXftLibrary || HasXft
          XFTDEFS = -DXFT
          XFTDEPS = XftClientDepLibs $(DEPXRENDERLIB)
          XFTLIBS = XftClientLibs $(XRENDERLIB)
 
 Well. Actually, that's all. And all that stuff doesn't help with Qt
 and "fonts all look the same" problem %(
 
 SY, Seva Gluschenko | GVS-RIPE | GVS3-RIPN
State-Changed-From-To: open->closed 
State-Changed-By: anholt 
State-Changed-When: Sun Apr 6 01:02:22 PST 2003 
State-Changed-Why:  
It seems the submitter had imake-4 from the pre-4.3 ports installed and just  
needed to update. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=50009 
>Unformatted:
