Bug 1109392 - wrong target used for armv7hl
Summary: wrong target used for armv7hl
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: gprbuild
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Pavel Zhukov
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1095083 1105979 1105989 1106665 1107446
TreeView+ depends on / blocked
 
Reported: 2014-06-13 19:08 UTC by Julian Leyh
Modified: 2014-11-01 16:57 UTC (History)
4 users (show)

Fixed In Version: gprbuild-2013-13.fc21
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-10-11 22:23:05 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
complete output of gprconfig with wrong target (4.63 KB, text/plain)
2014-06-13 19:08 UTC, Julian Leyh
no flags Details
complete output of gprconfig with correct target (6.90 KB, text/plain)
2014-06-13 19:10 UTC, Julian Leyh
no flags Details

Description Julian Leyh 2014-06-13 19:08:40 UTC
Created attachment 908684 [details]
complete output of gprconfig with wrong target

gprbuild tries to use wrong target "armv7hl-redhat-linux-gnu" instead of "armv7hl-redhat-linux-gnueabi", which leads to gprconfig not finding any compilers.

$ cat foo.gpr
project Foo is
   for Source_Dirs use ("src");
   for Object_Dir use "obj";
   for Library_Name use "foo";
   for Library_Dir use "lib";
end Foo;
$ gprbuild -v -P foo.gpr
GPRBUILD GPL 2013 (20130314) (armv7hl-redhat-linux-gnu)
Copyright (C) 2004-2013, Free Software Foundation, Inc.
gprconfig --batch -o /home/oenone/test/obj/auto.cgpr --target=armv7hl-redhat-linux-gnu --config=ada,,
Error: no matching compiler found for --config=ada,,,,
Creating configuration file: /home/oenone/test/obj/auto.cgpr
Checking configuration /home/oenone/test/obj/auto.cgpr

==============Error messages for project file: /home/oenone/test/foo.gpr
     1. project Foo is
                |
        >>> no languages defined for this project

     4.    for Library_Name use "foo";
                                |
        >>> warning: libraries are not supported on this platform

 6 lines: 1 error, 1 warning
gprbuild: "foo.gpr" processing failed
$ /usr/bin/gprconfig -v --batch -o /home/oenone/test/obj/auto.cgpr --target=armv7hl-redhat-linux-gnu --config=ada,,
Parsing knowledge base at /usr/share/gprconfig
[...]
Language ada requires a compiler
Only compilers matching target armv7hl-redhat-linux-gnu will be preserved
create a new target set for armv7hl-redhat-linux-gnu
Completing info for --config parameters, extra_dirs=
  Will examine P /usr/local/bin
  Will examine P /usr/bin
[...]
  Foreach compiler in /usr/bin regexp=TRUE extra_dir=FALSE
[...]
    GNAT is candidate: filename=gnatmake
      target: executing "gcc -dumpmachine" output=<use -v -v> no match
      target: grep matched="armv7hl-redhat-linux-gnueabi"
      Target for this compiler does not match --target
[...]
Error: no matching compiler found for --config=ada,,,,
Creating configuration file: /home/oenone/test/obj/auto.cgpr


running gprconfig with correct target works:
$ /usr/bin/gprconfig -v --batch -o /home/oenone/test/obj/auto.cgpr --target=armv7hl-redhat-linux-gnueabi --config=ada,,
Parsing knowledge base at /usr/share/gprconfig
[...]
Language ada requires a compiler
Only compilers matching target armv7hl-redhat-linux-gnueabi will be preserved
create a new target set for armv7hl-redhat-linux-gnueabi
Completing info for --config parameters, extra_dirs=
  Will examine P /usr/local/bin
  Will examine P /usr/bin
[...]
  Foreach compiler in /usr/bin regexp=TRUE extra_dir=FALSE
[...]
    GNAT is candidate: filename=gnatmake
      target: executing "gcc -dumpmachine" output=<use -v -v> no match
      target: grep matched="armv7hl-redhat-linux-gnueabi"
      version: executing "gnatls -v" output=<use -v -v> no match
      version: grep matched="4.9"
      variables: executing "gcc -v" output=<use -v -v> no match
      variables: grep matched="4.9.0"
      languages: constant := Ada
[...]
      Done search directories
      Saving compiler for possible backtracking: Ada,4.9,default,/usr/bin/,GNAT (matches --config ada,,,,)
      Selecting it since this filter was not matched yet  1/ 1
Parsing knowledge base at /usr/lib/gcc/armv7hl-redhat-linux-gnueabi/4.9.0
Creating configuration file: /home/oenone/test/obj/auto.cgpr

Comment 1 Julian Leyh 2014-06-13 19:10:19 UTC
Created attachment 908686 [details]
complete output of gprconfig with correct target

Comment 2 Pavel Zhukov 2014-06-13 19:48:48 UTC
(In reply to Julian Leyh from comment #0)
> Created attachment 908684 [details]
> complete output of gprconfig with wrong target
> 
> gprbuild tries to use wrong target "armv7hl-redhat-linux-gnu" instead of
> "armv7hl-redhat-linux-gnueabi", which leads to gprconfig not finding any
> compilers.

Thank you reporting this. I'm aware of the issue but not sure if the problem is in gprbuild. 

See configure options here: https://kojipkgs.fedoraproject.org//packages/gprbuild/2013/11.fc21/data/logs/armv7hl/build.log for example. 

For some reasons koji passes armv7hl-redhat-linux-gnu isntead of "expected" armv7hl-redhat-linux-gnueabi (mock under qemu uses "right" option...

Comment 3 Pavel Zhukov 2014-06-13 19:49:01 UTC
(In reply to Julian Leyh from comment #0)
> Created attachment 908684 [details]
> complete output of gprconfig with wrong target
> 
> gprbuild tries to use wrong target "armv7hl-redhat-linux-gnu" instead of
> "armv7hl-redhat-linux-gnueabi", which leads to gprconfig not finding any
> compilers.

Thank you reporting this. I'm aware of the issue but not sure if the problem is in gprbuild. 

See configure options here: https://kojipkgs.fedoraproject.org//packages/gprbuild/2013/11.fc21/data/logs/armv7hl/build.log for example. 

For some reasons koji passes armv7hl-redhat-linux-gnu isntead of "expected" armv7hl-redhat-linux-gnueabi (mock under qemu uses "right" option...

Comment 4 Pavel Zhukov 2014-06-13 22:14:36 UTC
Seems like gprconfig is not supported on native arm at all. I've added it to targets manually but it should be done in upstream as well...

Comment 5 Fedora Update System 2014-10-11 21:54:00 UTC
gprbuild-2013-13.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/gprbuild-2013-13.fc21

Comment 6 Fedora Update System 2014-11-01 16:57:17 UTC
gprbuild-2013-13.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.