media/webrtc/trunk/webrtc/voice_engine/voice_engine_defines.h:295:9: error: 'FALSE' macro redefined [-Werror,-Wmacro-redefined]

RESOLVED FIXED in 4.17

Status

defect
RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: jbeich, Unassigned)

Tracking

4.16
4.17
All
FreeBSD
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

Reporter

Description

2 years ago
Properly passing -DWEBRTC_BSD in Gecko exposes NSPR includes <rpc/types.h> which (conditionally) defines TRUE/FALSE. FreeBSD had INADDR_LOOPBACK in <netinet/in.h> for ~21 years. Let's drop such necro-portability.

http://searchfox.org/mozilla-central/rev/e8c36327cd8c/nsprpub/pr/include/prinet.h#66
https://svnweb.freebsd.org/changeset/base/21098

$ echo "ac_add_options --enable-warnings-as-errors # mimic MOZ_AUTOMATION" >>.mozconfig
$ ./mach build
[...]
In file included from media/webrtc/signaling/src/media-conduit/AudioConduit.cpp:27:
In file included from media/webrtc/trunk/webrtc/voice_engine/voice_engine_impl.h:18:
In file included from media/webrtc/trunk/webrtc/voice_engine/voe_base_impl.h:18:
In file included from media/webrtc/trunk/webrtc/voice_engine/shared_data.h:22:
In file included from media/webrtc/trunk/webrtc/voice_engine/statistics.h:18:
media/webrtc/trunk/webrtc/voice_engine/voice_engine_defines.h:295:9: error: 'FALSE'
      macro redefined [-Werror,-Wmacro-redefined]
#define FALSE 0
        ^
/usr/include/rpc/types.h:57:10: note: previous definition is here
#       define FALSE    (0)
               ^
In file included from media/webrtc/signaling/src/media-conduit/AudioConduit.cpp:27:
In file included from media/webrtc/trunk/webrtc/voice_engine/voice_engine_impl.h:18:
In file included from media/webrtc/trunk/webrtc/voice_engine/voe_base_impl.h:18:
In file included from media/webrtc/trunk/webrtc/voice_engine/shared_data.h:22:
In file included from media/webrtc/trunk/webrtc/voice_engine/statistics.h:18:
media/webrtc/trunk/webrtc/voice_engine/voice_engine_defines.h:296:9: error: 'TRUE' macro
      redefined [-Werror,-Wmacro-redefined]
#define TRUE 1
        ^
/usr/include/rpc/types.h:60:10: note: previous definition is here
#       define TRUE     (1)
               ^
2 errors generated.
Reporter

Comment 1

2 years ago
Posted patch v1Splinter Review
Attachment #8898932 - Flags: review?(kaie)

Updated

2 years ago
Attachment #8898932 - Flags: review?(kaie) → review+
https://hg.mozilla.org/projects/nspr/rev/75777231f326
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 4.17
You need to log in before you can comment on or make changes to this bug.