<?xml version="1.0" ?>
<!DOCTYPE gprconfig [
   <!ENTITY gnat_pre_6.4
     '<compiler language="Ada" version="3.16" />
      <compiler language="Ada" version="5.00" />
      <compiler language="Ada" version="5.01" />
      <compiler language="Ada" version="5.02" />
      <compiler language="Ada" version="5.03" />
      <compiler language="Ada" version="5.04" />
      <compiler language="Ada" version="6.0" />
      <compiler language="Ada" version="6.1" />
      <compiler language="Ada" version="6.2" />
      <compiler language="Ada" version="6.3" />
      <compiler language="Ada" version="6.4" />'
   >

   <!ENTITY if_not_vx7r2_llvm_compiler
   '
      <compilers negate="true">
         <compiler name="^CLANG-C-*;$" />
         <compiler name="^GNAT_LLVM-*;$" />
      </compilers>
   '>

   <!ENTITY if_vx7r2_llvm_compiler
   '
      <compilers>
         <compiler name="^CLANG-C-*;$" />
         <compiler name="^GNAT_LLVM-*;$" />
      </compilers>
   '>
]>

<gprconfig>

  <!--  This configuration shows how to link a multi language
        application with GNAT and either GCC or toolchains
        derived from gcc -->

  <!--  Export File / Object Lister  -->

  <configuration>
    <targets>
      <target name="^i686-pc-mingw32$" />
    </targets>
    <hosts negate="true">
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Object_Lister use ("i686-pc-mingw32-nm", "-g", "--no-demangle");
   for Object_Lister_Matcher use " [TDRB] _(.*)";

   package Linker is
      for Export_File_Format use "DEF";
      for Export_File_Switch use "-Wl,";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^x86_64-pc-mingw32$" />
    </targets>
    <hosts negate="true">
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Object_Lister use ("x86_64-pc-mingw32-nm", "-g", "--no-demangle");
   for Object_Lister_Matcher use " [TDRB] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^x86_64-w64-mingw32$" />
    </targets>
    <hosts negate="true">
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Object_Lister use ("x86_64-w64-mingw32-nm", "-g", "--no-demangle");
   for Object_Lister_Matcher use " [TDRB] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^i686-pc-mingw32$" />
    </targets>
    <hosts>
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Object_Lister use ("nm", "-g", "--no-demangle");
   for Object_Lister_Matcher use " [TDRB] _(.*)";

   package Linker is
      for Export_File_Format use "DEF";
      for Export_File_Switch use "-Wl,";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^x86_64-.*-mingw32$" />
      <!-- LLVM version of the mingw32 triplet -->
      <target name="^x86_64-.*-windows-gnu$" />
    </targets>
    <hosts>
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Object_Lister use ("nm", "-g", "--no-demangle");
   for Object_Lister_Matcher use " [TDRB] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^i686.*-linux.*$" />
      <target name="^x86_64.*-linux.*" />
    </targets>
    <hosts>
      <host name="^x86_64.*-linux.*" />
      <host name="^i686.*-linux.*$" />
    </hosts>
    <config>
   for Object_Lister use ("nm", "-g");
   for Object_Lister_Matcher use " [TDRB] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="Ada" runtime="ios-simulator" />
    </compilers>
    <targets>
       <target name="^i.86-.*darwin.*$" />
       <target name="^x86_64-.*darwin.*$" />
    </targets>
    <config>
   for Object_Lister use ("nm", "-g");
   for Object_Lister_Matcher use " [TDS] (.*)";

   package Linker is
      for Export_File_Format use "FLAT";
      for Export_File_Switch use "-Wl,-exported_symbols_list,";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <!-- aarch64-linux - native compiler. -->
    <targets>
      <target name="^aarch64-linux-gnu$" />
    </targets>
    <hosts>
      <host name="^aarch64-linux-gnu$" />
    </hosts>
    <config>
   for Object_Lister use ("nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <!-- aarch64-linux - cross compiler. -->
    <targets>
      <target name="^aarch64-.*linux-gnu$" />
    </targets>
    <hosts negate="true">
      <host name="^aarch64-linux-gnu$" />
    </hosts>
    <config>
   for Object_Lister use ("aarch64-linux-gnu-nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-linux-gnueabi$" />
    </targets>
    <config>
   for Object_Lister use ("arm-linux-gnueabi-nm", "-g");
   for Object_Lister_Matcher use " [TDSR] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-linux-gnueabihf$" />
    </targets>
    <config>
   for Object_Lister use ("arm-linux-gnueabihf-nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-.*linux.*$" />
    </targets>
    <hosts negate="true">
      <!-- Cross compiler case -->
      <host name="^(ppc|powerpc)-.*linux.*$" />
    </hosts>
    <config>
   for Object_Lister use ("powerpc-generic-linux-gnu-nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-.*linux.*$" />
    </targets>
    <hosts>
      <!-- Native compiler case -->
      <host name="^(ppc|powerpc)-.*linux.*$" />
    </hosts>
    <config>
   for Object_Lister use ("nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc64-generic-linux-gnu$" />
    </targets>
    <config>
   for Object_Lister use ("powerpc64-generic-linux-gnu-nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^e500v2-gnu-linux$" />
    </targets>
    <config>
   for Object_Lister use ("e500v2-gnu-linux-nm", "-g");
   for Object_Lister_Matcher use " [TDRBSG] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64-nto-qnx$" />
    </targets>
    <config>
   for Object_Lister use ("aarch64-nto-qnx-nm", "-g");
   for Object_Lister_Matcher use " [TDRBS] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64-thales-fastos$" />
    </targets>
    <config>
   for Object_Lister use ("aarch64-thales-fastos-nm", "-g");
   for Object_Lister_Matcher use " [TDRBS] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-nto-qnx$" />
    </targets>
    <config>
   for Object_Lister use ("arm-nto-qnx-nm", "-g");
   for Object_Lister_Matcher use " [TDRBS] (.*)";

   package Linker is
      for Export_File_Format use "GNU";
      for Export_File_Switch use "-Wl,--version-script=";
   end Linker;
    </config>
  </configuration>

  <!--  Archiver.  -->
  <configuration>
    <targets>
      <target name="^x86_64-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("x86_64-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("x86_64-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^i686-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("i686-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("i686-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^visium-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("visium-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("visium-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^cuda$" />
    </targets>
    <config>
   for Archive_Builder  use ("cuda-gcc");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <!-- This is the Ada version of this rule using ${PREFIX(Ada)} -->
  <configuration>
    <compilers>
      <compiler language="Ada" />
    </compilers>
    <targets>
      <target name="^arm(-none)?-eabi$" />
      <target name=".*lynxos178.*$" />
      <target name="^r7-elf$" />
      <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("${PREFIX(Ada)}ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("${PREFIX(Ada)}ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <!-- This is the C version of this rule using ${PREFIX(C)} -->
  <configuration>
    <compilers>
      <compiler language="c" />
    </compilers>
    <targets>
      <target name="^arm(-none)?-eabi$" />
      <target name=".*lynxos178.*$" />
      <target name="^r7-elf$" />
      <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("${PREFIX(c)}ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("${PREFIX(c)}ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <!-- This is the C++ version of this rule using ${PREFIX(c++)} -->
  <configuration>
    <compilers>
      <compiler language="c++" />
    </compilers>
    <targets>
      <target name="^arm(-none)?-eabi$" />
      <target name=".*lynxos178.*$" />
      <target name="^r7-elf$" />
      <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("${PREFIX(c++)}ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("${PREFIX(c++)}ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^m68020-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("m68020-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("m68020-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^morello(-unknown-unknown)?-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("morello-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("morello-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^morello-freebsd\d+$" />
    </targets>
    <config>
   for Archive_Builder  use ("${PREFIX(ada)}ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("${PREFIX(ada)}ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("powerpc-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("powerpc-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-elf-lynxos$" />
    </targets>
    <config>
   for Archive_Builder  use ("ar", "crs");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-eabispe$" />
    </targets>
    <config>
   for Archive_Builder  use ("powerpc-eabispe-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("powerpc-eabispe-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^i686-pc-mingw32$" />
    </targets>
    <hosts negate="true">
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Archive_Builder  use ("i686-pc-mingw32-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("i686-pc-mingw32-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^i686-pc-mingw32$" />
    </targets>
    <hosts>
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^x86_64-pc-mingw32$" />
    </targets>
    <hosts negate="true">
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Archive_Builder  use ("x86_64-pc-mingw32-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("x86_64-pc-mingw32-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^x86_64-w64-mingw32$" />
    </targets>
    <hosts negate="true">
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Archive_Builder  use ("x86_64-w64-mingw32-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("x86_64-w64-mingw32-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^x86_64-.*-mingw32$" />
      <!-- LLVM version of the mingw32 triplet -->
      <target name="^x86_64-.*-windows-gnu$" />
    </targets>
    <hosts>
      <host name="^i686-.*-mingw32$" />
      <host name="^x86_64-.*-mingw32$" />
    </hosts>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-generic-linux-gnu$" />
    </targets>
    <hosts negate="true">
      <!-- Cross compiler case -->
      <host name="^(ppc|powerpc)-.*linux.*$" />
    </hosts>
    <config>
   for Archive_Builder  use ("powerpc-generic-linux-gnu-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("powerpc-generic-linux-gnu-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-generic-linux-gnu$" />
    </targets>
    <hosts>
      <!-- Native compiler case -->
      <host name="^(ppc|powerpc)-.*linux.*$" />
    </hosts>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc64-generic-linux-gnu$" />
    </targets>
    <config>
   for Archive_Builder  use ("powerpc64-generic-linux-gnu-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("powerpc64-generic-linux-gnu-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-linux-androideabi$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-linux-androideabi-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-linux-androideabi-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-linux-gnueabi$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-linux-gnueabi-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-linux-gnueabi-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-linux-gnueabihf$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-linux-gnueabihf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-linux-gnueabihf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <!-- aarch64-android - cross compiler. -->
    <targets>
      <target name="^aarch64-linux-android$" />
    </targets>
    <config>
   for Archive_Builder  use ("aarch64-linux-android-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-linux-android-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <!-- aarch64-linux - native compiler. -->
    <targets>
      <target name="^aarch64-linux-gnu$" />
    </targets>
    <hosts>
      <host name="^aarch64-linux-gnu$" />
    </hosts>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <!-- aarch64-linux - cross compiler. -->
    <targets>
      <target name="^aarch64-.*linux-gnu$" />
    </targets>
    <hosts negate="true">
      <host name="^aarch64-linux-gnu$" />
    </hosts>
    <config>
   for Archive_Builder  use ("aarch64-linux-gnu-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-linux-gnu-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64-thales-fastos$" />
    </targets>
    <config>
   for Archive_Builder  use ("aarch64-thales-fastos-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-thales-fastos-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64-nto-qnx$" />
    </targets>
    <config>
   for Archive_Builder  use ("aarch64-nto-qnx-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-nto-qnx-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-nto-qnx$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-nto-qnx-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-nto-qnx-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64-rtems.*$"/>
    </targets>
    <config>
   for Archive_Builder  use ("aarch64-rtems6-gcc-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-rtems6-gcc-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^e500v2-gnu-linux$" />
    </targets>
    <config>
   for Archive_Builder  use ("e500v2-gnu-linux-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("e500v2-gnu-linux-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^erc32-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("erc32-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("erc32-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^leon-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("leon-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("leon-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^leon3-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("leon3-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("leon3-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64(-unknown-unknown)?-elf$" />
    </targets>
    <config>
   for Archive_Builder  use ("aarch64-elf-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-elf-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^avr$" />
    </targets>
    <config>
   for Archive_Builder  use ("avr-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("avr-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^aarch64-sysgo-pikeos5$" />
    </targets>
    <config>
   for Archive_Builder  use ("aarch64-sysgo-pikeos5-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("aarch64-sysgo-pikeos5-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-sysgo-pikeos$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-sysgo-pikeos-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-sysgo-pikeos-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-sysgo-pikeos4$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-sysgo-pikeos4-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-sysgo-pikeos4-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^arm-sysgo-pikeos5$" />
    </targets>
    <config>
   for Archive_Builder  use ("arm-sysgo-pikeos5-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("arm-sysgo-pikeos5-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^i586-sysgo-pikeos$" />
    </targets>
    <config>
   for Archive_Builder  use ("i586-sysgo-pikeos-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("i586-sysgo-pikeos-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-sysgo-pikeos$" />
    </targets>
    <config>
   for Archive_Builder  use ("powerpc-sysgo-pikeos-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("powerpc-sysgo-pikeos-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^powerpc-sysgo-pikeos5$" />
    </targets>
    <config>
   for Archive_Builder  use ("powerpc-sysgo-pikeos5-ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("powerpc-sysgo-pikeos5-ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <!-- Do not run ranlib on AIX -->
  <configuration>
    <targets>
      <target name="^.*aix.*$" />
    </targets>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Suffix   use ".a";

   package Linker is
      for Max_Command_Line_Length use "15000";
      for Response_File_Format    use "object_list";
      for Response_File_Switches  use ("-Wl,-f,");
      for Map_File_Option         use "-Wl,-Map,";
   end Linker;
    </config>
  </configuration>

  <!-- Do not run ranlib on IA64 HPUX -->
  <configuration>
    <targets>
      <target name=".*ia64.*hpux.*" />
    </targets>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <!-- Provide a dummy Archive_Builder and no ranlib when generating C -->
  <configuration>
    <targets>
      <target name="^c$" />
    </targets>
    <config>
   for Archive_Builder  use ("c-gcc");
    </config>
  </configuration>

  <configuration>
    <targets negate="true">
      <target name="^x86_64-elf$"/>
      <target name="^i686-elf$"/>
      <target name="^.*-wrs-vxworks.*$" />
      <target name="^visium-elf$"/>
      <target name="^r7-elf$" />
      <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
      <target name="^m68020-elf$"/>
      <target name="^morello(-unknown-unknown)?-elf$"/>
      <target name="^morello-freebsd\d+$"/>
      <target name="^powerpc-elf$"/>
      <target name="^powerpc-elf-lynxos$" />
      <target name="^.*lynxos178.*$" />
      <target name="^powerpc-eabispe$"/>
      <target name="^avr$"/>
      <target name="^erc32-elf$"/>
      <target name="^leon-elf$"/>
      <target name="^leon3-elf$"/>
      <target name="^arm(-none)?-eabi$"/>
      <target name="^aarch64(-unknown-unknown)?-elf$"/>
      <target name="^.*aix.*$" />
      <target name="^.*ia64.*hpux.*$" />
      <target name="^.*pc-mingw32$" />
      <target name="^.*-pikeos.*$" />
      <target name="^.*-linux.*" />
      <target name="^.*-fastos.*$" />
      <target name="^.*-gnueabihf$" />
      <target name="^.*-gnueabi$" />
      <target name="^c$" />
      <target name="^.*-qnx[0-9]*$"/>
      <target name="^.*-rtems.*$"/>
      <target name="^cuda$" />
    </targets>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

  <!-- Do not use the native ar on cross linuxes.
       ??? This will be simplified when switching to the new scheme for
       cross linuxes; then we'll have a simple way to check if a toolchain
       is native or cross.  -->

  <configuration>
    <targets>
      <target name="^i.86-.*linux.*" />
      <target name="^x86_64-.*linux.*" />
    </targets>
    <hosts>
      <host name="^i.86-.*linux.*" />
      <host name="^x86_64-.*linux.*" />
    </hosts>
    <config>
   for Archive_Builder  use ("ar", "cr");
   for Archive_Builder_Append_Option use ("q");
   for Archive_Indexer  use ("ranlib");
   for Archive_Suffix   use ".a";
    </config>
  </configuration>

<!--  Systems with no support for shared libraries, but with static libraries -->
  <configuration>
    <targets>
       <target name="^.*aix.*$" />
       <target name="^.*lynxos.*$" />
       <target name="^x86_64-elf$" />
       <target name="^i686-elf$" />
       <target name="^visium-elf$" />
       <target name="^r7-elf$" />
       <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
       <target name="^m68020-elf$" />
       <target name="^morello(-unknown-unknown)?-elf$" />
       <target name="^powerpc-elf$" />
       <target name="^powerpc-eabispe$" />
       <target name="^erc32-elf$" />
       <target name="^leon-elf$" />
       <target name="^leon3-elf$" />
       <target name="^aarch64(-unknown-unknown)?-elf$" />
       <target name="^arm(-none)?-eabi$" />
       <target name="^arm-apple-darwin.*$" />
       <target name="^(arm|powerpc|i586)-wrs-vxworks.*$" />
       <target name="^avr$" />
       <target name="^.*-pikeos.*$" />
       <target name="^c$" />
       <target name="^llvm$" />
       <target name="^.*-rtems.*$"/>
    </targets>
    <config>
   for Library_Support  use "static_only";
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^c$" />
      <target name="jvm" />
    </targets>
    <config>
      for Disable_Linking use "true";
    </config>
  </configuration>

  <!-- DOTNET -->
  <configuration>
    <targets>
       <target name="dotnet" />
    </targets>
    <config>
   for Library_Support use "none";

   package Linker is
      for Driver use "dotnet-ld";
   end Linker;
    </config>
  </configuration>

  <!-- JGNAT -->
  <configuration>
    <targets>
       <target name="jvm" />
    </targets>
    <config>
   for Library_Support use "none";
    </config>
  </configuration>

  <!-- Symbolic links supported everywhere except on mingw and VMS -->

  <configuration>
    <hosts negate="true">
      <host name="^.*mingw.*$" />
      <host name="^.*vms.*$" />
    </hosts>
    <config>
   for Symbolic_Link_Supported use "true";
   for Library_Major_Minor_Id_Supported use "true";
    </config>
  </configuration>

  <configuration>
    <hosts>
      <host name="^.*mingw.*$" />
      <host name="^.*vms.*$" />
    </hosts>
    <config>
   for Symbolic_Link_Supported use "false";
   for Library_Major_Minor_Id_Supported use "false";
    </config>
  </configuration>

  <!--  Darwin (MacOS): not applicable to iOS  -->
  <configuration>
    <compilers negate="true">
       <compiler runtime="ios-simulator" />
    </compilers>
    <targets>
       <target name="^i.86-.*darwin.*$" />
       <target name="^powerpc-.*darwin.*$" />
       <target name="^x86_64-.*darwin.*$" />
       <target name="^aarch64-.*darwin.*$" />
    </targets>
    <config>
   for Library_Builder use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support use "full";
   for Shared_Library_Prefix use "lib";

   for Run_Path_Option  use ("-Wl,-rpath,");
   for Separate_Run_Path_Options use "true";
   for Run_Path_Origin use "@loader_path";
   for Library_Install_Name_Option use "-Wl,-install_name,@rpath";

   for Shared_Library_Suffix use ".dylib";
   for Library_Auto_Init_Supported use "true";
   for Archive_Indexer use project'Archive_Indexer &amp; ("-c");
   for Shared_Library_Minimum_Switches use
         ("-dynamiclib", "-shared-libgcc");
   for Library_Encapsulated_Options use ("-shared", "-static-libgcc");

   package Linker is
      for Map_File_Option         use "-Wl,-map,";
      for Max_Command_Line_Length use "128000";
      for Response_File_Format    use "object_list";
      for Response_File_Switches  use ("-Wl,-filelist,");
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers>
        <compiler name="^G\+\+$" language="C++" />
    </compilers>
    <targets>
       <target name="^i.86-.*darwin.*$" />
       <target name="^powerpc-.*darwin.*$" />
       <target name="^x86_64-.*darwin.*$" />
    </targets>
    <config>
    for Library_Rpath_Options ("C++") use ("-print-file-name=libstdc++.dylib");
    </config>
  </configuration>

  <!--  HPUX -->
  <configuration>
    <targets>
       <target name="^.*hpux.*$" />
    </targets>
    <config>
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support  use "full";
   for Shared_Library_Prefix use "lib";
   for Shared_Library_Minimum_Switches use ("-shared", "-fPIC");
   for Library_Version_Switches use ("-Wl,-soname,");

   for Shared_Library_Suffix use ".sl";
   for Library_Auto_Init_Supported use "true";
   for Run_Path_Option  use ("-Wl,+b,");
   for Library_Partial_Linker use ("gcc", "-nostdlib", "-Wl,-r", "-o");

   package Linker is
      for Max_Command_Line_Length use "5000";
      for Response_File_Format    use "object_list";
      for Response_File_Switches  use ("-Wl,-c,");
   end Linker;
    </config>
  </configuration>

  <!-- On IA64 HPUX, the shared library suffix is .so,
       and the ld switch for internal names in +h -->
   <configuration>
    <targets>
       <target name=".*ia64.*hpux.*" />
    </targets>
    <config>
   for Shared_Library_Suffix use ".so";
   for Library_Version_Switches use ("-Wl,+h,");
    </config>
  </configuration>

  <!-- linux, freebsd, Irix, OpenBSD, NetBSD, Dragonfly BSD, QNX -->
  <configuration>
    <targets>
       <target name="^.*linux.*$" />
       <target name="^.*freebsd.*$" />
       <target name="^.*irix.*$" />
       <target name="^.*openbsd.*$" />
       <target name="^.*netbsd.*$" />
       <target name="^.*dragonfly.*$" />
       <target name="^.*-fastos.*$" />
       <target name="^.*qnx[0-9]*$" />
    </targets>
    <config>
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support  use "full";
   for Shared_Library_Prefix use "lib";
   for Shared_Library_Minimum_Switches use ("-shared");
   for Library_Version_Switches use ("-Wl,-soname,");

   for Shared_Library_Suffix use ".so";
   for Library_Auto_Init_Supported use "true";
    </config>
  </configuration>

  <!-- VxWorks7r2 -->
  <configuration>
    <compilers>
       <compiler runtime="^rtp$" />
    </compilers>
    <targets>
       <target name="^powerpc64-wrs-vxworks7r2" />
       <target name="^aarch64-wrs-vxworks7r2" />
       <target name="^morello-wrs-vxworks7r2" />
       <target name="^x86_64-wrs-vxworks7r2" />
    </targets>
    <config>
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support  use "full";
   for Shared_Library_Prefix use "lib";
   for Shared_Library_Minimum_Switches use ("-shared", "-mrtp");
   for Library_Version_Switches use ("-Wl,-soname,");

   for Shared_Library_Suffix use ".so";
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler runtime="^rtp$" />
    </compilers>
    <targets>
       <target name="^powerpc64-wrs-vxworks7r2" />
       <target name="^aarch64-wrs-vxworks7r2" />
       <target name="^morello-wrs-vxworks7r2" />
       <target name="^x86_64-wrs-vxworks7r2" />
    </targets>
    <config>
   for Library_Support  use "static_only";
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
    </config>
  </configuration>

  <configuration>
    <targets>
      <target name="^.*-wrs-vxworks7r2" />
    </targets>
    <config>
   for Library_Auto_Init_Supported use "true";
    </config>
  </configuration>

  <!-- linux, freebsd, OpenBSD, NetBSD, Dragonfly BSD, QNX -->
  <configuration>
    <targets>
       <target name="^.*linux.*$" except="linux-android" />
       <target name="^.*qnx[0-9]*$" />
       <target name="^.*-fastos.*$" />
       <target name="^.*freebsd.*$" />
       <target name="^.*openbsd.*$" />
       <target name="^.*netbsd.*$" />
       <target name="^.*dragonfly.*$" />
    </targets>
    <config>
   for Run_Path_Option  use ("-Wl,-z,origin,-rpath,");
   for Run_Path_Origin use "$$ORIGIN";
   for Library_Encapsulated_Options use ("-shared", "-static-libgcc");

   package Linker is
      for Map_File_Option         use "-Wl,-Map,";
   end Linker;
    </config>
  </configuration>

  <!-- linux-android

       This would be identical to the generic linux block above, but for
       the dynamic linker on old versions of Android which raises warnings
       on the executable flag set by ld -z origin, claiming it does
       not know about it. The loader processes $ORIGIN regardless, so
       this custom block simply prevents the warning by not passing -z
       origin in Run_Path_Option.  -->
  <configuration>
    <targets>
       <target name="^.*linux-android.*$" />
    </targets>
    <config>
   for Run_Path_Option  use ("-Wl,-rpath,");
   for Run_Path_Origin use "$$ORIGIN";
   for Library_Encapsulated_Options use ("-shared", "-static-libgcc");

   package Linker is
      for Map_File_Option         use "-Wl,-Map,";
   end Linker;
    </config>
  </configuration>

  <!-- Cross linux, QNX: add rpath-link to the runtime -->
  <configuration>
    <compilers>
       <compiler language="Ada" />
    </compilers>
     <targets>
       <target name="^.*-linux.*$" />
       <target name="^.*-fastos.*$" />
       <target name="^.*-qnx[0-9]*"/>
     </targets>
    <config>
     GCC_Prefix := "${PREFIX(ada)}";
     case GCC_Prefix is
        when "" =>
           null;
        when others =>
           package Linker is
              for Required_Switches use
                Linker'Required_Switches
                &amp; ("-Wl,-rpath-link,${RUNTIME_DIR(ada)}/adalib");
           end Linker;
     end case;
    </config>
  </configuration>

  <!-- Settings for Library_Partial_Linker -->

  <!-- The partial linking option (-r) conflicts with -pie. Recent GNU/Linux
       distributions tune GCC to automatically pass -pie, so we need to pass
       -no-pie for partial linking. GNAT started supporting -no-pie flag only
       for the 17.1 release: leave -r alone for earlier versions and hope for
       the best. -->
  <configuration>
    <compilers>
       <compiler name="^GNAT$" />
       <compiler name="GCC" />
    </compilers>
    <compilers>
      <compiler version="^3\." />
      <compiler version="^5\." />
      <compiler version="^6\." />
      <compiler version="^7\." />
    </compilers>
    <config>
        GCC_No_Pie := ();
    </config>
  </configuration>
  <configuration>
    <compilers>
       <compiler name="^GNAT$" />
       <compiler name="GCC" />
    </compilers>
    <compilers negate="true">
      <compiler version="^3\." />
      <compiler version="^5\." />
      <compiler version="^6\." />
      <compiler version="^7\." />
    </compilers>
    <config>
        GCC_No_Pie := ("-no-pie");
    </config>
  </configuration>

  <configuration>
    <compilers>
       <compiler name="^GNAT$" />
    </compilers>
    <targets>
       <target name="^.*-fastos.*$" />
       <!-- The Android exception was added in OA23-038 due to a conflict with
            -pie; is it still valid? -->
       <target name="linux" except="androideabi" />
       <target name="^.*qnx[0-9]*$" />
       <target name="darwin" />
       <target name="mingw" />
    </targets>
    <config>
   for Library_Partial_Linker use
     ("${PATH(ada)}${PREFIX(ada)}gcc", "-nostdlib")
      &amp; GCC_No_Pie
      &amp; ("-Wl,-r", "-o");
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler name="^GNAT$" />
    </compilers>
    <compilers>
       <compiler name="GCC" language="c"/>
    </compilers>
    <targets>
       <target name="^.*-fastos.*$" />
       <!-- The Android exception was added in OA23-038 due to a conflict with
            -pie; is it still valid? -->
       <target name="linux" except="androideabi" />
       <target name="^.*qnx[0-9]*$" />
       <target name="darwin" />
       <target name="mingw" />
       <!-- LLVM version of the "mingw" triplet -->
       <target name="windows" />
    </targets>
    <config>
   for Library_Partial_Linker use
     ("${PATH(c)}${PREFIX(c)}gcc", "-nostdlib")
      &amp; GCC_No_Pie
      &amp; ("-Wl,-r", "-o");
    </config>
  </configuration>

  <!-- Clang automatically disables -pie when the driver gets the -r option
       (which is forwarded to the linker). The same applies to GNAT-LLVM
       because it uses Clang for linking. However, lld doesn't support partial
       linking on Windows, so we only enable it for Linux. -->
  <configuration>
    <compilers>
       <compiler name="^GNAT_LLVM$" />
       <compiler name="^GNAT_LLVM_VXWORKS$" />
       <compiler name="^GNAT_LLVM-.*$" />
    </compilers>
    <targets>
       <target name="linux" />
    </targets>
    <config>
   for Library_Partial_Linker use
     ("${PATH(ada)}${PREFIX(ada)}gcc", "-nostdlib", "-r", "-o");
    </config>
  </configuration>
  <configuration>
    <compilers>
       <compiler name="CLANG" language="c"/>
    </compilers>
    <targets>
       <target name="linux" />
    </targets>
    <config>
   for Library_Partial_Linker use
     ("${PATH(c)}${PREFIX(c)}clang", "-nostdlib", "-r", "-o");
    </config>
  </configuration>

  <!-- Settings for Library_Rpath_Options -->
  <configuration>
    <compilers>
        <compiler name="^G\+\+$" language="C++" />
    </compilers>
    <targets>
       <target name="^.*linux.*$" />
    </targets>
    <config>
    for Library_Rpath_Options ("C++") use ("-print-file-name=libstdc++.so");
    </config>
  </configuration>

  <!-- irix -->
  <configuration>
    <targets>
       <target name="^.*irix.*$" />
    </targets>
    <config>
   for Run_Path_Option  use ("-Wl,-rpath,");

   package Linker is
      for Max_Command_Line_Length use "5000";
      for Response_File_Format    use "object_list";
      for Response_File_Switches  use ("-Wl,-objectlist,");
   end Linker;
    </config>
  </configuration>

  <!--  Solaris -->
  <configuration>
    <targets>
       <target name="^.*sunos.*$" />
       <target name="^.*solaris.*$"/>
    </targets>
    <config>
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support  use "full";
   for Shared_Library_Prefix use "lib";
   for Shared_Library_Minimum_Switches use ("-shared");

   for Library_Version_Switches use ("-Wl,-h,");

   for Shared_Library_Suffix use ".so";
   for Library_Auto_Init_Supported use "true";
   for Library_Encapsulated_Options use
      ("-shared", "-static-libgcc", "-mimpure-text");
   for Run_Path_Option  use ("-Wl,-z,origin,-R,");
   for Run_Path_Origin use "$$ORIGIN";
   for Library_Partial_Linker use ("gcc", "-nostdlib", "-Wl,-r", "-o");
    </config>
  </configuration>

  <configuration>
    <compilers>
        <compiler name="^G\+\+$" language="C++" />
    </compilers>
    <targets>
       <target name="^.*sunos.*$" />
       <target name="^.*solaris.*$" />
    </targets>
    <config>
    for Library_Rpath_Options ("C++") use ("-print-file-name=libstdc++.so");
    </config>
  </configuration>

  <!--  Windows -->
  <configuration>
    <targets>
      <target name="^.*mingw.*$" />
      <!-- LLVM version of the mingw32 triplet -->
      <target name="^.*-windows-gnu$" />
    </targets>
    <config>
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support  use "full";
   for Shared_Library_Prefix use "lib";
   for Shared_Library_Minimum_Switches use ("-shared", "-shared-libgcc");
   for Library_Version_Switches use ("-Wl,-soname,");
   for Shared_Library_Suffix use ".dll";
   for Library_Encapsulated_Options use ("-shared", "-static-libgcc");
   for Library_Auto_Init_Supported use "true";

   package Linker is
      for Map_File_Option         use "-Wl,-Map,";
   end Linker;
    </config>
  </configuration>

  <!-- Tru64-->
  <configuration>
    <targets>
       <target name="^.*osf.*$" />
    </targets>
    <config>
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Support  use "full";
   for Shared_Library_Prefix use "lib";
   for Shared_Library_Minimum_Switches use
      ("-shared", "-Wl,-expect_unresolved,*");
   for Library_Version_Switches use ("-Wl,-soname,");

   for Shared_Library_Suffix use ".so";
   for Library_Auto_Init_Supported use "true";
   for Run_Path_Option  use ("-Wl,-rpath,");

   package Linker is
      for Max_Command_Line_Length use "10000";
      for Response_File_Format    use "object_list";
      for Response_File_Switches  use ("-Wl,-input,");
   end Linker;
    </config>
  </configuration>

  <!--  Cygming -->
  <configuration>
    <compilers><compiler name="^GCC-CYGMING$"/></compilers>
    <config>
   package Linker is
       for Required_Switches use ("-mno-cygwin");
   end Linker;
    </config>
  </configuration>

  <!-- CodePeer -->

  <configuration>
    <targets>
       <target name="codepeer" />
    </targets>
    <config>
   for Library_Support use "full";
   for Library_Auto_Init_Supported use "true";
   for Library_Builder use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
    </config>
  </configuration>

  <!-- CUDA -->

  <configuration>
    <targets>
       <target name="^cuda$" />
    </targets>
    <config>
   for Library_Support use "full";
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Shared_Library_Suffix use ".fatbin.o";
    </config>
  </configuration>

  <!--  use C++, Fortran, Ada or C driver to link in this order -->

  <configuration>
    <compilers>
       <compiler language="C++" />
    </compilers>
    <targets negate="true">
      <target name="^.*-wrs-vxworks.*$" />
      <target name="^.*-wrs-linux.*$" />
    </targets>
    <config>
   package Linker is
      for Driver use Compiler'Driver ("C++");
   end Linker;
    </config>
  </configuration>

  <!-- On most platforms, g++ would use shared-libstdc++ by default:
       some features (e.g. thread cancellation) are known to be broken
       with static linking for C/C++. On the other hand, Ada uses
       -static-libgcc by default. This static/shared mix would not work.
       In order to fix that, we follow the choice of C++ (shared libs)
       when C++ is in the partition.
       For more details, see eng/gpr/gpr-issues#93 and P918-005.  -->

  <configuration>
    <compilers>
       <compiler language="C++" />
    </compilers>
    <targets>
      <target name="^.*linux.*$" />
      <target name="^.*fastos.*$" />
      <target name="^.*sunos.*$" />
      <target name="^.*solaris.*$" />
      <target name="^.*mingw.*$" />
      <!-- LLVM version of the "mingw" triplet -->
      <target name="^.*windows.*$" />
    </targets>
    <config>
     package Linker is
        for Required_Switches use Linker'Required_Switches &amp; ("-shared-libgcc");
     end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C++" />
    </compilers>
    <compilers>
       <compiler language="Fortran" />
    </compilers>
    <config>
   package Linker is
      for Driver use Compiler'Driver ("Fortran");
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C++" />
       <compiler language="Fortran" />
    </compilers>
    <compilers>
       <compiler language="Ada" />
    </compilers>
    <targets negate="true">
       <target name="aamp" />
       <target name="dotnet" />
       <target name="jvm" />
       <target name="^.*-sysgo-pikeos.*$" />
       <target name="^.*-wrs-vxworks.*$" />
    </targets>
    <config>
   package Linker is
      for Driver use Compiler'Driver ("Ada");
   end Linker;
    </config>
  </configuration>

  <!-- For PikeOS use C drivers as default for linking,
       to use SYSGO's libgcc -->
  <configuration>
    <compilers>
       <compiler language="C" />
    </compilers>
    <targets>
      <target name="^.*-sysgo-pikeos.*$" />
    </targets>
    <config>
   package Linker is
      for Driver use Compiler'Driver ("C");
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C" />
    </compilers>
    <compilers>
       <compiler language="Ada" />
    </compilers>
    <targets>
      <target name="^.*-sysgo-pikeos.*$" />
    </targets>
    <config>
   package Linker is
      for Driver use Compiler'Driver ("Ada");
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C++" />
       <compiler language="Fortran" />
       <compiler language="Ada" />
    </compilers>
    <compilers>
       <compiler language="C" />
    </compilers>
    <targets negate="true">
      <target name="^.*-wrs-vxworks.*$" />
    </targets>
    <config>
   package Linker is
      for Driver use Compiler'Driver ("C");
   end Linker;
    </config>
  </configuration>

  <!-- cross targets that use GNU ld -->
  <configuration>
    &if_not_vx7r2_llvm_compiler;
    <targets>
       <target name="^.*-vxworks.*$" />
       <target name="^.*-lynxos.*$" />
       <target name="^.*-pikeos.*$" />
       <target name="^.*-elf$" />
       <target name="^.*-eabispe$" />
       <target name="^.*-eabi$" />
       <target name="^avr$" />
    </targets>
    <config>
     package Linker is
        for Map_File_Option use "-Wl,-Map,";
     end Linker;
    </config>
  </configuration>

  <configuration>
    &if_vx7r2_llvm_compiler;
    <targets>
       <target name="^.*-vxworks7r2$" />
    </targets>
    <config>
     package Linker is
        for Map_File_Option use "-Map,";
     end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C++" />
       <compiler language="Fortran" />
       <compiler language="Ada" />
    </compilers>
    <compilers>
       <compiler name="^GCC-WRS7ARM$" runtime="rtp"/>
       <compiler name="^GCC-WRS7E500V2$" runtime="rtp"/>
       <compiler name="^GCC-WRS7PPC$" runtime="rtp"/>
       <compiler name="^GCC-WRS7X86$" runtime="rtp"/>
       <compiler name="^GCC-WRS7X86_64$" runtime="rtp"/>
    </compilers>
    <config>
     package Linker is
        for Required_Switches use
          Linker'Required_Switches
          &amp; ("-mrtp", "-L" &amp; VSB_Dir &amp; "/usr/lib/common");
     end Linker;
    </config>
  </configuration>

  <!-- On x86_64 vxWorks, when Linker'Driver is WRS gcc, -m64,
       -mcmodel=large and -mno-red-zone have to be specified
       explicitely. When Linker'Driver is GNAT, this is the default
       already, so it is harmless to pass it twice.  -->

  <configuration>
    <compilers>
       <compiler name="^GCC-WRS7X86_64$"/>
    </compilers>
    <config>
   package Linker is
        for Required_Switches use
          Linker'Required_Switches
          &amp; ("-m64", "-mcmodel=large", "-mno-red-zone");
   end Linker;
    </config>
  </configuration>

  <!--  Define the right response file mechanism for linking
        when possible use both the GCC @response file (available starting with
        GNAT Pro 6) and the GNU linker mechanism. The latter can be used with
        all cross since they rely on GNU ld and some of the major natives.
        Max_Command_Line could be made different for different hosts but we
        use the smallest value of all the hosts instead for uniformity.
  -->

   <configuration>
    <compilers negate="true">
       <compiler language="C++" />
       <compiler language="Fortran" />
    </compilers>
    <compilers>
       <compiler language="Ada" />
    </compilers>
    <compilers negate="true">
      <compiler version="3.16" />
      <compiler version="5.00" />
      <compiler version="5.01" />
      <compiler version="5.02" />
      <compiler version="5.03" />
      <compiler version="5.04" />
    </compilers>
     <targets>
       <target name="^.*-wrs-vxworks.*$" />
       <target name="^.*-elf-lynx.*$" />
       <target name="^.*-lynx-lynx.*$" />
       <target name="^x86_64-elf$" />
       <target name="^i686-elf$" />
       <target name="^visium-elf$" />
       <target name="^r7-elf$" />
       <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
       <target name="^m68020-elf$" />
       <target name="^morello(-unknown-unknown)?-elf$" />
       <target name="^powerpc-elf$" />
       <target name="^powerpc-eabispe$" />
       <target name="^erc32-elf$" />
       <target name="^leon-elf$" />
       <target name="^leon3-elf$" />
       <target name="^aarch64(-unknown-unknown)?-elf$" />
       <target name="^arm(-none)?-eabi$" />
       <target name="^arm-elf$" />
       <target name="^avr$" />
       <target name="^.*wrs-vxworks.*$" />
       <target name="^.*lynxos178.*$" />
       <target name="^.*-elinos-linux$" />
       <target name="^.*-fastos.*$" />
       <target name="^.*-generic-linux-gnu$" />
       <target name="^.*-wrs-linux$" />
       <target name="^.*-pikeos.*$" />
       <target name="^.*mingw.*$" />
       <target name="^.*linux.*$" />
       <target name="^.*freebsd.*$" />
       <target name="^.*openbsd.*$" />
       <target name="^.*netbsd.*$" />
       <target name="^.*dragonfly.*$" />
       <target name="^.*-qnx[0-9]*"/>
     </targets>
    <config>
   package Linker is
      for Response_File_Format use "GCC_GNU";
      for Max_Command_Line_Length use "8192";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers>
      <compiler name="^GNAT_LLVM.*$" />
    </compilers>
    <targets>
      <target name="^.*windows.*$" />
    </targets>
    <config>
   package Linker is
      for Response_File_Format use "GCC_Object_List";
      for Response_File_Switches use ("@");
      for Max_Command_Line_Length use "8192";
   end Linker;
    </config>
  </configuration>

   <configuration>
    <compilers negate="true">
       <compiler language="C++" />
       <compiler language="Fortran" />
    </compilers>
    <compilers>
       <compiler language="Ada" />
    </compilers>
    <compilers>
      <compiler version="3.16" />
      <compiler version="5.00" />
      <compiler version="5.01" />
      <compiler version="5.02" />
      <compiler version="5.03" />
      <compiler version="5.04" />
    </compilers>
     <targets>
       <target name="^.*wrs-vxworks.*$" />
       <target name="^.*-elf-lynx.*$" />
       <target name="^.*-lynx-lynx.*$" />
       <target name="^x86_64-elf$" />
       <target name="^i686-elf$" />
       <target name="^visium-elf$" />
       <target name="^r7-elf$" />
       <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
       <target name="^m68020-elf$" />
       <target name="^morello(-unknown-unknown)?-elf$" />
       <target name="^powerpc-elf$" />
       <target name="^powerpc-eabispe$" />
       <target name="^erc32-elf$" />
       <target name="^leon-elf$" />
       <target name="^leon3-elf$" />
       <target name="^arm(-none)?-eabi$" />
       <target name="^arm-elf$" />
       <target name="^avr$" />
       <target name="^.*-elinos-linux$" />
       <target name="^.*-generic-linux-gnu$" />
       <target name="^.*-wrs-linux$" />
       <target name="^.*mingw.*$" />
       <target name="^.*linux.*$" />
       <target name="^.*freebsd.*$" />
       <target name="^.*openbsd.*$" />
       <target name="^.*netbsd.*$" />
       <target name="^.*dragonfly.*$" />
     </targets>
    <config>
   package Linker is
      for Response_File_Format use "GNU";
      for Max_Command_Line_Length use "8192";
   end Linker;
    </config>
  </configuration>

   <configuration>
    <compilers>
       <compiler language="C++" />
    </compilers>
     <targets>
       <target name="^.*wrs-vxworks.*$" />
       <target name="^.*-elf-lynx.*$" />
       <target name="^.*-lynx-lynx.*$" />
       <target name="^x86_64-elf$" />
       <target name="^i686-elf$" />
       <target name="^visium-elf$" />
       <target name="^r7-elf$" />
       <target name="^riscv(32|64)(c)?(-none|-unknown)?-elf$" />
       <target name="^m68020-elf$" />
       <target name="^morello(-unknown-unknown)?-elf$" />
       <target name="^powerpc-elf$" />
       <target name="^powerpc-eabispe$" />
       <target name="^erc32-elf$" />
       <target name="^leon-elf$" />
       <target name="^leon3-elf$" />
       <target name="^aarch64(-unknown-unknown)?-elf$" />
       <target name="^arm(-none)?-eabi$" />
       <target name="^arm-elf$" />
       <target name="^avr$" />
       <target name="^.*-elinos-linux$" />
       <target name="^.*-generic-linux-gnu$" />
       <target name="^.*-wrs-linux$" />
       <target name="^.*mingw.*$" />
       <target name="^.*linux.*$" />
       <target name="^.*freebsd.*$" />
       <target name="^.*openbsd.*$" />
       <target name="^.*netbsd.*$" />
       <target name="^.*dragonfly.*$" />
     </targets>
    <config>
   package Linker is
      for Response_File_Format use "GNU";
      for Max_Command_Line_Length use "8192";
   end Linker;
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C++" />
       <compiler language="Fortran" />
    </compilers>
    <compilers>
       <compiler language="Ada" />
    </compilers>
    <compilers negate="true">
      <compiler version="3.16" />
      <compiler version="5.00" />
      <compiler version="5.01" />
      <compiler version="5.02" />
      <compiler version="5.03" />
      <compiler version="5.04" />
    </compilers>
    <targets>
      <target name="^.*aix.*$" />
      <target name="^.*hpux.*$" />
      <target name="^.*irix.*$" />
      <target name="^.*osf.*$" />
    </targets>
    <config>
   package Linker is
      for Response_File_Format use "GCC_Object_List";
   end Linker;
    </config>
  </configuration>

 <!-- Default language is Ada, C, Fortran, C++ in that order -->

  <configuration>
    <compilers>
       <compiler language="Ada" />
    </compilers>
    <config>
   for Default_Language use "Ada";
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="Ada" />
    </compilers>
    <compilers>
       <compiler language="C" />
    </compilers>
    <config>
   for Default_Language use "C";
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C" />
       <compiler language="Ada" />
    </compilers>
    <compilers>
       <compiler language="Fortran" /></compilers>
    <config>
   for Default_Language use "Fortran";
    </config>
  </configuration>

  <configuration>
    <compilers negate="true">
       <compiler language="C" />
       <compiler language="Fortran" />
       <compiler language="Ada" />
    </compilers>
    <compilers>
       <compiler language="C++" />
    </compilers>
    <config>
   for Default_Language use "C++";
    </config>
  </configuration>

  <!-- When using the (Ada) ios-simulator runtime, some additional
       arguments are needed to complete the link.  -->

   <configuration>
     <compilers>
       <compiler runtime="ios-simulator" />
     </compilers>
     <config>
   for Library_Support  use "static_only";
   for Library_Builder  use "${GPRCONFIG_PREFIX}lib/gprbuild/gprlib";
   for Library_Partial_Linker use ("${PATH(ada)}${PREFIX(ada)}gcc",
                                   "-mios-simulator-version-min=8.0",
                                   "-nostdlib", "-Wl,-r", "-o");
   package Linker is
      for Required_Switches use Linker'Required_Switches
        &amp; ("-mios-simulator-version-min=8.0",
               "-nostartfiles",
               "-Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk");
   end Linker;
     </config>
   </configuration>

</gprconfig>
