FLTK logo

Re: [fltk/fltk] [fltk 1.4.x/Linux] application invoking native chooser crashes under linux if if fltk built with --enable-localpng (#232)

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.issues  ]
 
Previous Message ]New Message | Reply ]Next Message ]

Re: [fltk/fltk] [fltk 1.4.x/Linux] application invoking native chooser crashes under linux if if fltk built with --enable-localpng (#232) Albrecht Schlosser May 25, 2021  
 

I'm aware of the problems with macros and that's why I wrote that I don't like that solution. I only mentioned it because ISTR that there was a request to use it for building FLTK and some of the bundled libs offer it. For instance: zlib offers #define Z_PREFIX (configure option) to prefix all zlib symbols with 'z_' (see zconf.h).

I agree that a namespace like Fl_PNG_Lib:: sounds much better. I'd guess that most programs wouldn't even notice the difference because they don't use the image lib functions directly - they would only deal with Fl_PNG_Image etc.. Then, if a program decides to deal with the PNG image format directly, they could either link in the png lib of their own choice or use FLTK's Fl_PNG_Lib:: with the namespace.

However, what would we do with the FLTK code to be able to use either the system libs or the bundled libs? Would we just use the namespace by adding using ... or not, depending on the usage of the bundled lib or not, resp.? Unfortunately I think that we'd have to modify the source code of the bundled libs in a way that makes upgrading more difficult. Currently we're using the bundled lib code unmodified except the build files.

Anyway, this is an interesting idea which seems to be worth investigating ...


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Direct Link to Message ]
 
     
Previous Message ]New Message | Reply ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.