Currently, PARROT_API is declared similar to this.
#if defined(PARROT_IN_EXTENSION)
#define PARROT_API __declspec(dllimport)
#else
#define PARROT_API __declspec(dllexport)
#endif
That is, only import if we're in an extension, otherwise export. IMHO,
this isn't quite right. Export and import should be set depending on
whether we're compiling libparrot or using it, with the default set to
using libparrot, for example like so.
#if defined(PARROT_EXPORTS)
#define PARROT_API __declspec(dllexport)
#else
#define PARROT_API __declspec(dllimport)
#endif
And then define PARROT_EXPORTS when compiling units that should make its
way into libparrot. In Makefile terms that's O_FILES.
This is the one thing I haven't figured out yet. Does anyone know how
to set a compiler flag for the O_FILES only?
Any other thoughts on this?
Thanks,
Ron