From dm@home3.dinoex.sub.de  Tue Oct  6 07:51:40 2009
Return-Path: <dm@home3.dinoex.sub.de>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 78C3D106568F
	for <FreeBSD-gnats-submit@freebsd.org>; Tue,  6 Oct 2009 07:51:40 +0000 (UTC)
	(envelope-from dm@home3.dinoex.sub.de)
Received: from uucp.dinoex.sub.de (uucp.dinoex.sub.de [194.45.71.2])
	by mx1.freebsd.org (Postfix) with ESMTP id DECB78FC19
	for <FreeBSD-gnats-submit@freebsd.org>; Tue,  6 Oct 2009 07:51:39 +0000 (UTC)
Received: from home3.dinoex.sub.de (home3.dinoex.sub.de [194.45.71.20])
	by uucp.dinoex.sub.de (8.14.3/8.14.2) with ESMTP id n967oBVO077979
	for <FreeBSD-gnats-submit@freebsd.org>; Tue, 6 Oct 2009 09:50:28 +0200 (CEST)
	(envelope-from dm@home3.dinoex.sub.de)
Received: (from dm@localhost)
	by home3.dinoex.sub.de (8.14.3/8.14.3/Submit) id n967q5L1036533;
	Tue, 6 Oct 2009 09:52:05 +0200 (CEST)
	(envelope-from dm)
Message-Id: <200910060752.n967q5L1036533@home3.dinoex.sub.de>
Date: Tue, 6 Oct 2009 09:52:05 +0200 (CEST)
From: dirk.meyer@dinoex.sub.org
Reply-To: dirk.meyer@dinoex.sub.org
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [patch] graphics/xpdf fix build with lesstif
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         139374
>Category:       ports
>Synopsis:       [patch] graphics/xpdf fix build with lesstif
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    araujo
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 06 08:00:11 UTC 2009
>Closed-Date:    Tue Oct 20 11:16:53 UTC 2009
>Last-Modified:  Tue Oct 20 11:20:01 UTC 2009
>Originator:     Dirk Meyer
>Release:        FreeBSD 8.0-BETA4
>Organization:
privat
>Environment:

	FreeBSD 7.x FreeBSD 8.x
	/etc/make.conf
	WANT_LESSTIF=YES

>Description:

	xdpf does not build with lesstif.
	Error mesasge:
In file included from XPDFApp.cc:18:
XPDFViewer.h:338: error: 'nColorMenuItems' was not declared in this scope

	bails out at:
	[...]
#if USE_COMBO_BOX
  Widget zoomComboBox;
#else
  Widget zoomMenu;
  Widget zoomMenuBtns[nZoomMenuItems];
  Widget colorMenuBtns[nColorMenuItems];
#endif
	[...]

	nColorMenuItems is not defined at all,
	neither in lestif nor in open-motif itself.

	The following detection stuff is wrong.
	[...]
#if (XmVERSION >= 2 && !defined(LESSTIF_VERSION))
#  define USE_COMBO_BOX 1
#else
#  undef USE_COMBO_BOX
#endif
	[...]

	Problem reported at 08th Nov 2008
	To: araujo@freebsd.org 
	Feedback received at 10th Nov 2008
	Details reported at 11th Nov 2008

>How-To-Repeat:

	pkg_add lesstif-0.95.2_1,2.tbz
	cd /usr/ports/graphics/xpdf && make WANT_LESTIF=1

>Fix:

	
	a) fix the patch-zz-xpdf-annot.20080728a
	   by removing "!defined(LESSTIF_VERSION))" in XPDFViewer.h

	b) or Apply this patch.

Index: Makefile
===================================================================
RCS file: /home/pcvs/ports/graphics/xpdf/Makefile,v
retrieving revision 1.91
diff -u -r1.91 Makefile
--- Makefile	18 Apr 2009 17:27:21 -0000	1.91
+++ Makefile	6 Oct 2009 07:34:30 -0000
@@ -78,6 +78,10 @@
 # add support for adding/deleting drawing annotations in PDF files
 PATCH_SITES+=   http://info.iet.unipi.it/~luigi/FreeBSD/
 PATCHFILES+=    patch-zz-xpdf-annot.20080728a
+
+post-patch:
+	${REINPLACE_CMD} -e 's|undef USE_COMBO_BOX|define USE_COMBO_BOX 1|' \
+		${WRKSRC}/xpdf/XPDFViewer.h
 .endif
 
 post-install:


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->araujo 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Tue Oct 6 08:00:22 UTC 2009 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=139374 
State-Changed-From-To: open->closed 
State-Changed-By: araujo 
State-Changed-When: Tue Oct 20 11:16:51 UTC 2009 
State-Changed-Why:  
Committed. Thanks! 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/139374: commit references a PR
Date: Tue, 20 Oct 2009 11:16:36 +0000 (UTC)

 araujo      2009-10-20 11:16:27 UTC
 
   FreeBSD ports repository
 
   Modified files:
     graphics/xpdf        Makefile distinfo 
   Log:
   - Fix compatibility with lesstif. [1]
   - Add a new patch to fix multiple vulnerabilities. [2]
   - Bump PORTREVISION.
   
   PR:             ports/139374 [1], ports/139782 [2]
   Submitted by:   dirk.meyer@dinoex.sub.org [1],
                   Sylvio Cesar <scjamorim@bsd.com.br> [2]
   http://www.vuxml.org/freebsd/8581189c-bd5f-11de-8709-0017a4cccfc6.html
   
   Revision  Changes    Path
   1.92      +7 -2      ports/graphics/xpdf/Makefile
   1.31      +3 -0      ports/graphics/xpdf/distinfo
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
>Unformatted:
