DescriptionMake IPC_MESSAGE_EXPORT more robust.
Currently, files that want to export ipc messages currently do
#undef IPC_MESSAGE_EXPORT
#define IPC_MESSAGE_EXPORT CONTENT_EXPORT
at the top, and files that don't want to export ipc messages just do nothing. This is problematic if a cc file does
#include "exported_messages.h"
#include "not_exported_messages.h"
because the second header file picks up the #define from the first file and declares all its messages as exported. In other translation units, where not_exported_messages.h is #included without another header above it, the messages will get default visibility – so the same class ends up with different visibilities in different translation units.
Instead, let ipc_message_macros.h #undef IPC_MESSAGE_EXPORT outside of the include guard, so that all files that don't set the define see it as defined to nothing. (Idea from jam@)
Also disable about:ipc in the component build, since ipc logging adds a dependency from chrome on all ipc message classes, so they would all have to be exported.
BUG=90078
TEST=No linker errors about IPC messages when doing components build on mac. (Other linker errors remain for now.)
TBR=brettw
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=122689
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=122828
Patch Set 1 #Patch Set 2 : . #Patch Set 3 : tests #Patch Set 4 : shell #Patch Set 5 : importer tests #Patch Set 6 : jammify #Patch Set 7 : . #Patch Set 8 : linux_shared links #Patch Set 9 : disable ipc logging if components build enabled #Patch Set 10 : fff #Patch Set 11 : ffff #
Total comments: 1
Patch Set 12 : add comment #Patch Set 13 : . #
Messages
Total messages: 21 (0 generated)
|