The attached patch addresses both of Tom's comments. On Fri, Apr 12, 2013 at 1:56 PM, Tom Tromey wrote: > The intro comment to build_executable_from_specs needs an update to note > that with_pthreads is handled locally. Done. > Siva> + if { [lsearch -exact $options "with_pthreads"] >= 0 } { > Siva> + if { [gdb_compile_pthreads $objects "${binfile}" executable $options] != "" } { > > I wonder if you need to remove with_pthreads from the options here. Done. ChangeLog 2013-04-15 Siva Chandra Reddy Add option to link testcases with Pthreads library when using 'prepare_for_testing' in tests. testsuite/ * lib/gdb.exp (build_executable_from_specs): Use gdb_compile_pthreads to compile if option "with_pthreads" is specified.