Reopening, this bug still happen on natty.
Trying to execute appears:
$ gnat
fatal error, run-time library not installed correctly
cannot locate file system.ads
raised TYPES.UNRECOVERABLE_ERROR : targparm.adb:177
Searching with strace, show that gnat look for gcc 4.4, but the folder
is 4.4.4:
$ strace gnat
execve("/usr/bin/gnat", ["gnat"], [/* 42 vars */]) = 0
brk(0) = 0x849f000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb774f000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=118164, ...}) = 0
mmap2(NULL, 118164, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7732000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/i386-linux-gnu/libgnat-4.4.so.1", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0000\\\f\0004\0\0\0"...,
512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=2906304, ...}) = 0
mmap2(NULL, 2959424, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x67a000
mmap2(0x938000, 36864, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2bd) = 0x938000
mmap2(0x941000, 47168, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x941000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/libgnatvsn.so.4.4", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0 \2\5\0004\0\0\0"...,
512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=967636, ...}) = 0
mmap2(NULL, 3272432, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x110000
mmap2(0x1fa000, 12288, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xe9) = 0x1fa000
mmap2(0x1fd000, 2301680, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x1fd000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/libgnatprj.so.4.4", O_RDONLY) = 3
read(3,
"\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\340\347\3\0004\0\0\0"..., 512)
= 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=1294248, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7731000
mmap2(NULL, 3833224, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0xa80000
mmap2(0xbb9000, 12288, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x139) = 0xbb9000
mmap2(0xbbc000, 2538888, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xbbc000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/libgcc_s.so.1", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0P\37\0\0004\0\0\0"...,
512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=108040, ...}) = 0
mmap2(NULL, 111148, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x42f000
mmap2(0x449000, 8192, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19) = 0x449000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/i386-linux-gnu/libc.so.6", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\220o\1\0004\0\0\0"...,
512) = 512
fstat64(3, {st_mode=S_IFREG|0755, st_size=1434180, ...}) = 0
mmap2(NULL, 1444360, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x4ed000
mprotect(0x647000, 4096, PROT_NONE) = 0
mmap2(0x648000, 12288, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x15a) = 0x648000
mmap2(0x64b000, 10760, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x64b000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/i386-linux-gnu/libm.so.6", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\2604\0\0004\0\0\0"...,
512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=149392, ...}) = 0
mmap2(NULL, 151680, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) =
0x9db000
mmap2(0x9ff000, 8192, PROT_READ|PROT_WRITE,
MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x23) = 0x9ff000
close(3) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7730000
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb772f000
set_thread_area({entry_number:-1 -> 6, base_addr:0xb772f6c0, limit:1048575,
seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0,
useable:1}) = 0
mprotect(0x9ff000, 4096, PROT_READ) = 0
mprotect(0x648000, 8192, PROT_READ) = 0
mprotect(0x449000, 4096, PROT_READ) = 0
mprotect(0x4eb000, 4096, PROT_READ) = 0
munmap(0xb7732000, 118164) = 0
sigaltstack({ss_sp=0x948840, ss_flags=0, ss_size=16384}, NULL) = 0
rt_sigaction(SIGABRT, {0x8bb270, [], SA_RESTART|SA_NODEFER|SA_SIGINFO}, NULL,
8) = 0
rt_sigaction(SIGFPE, {0x8bb270, [], SA_RESTART|SA_NODEFER|SA_SIGINFO}, NULL, 8)
= 0
rt_sigaction(SIGILL, {0x8bb270, [], SA_RESTART|SA_NODEFER|SA_SIGINFO}, NULL, 8)
= 0
rt_sigaction(SIGBUS, {0x8bb270, [], SA_RESTART|SA_NODEFER|SA_SIGINFO}, NULL, 8)
= 0
rt_sigaction(SIGSEGV, {0x8bb270, [],
SA_STACK|SA_RESTART|SA_NODEFER|SA_SIGINFO}, NULL, 8) = 0
fstat64(2, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 4), ...}) = 0
fstat64(0, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 4), ...}) = 0
fstat64(1, {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 4), ...}) = 0
brk(0) = 0x849f000
brk(0x84c0000) = 0x84c0000
brk(0x84e6000) = 0x84e6000
getcwd("/home/shakaran/Desktop/PracticasSC", 4096) = 35
brk(0x8507000) = 0x8507000
mmap2(NULL, 176128, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0xb7704000
stat64("/usr/local/sbin/gnat", 0xbfb7309c) = -1 ENOENT (No such file or
directory)
stat64("/usr/local/bin/gnat", 0xbfb7309c) = -1 ENOENT (No such file or
directory)
stat64("/usr/sbin/gnat", 0xbfb7309c) = -1 ENOENT (No such file or directory)
stat64("/usr/bin/gnat", {st_mode=S_IFREG|0755, st_size=266304, ...}) = 0
readlink("/usr", 0xbfb70210, 4098) = -1 EINVAL (Invalid argument)
readlink("/usr/bin", 0xbfb70210, 4098) = -1 EINVAL (Invalid argument)
readlink("/usr/bin/gnat", 0xbfb70210, 4098) = -1 EINVAL (Invalid argument)
open("/usr/share/ada/adainclude/ada_source_path", O_RDONLY) = -1 ENOENT (No
such file or directory)
open("/usr/share/ada/adainclude/ada_object_path", O_RDONLY) = -1 ENOENT (No
such file or directory)
stat64("system.ads", 0xbfb73bac) = -1 ENOENT (No such file or directory)
stat64("/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4.4/adainclude/system.ads",
0xbfb73b2c) = -1 ENOENT (No such file or directory)
write(1, "fatal error, run-time library no"..., 54fatal error, run-time library
not installed correctly
) = 54
write(1, "cannot locate file system.ads\n", 30cannot locate file system.ads
) = 30
write(2, "\n", 1
) = 1
write(2, "r", 1r) = 1
write(2, "a", 1a) = 1
write(2, "i", 1i) = 1
write(2, "s", 1s) = 1
write(2, "e", 1e) = 1
write(2, "d", 1d) = 1
write(2, " ", 1 ) = 1
write(2, "T", 1T) = 1
write(2, "Y", 1Y) = 1
write(2, "P", 1P) = 1
write(2, "E", 1E) = 1
write(2, "S", 1S) = 1
write(2, ".", 1.) = 1
write(2, "U", 1U) = 1
write(2, "N", 1N) = 1
write(2, "R", 1R) = 1
write(2, "E", 1E) = 1
write(2, "C", 1C) = 1
write(2, "O", 1O) = 1
write(2, "V", 1V) = 1
write(2, "E", 1E) = 1
write(2, "R", 1R) = 1
write(2, "A", 1A) = 1
write(2, "B", 1B) = 1
write(2, "L", 1L) = 1
write(2, "E", 1E) = 1
write(2, "_", 1_) = 1
write(2, "E", 1E) = 1
write(2, "R", 1R) = 1
write(2, "R", 1R) = 1
write(2, "O", 1O) = 1
write(2, "R", 1R) = 1
write(2, " ", 1 ) = 1
write(2, ":", 1:) = 1
write(2, " ", 1 ) = 1
write(2, "t", 1t) = 1
write(2, "a", 1a) = 1
write(2, "r", 1r) = 1
write(2, "g", 1g) = 1
write(2, "p", 1p) = 1
write(2, "a", 1a) = 1
write(2, "r", 1r) = 1
write(2, "m", 1m) = 1
write(2, ".", 1.) = 1
write(2, "a", 1a) = 1
write(2, "d", 1d) = 1
write(2, "b", 1b) = 1
write(2, ":", 1:) = 1
write(2, "1", 11) = 1
write(2, "7", 17) = 1
write(2, "7", 17) = 1
write(2, "\n", 1
) = 1
exit_group(1) = ?
So, just for check:
$ sudo find / -name system.ads
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4/rts-sjlj/adainclude/system.ads
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4/rts-native/adainclude/system.ads
I dit the symbolic link recommended on comment #3 for David adapting to
my architecture paths:
$ sudo ln -s /usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4.4
And now, it works PERFECTLY:
$ gnat
GNAT 4.4.5
Copyright 1996-2008, Free Software Foundation, Inc.
List of available commands
gnat bind gnatbind
gnat chop gnatchop
gnat clean gnatclean
gnat compile gnatmake -f -u -c
gnat check gnatcheck
gnat sync gnatsync
gnat elim gnatelim
gnat find gnatfind
gnat krunch gnatkr
gnat link gnatlink
gnat list gnatls
gnat make gnatmake
gnat metric gnatmetric
gnat name gnatname
gnat preprocess gnatprep
gnat pretty gnatpp
gnat stack gnatstack
gnat stub gnatstub
gnat xref gnatxref
Commands find, list, metric, pretty, stack, stub and xref accept project
file switches -vPx, -Pprj and -Xnam=val
But still more funny, because the error can would to happen with more compiler
versions that I have:
$ ls /usr/lib/gcc/i686-linux-gnu/4.
4.1/ 4.1.3/ 4.4/ 4.4.4/ 4.4.5/ 4.5/ 4.5.1/ 4.5.2/
Now, more problems, trying to compile a basic example like:
$gnat make hello.adb
gnatmake search wrongly the gnat1 binary:
stat64("/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4.4/adalib/hello.ali",
0xbfc1f66c) = -1 ENOENT (No such file or directory)
write(2, "gcc-4.4 -c hello.adb\n", 21gcc-4.4 -c hello.adb
) = 21
clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD,
child_tidptr=0xb77bc728) = 17773
waitpid(-1, gcc-4.4: error trying to exec 'gnat1': execvp: No existe el fichero
o el directorio
[{WIFEXITED(s) && WEXITSTATUS(s) == 1}], 0) = 17773
--- SIGCHLD (Child exited) @ 0 (0) ---
write(2, "gnatmake: \"hello.adb\" compilatio"..., 40gnatmake: "hello.adb"
compilation error
) = 40
exit_group(4) = ?
It is located for me on:
$ sudo find / -name gnat1
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4/gnat1
So I did:
$ sudo mv /usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4.4/gnat1
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4.4/gnat1.backup
$ sudo ln -s /usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4/gnat1
/usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.4.4/gnat1
But still the same error, and hello.adb exist on my folder. So I am lost
with this error.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/250173
Title:
gnat broken with last gcc update
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs