Compile mfix 18.1.5 in dmp with debug mode

On our cluster I compile mfix.18.1.5 for DMP with

build_mfixsolver --batch --dmp FC=mpiifort -DMPI_Fortran_COMPILER=mpiifort

what changes should I make to have the built in full debug mode to tell me in what subroutine mfix crashes?
I tried this:

build_mfixsolver --batch --dmp FC=mpiifort -DMPI_Fortran_COMPILER=mpiifort -DCMAKE_Fortran_FLAGS="-O3 -g"

but did not seem to work.

Thanks

E.

To add runtime checking for the Intel Fortran compiler, use:

build_mfixsolver --batch --dmp FC=mpiifort -DMPI_Fortran_COMPILER=mpiifort -DCMAKE_Fortran_FLAGS="-O3 -g -check=all"

(For GFortran it would be -fcheck=all)

Thank you. It states:
ifort: command line warning #10158: ignoring option ‘-check’; argument must be separate

https://software.intel.com/sites/default/files/m/f/8/5/8/0/6366-ifort.txt

Looks like you should use -C or -check all