&My::Web::footer call is deprecated now, use just: exit;
[www.jankratochvil.net.git] / project / libtool / Index.pm
1 # $Id$
2 # Main page of 'My::Project::libtool'
3 # Copyright (C) 2003-2005 Jan Kratochvil <project-www.jankratochvil.net@jankratochvil.net>
4
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; exactly version 2 of June 1991 is required
8
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13
14 # You should have received a copy of the GNU General Public License
15 # along with this program; if not, write to the Free Software
16 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
17
18
19 package project::libtool::Index;
20 require 5.6.0;  # at least 'use warnings;' but we need some 5.6.0+ modules anyway
21 our $VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; };
22 our $CVS_ID=q$Id$;
23 use strict;
24 use warnings;
25
26 use My::Web;
27 Wuse 'project::Lib';
28
29
30 our @ListItem=(
31                 "name"=>sub { return a_href('http://www.gnu.org/software/libtool/libtool.html','GNU Libtool').' fix'; },
32                 "platform"=>"patch",
33                 "priority"=>620,
34                 "summary"=>'Handle duplicate object file names',
35                 "download-patch"=>'http://savannah.gnu.org/cgi-bin/cvsweb/libtool/ltmain.in.diff?r1=1.320&r2=1.321',
36                 "license"=>"GPL",
37                 "maintenance"=>"accepted",
38                 "language"=>"sh patch",
39                 "description"=><<"HERE",
40 <p>Patch fixes linking of convenience libraries (<i>.a</i>) containing two
41 conflicting name objects.</p>
42 HERE
43                 );
44
45 sub handler
46 {
47 project::Lib->init();
48
49
50 print <<"HERE";
51 <p>When you include convenience library (<i>.a</i>) containing two conflicting name
52 objects (same basename from two different directories) only one of those two
53 object files will survive in &quot;<i>.libs/libA.lax/</i>&quot; arena:</p>
54 <pre>
55         rm -fr .libs/libA.lax/libB.a
56         mkdir .libs/libA.lax/libB.a
57         (cd .libs/libA.lax/libB.a &amp;&amp; ar x /abs/path/to/A/B/.libs/libB.a)
58 </pre>
59
60 <p>The patch implements automatic renaming of &quot;<i>*.*</i>&quot; to &quot;<i>*-@{[ '$' ]}seqnum.*</i>&quot;
61 in such case:</p>
62 <pre>
63         libtool: link: warning: object name conflicts; renaming object files
64         libtool: link: warning: to ensure that they will not overwrite
65         (cd .libs/libA.lax/libB.a &amp;&amp; ar xN 1 /abs/path/to/A/B/.libs/libB.a 'XconflictX.o' &amp;&amp; mv -f 'XconflictX.o' 'XconflictX-1.o')
66         (cd .libs/libA.lax/libB.a &amp;&amp; ar xN 2 /abs/path/to/A/B/.libs/libB.a 'XconflictX.o' &amp;&amp; mv -f 'XconflictX.o' 'XconflictX-2.o')
67 </pre>
68
69 <p>Although renaming to a new name may be confusing IMO there is no better option.
70 The original (conflicting) name is not left there in any instance to prevent
71 misleading confusion of different object file found than expected.</p>
72 HERE
73
74
75 exit;
76 }
77 1;