Update script to install libwrap and add CXX flags for compilation compatibility