MXNET amalgamation with mkl-dnn

I am trying to amalgamate the MXNET library by following the instructions here.
By default, the amalgamation uses OpenBLAS as the BLAS library.

How can I modify the Makefile to select mkl-dnn instead using a specified path to the library. I have obtained one of the static builds of mkl-dnn libmkldnn.a and would like to use that as it is the best performing backend. Note that I need to use the static library and not the dynamic one.

Any help is appreciated, I am not very familiar with using Makefiles.