Re: [AD] version check in allegro_init

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> Do we really need to make the check optional?  We could just put the
> check into install_allegro() and if the versions don't match we can show
> a message using allegro_message() and return an error code.

The problem is that we need to check the values of ALLEGRO_VERSION,
ALLEGRO_SUB_VERSION and ALLEGRO_WIP_VERSION as defined in the header file
#included by the user to the values in the headerfile used when the library
was compiled. The only way to do this (as far as I know) is to pass the
values as arguments to a function in the library from the user's code.
Doing this using install_allegro() makes the most sense, but we can't add
arguments to the function because it's part of the public API.

I guess that means that it will continue to be possible for the user to
skip the check if s/he really wants to do that, although we could depricate
the plain install_allegro() to encourage people to switch to the new
function.

Evert




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/