• Welcome to Vampyre Imaging Library Forum. Please login or sign up.
 

Imaging does not work when used inside shared library on freebsd

Started by kaukas, 25 December 2009, 07:21:13

Previous topic - Next topic

kaukas

Because IO functions are assigned in initialization section and there is fpc bug on freebsd (initialization/finalization are not called), Imaging crashes library. I reported bug 0015422 in fpc bug tracker about this issue. So be careful.

Galfar

Thanks for letting me know.

I'm thinking of putting the IO init code to separate procedure that could be called in ImLoadLibrary function - so IO will be inited before user calls any loading/saving functions.

Problem is ImLoadLibrary is now only used in C .so header, not in Pascal.
May I ask from which language you accessed Imaging as shared library? 

kaukas

Sorry for late reply. If you still interesting, the library was loaded from postgresql for so called "c style functions" (in my case they are actually written in pascal). After workaround mentioned in fpc bug report, there is no problems and library that uses imaging works very well on freebsd production server. Postgresql is written in c, but that doesn't matter because this bug would appear in any software while loading library with dlopen on bsd systems. Bug exists for several years and I don't think it will be resolved in the near future.

Galfar

Ok thanks for more info.
I'll put a note about this problem somewhere in Imaging documentation along with a link to this thread.




Quick Reply

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Name:
Email:

Shortcuts: ALT+S save/post or ALT+P preview

SMF spam blocked by CleanTalk