Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6014005
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T02:37:46+00:00 2026-05-23T02:37:46+00:00

I just started with learning vala. I tried the following program from the vala

  • 0

I just started with learning vala. I tried the following program from the vala tutorial.

class Demo.Hello : Glib.Object
{
  public static int main( string[] args )
  {
    stdout.printf("Hello, Vala!\n");
    return 0;
  }
}

and got this when I compiled.

$ valac hello.vala 
hello.vala:1.20-1.23: error: The symbol `Glib' could not be found
class Demo.Hello : Glib.Object
                   ^^^^
Compilation failed: 1 error(s), 0 warning(s)
[1]+  Done                    gvim hello.vala

If I remove Glib. from Glib.Object i.e leave it with just class Demo.Hello : Object, then everything works fine. But all the programs in the tutorial use Glib.Object. What’s wrong here? I searched for answers but could not find it. Here is the vala version info:

$ valac --version
Vala 0.5.2

And I am running the latest version of CentOS.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T02:37:46+00:00Added an answer on May 23, 2026 at 2:37 am

    The correct name is GLib. But you can just as well leave the “GLib.” out and just write “Object”, the GLib namespace is implicitely used in all vala apps.
    For other namespaces you can use “using”, for example using Gtk;.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I just started learning C++ and I wrote this sample program from the text
I just started learning C++ (coming from Java ) and am having some serious
I've just started learning Qt, using their tutorial. I'm currently on tutorial 7, where
i just started learning swings. And thought of trying out a simple program, but
I just started learning Python... I am writing a simple program that will take
I just started learning SL. I have tried to resize all the elements inside
I just started learning blueprint css , with the tutorial a closer look at
Just started learning OpenGL and couldn't find a decent tutorial to get me going.
We just started learning about class inheritance and attribute lookup in python. I have
I just started learning haskell, and I tried to implement a simple function to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.