#include <glibmm.h>
  
class MyOptionGroup : public Glib::OptionGroup
{
public:
    Glib::ustring t_arg;

    MyOptionGroup() : Glib::OptionGroup("", "")
    {
        Glib::OptionEntry t_entry;
        t_entry.set_short_name('t');
        t_entry.set_long_name("target");
        add_entry(t_entry, t_arg);
    }
};

int main(int argc, char** argv)
{
    Glib::init();

    Glib::OptionContext ctx("");
    MyOptionGroup grp;

    ctx.set_main_group(grp);
    
    try {
      ctx.parse(argc, argv);
    } catch (...) {}
}
