Since the problem was only one package which was using the older apt tool. This tool was deprecated in Java 7 and removed in Java 8. I had Java 8 on my system. So I took the tools.jar from older OpenJDK7u51 and included it as an external jar to my project. Problem solved
I know the issue I raised was help in migrating the code from apt tool. But now since the compilation errors have been removed, I can proceed with proper replacement on my own.