Addressing some dmake issues

#2583
#2840