regarding SWIG

A

Anish Chapagain

Hi..
I'm new to SWIG and need to create Wrapper for C code,
so, I have installed the SWIG already but doesnot know how to run it
for generating Interface file...
My C code is in message.c so what do i need to do the first
step..uisng SWIG..i read the documentation but cannot grasp creating
interface file.

thank's anish
 
D

Diez B. Roggisch

Anish said:
Hi..
I'm new to SWIG and need to create Wrapper for C code,
so, I have installed the SWIG already but doesnot know how to run it
for generating Interface file...
My C code is in message.c so what do i need to do the first
step..uisng SWIG..i read the documentation but cannot grasp creating
interface file.

If it's pure C, stop using SWIG. Create a DLL/SO-file of your message.c &
use ctypes to wrap that.


Diez
 
H

Hyuga

Hi..
I'm new to SWIG and need to create Wrapper for C code,
so, I have installed the SWIG already but doesnot know how to run it
for generating Interface file...
My C code is in message.c so what do i need to do the first
step..uisng SWIG..i read the documentation but cannot grasp creating
interface file.

thank's anish

Not sure where you're having trouble. I can understand if there's a
language barrier, but I think that the introductory SWIG documentation
is pretty darn straightforward, even if you just look at the code, so
I don't think there's anything that could be said here that's any more
clear, as far as the basics are concerned. You'd have to explain
exactly what it is you're stuck on.
 
S

Stefaan Himpe

Hi..
I'm new to SWIG and need to create Wrapper for C code,
so, I have installed the SWIG already but doesnot know how to run it
for generating Interface file...

As far as I understand, SWIG will not generate an interface file for
you. You have to write it yourself, to tell SWIG what parts of your API
you want to expose in python.

HTH,
Stefaan.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,678
Members
48,796
Latest member
Greg L.

Latest Threads

Top