Fix linking errors when using