re-committing makelibrary change to dynamically calculate number of partial libs