You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have a large C++ Project and are trying to generate Csharp Wrapper files. I could not share the contents of the CPP files due to security issues. We are trying to use SWIG to generate Wrapper classes. Our Previous team did this and I see that they are generating around 30 wrapper files.
Now When I try to compile the filename.i interface file I see that few wrapper files are not getting generated like
Eg SWIGTYPE_p_long.cs. Swigtype_p_time._tcs, Swigtype_p_short.cs, SwigType_p_MTInt4.cs. These files are not getting generated whereas previously they used to get created. No Code changes were done since then.
My Interface file looks like below at high level
// Swig interface file for C# wrapeer for c++ dll
//export module CPP_interface;
% module cppwrappername
% include <std_common.i>
% include <typemaps.i>
% include <std_string.i>
% include <std_wstring.i>
% include <std_vector.i>
% include <std_map.i>
% include <std_pair.i>
% include <windows.i>
using namespace std;
#define unix
% apply char[] { const unsigned char*};
namespace std {
% apply const string& { string& };
};
#include <pthread.h>
#include <semaphore.h>
% apply sem_t* { Semaphore };
% {
#include <limits.h>
#include <float.h>
#include <string>
#include <iostream>
#include <sstream>
#include <semaphore.h>
#include <pthread.h>
#include <locale>
#include <emperror.h>
#include <empmessage.h>
%}
% ignore operator<<;
% ignore operator=;
% ignore operator==;
//%include "windows.h"
% include "emperror.h"
% include "empmessage.h"
I am new to SWIG and its very confusing where to look at it for this issue.
Is there any SWIG command to view the errors
Any pointers to where to look at this will help
I am running the below Swig command and see only 2 warnings
swig -csharp -c++ -outdir C:\pathname\Generated CPP_interface.i
emperror.h(52) : Warning 401: Nothing known about base class 'EMP::EMPException'. Ignored.
CPP_interface.i(38) : Warning 453: Can't apply (sem_t *). No typemaps are defined.
I am using Visual Studio and the paths to Linking are configured correctly
The text was updated successfully, but these errors were encountered:
We have a large C++ Project and are trying to generate Csharp Wrapper files. I could not share the contents of the CPP files due to security issues. We are trying to use SWIG to generate Wrapper classes. Our Previous team did this and I see that they are generating around 30 wrapper files.
Now When I try to compile the filename.i interface file I see that few wrapper files are not getting generated like
Eg SWIGTYPE_p_long.cs. Swigtype_p_time._tcs, Swigtype_p_short.cs, SwigType_p_MTInt4.cs. These files are not getting generated whereas previously they used to get created. No Code changes were done since then.
My Interface file looks like below at high level
I am new to SWIG and its very confusing where to look at it for this issue.
Is there any SWIG command to view the errors
Any pointers to where to look at this will help
I am running the below Swig command and see only 2 warnings
I am using Visual Studio and the paths to Linking are configured correctly
The text was updated successfully, but these errors were encountered: