From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11600 invoked by alias); 24 Mar 2013 04:51:03 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 11583 invoked by uid 89); 24 Mar 2013 04:50:55 -0000 X-Spam-SWARE-Status: No, score=-4.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,RP_MATCHES_RCVD autolearn=ham version=3.3.1 Received: from mail-ee0-f43.google.com (HELO mail-ee0-f43.google.com) (74.125.83.43) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Sun, 24 Mar 2013 04:50:51 +0000 Received: by mail-ee0-f43.google.com with SMTP id c50so2718200eek.30 for ; Sat, 23 Mar 2013 21:50:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:date:message-id:subject:from:to :content-type:x-gm-message-state; bh=ozjiZxW0LYJ1s+5qSGVJXSPLjOobm3c7VTCUNXl9wxM=; b=QdYrY5A3ZIzXUmu8cg55/P39tWZADpilGp+a9rGeeTHRqjwrH3eugC+tNBerpUtNwO w+YC8cuRZO2kCv+mHgX7s/Uo/kA4+7yITkq6arHQ+0P5w3tTzIrm+5c0YYrAdc8Xupko 57itYZG3ngB4OaTnTJ09kKXL6RX7N32w2trMhr/Z0RgQgoJ9xra3UREhN1xkCDWgGNYy efxC5ibwteYl1i0JsHUnALPAgZjOJVBMlXIrBsVj2wNR3PvCZ6fMU7NSToFb79QbM5tk oxNOvbStpiynafB5JYyhzpvxDUZmLs2JyXKwzi2U7CvIqnEL8JSjcUcZN05glj3g5lrc B5Ag== MIME-Version: 1.0 X-Received: by 10.14.219.7 with SMTP id l7mr20145431eep.12.1364100649447; Sat, 23 Mar 2013 21:50:49 -0700 (PDT) Received: by 10.14.204.1 with HTTP; Sat, 23 Mar 2013 21:50:49 -0700 (PDT) Date: Sun, 24 Mar 2013 12:02:00 -0000 Message-ID: Subject: [RFC][testsuite] Add option to link testcases with pthreads when using 'prepare_for_testing' From: Siva Chandra To: gdb-patches Content-Type: multipart/mixed; boundary=047d7b6247bea624a304d8a46ec3 X-Gm-Message-State: ALoCoQlYOuJvMt7NoPnlc3Qc7wDS7TgBZG8a6sd6taDwucWedfnx5Uufb4hDNNkcUvUxy2y9ElY7RQEoHvt7B8CgGVxRA4omowTVz0zFbDowGn4mXvnazNSgj8s/GiqdOydJ8W3le0KX/qP+tC7GWxaXbBaudQ4A3bK2CiF15ShAK56PfTFLcK+5hA+s3NFqqo6MSxX/p5u6o4bgk/9/5ftGnIQV01ACew== X-Virus-Found: No X-SW-Source: 2013-03/txt/msg00890.txt.bz2 --047d7b6247bea624a304d8a46ec3 Content-Type: text/plain; charset=ISO-8859-1 Content-length: 740 Hello, The attached patch allows one to specify an option 'with_pthreads' when using 'prepare_for_testing' in tests. One could call gdb_compile_pthreads directly for such a purpose, but I think using 'prepare_for_testing' is the suggested approach. If my understanding or approach is wrong here, then what is the best way to make testcases to link with pthreads for c++ testcases? 2013-03-23 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. Thanks, Siva Chandra --047d7b6247bea624a304d8a46ec3 Content-Type: text/plain; charset=US-ASCII; name="pthreads_option_patch.txt" Content-Disposition: attachment; filename="pthreads_option_patch.txt" Content-Transfer-Encoding: base64 X-Attachment-Id: f_henq9w7q0 Content-length: 1172 ZGlmZiAtLWdpdCBhL2dkYi90ZXN0c3VpdGUvbGliL2dkYi5leHAgYi9nZGIv dGVzdHN1aXRlL2xpYi9nZGIuZXhwCmluZGV4IGVlOWZkZWMuLmFiOTFjYzUg MTAwNjQ0Ci0tLSBhL2dkYi90ZXN0c3VpdGUvbGliL2dkYi5leHAK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