From nobody@FreeBSD.org  Tue Jun 15 05:38:08 2010
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 8FEBF106566B
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 Jun 2010 05:38:08 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 65F358FC1C
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 Jun 2010 05:38:08 +0000 (UTC)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o5F5c8Z5087429
	for <freebsd-gnats-submit@FreeBSD.org>; Tue, 15 Jun 2010 05:38:08 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id o5F5c8gO087428;
	Tue, 15 Jun 2010 05:38:08 GMT
	(envelope-from nobody)
Message-Id: <201006150538.o5F5c8gO087428@www.freebsd.org>
Date: Tue, 15 Jun 2010 05:38:08 GMT
From: Kuan-Chung Chiu <buganini@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] fix maxima with LC_MESSAGES
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         147861
>Category:       ports
>Synopsis:       [patch] fix math/maxima with LC_MESSAGES
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    bf
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Jun 15 05:40:01 UTC 2010
>Closed-Date:    Sun Aug 08 22:09:11 UTC 2010
>Last-Modified:  Sun Aug 08 22:09:11 UTC 2010
>Originator:     Kuan-Chung Chiu
>Release:        9.0-CURRENT
>Organization:
N/A
>Environment:
FreeBSD security-hole.info 9.0-CURRENT FreeBSD 9.0-CURRENT #0: Fri May 28 22:25:02 CST 2010     root@security-hole.info:/usr/obj/usr/src/sys/SECURITYHOLE  i386

>Description:
> locale
LANG=zh_TW.UTF-8
LC_CTYPE="zh_TW.UTF-8"
LC_COLLATE="zh_TW.UTF-8"
LC_TIME="zh_TW.UTF-8"
LC_NUMERIC="zh_TW.UTF-8"
LC_MONETARY="zh_TW.UTF-8"
LC_MESSAGES="zh_TW.UTF-8"
LC_ALL=

> ktrace maxima
Maxima 5.21.1 http://maxima.sourceforge.net

*** - UNIX error 20 (ENOTDIR): Not a directory
The following restarts are available:
MACSYMA-QUIT   :R1      Maxima top-level
Break 1 [1]> 
[eval.d:573] reset() found no driver frame (sp=0x7fbfe5d0-0x7fbf8250)

Exiting on signal 6
kAbort (core dumped)

> kdump -f ktrace.out | grep -C 3 "a dir"
 67098 lisp.run RET   lstat 0
 67098 lisp.run CALL  lstat(0x7fbf8f50,0x7fbf93e4)
 67098 lisp.run NAMI  "/usr/share/locale/zh_TW.UTF-8/LC_MESSAGES/maxima.mo"
 67098 lisp.run RET   lstat -1 errno 20 Not a directory
 67098 lisp.run CALL  setitimer(0,0x7fbf8e8c,0x7fbf8e7c)
 67098 lisp.run RET   setitimer 0
 67098 lisp.run CALL  getuid

>How-To-Repeat:
set LC_MESSAGES other than C and run maxima
>Fix:
${WRKSRC}/src/intl.lisp (installed as /usr/local/share/maxima/5.21.1/src/intl.lisp)
has a line (defvar *locale-directories* '(#p"/usr/share/locale/"))
that is the problem, /usr/share/locale/zh_TW.UTF-8/LC_MESSAGES is a file but not a directory in FreeBSD system.

Patch attached with submission follows:

--- Makefile.orig	2010-06-15 13:21:46.000000000 +0800
+++ Makefile	2010-06-15 13:26:15.000000000 +0800
@@ -7,6 +7,7 @@
 
 PORTNAME=	maxima
 PORTVERSION=	5.21.1
+PORTREVISION=	1
 CATEGORIES=	math tk
 MASTER_SITES=	SF/maxima/Maxima-source/${PORTVERSION}-source
 
@@ -81,6 +82,7 @@
 	 -name "Makefile*" | ${XARGS} ${REINPLACE_CMD} -e "s;tclsh;${TCLSH};g"
 	( cd ${WRKSRC}/doc/info ; ${LOCALBASE}/bin/bash ./fix_crlf ; \
 	${LOCALBASE}/bin/bash ./fix_tab )
+	${REINPLACE_CMD} -e "s;/usr/;${LOCALBASE}/;g" ${WRKSRC}/src/intl.lisp
 
 regression-test: build
 	${LOCALBASE}/bin/bash ${WRKSRC}/maxima-local --batch-string='run_testsuite();'


>Release-Note:
>Audit-Trail:

From: Buganini <buganini@gmail.com>
To: bug-followup@FreeBSD.org, buganini@gmail.com
Cc: bf1783@gmail.com
Subject: Re: ports/147861: [patch] fix math/maxima with LC_MESSAGES
Date: Sun, 20 Jun 2010 14:07:26 +0800

 Hi, could you take a look at this patch, please?
 
 --Buganini

From: "b. f." <bf1783@googlemail.com>
To: Buganini <buganini@gmail.com>
Cc: bug-followup@freebsd.org
Subject: Re: ports/147861: [patch] fix math/maxima with LC_MESSAGES
Date: Wed, 23 Jun 2010 16:42:41 +0000

 Yes, I'll try to look at it soon. And fix the auto-assign.
 
 Regards,
                 b.
 
 On 6/20/10, Buganini <buganini@gmail.com> wrote:
 > Hi, could you take a look at this patch, please?
 >
 > --Buganini
 >
Responsible-Changed-From-To: freebsd-ports-bugs->bf 
Responsible-Changed-By: bf 
Responsible-Changed-When: Thu Jul 8 16:57:39 UTC 2010 
Responsible-Changed-Why:  
I'll take it. 

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

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/147861: commit references a PR
Date: Fri,  6 Aug 2010 21:48:44 +0000 (UTC)

 bf          2010-08-06 21:48:35 UTC
 
   FreeBSD ports repository
 
   Modified files:
     math/maxima          Makefile distinfo pkg-plist 
   Removed files:
     math/maxima/files    patch-interfaces-xmaxima-doc-xmaxima.texi 
   Log:
   -Update to 5.22.0
   -Fix a localization problem [1]
   -Temporarily rename regression-test target to prevent tinderbox
   errors WITH_SBCL
   (See http://www.math.utexas.edu/pipermail/maxima/2010/022185.html )
   
   PR:             147861 [1]
   Submitted by:   Kuan-Chung Chiu <buganini@gmail.com> [1]
   Approved by:    makc (co-mentor)
   
   Revision  Changes    Path
   1.58      +4 -3      ports/math/maxima/Makefile
   1.22      +3 -3      ports/math/maxima/distinfo
   1.2       +0 -15     ports/math/maxima/files/patch-interfaces-xmaxima-doc-xmaxima.texi (dead)
   1.21      +12 -1     ports/math/maxima/pkg-plist
 _______________________________________________
 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"
 
State-Changed-From-To: open->closed 
State-Changed-By: bf 
State-Changed-When: Sun Aug 8 22:09:10 UTC 2010 
State-Changed-Why:  
Committed. Thanks! 

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