freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Devel] Win32 library does not work in VC++ 6.0


From: Vincent Caron
Subject: RE: [Devel] Win32 library does not work in VC++ 6.0
Date: 02 Aug 2002 00:47:30 +0200

On Fri, 2002-08-02 at 00:27, Jan Slupski wrote:
> Hi!
> 
> Could you please write how to create DLL from freetype?
> I tried with VisualStudio 6.0 using ide, gnu make, jam,
> but I couldn't figure how to obtain anythig else than static freetype.lib.

FreeType2 does not seem to have a VC6 project to build as a DLL, that
could be added to the distribution I think (but David will rightfully
that it is another stupid build file to sync with the rest :)).

There also lacks a mean of exporting and importing sybmols, a tedious
tasks that DLLs impose. When building the DLL, one must explicitely
'export' every public symbol. This can be done either by preceding each
symbol declaration by a blurb :

  FT_EXPORT( FT_Error ) __declspec(dllexport) FT_Face_New(...);

that would need some more tweaking in <freetype/config/ftconfig.h>. Or
one can write a standalone 'freetype.def' file listing the symbol names
to export and pass it to the linker.

Either way, you still a mean to 'import' symbol as the DLL user, it
means that when building against FreeType DLL you'll have to include
this proto :

  FT_EXPORT( FT_Error ) __declspec(dllimport) FT_Face_New(...);

And this one is sadly mandatory AFAIK. I only discovered this 'DLL Hell'
two weeks ago, I'm from the Unix world. Any corrections/precisions
warmly welcome ...





reply via email to

[Prev in Thread] Current Thread [Next in Thread]