Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

__sample_consumer.c: unresolved external symbols allocMemory, freeMemory, glowTags #49

Open
ghost opened this issue Sep 21, 2016 · 1 comment
Labels
Component-LibEmberSlim Issues relating to the libember_slim library. Kind-Bug
Milestone

Comments

@ghost
Copy link

ghost commented Sep 21, 2016

Hi all,

I observed some unresolved external symbols when compiling the sample application of the libember_slim library. I use Visual Studio 2010. The sample program doesn't compile. The functions allocMemory freeMemory are not exported in the libember_slim.dll.. Is this a known issue.??

If i add the sources glow.c , glow.h, and emberinternal.c , emberinternal.h the program does compile, but crashes when executed.

I use the sources of the git repository and not the sources from the SDK. This, because in the SDK the file API.h is not present and all the functions are not exported when compiling the library. You get a DLL but this is empty.. (checked with dependency walker). Alse there is no import library (*.lib) generated which indicates there is nothing to export. Because of this i use the sources from the git repository which Does contain the api.h file.. and the functions are all exported. Don't know why this SDK doesn't have the exported functions...

@KimonHoffmann
Copy link
Contributor

Hi,

thanks for bringing this to our attention. It appears that both the sample provider as well as the sample consumer user internal functions imported from emberinternal.h that (naturally) aren't part of the exported interface. The culprits are the two macros newobj and newarr that are defined in terms of allocMemory, which in turn is defined as an internal declaration in the above mentioned header.

The ability to build libember_slim as a shared library is a rather recent addition that has not yet been fully tested.

We will attend to this, but for now I suggest using libember_slim as a static library, which should work as expected.

@KimonHoffmann KimonHoffmann added this to the Release v1.8 milestone Sep 22, 2016
@KimonHoffmann KimonHoffmann added the Component-LibEmberSlim Issues relating to the libember_slim library. label Nov 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component-LibEmberSlim Issues relating to the libember_slim library. Kind-Bug
Projects
None yet
Development

No branches or pull requests

1 participant