dmm: add wrapper for conversion of logicals to integers (supported under intel compiler but not gfortran), #568
dmm: incorporate into build system