0

I get two errors while compiling the latest source of Files.

error: The name `with_total_usage' does not exist in the context of `Granite.Widgets.StorageBar'
            storagebar = new Granite.Widgets.StorageBar.with_total_usage (fs_capacity, fs_used);
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

And

 error: The name `FILES' does not exist in the context of `Granite.Widgets.StorageBar.ItemDescription'
        storagebar.update_block_size (Granite.Widgets.StorageBar.ItemDescription.FILES, size);
                                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

But when compiling the 0.2.x version it builds perfectly.

Also, as a side question, why can't I compile main.vala with valac main.vala whitout failing because it can't find Marlin?

  • main.vala is not an independent program - there are a lot of dependencies which valac needs to be able to find. It is intended that you use cmake to build Files (after installing all the necessary -dev packages). – Jeremy Wootten Sep 7 '16 at 16:40
1

Those two errors are pretty self-explanatory. Granite.Widgets.StorageBar.with_total_usage and Granite.Widgets.StorageBar.ItemDescription.FILES don't exist in the version of granite you have installed. You probably need a newer version of granite (quite possibly from git or whatever they use for revision control, if that's where you got files).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.