Page 1 of 1
GetDiskFreeSpace & GetVolumeInformation on Linux & Mac ?
Posted: Wed Nov 24, 2010 12:29 am
by sverson
Hi Linux & Mac experts,
I am looking for functions similar to the Win API functions GetDiskFreeSpaceEx_ & GetVolumeInformation_.
Thanks.
Re: GetDiskFreeSpace & GetVolumeInformation on Linux & Mac ?
Posted: Wed Nov 24, 2010 6:06 pm
by IdeasVacuum
I don't know - in Unix you would use something like:
So if df is also used by Linux (I think so), you can do something in PB with RunProgram()
This might help for the MAC:
http://developer.apple.com/library/mac/ ... til.8.html
Re: GetDiskFreeSpace & GetVolumeInformation on Linux & Mac ?
Posted: Wed Nov 24, 2010 7:15 pm
by LuCiFeR[SD]
statvfs() and fstatvfs() are probably what you would require. Just search for those in the "flavour of linux you use" man pages for info about the structures etc.
Re: GetDiskFreeSpace & GetVolumeInformation on Linux & Mac ?
Posted: Thu Nov 25, 2010 1:26 am
by sverson
Thanks IdeasVacuum,
Thanks LuCiFeR[SD]
remi_meier actually wrote a statvfs example:
PureBoard (german)
