Issue 107027 - GNU patch-2.6 (the newest version) not recognized as valid for build
Summary: GNU patch-2.6 (the newest version) not recognized as valid for build
Status: CLOSED NOT_AN_OOO_ISSUE
Alias: None
Product: General
Classification: Code
Component: code (show other issues)
Version: OOO310m19
Hardware: PC Linux, all
: P3 Trivial (vote)
Target Milestone: ---
Assignee: pmladek
QA Contact: issues@framework
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-19 09:28 UTC by jomen
Modified: 2009-11-23 12:27 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Patch against ooo-build-3.1.1.4 (725 bytes, patch)
2009-11-23 12:27 UTC, pmladek
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description jomen 2009-11-19 09:28:34 UTC
This is on Gentoo Linux (~x86 aka not the stable version).
A few days ago, the new version of GNU patch (patch-2.6) became available.
Since then the building of openoffice fails, rather: it does not even start
- because patch-2.6 is not recognized by the build scripts as a valid version to
do the job.

Downgrading patch to the previous version (patch-2.5.9-r1) will work as expected:
I now have openoffice OOO310m19 (build:9420) - at the bottom it says: "Build
3.1.1.4" running.


The failure message, when patch-2.6 is used, is:
...
Execute with  for distro(s) 'Gentoo Binfilter System Sdk Extensions Localize'
Can't get patch version
make: *** [stamp/patch.apply] Error 255
..."

The reason seems to be in line 923 of

ooo-build-3.1.1.4/patches/apply.pl.in

which seems to do the parsing
The following line checks for a version greater or equal to 2.5.9 but the script
does not get there with patch-2.6 installed.

output of "patch --version" is for me:

patch --version
patch 2.6
Copyright (C) 1988 Larry Wall
Copyright (C) 2003 Free Software Foundation, Inc.

This program comes with NO WARRANTY, to the extent permitted by law.
You may redistribute copies of this program
under the terms of the GNU General Public License.
For more information about these matters, see the file named COPYING.

written by Larry Wall and Paul Eggert


and this is the parsing code which fails on patch 2.6

$ver_line =~ m/\s+(\d+)\.(\d+)\.(\d+)/ || die "Can't get patch version\n";

If I where able to decipher this I would have suggested a fix...

There is a bug-report on bugs.gentoo.org - #293385
http://bugs.gentoo.org/show_bug.cgi?id=293385
but I suppose this place is better suited.

I hope this (OOO310m19) is the right category - it is an issue with all
versions, I suppose.
Comment 1 Olaf Felka 2009-11-19 10:01:09 UTC
@ hr: Please have a look.
Comment 2 caolanm 2009-11-20 11:09:35 UTC
This is specific to an ooo-build apply.pl tool which is only in the ooo-build
build wrapper of course, not OOo itself
Comment 3 caolanm 2009-11-20 11:10:58 UTC
closing as invalid for upstream OOo
Comment 4 caolanm 2009-11-20 11:12:15 UTC
closing
Comment 5 pmladek 2009-11-23 12:25:51 UTC
Just for record, I have fixed this in ooo-build master, see
http://cgit.freedesktop.org/ooo-build/ooo-build/commit/?id=a18e1b9821f904fd5e70aca8b2a69c31402a8dba

I'll attach a patch that could be applied against ooo-build-3.1.1.4.
Comment 6 pmladek 2009-11-23 12:27:36 UTC
Created attachment 66283 [details]
Patch against ooo-build-3.1.1.4