On 04/02/2019 16:15, Ingo Franzki wrote: > It would be nice if I could check via #ifdef if that new function is available or not. > For example have a symbol in libcryptsetup.h that contains the current version: > #define LIBCRYPTSETUP_VERSION 0x00020006 > That way one could use > #ifdef LIBCRYPTSETUP_VERSION >= 0x00020006 > to check for a feature. No, sorry, I am not going to provide such strings. Usually, it ends in a big confusion (some distro backports patches without modifying define, etc.) Also, the version of API is not the version of binaries (we use so lib versioning that provides backward compatibility on the symbol level). The proper way would be to use autoconf (or similar tool) that checks availability of symbol and then it automatically defines HAVE_symbol in config.h, but I am not sure if you can use it. I'll try to squeeze it to 2.1 release, there will be some new defines as well, so library name version will be updated appropriately. In the worst case, you can probably "abuse" other defines that appears in libcryptsetup.h (like CRYPT_LOG_DEBUG_JSON) in the same version. Milan _______________________________________________ dm-crypt mailing list dm-crypt@xxxxxxxx https://www.saout.de/mailman/listinfo/dm-crypt