Add a kludge to fix building shared libs