mdp needs the ncursesw headers to compile.
So make sure you have them installed:
-- On Ubuntu you need ```libncursesw5``` and ```libncursesw5-dev``` to be installed.
+- On Ubuntu/Debian you need `libncursesw5` and `libncursesw5-dev` to be installed.
Now download and install mdp: