[Gambas-user] Calling library functions in Gambas2

easuter easuter at ...626...
Thu Aug 30 20:22:16 CEST 2007


Thanks for both the replies!
I'll try the latest revision of Gambas (and parted, just to make sure ;)

Ron: unfortunately, fdisk returns the filesystem type (ID), not the
filesystem name. It will identify both reiserfs and ext3 simply as "Linux",
thats why its not very useful.
I already have working code to parse the text output from parted which will
give me the filesystem names (parted /dev/hda unit compact print), however,
parted is slower than fdisk and does not (and cannot) give the data for all
the drives at once (that command has to be re-run for hdb, sda, etc...). Add
to that that the output still has to be parsed with some very intricate FOR
loops (within other FOR/WHILE loops) and using a couple of arrays to get the
data split up in a usable manner...its just far to slow and messy.

Thats why I'm trying to use libparted directly. This is the hardest way, but
will be the fastest if I can get it to return only the values I need, and in
a way that requires the least amount of parsing.
-- 
View this message in context: http://www.nabble.com/Calling-library-functions-in-Gambas2-tf4295859.html#a12413230
Sent from the gambas-user mailing list archive at Nabble.com.





More information about the User mailing list