In Qt6, if you use cmake rather than configure (both are available), you can pass -DQT_LIBINFIX=_MyInFix to cmake.
-DQT_LIBINFIX=_MyInFix