From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20846 invoked by alias); 28 Oct 2019 07:41:43 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 20265 invoked by uid 89); 28 Oct 2019 07:41:43 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=smooth, HX-Languages-Length:978, enterprise, Enterprise X-HELO: mail-lf1-f48.google.com Received: from mail-lf1-f48.google.com (HELO mail-lf1-f48.google.com) (209.85.167.48) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 28 Oct 2019 07:41:41 +0000 Received: by mail-lf1-f48.google.com with SMTP id u16so7023333lfq.3 for ; Mon, 28 Oct 2019 00:41:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=mime-version:from:date:message-id:subject:to; bh=10DyFA2NHsJTw5S2Iq1iPTMUMwKy18GDd6FYFiuRX14=; b=lVNI6WR9grF2pvHmwNMyeqqnIS8ASqGrZxJmS0K1mZydFOYJvQ7Ndiey8VwRWBmfzz BqYgderNziZ0QOClR3G8/yxUTk9ae1MH4rA0+xEeYk8OA9hMiiGS5r9yaccDa5kglBbL P3M1R4cnED5aIoICqPhnGdZYdjOtmko/c9pE2AJBHolpNRy19iR0vp95r4cnZGGhW/li CSqaJCXlVFLgItvvYa2KLhdCTqHxGjmfgSuCCW+Rn3N48Qmg7wSLcBk0wY/Zl/VTf8dy d/ThFQc7KTQpPvqYwIzZnO8Waqj83OAzdEi/pPNXe7CVqj5sjeBdwjoCP7PDJx78rkpz FNsQ== MIME-Version: 1.0 From: Craig Ringer Date: Mon, 28 Oct 2019 07:41:00 -0000 Message-ID: Subject: Setting values in library tapsets from user tapscript? To: systemtap@sourceware.org Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2019-q4/txt/msg00014.txt.bz2 Hi folks Related to my earlier post, is there any way to supply macro values to referenced tapsets? Say I need to define @EXECPATH in "myexec.stp" so I can use @var and @cast etc for references to the executable that "myexec.stp" targets. Is there any way to do that from the main user tapscript, or the commandline? Library tapsets don't seem to see @define'd macros from user tapscripts, which is sensible. But I didn't find a way to define them on the commandline either; -D macros don't appear to be visible to the tapscripts, just the generated C code. Using -G doesn't help since you can't write @var("sym@CU",$someglobal) I'm struggling to find any way to create a tapset that can probe globals in postgres :( and I just cannot understand why it's this hard in a tool that's so smooth and simple in most ways. -- Craig Ringer http://www.2ndQuadrant.com/ 2ndQuadrant - PostgreSQL Solutions for the Enterprise