fix for portable library