tweak to library.pl