Bug 2353

Summary: libftk.so missing a dependency (librt.so)
Product: frysk Reporter: Sami Wagiaalla <swagiaal>
Component: generalAssignee: Chris Moller <cmoller>
Status: RESOLVED FIXED    
Severity: normal CC: pmuldoon, woodzltc
Priority: P2    
Version: unspecified   
Target Milestone: ---   
Host: Target:
Build: Last reconfirmed:
Bug Depends on:    
Bug Blocks: 1664    

Description Sami Wagiaalla 2006-02-18 21:00:34 UTC
modified tlwidgets/Makefile.am and added -ltlwidgets
Comment 1 Andrew Cagney 2006-02-19 01:20:26 UTC
*** Bug 2348 has been marked as a duplicate of this bug. ***
Comment 2 Wu Zhou 2006-02-19 06:33:27 UTC
Is this the fix?  It is somewhat the same as what I added to generated Makefile.

===================================================================
RCS file: /cvs/frysk/frysk-gtk/tlwidgets/Makefile.am,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- frysk-gtk/tlwidgets/Makefile.am	2006/02/06 18:18:16	1.5
+++ frysk-gtk/tlwidgets/Makefile.am	2006/02/18 21:01:25	1.6
@@ -93,3 +93,9 @@
 solib_PROGRAMS += libftk.so
 libftk_so_SOURCES =
 libftk.so: libftk.a
+	soname=`basename $@` ; \
+	$(CC) -shared -o $@.tmp -lrt \
+		-Wl,--whole-archive,$<,--no-whole-archive \
+		-Wl,--soname,$$soname,-z,-defs
+	if readelf -d $@.tmp | fgrep -q TEXTREL; then exit 1; fi
+	mv $@.tmp $@
\ No newline at end of file

It is strange that frysk on x86 doesn't need this extra option.  How did frysk
on x86 knows that it need to search librt.so for it to work correctly.  Odd.

Anyway, it does fix the problem.  Thanks.
Comment 3 Andrew Cagney 2006-05-05 18:05:09 UTC
Code rewritten to not need librt (and all that timer stuff).