
On Feb 28, 2010, at 05:17 , Matthias Kilian wrote:
On Sat, Feb 27, 2010 at 06:27:19PM -0500, Brandon S. Allbery KF8NH wrote:
I don't know of any Haskell bindings offhand, but getmntent() and friends are the standard library interface for identifying mountpoints and statfs()/statvfs() are the interface for getting information about them. Be aware that the latter can be fairly system-dependent.
getmntent() isn't in any standard I know about. IMHO, getting information about mounted filesystems will always be system dependent.
It's more of a de-facto standard, inherited from System V but not part of SVID and successors. Between Linux/glibc and Solaris you have a goodly chunk of the GHC-relevant world. *BSD and Mac OS X should look at getmntinfo(); I suspect that'll be painful to get at via the FFI, though. -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery@kf8nh.com system administrator [openafs,heimdal,too many hats] allbery@ece.cmu.edu electrical and computer engineering, carnegie mellon university KF8NH