Created attachment 2953 [details] Patch for ENV bug Using the ENV macro the generated code contains an additional brace ')' - the attached patch fixes the behavior. The problem persists at least since 2.5 and also in trunk. Thanks.
Created attachment 2954 [details] Correct patch Sorry, previous patch was not correct. Following examples for the td file: (cmd_line "gcc -o $OUTFILE $INFILE $ENV(FOO)/bar") generates: vec.push_back(checkCString(std::getenv("STMLIBDIR")) + std::string("/libtanger-stm.a"))); The middle brace is left over. That brace is generated under every condition (before return statement) but this makes no sense as braces are generated correctly (same number for opening and closing braces) for both cases CALL and ENV.
Created attachment 2955 [details] As previous patch but with correct path from LLVM root dir
Applied, thanks!