in reply to use package

To make the package load happen at runtime, you need to use require rather than use, and for safety, wrap it in an eval block to check errors. The basic approach is
if ( $Format eq "MSWin32" ) { eval { require Win32::DriveInfo }; if ( $@ ) { # handle error }