HolyLow commented on PR #2976: URL: https://github.com/apache/celeborn/pull/2976#issuecomment-2522739151
@FMX FindProtobuf method has its problem, that the dependency of protobuf-generation cannot be declared explicitly. This wouldn't be a problem if the protobuf module is exported as a standalone library so the dependency could be solved by other moudle's target_link_library(), but celebornCpp would be exported as a compact library as a whole, and all the compilation target would be exported in a single libceleborn.a. In this case, the protobuf's .o file would be collected in a libceleborn.a library rather than a standalone libproto.a library, and the dependency between the proto generation and other proto-dependent files cannot be declared by the FindProtobuf method. This is why I explicitly use the add_custom_command() method which offers more accurate control over the dependency problem. Besides, it seems you are using the clion IDE to import the project, and I guess maybe you trigger the compilation by running the utils/tests/ExceptionTest.cpp. As the testcase has no dependency over the libproto.a, the proto generation would not be triggered. If you are running the compilation on command line, like ``` rm -rf build && mkdir build && cd build cmake .. make ``` The libproto.a and the protofiles would be generated as expected, which I've tested several times. Also, maybe you could try to compile the whole project on Clion IDE to check if the protofile and libproto.a could be generated as expected. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
