* [RFC] DJGPP: fnchange.lst removal attempt
@ 2010-04-12 0:09 Jan Kratochvil
2010-04-12 17:48 ` Eli Zaretskii
0 siblings, 1 reply; 5+ messages in thread
From: Jan Kratochvil @ 2010-04-12 0:09 UTC (permalink / raw)
To: gdb-patches
Hi,
tried to create a script to autogenerate and remove fnchange.lst but ... after
writing it I found I am not able to even compile the current FSF GDB HEAD.
configure:4342: checking for C compiler default output file name
configure:4364: gcc -O2 -ggdb -g3 conftest.c >&5
conftest.c:10:1: warning: "PACKAGE_TARNAME" redefined
conftest.c:3:1: warning: this is the location of the previous definition
c:/djgpp/lib/crt0.o:crt0.s:(.data+0xc2): undefined reference to `_main'
c:/djgpp/lib/libc.a(crt1.o):crt1.c:(.text+0x404): undefined reference to `_main'
collect2: ld returned 1 exit status
configure:4368: $? = 1
configure:4405: result:
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAMEconfigure:4411: error: in `c:/gdborig/gdb':
configure:4415: error: C compiler cannot create executables
See `config.log' for more details.
But FreeDOS-1.0 is generating corrupted disk (in qemu-kvm) so it may have been
also due to the disk corruption. Does the build work for anyone? Tried with:
bnu219b.zip bsh204br3.zip bsn241b.zip csdpmi7b.zip djdev203.zip
fil41b.zip find41b.zip flx254b.zip gcc442b.zip mak3791b.zip
pdcur34a.zip sed421b.zip shl2011b.zip tar112ab.zip txt20b.zip
BTW current fnchange.lst is already in a bad shape:
Duplicates in fnchange.lst:
bfd/elf32-microblaze.c
gdb/ChangeLog-2002
gdb/amd64-windows-nat.c
gdb/amd64-windows-tdep.c
opcodes/microblaze-opc.h
opcodes/microblaze-opcm.h
in fnchange.lst && in repository && not in dist .tar
COPYING.LIBGLOSS
in fnchange.lst && not in repository && in dist .tar
(none)
Not a bad shape but statement: fnchange.lst change of directories:
@V@/sim/microblaze @V@/sim/mb
@V@/sim/microblaze/microblaze.h @V@/sim/mb/mb.h
@V@/sim/microblaze/microblaze.isa @V@/sim/mb/mb.isa
other files in sim/microblaze/:
Makefile.in
config.in
configure
configure.ac
interp.c
sim-main.h
sysdep.h
But there are no 8.3 conflicts in sim/microblaze/.
fnchange.lst change of directory names:
@V@/gdb/testsuite/gdb.gdbtk/EVERYTHING @V@/gdb/testsuite/gdb.tk/EVERYTHING
Mistaken change of directory:
@V@/bfd/doc/ChangeLog-9103 @V@/bfd/ChangeLog.9103
@V@/bfd/elf32-microblaze.c @V@e32mb.c
@V@/gdb/features/i386/i386-avx-linux.c @V@/features/i386/i32-al.c
@V@/gdb/features/i386/i386-mmx-linux.c @V@/features/i386/i32-ml.c
@V@/sim/testsuite/sim/cris/asm/tjmpsrv32-2.ms @V@/sim/testsuite/sim/cris/tjmp32-2.ms
@V@/sim/testsuite/sim/cris/asm/tjmpsrv32.ms @V@/sim/testsuite/sim/cris/tjmp32.ms
@V@/sim/testsuite/sim/cris/c/ftruncate1.c @V@/sim/testsuite/sim/cris/ftrunc1.c
@V@/sim/testsuite/sim/cris/c/ftruncate2.c @V@/sim/testsuite/sim/cris/ftrunc2.c
@V@/sim/testsuite/sim/cris/c/readlink1.c @V@/sim/testsuite/sim/cris/rdlink1.c
@V@/sim/testsuite/sim/cris/c/readlink2.c @V@/sim/testsuite/sim/cris/rdlink2.c
@V@/sim/testsuite/sim/cris/c/readlink3.c @V@/sim/testsuite/sim/cris/rdlink3.c
@V@/sim/testsuite/sim/cris/c/readlink4.c @V@/sim/testsuite/sim/cris/rdlink4.c
@V@/sim/testsuite/sim/cris/c/readlink5.c @V@/sim/testsuite/sim/cris/rdlink5.c
@V@/sim/testsuite/sim/cris/c/readlink6.c @V@/sim/testsuite/sim/cris/rdlink6.c
@V@/sim/testsuite/sim/cris/c/readlink7.c @V@/sim/testsuite/sim/cris/rdlink7.c
@V@/sim/testsuite/sim/cris/c/readlink8.c @V@/sim/testsuite/sim/cris/rdlink8.c
@V@/sim/testsuite/sim/cris/c/readlink9.c @V@/sim/testsuite/sim/cris/rdlink9.c
@V@/sim/testsuite/sim/cris/c/readlink10.c @V@/sim/testsuite/sim/cris/rdlink10.c
@V@/sim/testsuite/sim/cris/c/sigreturn1.c @V@/sim/testsuite/sim/cris/sigret1.c
@V@/sim/testsuite/sim/cris/c/sigreturn2.c @V@/sim/testsuite/sim/cris/sigret2.c
@V@/sim/testsuite/sim/cris/c/sigreturn3.c @V@/sim/testsuite/sim/cris/sigret3.c
@V@/sim/testsuite/sim/cris/c/sigreturn4.c @V@/sim/testsuite/sim/cris/sigret4.c
@V@/sim/testsuite/sim/cris/c/truncate1.c @V@/sim/testsuite/sim/cris/trunc1.c
@V@/sim/testsuite/sim/cris/c/truncate2.c @V@/sim/testsuite/sim/cris/trunc2.c
And currently missing translations generating DJTAR.EXE error:
Cannot exclusively open file:
gdb/regformats/s390-linux64.dat gdb/regformats/i386/amd64-avx-linux.dat gdb/regformats/i386/i386-avx-linux.dat gdb/regformats/i386/i386-mmx-linux.dat gdb/features/s390-core64.xml gdb/features/s390-linux64.c gdb/features/s390-linux32.xml gdb/testsuite/gdb.cp/pr10728-y.cc gdb/testsuite/gdb.cp/virtfunc.cc gdb/testsuite/gdb.cp/virtfunc2.exp gdb/testsuite/gdb.reverse/consecutive-precsave.exp gdb/testsuite/gdb.reverse/machinestate-precsave.exp gdb/testsuite/gdb.base/unloadshr2.c gdb/testsuite/gdb.base/watchpoints.exp gdb/testsuite/gdb.base/break-interp-main.c gdb/testsuite/gdb.base/sepdebug2.c gdb/testsuite/gdb.base/watchpoint.c gdb/testsuite/gdb.base/watchpoint-hw-hit-once.exp gdb/testsuite/gdb.base/watchpoints.c gdb/testsuite/gdb.threads/watchthreads-reorder.exp gdb/testsuite/gdb.threads/watchthreads-reorder.c gdb/gnulib/m4/gnulib-comp.m4 gdb/gnulib/m4/gnulib-cache.m4 gdb/ChangeLog bfd/ChangeLog libdecnumber/dpd/decimal128Local.h libdecnumber/dpd/decimal128.h libdecnumber/dpd/decimal32.h libdecnumber/dpd/decimal64Symbols.h libdecnumber/decPackedSymbols.h libdecnumber/bid/host-ieee32.c libdecnumber/bid/decimal128Local.h libdecnumber/bid/decimal128.h libdecnumber/bid/host-ieee64.c libdecnumber/bid/decimal32.h libdecnumber/bid/decimal64Symbols.h libdecnumber/decNumberSymbols.h libdecnumber/decNumber.h libdecnumber/decContext.h libdecnumber/decDouble.h libdecnumber/decSingle.h opcodes/ChangeLog
Also current gdb/config/djgpp/djconfig.sh cannot find gdb/ChangeLog.002 .
In this state I find all the adjustments of gdb/config/djgpp/fnchange.lst not
much useful.
Including script generating fnchange.lst. It would need to adjust
gdb/config/djgpp/djconfig.sh checking existing files - and maybe something
more - but it already does not work. Some (few) of the generated translations
may need to be made static; currently they are all generated dynamically.
Current output:
http://people.redhat.com/jkratoch/fnchange.lst
File for this script (saving a rebuild of gdb.tar to list its files).
http://people.redhat.com/jkratoch/fnchange.cache
Regards,
Jan
------------------------------------------------------------------------------
#! /usr/bin/perl
# Copyright (C) 2010 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; see the file COPYING3. If not see
# <http://www.gnu.org/licenses/>.
use strict;
use warnings;
my $cache = $ARGV[0];
if ((@ARGV != 0 && @ARGV != 1) || $cache eq "-h" || $cache eq "--help") {
die "$0: [<filenames list cache file>]\n";
}
sub read_file($)
{
my($name) = @_;
local *F;
open F, $name or die "$name: $!";
defined (my $F = do { local $/ = undef; <F>; }) or die "$name: $!";
close F or die "$name: $!";
return $F;
}
sub write_file($$)
{
my($name, $content) = @_;
local *F;
open F, ">$name" or die "$name: $!";
print F $content or die "$name: $!";
close F or die "$name: $!";
}
my $tar;
if (!$cache || !-f $cache) {
my $F = read_file "git status; true |";
$F =~ /^# On branch .+\n\Qnothing to commit (working directory clean)\E\n$/
or die "Unexpected git status: $F";
my $cmd = "make -j1 -f src-release gdb.tar";
system $cmd and die "$cmd: $?";
my @glob = glob "gdb*.tar";
@glob == 1 or die "Unexpected gdb*.tar match: ".join " ",@glob;
my $g = $glob[0];
$tar = read_file "tar tf $g |";
write_file $cache, $tar if $cache;
$cmd = "git clean -df";
system $cmd and die "$cmd: $?";
} else {
$tar = read_file $cache;
}
my @tar = split /\n/, $tar;
@tar = sort @tar;
# orig -> mapped
my %map = ("." => ".");
# mapped -> count
my %used;
for (@tar) {
next if $_ eq ".";
s{^(?:\.|gdb-[^/]*)/}{./} or die "No (.|gdb-*)/ prefix: $_";
# Duplicate filename?
die if $map{$_};
# Simulate leading dir1 and dir1/dir2 for any dir1/dir2/file.
# gdb.tar specifically omits any directory entries themselves.
my @elem=split /\//, $_;
my @use;
while (@elem) {
push @use,shift @elem;
my $o = join ("/", @use);
next if $map{$o};
my($dir, $file) = ($o =~ m{^(.*)/([^/]+)$}) or die $o;
$_ = $file;
tr/-._a-zA-Z0-9//cd;
s/^[.]?//;
# Keep only the first dot, later dots convert to '-'.
s/[.]/%/;
tr/./-/;
tr/%/./;
s/^([^.]{1,8})[^.]*((?:[.][^.]{1,3})?)[^.]*$/$1$2/
or die "$o component $_ has two dots\n";
$file = $_;
$dir = $map{lc $dir} or die "Dir not mapped: $dir";
$_ = "$dir/$file";
my $valid83 = qr/^([^.]{1,8})((?:[.][^.]{1,3})?)$/o;
$file =~ /$valid83/ or die;
while ($used{lc $_}++) {
# Increase basename $FILE; $1 and $2 are matched by $VALID83.
my($base, $ext) = ($1,$2);
my($alpha, $num) = ($base =~ /^(.*?)(\d*)$/) or die;
$alpha =~ s/^(.*).$/$1/ if $num =~ /^9*$/ && 8 == length $base;
$num++;
$file = $alpha.$num.$ext;
$file =~ /$valid83/ or die;
$_ = "$dir/$file";
}
$map{lc $o} = $_;
$o =~ s{^\.\/}{\@V@/} or die;
$_ =~ s{^\.\/}{\@V@/} or die;
print "$o $_\n" if $o ne $_;
}
}
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: [RFC] DJGPP: fnchange.lst removal attempt
2010-04-12 0:09 [RFC] DJGPP: fnchange.lst removal attempt Jan Kratochvil
@ 2010-04-12 17:48 ` Eli Zaretskii
2010-04-12 20:05 ` Joel Brobecker
0 siblings, 1 reply; 5+ messages in thread
From: Eli Zaretskii @ 2010-04-12 17:48 UTC (permalink / raw)
To: Jan Kratochvil; +Cc: gdb-patches
> Date: Mon, 12 Apr 2010 02:08:56 +0200
> From: Jan Kratochvil <jan.kratochvil@redhat.com>
>
> tried to create a script to autogenerate and remove fnchange.lst
Thanks for doing this.
> but ... after
> writing it I found I am not able to even compile the current FSF GDB HEAD.
Don't worry about that. You can test the output of the script in a
different, much easier way: use the ARI script to check that no
file-name conflicts are reported by it after you update fnchange.lst.
That way, you don't need to set up a DOS system.
Btw, I take it that a release tarball will still include the file,
right? I wouldn't want to ask DJGPP users to have Perl installed, and
the need to produce the file will complicate the unpacking
instructions, which are already quite complicated (see
gdb/config/djgpp/README).
> fnchange.lst change of directory names:
> @V@/gdb/testsuite/gdb.gdbtk/EVERYTHING @V@/gdb/testsuite/gdb.tk/EVERYTHING
That's because we also have gdb/testsuite/gdb.gdb and
gdb/testsuite/gdb.gdbserver, which clash with it.
> Also current gdb/config/djgpp/djconfig.sh cannot find gdb/ChangeLog.002 .
Can you see why this happens? gdb/ChangeLog.002 should have been
produced by renaming gdb/ChangeLog-2002, by this line in fnchange.lst:
@V@/gdb/ChangeLog-2002 @V@/gdb/ChangeLog.002
> In this state I find all the adjustments of gdb/config/djgpp/fnchange.lst not
> much useful.
It worked for me during GDB 7.0 pretest. But I agree that maintaining
it by hand is annoying and error-prone. So I'm very much in favor of
producing it with a script.
Thanks.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [RFC] DJGPP: fnchange.lst removal attempt
2010-04-12 17:48 ` Eli Zaretskii
@ 2010-04-12 20:05 ` Joel Brobecker
2010-04-12 20:48 ` Jan Kratochvil
0 siblings, 1 reply; 5+ messages in thread
From: Joel Brobecker @ 2010-04-12 20:05 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Jan Kratochvil, gdb-patches
> Btw, I take it that a release tarball will still include the file,
> right? I wouldn't want to ask DJGPP users to have Perl installed, and
> the need to produce the file will complicate the unpacking
> instructions, which are already quite complicated (see
> gdb/config/djgpp/README).
The tarballs are produced using "make -f src-release gdb.tar", so
the src-release makefile will need to be adjusted accordingly.
--
Joel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [RFC] DJGPP: fnchange.lst removal attempt
2010-04-12 20:05 ` Joel Brobecker
@ 2010-04-12 20:48 ` Jan Kratochvil
2010-04-12 20:57 ` Eli Zaretskii
0 siblings, 1 reply; 5+ messages in thread
From: Jan Kratochvil @ 2010-04-12 20:48 UTC (permalink / raw)
To: Joel Brobecker; +Cc: Eli Zaretskii, gdb-patches
On Mon, 12 Apr 2010 22:05:20 +0200, Joel Brobecker wrote:
> > Btw, I take it that a release tarball will still include the file,
> > right? I wouldn't want to ask DJGPP users to have Perl installed, and
> > the need to produce the file will complicate the unpacking
> > instructions, which are already quite complicated (see
> > gdb/config/djgpp/README).
>
> The tarballs are produced using "make -f src-release gdb.tar", so
> the src-release makefile will need to be adjusted accordingly.
I was originally thinking generated fnchange.lst would be even in the
repository as generating the list requires gdb.tar which is difficult to
create.
But it is true it would be fine to generate fnchange.lst at the dist time.
Just the Perl script would be worth adjusting from git to CVS dependency.
But that is not the main point; I should try again to build GDB on DOS.
If no one is able to build it... I thought Eli Z. builds it regularly.
Thanks,
Jan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [RFC] DJGPP: fnchange.lst removal attempt
2010-04-12 20:48 ` Jan Kratochvil
@ 2010-04-12 20:57 ` Eli Zaretskii
0 siblings, 0 replies; 5+ messages in thread
From: Eli Zaretskii @ 2010-04-12 20:57 UTC (permalink / raw)
To: Jan Kratochvil; +Cc: brobecker, gdb-patches
> Date: Mon, 12 Apr 2010 22:48:21 +0200
> From: Jan Kratochvil <jan.kratochvil@redhat.com>
> Cc: Eli Zaretskii <eliz@gnu.org>, gdb-patches@sourceware.org
>
> But that is not the main point; I should try again to build GDB on DOS.
> If no one is able to build it... I thought Eli Z. builds it regularly.
I'm building it from time to time, but the last time was around the
release of 7.0. I'm too busy lately adding bidirectional display to
Emacs, sorry.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2010-04-12 20:57 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-04-12 0:09 [RFC] DJGPP: fnchange.lst removal attempt Jan Kratochvil
2010-04-12 17:48 ` Eli Zaretskii
2010-04-12 20:05 ` Joel Brobecker
2010-04-12 20:48 ` Jan Kratochvil
2010-04-12 20:57 ` Eli Zaretskii
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox