Dear Andi,

Please note that we are not using Python at all when using the wrappers - we use the generated C++ classes directly in a C++ program. The documentation says that you need --shared to be able to load several JCC wrapper libraries at the same time, and to be able to call Python from Java - do you also need it to throw exceptions from Java to C++?

Does --shared affect the generated code? We do not use the --build or --install flags, since we do not need a Python extension. Looking at, it looks like it (for the C++ wrappers) should be enough to build a DLL from jcc.cpp & JCCEnv.cpp, exclude them from the .lib and then link against the DLL as well. Is that correct?


-----Original Message-----
From: Andi Vajda [mailto:[EMAIL PROTECTED]]
Sent: den 29 november 2017 21:52
Cc: Jesper Mattsson <[EMAIL PROTECTED]>
Subject: Re: JCCEnv::ExceptionOccurred() returns NULL

I mean: build JCC with shared mode enabled (see and then build your wrappers with —shared on JCC command line.

This makes it possible to use multiple jcc-built libraries in the same VM by sharing the jcc runtime among them which is then in its own DLL.

That build mode is required for the exception passing support to work.


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.