Gentoo Archives: gentoo-commits

From: "Mike Frysinger (vapier)" <vapier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-devel/make/files: make-3.82-archives-many-objs.patch
Date: Sun, 29 Aug 2010 00:02:37
Message-Id: 20100829000230.520CF20054@flycatcher.gentoo.org
1 vapier 10/08/29 00:02:30
2
3 Added: make-3.82-archives-many-objs.patch
4 Log:
5 Add fix from upstream for archive targets with multiple objects #334889 by Diego E. Pettenò.
6 (Portage version: 2.2_rc67/cvs/Linux x86_64)
7
8 Revision Changes Path
9 1.1 sys-devel/make/files/make-3.82-archives-many-objs.patch
10
11 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-devel/make/files/make-3.82-archives-many-objs.patch?rev=1.1&view=markup
12 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-devel/make/files/make-3.82-archives-many-objs.patch?rev=1.1&content-type=text/plain
13
14 Index: make-3.82-archives-many-objs.patch
15 ===================================================================
16 http://bugs.gentoo.org/334889
17 https://savannah.gnu.org/bugs/?30612
18
19 revision 1.194
20 date: 2010-08-13 22:50:14 -0400; author: psmith; state: Exp; lines: +9 -6; commitid: 4UaslPqQHZTs5wKu;
21 - Fix Savannah bug #30612: handling of archive references with >1 object
22
23 Index: read.c
24 ===================================================================
25 RCS file: /sources/make/make/read.c,v
26 retrieving revision 1.193
27 retrieving revision 1.194
28 diff -u -p -r1.193 -r1.194
29 --- read.c 13 Jul 2010 01:20:42 -0000 1.193
30 +++ read.c 14 Aug 2010 02:50:14 -0000 1.194
31 @@ -3028,7 +3028,7 @@ parse_file_seq (char **stringp, unsigned
32 {
33 /* This looks like the first element in an open archive group.
34 A valid group MUST have ')' as the last character. */
35 - const char *e = p + nlen;
36 + const char *e = p;
37 do
38 {
39 e = next_token (e);
40 @@ -3084,19 +3084,19 @@ parse_file_seq (char **stringp, unsigned
41 Go to the next item in the string. */
42 if (flags & PARSEFS_NOGLOB)
43 {
44 - NEWELT (concat (2, prefix, tp));
45 + NEWELT (concat (2, prefix, tmpbuf));
46 continue;
47 }
48
49 /* If we get here we know we're doing glob expansion.
50 TP is a string in tmpbuf. NLEN is no longer used.
51 We may need to do more work: after this NAME will be set. */
52 - name = tp;
53 + name = tmpbuf;
54
55 /* Expand tilde if applicable. */
56 - if (tp[0] == '~')
57 + if (tmpbuf[0] == '~')
58 {
59 - tildep = tilde_expand (tp);
60 + tildep = tilde_expand (tmpbuf);
61 if (tildep != 0)
62 name = tildep;
63 }
64 @@ -3152,7 +3152,10 @@ parse_file_seq (char **stringp, unsigned
65 else
66 {
67 /* We got a chain of items. Attach them. */
68 - (*newp)->next = found;
69 + if (*newp)
70 + (*newp)->next = found;
71 + else
72 + *newp = found;
73
74 /* Find and set the new end. Massage names if necessary. */
75 while (1)