From nobody@FreeBSD.org  Fri Jul  3 17:24:48 2009
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 8ACAC106564A
	for <freebsd-gnats-submit@FreeBSD.org>; Fri,  3 Jul 2009 17:24:48 +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 5EB4C8FC18
	for <freebsd-gnats-submit@FreeBSD.org>; Fri,  3 Jul 2009 17:24:48 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n63HOmwD027427
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 3 Jul 2009 17:24:48 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id n63HOmHp027426;
	Fri, 3 Jul 2009 17:24:48 GMT
	(envelope-from nobody)
Message-Id: <200907031724.n63HOmHp027426@www.freebsd.org>
Date: Fri, 3 Jul 2009 17:24:48 GMT
From: Pavel Plesov <pavel.plesov@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [patch] editors/openoffice.org-3: gpatch failure
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         136291
>Category:       ports
>Synopsis:       [patch] editors/openoffice.org-3: gpatch failure
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    openoffice
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 03 17:30:08 UTC 2009
>Closed-Date:    Sun Feb 13 07:35:27 UTC 2011
>Last-Modified:  Sun Feb 13 07:35:27 UTC 2011
>Originator:     Pavel Plesov
>Release:        FreeBSD 7.2-STABLE amd64
>Organization:
>Environment:
FreeBSD 7.2-STABLE #17: Mon Jun 29 18:24:56 MSD 2009  amd64

cvsup'ed ports.

$FreeBSD: ports/editors/openoffice.org-3/Makefile,v 1.319 2009/07/03 07:11:29 maho Exp $
>Description:
gpatch fails to apply the patches to many parts of OO.org. He dies with the message:
----
/usr/local/bin/gpatch: **** File libmspack/mspack/mspack.h seems to be locked by somebody else under Perforce
----

I have checked some of files gpatch fails on. Them was not owned to root - e.g. uid=500 or 1500 (I have no such uids registered on my host anyway). All of them have have 0755 mode.

I am pretty sure these files are not locked under Perforce.

>How-To-Repeat:
cd /usr/ports/editors/openoffice.org-3 && make
>Fix:
gpatch needs "-g0" command line flag or PATCH_GET=0 env var to be set.
===
       -g num  or  --get=num
          This  option  controls  patch's  actions when a file is under RCS or
          SCCS control, and does not exist or is  read-only  and  matches  the
          default  version, or when a file is under ClearCase or Perforce con-
          trol and does not exist.  If num is positive, patch gets (or  checks
          out)  the  file  from  the  revision  control system; if zero, patch
          ignores RCS, ClearCase, Perforce, and SCCS  and  does  not  get  the
          file;  and if negative, patch asks the user whether to get the file.
          The default value of this option  is  given  by  the  value  of  the
          PATCH_GET  environment  variable  if  it is set; if not, the default
          value is zero if patch is conforming to POSIX, negative otherwise.
===

Attached oo-gpatch.txt solved the problem. OO.org 3.1 seems to operate well.

Patch attached with submission follows:

--- /usr/ports/editors/openoffice.org-3/Makefile-orig	2009-07-03 17:02:56.000000000 +0400
+++ /usr/ports/editors/openoffice.org-3/Makefile	2009-07-03 17:07:18.000000000 +0400
@@ -191,7 +191,7 @@
 
 do-build:
 	@cd ${WRKSRC} ; ./bootstrap
-	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAKE_JOBS_NUMBER} --all --html --dontgraboutput -- -P${MAKE_JOBS_NUMBER}"
+	@cd ${WRKSRC} ; ${SETENV} "LANG=C" "LC_ALL=C" "TMP=${WRKSRC}" "PATCH_GET=0" ${TCSH} -c "source ${FREEBSD_ENV_SET} ; cd instsetoo_native ; build.pl --checkmodules ; build.pl -P${MAKE_JOBS_NUMBER} --all --html --dontgraboutput -- -P${MAKE_JOBS_NUMBER}"
 
 .if ${LOCALIZED_LANG} == "alllangs"
 	@${MAKE} languagepack


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->openoffice 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Fri Jul 3 17:30:21 UTC 2009 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=136291 
State-Changed-From-To: open->closed 
State-Changed-By: miwi 
State-Changed-When: Sun Feb 13 07:35:25 UTC 2011 
State-Changed-Why:  
this report can be close because, these version no longer supported in 
FreeBSD ports. 

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