add support for newer cm builds and pacman

Signed-off-by: Willi Ye <williye97@gmail.com>