use require.package instead of library

Fixes #26.