Statically link cfupgrade to libcompat.

(cherry picked from commit 53e0afea0f13187811b2e92c60f2d67c3dd2b71f)