-
Notifications
You must be signed in to change notification settings - Fork 16k
Description
The Obj-C backend currently mangles the input filenames, converting e.g., foo_bar.proto to FooBar.pb.m. This causes problems for build systems (including Xcode) that could otherwise automatically track dependencies and recompile proto files only as needed.
The offending code is in src/google/protobuf/compiler/objectivec/objectivec_helpers.cc. The call to UnderscoresToCamelCase() here should be removed:
string FilePath(const FileDescriptor* file) {
string output;
string basename;
string directory;
PathSplit(file->name(), &directory, &basename);
if (directory.length() > 0) {
output = directory + "/";
}
basename = StripProto(basename);
// CamelCase to be more ObjC friendly.
basename = UnderscoresToCamelCase(basename, true);
output += basename;
return output;
}