Add PKGMANDIR variable handling to be robotpkg compatible.

This avoid potential patches in robotpkg.