At startup, now tests if program is statically linked.  Bails with a useful
message if so.  If anyone thinks this will break anything, please yell.

Updated FAQ #5 correspondingly, added info on how to combine static and dynamic
libraries.

MERGE TO STABLE(?)


git-svn-id: svn://svn.valgrind.org/valgrind/trunk@1831 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/FAQ.txt b/FAQ.txt
index 3469afc..b4d9517 100644
--- a/FAQ.txt
+++ b/FAQ.txt
@@ -87,18 +87,17 @@
 Q5. I try running "valgrind my_program", but my_program runs normally,
     and Valgrind doesn't emit any output at all.
 
-A5. Is my_program statically linked?  Valgrind doesn't work with
-    statically linked binaries.  my_program must rely on at least one 
-    shared object.  To determine if a my_program is statically linked, 
-    run:
+A5. This should no longer happen, as a check for this takes place
+    when Valgrind starts up.
 
-      ldd my_program
+    However, Valgrind still doesn't work with programs that are entirely
+    statically linked.  If you still want static linking, you can ask 
+    gcc to link certain libraries statically.  Try the following options:
 
-    It will show what shared objects my_program relies on, or say:
+        -Wl,-Bstatic -lmyLibrary1 -lotherLibrary -Wl,-Bdynamic
 
-      not a dynamic executable
-
-    if my_program is statically linked.
+    Just make sure you end with -Wl,-Bdynamic so that libc is dynamically
+    linked.
 
 -----------------------------------------------------------------