Click here to Skip to main content
15,879,348 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I am implementing i18n to my project in c++ using GNU xgettext, Xcode.

The situation is as follows
c++”><br
FileOne.cpp

 void somefunction()
 { 
     string file = "fileName";
     loggerClass.addlog(gettext_args("some %s missing ", file));
 }
FileTwo.cpp

 void someOtherfunction()
 { 
     string doc = "docName";
     loggerClass.addlog(gettext_args("some %s missing ", doc));
 }
FileThree.cpp

std::string gettext_args()
{
    gettextWithArgs(const std::string& format, Args ...args);
    return string_format(gettext(format.c_str(), args…));
}


Since each file do not have explicit gettext() function call, I could not invoke xgettext for individual files (like: xgettext -d FileOne -o FileOne.pot FileOne.cpp) for this situation.

How should I invoke xgettext for a whole project (probably from Xcode)?

Thanks
Posted
Updated 12-Aug-16 6:31am
v2

1 solution

You should read the documentation for gettext.

Use msggrep for fetching a directory.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900