build system: fix dmm for linux
dmm: compute dmm-specific matrices
dmm: write matrices