fix linking problems