Package: gnat-4.6
Version: 4.6.3-5
Severity: important
Tags: patch
Usertags: kfreebsd
User: debian-...@lists.debian.org

When building polyorb-2.8~20110207 for GNU/kFreeBSD linking of
DYNAMIC/tools/po_catref/po_catref fails due to an undefined reference:
/usr/lib/i386-gnu/libgnarl-4.6.so.1: undefined reference to
`clock_gettime'

The reason for that is that libgnarl-4.6.so.1 is not linked with
librt.so.1. The solution is to add -lrt to the THREADSLIB variable.
Preferably it could be applied by modifying the patch:
ada-kfreebsd-gnu.diff. 

A diff for Makefile.in is inlined below.
--- a/src/gcc/ada/gcc-interface/Makefile.in     2012-08-20
14:04:41.000000000 +0200
+++ b/src/gcc/ada/gcc-interface/Makefile.in     2012-08-20
18:20:57.000000000 +0200
@@ -1137,7 +1137,7 @@
     indepsw.adb<indepsw-gnu.adb
 
   EH_MECHANISM=-gcc
-  THREADSLIB = -lpthread
+  THREADSLIB = -lpthread -lrt
   GNATLIB_SHARED = gnatlib-shared-dual
   GMEM_LIB = gmemlib
   LIBRARY_VERSION := $(LIB_VERSION)
@@ -1165,7 +1165,7 @@
     indepsw.adb<indepsw-gnu.adb
 
   EH_MECHANISM=-gcc
-  THREADSLIB = -lpthread
+  THREADSLIB = -lpthread -lrt
   GNATLIB_SHARED = gnatlib-shared-dual
   GMEM_LIB = gmemlib
   LIBRARY_VERSION := $(LIB_VERSION)


-- 
To UNSUBSCRIBE, email to debian-gcc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/1345586947.25812.64.ca...@hp.my.own.domain

Reply via email to