Closed Bug 1601230 Opened 5 years ago Closed 5 years ago

72.0b2 fails to build on double-conversion

Categories

(Core :: MFBT, defect)

Unspecified
OpenBSD
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1600520

People

(Reporter: gaston, Unassigned)

References

(Regression)

Details

(Keywords: regression)

Attachments

(3 files)

strange as m-c was correctly building some weeks ago..

In file included from Unified_cpp_mfbt0.cpp:119:                                                                                           
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:32:            
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:147:3: error: unknown type name            
      'DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN'                                                                                         
  DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(Bignum);                                                                                      
  ^                                                                                                                                        
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:116:7: error: use of undeclared identifier 
      'DOUBLE_CONVERSION_UNREACHABLE'                                                                                                      
      DOUBLE_CONVERSION_UNREACHABLE();                                                                                                     
      ^                                                                                                                                    
In file included from Unified_cpp_mfbt0.cpp:119:                                                                                           
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:33:            
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/ieee.h:31:                    
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:129:38: error: use of undeclared identifier
      'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                   
  static const uint64_t kUint64MSB = DOUBLE_CONVERSION_UINT64_2PART_C(0x80000000, 00000000);                                               
                                     ^                                                                                                     
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:53:5: error: use of undeclared identifier  
      'DOUBLE_CONVERSION_ASSERT'                                                                                                           
    DOUBLE_CONVERSION_ASSERT(e_ == other.e_);                                                                                              
    ^                                                                                                                                      
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:54:5: error: use of undeclared identifier  
      'DOUBLE_CONVERSION_ASSERT'                                                                                                           
    DOUBLE_CONVERSION_ASSERT(f_ >= other.f_);                                                                                              
    ^                                                                                                                                      
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:97:5: error: use of undeclared identifier  
      'DOUBLE_CONVERSION_ASSERT'                                                                                                           
    DOUBLE_CONVERSION_ASSERT(f_ != 0);                                                                                                     
    ^                                                                                                                                      
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:103:32: error: use of undeclared identifier
      'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                   
    const uint64_t k10MSBits = DOUBLE_CONVERSION_UINT64_2PART_C(0xFFC00000, 00000000);                                                     
                               ^                                                                                                           
gmake[3]: Leaving directory '/usr/obj/ports/firefox-72.0beta2/build-amd64/memory/build'                                                    
In file included from Unified_cpp_mfbt0.cpp:119:                                                                                           
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:33:            
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/ieee.h:44:37: error: use of undeclared identifier   
      'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                   
  static const uint64_t kSignMask = DOUBLE_CONVERSION_UINT64_2PART_C(0x80000000, 00000000);    
gmake[3]: Leaving directory '/usr/obj/ports/firefox-72.0beta2/build-amd64/memory/mozalloc'                                                 
/usr/obj/ports/firefox-72.0beta2/bin/c++ -o e_asin.o -c  -DNDEBUG=1 -DTRIMMED=1 -I/usr/obj/ports/firefox-72.0beta2/build-amd64/dist/stl_wra
ppers -I/usr/obj/ports/firefox-72.0beta2/build-amd64/dist/system_wrappers -include /usr/obj/ports/firefox-72.0beta2/firefox-72.0/config/gcc
_hidden.h -fstack-protector-strong -DMOZILLA_CLIENT -include /usr/obj/ports/firefox-72.0beta2/build-amd64/mozilla-config.h -Qunused-argumen
ts -I/usr/X11R6/include -Qunused-arguments -Wall -Wbitfield-enum-conversion -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtype-limits -Wunreachable-code -Wunreachable-code-return -Wwrite-strings -Wno-invalid-offsetof -Wclass-varargs -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wc++1z-compat -Wc++2a-compat -Wcomma -Wimplicit-fallthrough -Wstring-conversion -Wtautological-overlap-compare -Wtautological-unsigned-enum-zero-compare -Wtautological-unsigned-zero-compare -Wno-error=tautological-type-limit-compare -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=backend-plugin -Wno-error=return-std-move -Wno-error=atomic-alignment -Wformat -Wformat-security -Wno-gnu-zero-variadic-macro-arguments -Wno-unknown-warning-option -Wno-return-type-c-linkage -fno-sized-deallocation -fno-aligned-new -O2 -pipe -g -fno-exceptions -fn
o-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -pipe -I/usr/local/include -DEXPORT_JS_API -DMOZ_HAS_MOZGLUE -I/usr/obj/ports/firefox-72.0beta2/firefox-72.0/modules/fdlibm/src -I/usr/obj/ports/firefox-72.0beta2/build-amd64/modules/fdlibm/src -I/usr/obj/ports/firefox-72.0beta2/build-amd64/dist/include -I/usr/local/include/nspr -I/usr/obj/ports/firefox-72.0beta2/build-amd64/dist/include/nss -I/usr/include -fPIC -g -fno-omit-frame-pointer -funwind-tables -Wno-parentheses -Wno-sign-compare -Wno-dangling-else  -MD -MP -MF deps/e_asin.o.pp   /usr/obj/ports/firefox-72.0beta2/firefox-72.0/modules/fdlibm/src/e_asin.cpp                   
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/ieee.h:45:41: error: use of undeclared identifiermodules/fdlibm/src/e_atan2.o                                                                                                                  
                                                                                                                                           
      'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                   
  static const uint64_t kExponentMask = DOUBLE_CONVERSION_UINT64_2PART_C(0x7FF00000, 00000000);  

I think i can suspect bug #1587590 now..

Regressed by: 1587590

Can you check that diy-fp.h is including utils.h correctly? (Stick a #error in the latter as a quick and dirty test)

I wonder if maybe https://github.com/google/double-conversion/commit/3dfc1e3b8b315a36de3ad6b9f0a66661908a41ca isn't playing nice with the moz.build header export magic.

afaict yes it's included but not for all codepaths:

gmake[3]: Leaving directory '/usr/obj/ports/firefox-72.0beta2/build-amd64/js/src/jit' 
In file included from Unified_cpp_mfbt1.cpp:2:                                                                                             
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/double-to-string.cc:32:       
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/double-to-string.h:32:
 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/utils.h:30:2: error: fuuu
                          #error fuuu  


but this one doesnt ?

In file included from Unified_cpp_mfbt0.cpp:119:                                                                                           
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:32:            
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:147:3: error: unknown type name                  'DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN'                                                                                           DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(Bignum);                                                                                      
  ^                                                                                                                                        
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:116:7: error: use of undeclared identifier       'DOUBLE_CONVERSION_UNREACHABLE'                                                                                                            DOUBLE_CONVERSION_UNREACHABLE();                                                                                                     
      ^                                                                                                                                    
In file included from Unified_cpp_mfbt0.cpp:119:
In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:33: 
 In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/ieee.h:31:                    
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:129:38: error: use of undeclared identifier
      'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                     static const uint64_t kUint64MSB = DOUBLE_CONVERSION_UINT64_2PART_C(0x80000000, 00000000);      

Trying to replace "utils.h" with <double-conversion/utils.h> here and there..

Fwiw, an m-c build seems to be fine, so my guess is something to do with building from a source/release tarball - i'm using --with-system-nss & --with-system-nspr usually, but for now only nspr because of bug 1592007 comment 34

Could you do mach build path/to/objdir/mfbt/Unified_cpp_mfbt0.i and share the resulting .i file here?

Also, could you try a test with unified builds turned off? Change UNIFIED_SOURCES to SOURCES here: https://searchfox.org/mozilla-central/rev/8bc24752246aeac8a9aed566cf1caccf88d97d11/mfbt/moz.build#145

It might also be interesting to generate the mfbt0.i from a working m-c build for comparison.

Here's a strange thing I noticed in the include chains:

Unified_cpp_mfbt0.cpp
. e:/mc/mfbt/JSONWriter.cpp
.. e:/mc/obj/dist/include\mozilla/JSONWriter.h
... e:/mc/mfbt/double-conversion\double-conversion/double-conversion.h
.... e:/mc/mfbt/double-conversion\double-conversion/string-to-double.h
..... e:/mc/mfbt/double-conversion\double-conversion/utils.h

JSONWriter.h picks up double-conversion.h from the srcdir/mfbt, not objdir/dist/include! That's because mfbt has a LOCAL_INCLUDES of the double-conversion directory. JSONWriter.h is unique among includers of double-conversion.h in having this special include path.

This might explain the difference between mfbt0.cpp (which contains JSONWriter.cpp) and mfbt1.cpp (which doesn't), but it's not clear to me how exactly this results in the problem.

with SOURCES instead of UNIFIED_SOURCES it still fails:

In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:32:                                                                                  
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:147:3: error: unknown type name 'DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN'                                     
  DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(Bignum);                                                                                                                                                            
  ^                                                                                                                                                                                                              
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:116:7: error: use of undeclared identifier 'DOUBLE_CONVERSION_UNREACHABLE'                                       
      DOUBLE_CONVERSION_UNREACHABLE();                                                                                                                                                                                 ^                                                                                                                                                                                                          In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:33:                                                                                  In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/ieee.h:31:                                                                                          /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:129:38: error: use of undeclared identifier 'DOUBLE_CONVERSION_UINT64_2PART_C'                                     static const uint64_t kUint64MSB = DOUBLE_CONVERSION_UINT64_2PART_C(0x80000000, 00000000);                                                                                                                                                          ^                                                                                                                                                                           /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:53:5: error: use of undeclared identifier 'DOUBLE_CONVERSION_ASSERT'                                                 DOUBLE_CONVERSION_ASSERT(e_ == other.e_);                                                                                                                                                                        ^                                                                                                                                                                                                            /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:54:5: error: use of undeclared identifier 'DOUBLE_CONVERSION_ASSERT'                                                 DOUBLE_CONVERSION_ASSERT(f_ >= other.f_); 

js also fails:

js/src/jit/Unified_cpp_js_src_jit10.o
/usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:97:5: error: use of undeclared identifier 'DOUBLE_CONVERSION_ASSERT'                                                 DOUBLE_CONVERSION_ASSERT(f_ != 0);  

had a bit of a hard time generating it, since mach kept wanting to rerun configure. so this is after failing to build in our ports-tree infrastructure, and running mach build mfbt/Unified_cpp_mfbt0.i from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/ with a .mozconfig containing:

mk_add_options MOZ_OBJDIR=/usr/obj/ports/firefox-72.0beta2/build-amd64/
ac_add_options --with-libclang-path=/usr/local/lib
ac_add_options --with-system-nspr
ac_add_options --with-system-icu
ac_add_options --enable-system-sqlite
ac_add_options --with-system-zlib=/usr
ac_add_options --with-system-bz2=/usr/local

i hope it'll help understanding the include issue :)

doh, and now i realize it was with my tries of replacing "utils.h" with <double-conversion/utils.h> in bignum.h, bignum.cc, bignum-dtoa.h & diy-fp.h.. which didnt help. will retry generating it again.

This one is without patches/changing unified_sources to sources (and fails to build, ofc)

 3:41.00 In file included from Unified_cpp_mfbt0.cpp:119:                                                                                   3:41.00 In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:32:   
 3:41.00 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:147:3: error: unknown type name 'DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN'                                                                                                 
 3:41.01   DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(Bignum);                                                                              3:41.01   ^                                                                                                                               
 3:41.05 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum.h:116:7: error: use of undeclared identifier 'DOUBLE_CONVERSION_UNREACHABLE'                                                                                                   
 3:41.05       DOUBLE_CONVERSION_UNREACHABLE();                                                                                             3:41.05       ^                                                                                                                           
 3:41.06 In file included from Unified_cpp_mfbt0.cpp:119:                                                                                   3:41.06 In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:33:   
 3:41.06 In file included from /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/ieee.h:31:            3:41.07 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:129:38: error: use of undeclared i
dentifier 'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                3:41.07   static const uint64_t kUint64MSB = DOUBLE_CONVERSION_UINT64_2PART_C(0x80000000, 00000000);                                      
 3:41.07                                      ^                                                                                             3:41.07 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:53:5: error: use of undeclared ide
ntifier 'DOUBLE_CONVERSION_ASSERT'                                                                                                          3:41.08     DOUBLE_CONVERSION_ASSERT(e_ == other.e_);                                                                                     
 3:41.08     ^                                                                                                                              3:41.08 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:54:5: error: use of undeclared ide
ntifier 'DOUBLE_CONVERSION_ASSERT'                                                                                                          3:41.08     DOUBLE_CONVERSION_ASSERT(f_ >= other.f_);                                                                                     
 3:41.08     ^                                                                                                                              3:41.08 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:97:5: error: use of undeclared ide
ntifier 'DOUBLE_CONVERSION_ASSERT'                                                                                                          3:41.08     DOUBLE_CONVERSION_ASSERT(f_ != 0);                                                                                            
 3:41.08     ^                                                                                                                              3:41.11 /usr/obj/ports/firefox-72.0beta2/firefox-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:103:32: error: use of undeclared i
dentifier 'DOUBLE_CONVERSION_UINT64_2PART_C'                                                                                                3:41.11     const uint64_t k10MSBits = DOUBLE_CONVERSION_UINT64_2PART_C(0xFFC00000, 00000000);   

Fwiw i think i managed to build 72.0b2 further (unsure, since i have other errors but they're in libvpx or aom) by using SOURCES instead of UNIFIED_SOURCES in two places:

Index: mfbt/moz.build
--- mfbt/moz.build.orig
+++ mfbt/moz.build
@@ -142,7 +142,7 @@ elif CONFIG['OS_ARCH'] == 'Linux':
         'LinuxSignal.h',
     ]
 
-UNIFIED_SOURCES += [
+SOURCES += [
     'Assertions.cpp',
     'ChaosMode.cpp',
     'double-conversion/double-conversion/bignum-dtoa.cc',

Index: js/src/moz.build
--- js/src/moz.build.orig
+++ js/src/moz.build
@@ -208,7 +208,7 @@ EXPORTS.js.experimental += [
     '../public/experimental/SourceHook.h',
 ]
 
-UNIFIED_SOURCES += [
+SOURCES += [
     'builtin/Array.cpp',
     'builtin/AtomicsObject.cpp',
     'builtin/BigInt.cpp',

which are apparently some of the places that include double-conversion.h. Hope this helps.. this issue is a blocker so far for me.

That's because mfbt has a LOCAL_INCLUDES of the double-conversion directory.

I don't like making people waste time with random guesses, but since this one should be fairly quick to test: does anything improve if you remove that LOCAL_INCLUDES block?

(In reply to Landry Breuil (:gaston) from comment #13)

Created attachment 9114101 [details]
Unified_cpp_mfbt0.i from a broken 72.0b2 build

This one is without patches/changing unified_sources to sources (and fails to build, ofc)

Something is strange about this file, it looks like your mfbt0.cpp only includes RecordReplay.cpp, nothing else.

(In reply to :dmajor from comment #15)

That's because mfbt has a LOCAL_INCLUDES of the double-conversion directory.

I don't like making people waste time with random guesses, but since this one should be fairly quick to test: does anything improve if you remove that LOCAL_INCLUDES block?

sadly, that didnt help.

In parallel I've been trying to reproduce this locally in WSL, and I have not been successful. I used the 72b2 source tarball, and built my own ICU. (I don't know how to do the other parts, but I don't think they matter)

Sorry to push the work onto your side, but would you mind bisecting ICU to see where things went wrong? As far as I can tell, the regressor bug 1587590 was not motivated by any specific fix, just a general sense of "let's be less stale". Perhaps we can live with a slightly less up-to-date ICU revision if it prevents breaking your config.

I've seen many things in mozilla development, and i really doubt 'downgrade ICU to fix the break on a tier-3 platform' has a chance to happen :)

i hadnt realized it was linked to icu at all, and fwiw my build is with the systemwide ICU 65.1. I'll give it a shot with the bundled ICU but im not sure this matters.. pretty sure the problem lies somewhere in the way double-conversion is included from its consumers (mfbt & js/src, afaict per https://searchfox.org/mozilla-central/search?q=double-conversion.h&case=false&regexp=false&path=) and given that using SOURCES instead of UNIFIED_SOURCES in those two consumers seemed to help, although things then broke later on with include issues on vpx/aom....

bah. just need to find time to dig deeper into it, and i dont really know where to start. I can try as many things as you can propose, as long as you have precise directions.

Sorry to push the work onto your side, but would you mind bisecting ICU to see where things went wrong?

Oh, sorry! Big typo there. I meant bisecting double-conversion.

Even that might be difficult to revert for the sake of a tier 3 platform, but perhaps finding the culprit could make for an easier local patch that you could carry.

I'd also be happy to fast-track uplifting a fix to Beta if there's ultimately a patch which we could submit upstream for this too.

I tried reverting https://github.com/google/double-conversion/commit/3dfc1e3b8b315a36de3ad6b9f0a66661908a41ca completely, but the build fails with:

In file included from Unified_cpp_mfbt0.cpp:119:
/usr/obj/ports/firefox-72.0beta4/firefox-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:30:10: fatal error: 
      'double-conversion/bignum-dtoa.h' file not found
#include <double-conversion/bignum-dtoa.h>
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
gmake[3]: *** [/usr/obj/ports/firefox-72.0beta4/firefox-72.0/config/rules.mk:806: Unified_cpp_mfbt0.o] Error 1

which is strange, as double-conversion/bignum-dtoa.h exists in the source tree... but not in ../../../../build-amd64/dist/include/double-conversion (the objdir).

from my understanding, instead of completely reverting the said commit i should only do it for the includes that are copied in the objdir ?

The complete build line for the failure is:

/usr/obj/ports/firefox-72.0beta4/bin/c++ -o Unified_cpp_mfbt0.o -c  -I/usr/obj/ports/firefox-72.0beta4/build-amd64/dist/system_wrappers -in
clude /usr/obj/ports/firefox-72.0beta4/firefox-72.0/config/gcc_hidden.h -fstack-protector-strong -DNDEBUG=1 -DTRIMMED=1 -DIMPL_MFBT -DLZ4LI
B_VISIBILITY= -I/usr/obj/ports/firefox-72.0beta4/firefox-72.0/mfbt -I/usr/obj/ports/firefox-72.0beta4/build-amd64/mfbt -I/usr/obj/ports/fir
efox-72.0beta4/build-amd64/dist/include -I/usr/local/include/nspr -I/usr/local/include/nss -I/usr/obj/ports/firefox-72.0beta4/build-amd64/d
ist/include/nss -I/usr/include -fPIC -DMOZILLA_CLIENT -include /usr/obj/ports/firefox-72.0beta4/build-amd64/mozilla-config.h -Qunused-argum
ents -I/usr/X11R6/include -Qunused-arguments -Wall -Wbitfield-enum-conversion -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpoin
ter-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtype-limits -Wunreachable-code -Wunreachable-code-return -Wwrite-strings 
-Wno-invalid-offsetof -Wclass-varargs -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wc++1z-compat -Wc++2a-compat -Wc
omma -Wimplicit-fallthrough -Wstring-conversion -Wtautological-overlap-compare -Wtautological-unsigned-enum-zero-compare -Wtautological-uns
igned-zero-compare -Wno-error=tautological-type-limit-compare -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bo
unds -Wno-error=backend-plugin -Wno-error=return-std-move -Wno-error=atomic-alignment -Wformat -Wformat-security -Wno-gnu-zero-variadic-mac
ro-arguments -Wno-unknown-warning-option -Wno-return-type-c-linkage -fno-sized-deallocation -fno-aligned-new -O2 -pipe -g -fno-exceptions -
fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -pipe -I/usr/local/include -g -f
no-omit-frame-pointer -funwind-tables  -MD -MP -MF .deps/Unified_cpp_mfbt0.o.pp   Unified_cpp_mfbt0.cpp   

and that doesnt reach out to the source dir where 'missing' double-conversion headers are.

Good news! managed to build & link 72.0b4 with the following:

cd /usr/obj/ports/firefox-72.0beta4/firefox-72.0/mfbt/double-conversion/double-conversion/
sed -i.orig -e 's#"utils.h"#<double-conversion/utils.h>#' *

that modified 12 files in the double-conversion export, but apparently that's enough for a working build. Do we want to have that as an m-c commit on top of bug 1587590 (with a patch added in-tree like the 4 existing patches) or/and the sed should be added to double-conversion/update.sh ?

or the root cause should be found anyway ? i can still try things (poking at the moz.build files) during this beta cycle, i'd just like the issue to be fixed before 72 hits release.

Glad to hear you have a workaround. I don't think we truly understand the issue though, so I'm not very keen on applying the sed trick to m-c.

What's especially frustrating is that I could figure this out in a few minutes if I were physically sitting at your machine, or if I could reproduce it locally. Unfortunately, with the internet standing in between, this is pretty painful. I have a bunch of "what if" ideas that I don't want to waste your time with, nor keep asking you for this and that log. And I'm already confused about the existing comments in the bug, it's hard to keep track of what log was for what experiment. Since I have other work piling up I think I need to step away at this point. :-(

Not sure if Waldo has any strong opinions on this, but CCing him just in case.

interestingly, applying the same ugly workaround doesn't fix thunderbird 72.0b1 build:

/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/config/gcc_hidden.h -fstack-protector-strong -DMOZILLA_CLIENT -include /usr/obj/ports/thunderbird-72.0beta1/build-amd64/mozilla-config.h -Qunused-arguments -I/usr/local/include -I/usr/X11R6/include -Qunused-arguments -Wall -Wbitfield-enum-conversion -Wempty-body -Wignored-qualifiers -Woverloaded-virtual -Wpointer-arith -Wshadow-field-in-constructor-modified -Wsign-compare -Wtype-limits -Wunreachable-code -Wunreachable-code-return -Wwrite-strings -Wno-invalid-offsetof -Wclass-varargs -Wfloat-overflow-conversion -Wfloat-zero-conversion -Wloop-analysis -Wc++1z-compat -Wc++2a-compat -Wcomma -Wimplicit-fallthrough -Wstring-conversion -Wtautological-overlap-compare -Wtautological-unsigned-enum-zero-compare -Wtautological-unsigned-zero-compare -Wno-error=tautological-type-limit-compare -Wno-inline-new-delete -Wno-error=deprecated-declarations -Wno-error=array-bounds -Wno-error=backend-plugin -Wno-error=return-std-move -Wno-error=atomic-alignment -Wformat -Wformat-security -Wno-gnu-zero-variadic-macro-arguments -Wno-unknown-warning-option -Wno-return-type-c-linkage -fno-sized-deallocation -fno-aligned-new -O2 -pipe -g -fno-exceptions -fno-strict-aliasing -fno-rtti -ffunction-sections -fdata-sections -fno-exceptions -fno-math-errno -pthread -pipe -I/usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt -I/usr/obj/ports/thunderbird-72.0beta1/build-amd64/mfbt -I/usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion -I/usr/obj/ports/thunderbird-72.0beta1/build-amd64/dist/include -I/usr/local/include/nspr -I/usr/local/include/nss -I/usr/obj/ports/thunderbird-72.0beta1/build-amd64/dist/include/nss -I/usr/include -fPIC -g -fno-omit-frame-pointer -funwind-tables  -MD -MP -MF .deps/Unified_cpp_mfbt0.o.pp   Unified_cpp_mfbt0.cpp
In file included from /usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:32:                                   
/usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/bignum.h:147:3: error: unknown type name 'DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN'
  DOUBLE_CONVERSION_DISALLOW_COPY_AND_ASSIGN(Bignum); 
  ^                                                                                                                                                                                                                  
/usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/bignum.h:116:7: error: use of undeclared identifier 'DOUBLE_CONVERSION_UNREACHABLE'
      DOUBLE_CONVERSION_UNREACHABLE();
      ^                                                                                                                                                                                                              
In file included from Unified_cpp_mfbt0.cpp:119:
In file included from /usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/bignum-dtoa.cc:33:
In file included from /usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/ieee.h:31:
/usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:129:38: error: use of undeclared identifier 'DOUBLE_CONVERSION_UINT64_2PART_C'
  static const uint64_t kUint64MSB = DOUBLE_CONVERSION_UINT64_2PART_C(0x80000000, 00000000);                                                                                                                         
                                     ^                                                                    
/usr/obj/ports/thunderbird-72.0beta1/thunderbird-72.0/mfbt/double-conversion/double-conversion/diy-fp.h:53:5: error: use of undeclared identifier 'DOUBLE_CONVERSION_ASSERT'
    DOUBLE_CONVERSION_ASSERT(e_ == other.e_);            

as if there was yet another utils.h shadowing the one from double-conversion.. and wow now i think i know where it comes from.

double-conversion-3.1.5:math/double-conversion:/usr/local/include/double-conversion/utils.h

we have a systemwide double-conversion, which is a (new?) dependency of qt5, and it happens to be installed on my system (and i guess from a different now incompatible version from the one in m-c), and -I/usr/local/include is in the list of include paths. This port was imported two months ago in https://github.com/openbsd/ports/commit/b8264904e1c7c89ddf1f8ba6a35cb115fb39b439

If i uninstall it (and qt5) the thunderbird 72.0b1 build goes further.

So in light of all this, imo the ultimate (?) fix would be to ensure dist/include is searched first whatever is passed in the env...

Maybe related to bug 1600520. Did you try building 72.0b4 or later without hacks?

Flags: needinfo?(landry)

oh, thanks jan for the pointer, that definitely fixes it. 72.0b6 & tb 72.0b2 now build fine without messing around with double-conversion includes.

Status: NEW → RESOLVED
Closed: 5 years ago
Flags: needinfo?(landry)
Resolution: --- → DUPLICATE
Regressed by: 1596475
No longer regressed by: 1587590
Has Regression Range: --- → yes
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: