Thanks for the information. This thing I tried but it also not getting header files. Do I need to add something in interface file also like %import ...........? I am having some 20 header files to include which are in some 5 different folders at different locations. Can you please explain with some example.

Regards
Varun


On Wed, Oct 16, 2013 at 1:44 PM, Toivo Henningsson <toivo.henningsson@modelon.com> wrote:
> From: varungupta [mailto:varun06gupta@gmail.com]
> Sent: den 16 oktober 2013 09:12
> To: swig-user@lists.sourceforge.net
> Subject: [Swig-user] Regarding interface file for swig
>
> Hello I am beginner for swig. I am trying to generate python wrapper for C++ API's. I tried with simple C++ code and it was working fine. Then I started working on API's and when I tried to create a python wrapper for a single API ( by placing all the headers in the interface file), I got an error saying that some .h files are missing. I found out that the some header files are in some other folder. Please let me know how it is possible to add a header file present in a different folder into the interface file by writing some loops, conditions etc. Please suggest. Regards Varun

You can use the -I (capital i) command line option to SWIG to specify include directories. Command line options are documented at http://www.swig.org/Doc2.0/SWIG.html#SWIG_nn2

Hope that helps,
Toivo

This email and any attachments are intended solely for the use of the individual or entity to whom it is addressed and may be confidential and/or privileged. If you are not one of the named recipients or have received this email in error, (i) you should not read, disclose, or copy it, (ii) please notify sender of your receipt by reply email and delete this email and all attachments, (iii) Modelon does not accept or assume any liability or responsibility for any use of or reliance on this email.