This is a bash script to install the latest version of Dlib on an Ubuntu machine. You just need to execute the bash file in terminal and it takes care of everything.
$ chmod +x install_dlib.sh
$ ./install_dlib.sh
It also includes two bash files to compile dlib C++ codes and codes with both Dlib and OpenCV libraries:
$ ./compile_dlib.sh myDlibCode.cpp
$ ./compile_opencv_dlib.sh myOpenCvDlibCode.cpp