Improved method of loading libraries