<div dir="ltr">You don't really need Clang for something as simple as that, whatever you code in next 5 minutes will likely work in almost all circumstance :)<div>PPCallback is what you'd use in Clang, I'm not sure if that's accessible through Python, hopefully someone who know will chime in.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 11, 2015 at 2:27 PM, Riyad Parvez <span dir="ltr"><<a href="mailto:riyad.parvez@uwaterloo.ca" target="_blank">riyad.parvez@uwaterloo.ca</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
  

    
  
  <div bgcolor="#FFFFFF" text="#000000">
    Hi All,<br>
    <br>
    I want to write tool in python which will go through every source
    file and add preprocessor macro to the file.<br>
    <blockquote>#include <stdio.h><br>
      #include "my_header.h"   // This should be inserted by clang
      python tool<br>
      <br>
      int main() {<br>
      <br>
      }<br>
    </blockquote>
    <br>
    How can I do this using Python bindings?<br>
    <br>
    Thanks<span class="HOEnZb"><font color="#888888"><br>
    Riyad<br>
  </font></span></div>

<br>_______________________________________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@cs.uiuc.edu">cfe-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div><br></div>