matthiasm wrote:
>
> On May 27, 2007, at 11:03 AM, gga wrote:
>
>>>> FLTK's footprint needs to be made smaller by proper use of Makefiles.
>>>
>>> How? If you remove autoconf/configure, then you lose the ability
>>> to support a diverse range of systems.
>>>
>>
>> Sorry, this should not read proper use of Makefiles but proper use of
>> compiler options. Currently fltk is incorrectly exposing all of its
>> symbols instead of stripping them. This makes the fltk .so library be
>> several megs when its footprint could probably be reduced to only a
>> couple of Kb (or forces you to link it statically and be locked to a
>> specific fltk version).
>> Using __attribute__("hidden/visible") calls for gcc and DLLEXPORT stuff
>> on windows and having the makefile strip symbols should bring fltk's
>> footprint to something *much* more competitive to any other toolkit.
>
> That should be pretty easy because we already use FL_EXPORT macros on
> every symbol that should be public (to support VisualC). It's just a
> matter of setting the macro correctly then.
As I pointed out to gga in another post, we don't have exported APIs
that are not needed. FLTK's only private APIs that would qualify are
Fl_Font (2 private symbols) and Fl_Gl_Choice (5 symbols), so we can't
realistically expect to reduce the size of our shared libraries by much.
Also, the GCC "hidden" attribute is only supported on a handful of
platforms...
FL_EXPORT will only handle the "visible" attribute and isn't needed
on Linux anyways (all symbols are visible by default). We'd need to
add FL_INTERNAL to handle the "hidden" attribute, and it would be a
no-op on Windows...
--
______________________________________________________________________
Michael Sweet, Easy Software Products mike at easysw dot com
Internet Printing and Publishing Software http://www.easysw.com
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk