From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2094 invoked by alias); 28 May 2013 15:55:09 -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 2003 invoked by uid 48); 28 May 2013 15:55:03 -0000 From: "dsmith at redhat dot com" To: systemtap@sourceware.org Subject: [Bug translator/15542] New: %( CONFIG_NO_SUCH_VAR == "n" ... %) doesn't evaluate to true Date: Tue, 28 May 2013 15:55:00 -0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: systemtap X-Bugzilla-Component: translator X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dsmith at redhat dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: systemtap at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-q2/txt/msg00193.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=15542 Bug ID: 15542 Summary: %( CONFIG_NO_SUCH_VAR == "n" ... %) doesn't evaluate to true Product: systemtap Version: unspecified Status: NEW Severity: normal Priority: P2 Component: translator Assignee: systemtap at sourceware dot org Reporter: dsmith at redhat dot com If you use the '%( CONFIG_FOO ' preprocessor conditional on a CONFIG variable that doesn't exist, its value doesn't equal to 'n'. ==== # stap -ve '%( CONFIG_NO_SUCH_VAR == "n" %? probe begin { exit() } %)' Input file '' is empty after preprocessing. Pass 1: parsed user script and 92 library script(s) using 29176virt/16168res/2556shr/14148data kb, in 200usr/30sys/229real ms. Pass 1: parse failed. [man error::pass1] ==== Strangely enough, using ' != "y" ' works: ==== # stap -ve '%( CONFIG_NO_SUCH_VAR != "y" %? probe begin { exit() } %)' Pass 1: parsed user script and 92 library script(s) using 29172virt/16160res/2544shr/14144data kb, in 190usr/50sys/240real ms. Pass 2: analyzed script: 1 probe(s), 1 function(s), 0 embed(s), 0 global(s) using 29436virt/16684res/2800shr/14408data kb, in 10usr/0sys/5real ms. Pass 3: translated to C into "/tmp/stapY2PUI0/stap_e5865cf2f29bdb61e8371744a0339c71_959_src.c" using 29436virt/17000res/3096shr/14408data kb, in 0usr/0sys/1real ms. Pass 4: compiled C into "stap_e5865cf2f29bdb61e8371744a0339c71_959.ko" in 2110usr/1080sys/3553real ms. Pass 5: starting run. Pass 5: run completed in 20usr/150sys/468real ms. ==== If the CONFIG variable doesn't exist, its value should evaluate to "n". -- You are receiving this mail because: You are the assignee for the bug.