ipc_channel_posix.cc fails to compile on SeaMonkey OS X debug buildslave

RESOLVED FIXED in seamonkey2.16


Build Config
5 years ago
5 years ago


(Reporter: mcsmurf, Unassigned)


Mac OS X
Dependency tree / graph

SeaMonkey Tracking Flags

(seamonkey2.15 fixed)



(1 attachment, 1 obsolete attachment)



5 years ago
ipc_channel_posix.cc fails to compile on SeaMonkey OS X debug buildslave (in this case on the comm-aurora/mozilla-aurora tree):
/usr/bin/clang++ -o ipc_channel_posix.o -c  -fvisibility=hidden -DMOZILLA_INTERNAL_API -D_IMPL_NS_COM -DEXPORT_XPT_API -DEXPORT_XPTC_API -D_IMPL_NS_GFX -D_IMPL_NS_WIDGET -DIMPL_XREAPI -DIMPL_NS_NET -DIMPL_THEBES  -DSTATIC_EXPORTABLE_JS_API -DMOZ_SUITE=1 -DEXCLUDE_SKIA_DEPENDENCIES  -DOS_POSIX=1 -DOS_MACOSX=1  -DHAVE_CONFIG_H -I/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium/src -I/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/glue -I../../ipc/ipdl/_ipdlheaders  -I/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium/src/third_party/libevent -I/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium/src/third_party/libevent/mac -I/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium -I. -I../../dist/include  -I/builds/slave/comm-aurora-osx64-dbg/build/objdir/mozilla/dist/include/nspr -I/builds/slave/comm-aurora-osx64-dbg/build/objdir/mozilla/dist/include/nss      -fPIC -Qunused-arguments  -Qunused-arguments -Wall -Wpointer-arith -Woverloaded-virtual -Werror=return-type -Wtype-limits -Wempty-body -Wno-ctor-dtor-privacy -Wno-overlength-strings -Wno-invalid-offsetof -Wno-variadic-macros -Wno-c++0x-extensions -Wno-unknown-warning-option -Wno-return-type-c-linkage -Wno-mismatched-tags -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -pthread -DNO_X11 -pipe  -DDEBUG -D_DEBUG -DTRACING -gdwarf-2 -DNO_X11 -O3 -fno-omit-frame-pointer   -Qunused-arguments  -DMOZILLA_CLIENT -include ../../mozilla-config.h -MD -MF .deps/ipc_channel_posix.o.pp  /builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium/src/chrome/common/ipc_channel_posix.cc
/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium/src/chrome/common/ipc_channel_posix.cc:136:55: error: invalid use of nonstatic data member 'sun_path'
const size_t kMaxPipeNameLength = sizeof(sockaddr_un::sun_path);
/builds/slave/comm-aurora-osx64-dbg/build/mozilla/ipc/chromium/src/chrome/common/ipc_channel_posix.cc:156:5: warning: expression result unused [-Wunused-value]
17 warnings and 1 error generated.
make[6]: *** [ipc_channel_posix.o] Error 1

Possible fix for this issue: http://src.chromium.org/viewvc/chrome/trunk/src/ipc/ipc_channel_posix.cc?view=diff&r1=60130&r2=60131

But: The reason that this works on the Firefox tinderbox without that fix is that the FF tinderbox uses -std=gnu++0x in its buildflags, SeaMonkey buildbox somehow does not include that buildflag. Should probably investigate why that happens.

Comment 1

5 years ago
One more idea: Maybe this error has to do with the failed python virtualenv creation (this is not fatal yet, so the build just continues). We'll see when Bug 806317 is fixed.

Comment 2

5 years ago
Correction on Comment 1: I meant not the error itself, but the missing -std=gnu++0x compiler flag compared to the FF build or the SM opt build.

Comment 3

5 years ago
This code in configure.in probably causes the debug not to use the -std=gnu++0x mode:
2752 dnl Check for usable char16_t (2 bytes, unsigned)
2753 dnl (we might not need the unsignedness check anymore)
2754 AC_CACHE_CHECK(for usable char16_t (2 bytes, unsigned),

OS X debug build:
checking for gcc c++0x headers bug without rtti... no
checking for usable char16_t (2 bytes, unsigned)... no

OS X opt build:
checking for gcc c++0x headers bug without rtti... no
checking for usable char16_t (2 bytes, unsigned)... yes

For the -std=gnu++0x mode the first one needs to be no and the second one needs to be yes.

Comment 4

5 years ago
Created attachment 676935 [details] [diff] [review]

Quite likely the correct fix, we need to add the OS X sdk to the debug .mozconfig, too. I assume that's the reason why configure does not find a usable char16_t (see Comment 3).
Attachment #676935 - Flags: review?(bugspam.Callek)
Comment on attachment 676935 [details] [diff] [review]

Review of attachment 676935 [details] [diff] [review]:

::: suite/config/mozconfigs/macosx64/debug
@@ +1,1 @@
> +ac_add_options --with-macos-sdk=/Developer/SDKs/MacOSX10.6.sdk

Actually what we want is to source the common file

. $topsrcdir/build/macosx/mozconfig.common

Which will switch our debug builds to the same clang we use in the real opt builds. which is the right choice here to match TB/Firefox afaict

Attachment #676935 - Flags: review?(bugspam.Callek) → review-

Comment 6

5 years ago
Created attachment 678248 [details] [diff] [review]

Should I also add
# Enable parallel compiling
mk_add_options MOZ_MAKE_FLAGS="-j4"

to speed up the build?
Attachment #676935 - Attachment is obsolete: true
Attachment #678248 - Flags: review?(bugspam.Callek)
Comment on attachment 678248 [details] [diff] [review]

Not required, but adding -j4 is probably also a good idea!
Attachment #678248 - Flags: review?(bugspam.Callek) → review+

Comment 8

5 years ago
Pushed: https://hg.mozilla.org/comm-central/rev/71adceeda938
Leaving open for comm-aurora approval if the patch works as expected.
Target Milestone: --- → seamonkey2.16

Comment 9

5 years ago
> mk_add_options MOZ_MAKE_FLAGS="-j4"
Depends on how many cores the VM has.

Comment 10

5 years ago
Comment on attachment 678248 [details] [diff] [review]

[Approval Request Comment]
Regression caused by (bug #): -
User impact if declined: No debug builds on Mac OS X
Testing completed (on m-c, etc.): Patch has been tested on comm-central, debug builds work fine again, see http://tbpl.drapostles.org/?tree=SeaMonkey
Risk to taking this patch (and alternatives if risky): No risk, patch does not affect release builds
String changes made by this patch: -
Attachment #678248 - Flags: approval-comm-aurora?


5 years ago
Attachment #678248 - Flags: approval-comm-aurora? → approval-comm-aurora+

Comment 11

5 years ago
Pushed: http://hg.mozilla.org/releases/comm-aurora/rev/4f3140a9ed92
Last Resolved: 5 years ago
status-seamonkey2.15: --- → fixed
Resolution: --- → FIXED
Blocks: 831279
You need to log in before you can comment on or make changes to this bug.