Description: Link gnatcoll with pthread to circumvent #760211.
 On armel armhf hurd-i386 kfreebsd-amd64 s390x, inlining of
 Ada.Task_Attributes creates a direct dependency to the
 pthread_getspecific symbol.
 With --as-needed, -lpthread has no other effect than fixing the link
 stage for buggy architectures.
Author: Nicolas Boulenguez <nicolas@debian.org>
Bug-Debian: https://bugs.debian.org/760211
Forwarded: no

--- a/src/gnatcoll__copy.gpr
+++ b/src/gnatcoll__copy.gpr
@@ -13,6 +13,9 @@
       "lib" & Project'Library_Name
       & GnatColl_Shared.So_Ext & "." & GnatColl_Shared.Gnatcoll_Version;
 
+   --  See #760211. Only used if needed because of --as-needed.
+   for Library_Options use ("-lpthread");
+
    case Gnatcoll_Shared.Projects is
       when "yes" =>
          for Source_Dirs use
--- a/src/gnatcoll__gnat_util.gpr
+++ b/src/gnatcoll__gnat_util.gpr
@@ -17,6 +17,9 @@
       "lib" & Project'Library_Name
       & GnatColl_Shared.So_Ext & "." & GnatColl_Shared.Gnatcoll_Version;
 
+   --  See #760211. Only used if needed because of --as-needed.
+   for Library_Options use ("-lpthread");
+
    case Gnatcoll_Shared.Projects is
       when "yes" =>
          null;
