sanette / tsdl-image

OCaml SDL2_image bindings to go with Tsdl
https://sanette.github.io/tsdl-image/
BSD 3-Clause "New" or "Revised" License
2 stars 4 forks source link

Please remove startup log #8

Closed smimram closed 1 year ago

smimram commented 1 year ago

When using tsdl-image (and tsdl-ttf) in a program, we always get the following log messages at startup which is ennoying:

INFO: Loading Sdl_image, Target = linux
INFO: Loading Sdl_ttf, Target = linux

The culprit is here and since it's a side effect of the module, I don't think that there is an easy way to disable it by changing the log levels before the log message is issued (I don't think that there is a reliable way of ordering the side effects of linked modules).

Unless I overlooked something, could you please remove this startup message in tsdl-image and tsdl-ttf? Thanks!

sanette commented 1 year ago

I think someone else already mentioned this. I'm ok to remove these logs, they have been added to help debugging when porting to other platforms, especially mac os.

smimram commented 1 year ago

Thanks! NB: I have actually been able to remove the logs for now by creating a new library which is liked before tsdl-image and raises the level of printed warnings: https://github.com/savonet/liquidsoap/pull/2913. However, I think that most people would rather have to do that.

sanette commented 1 year ago

done. But I haven't created a new opam version yet

sanette commented 1 year ago

now on opam!

smimram commented 1 year ago

Great, thanks!