Unable to connect smack 4.1.5 on Android versions older than 4.2

Hello, I noticed my app works very well on Android versions higher than 4.2 but crashes in lower ones, while I noticed minidns library caused the error NoDef found error, how do I fix this please ?