I've recently had a question about coledatetime java implementation, and Chris said, that the problem might lay in type conversions: cpp-float vs java-float (Or maybe cpp-date vs java-date. Not types, but..). Now I have several questions on this:
In c++ type ranges can and do differ from one implementation (compiler/architecture) to another, so there is no standard Java-C++ type comparisons as there is no standard C++ type sizes.
But in most current architectures C++ doubles are standard IEEE 754 doubles, as it is in Java. So while the code will not be strictly portable to some rare architecture, it will more often than not work in any x86/x86_64 architectures.
There was a question in the comments of the previous answer that you did not address: what is it that does not work in the implementation you have?