GN processor's mozbuild writer may pick the wrong conditions
Categories
(Firefox Build System :: General, defect, P3)
Tracking
(Not tracked)
People
(Reporter: glandium, Unassigned)
References
Details
Attachments
(1 file)
2.46 KB,
text/plain
|
Details |
This happened in bug 1738845, because of the missing combinations for MOZ_X11. This was worked around in https://phabricator.services.mozilla.com/D149850, but we need a more definitive solution, preferably not relying on a manual list of combinations.
Updated•3 years ago
|
Just a question, can't we add
diff --git a/third_party/libwebrtc/moz.build b/third_party/libwebrtc/moz.build
index 8579f8bb3622..d9ca79d4fcb8 100644
--- a/third_party/libwebrtc/moz.build
+++ b/third_party/libwebrtc/moz.build
@@ -520,7 +520,10 @@ if CONFIG["CPU_ARCH"] == "ppc64" and CONFIG["OS_TARGET"] == "Linux":
"/third_party/libwebrtc/api/audio_codecs/isac/audio_decoder_isac_float_gn",
"/third_party/libwebrtc/api/audio_codecs/isac/audio_encoder_isac_float_gn",
"/third_party/libwebrtc/modules/audio_coding/isac_c_gn",
- "/third_party/libwebrtc/modules/audio_coding/isac_gn"
+ "/third_party/libwebrtc/modules/audio_coding/isac_gn",
+ "/third_party/libwebrtc/modules/desktop_capture/desktop_capture_generic_gn",
+ "/third_party/libwebrtc/modules/desktop_capture/desktop_capture_gn",
+ "/third_party/libwebrtc/modules/desktop_capture/primitives_gn"
]
if CONFIG["CPU_ARCH"] == "x86" and CONFIG["OS_TARGET"] == "Linux":
as a workaround until there is a proper fix? I am aware we would lose the workaround when the moz.build file will be regenerated, but it would help our CI running green even with webrtc enabled on ppc64le.
Comment 3•2 years ago
|
||
This almost acts like it believes desktop capture is unsupported on ppc64.
Comment 4•2 years ago
|
||
Comparing the output of gn from x86_64
and ppc64
, desktop_capture_generic
, desktop_capture
and primitives
all appear in the generated JSON, so I don't know why gn_processor.py
didn't pick it up.
Reporter | ||
Comment 5•2 years ago
|
||
(In reply to Cameron Kaiser [:spectre] from comment #4)
Comparing the output of gn from
x86_64
andppc64
,desktop_capture_generic
,desktop_capture
andprimitives
all appear in the generated JSON, so I don't know whygn_processor.py
didn't pick it up.
because the code in https://searchfox.org/mozilla-central/rev/52da19becaa3805e7f64088e91e9dade7dec43c8/python/mozbuild/mozbuild/gn_processor.py#507-522 doesn't work properly.
Comment 6•2 years ago
|
||
Regardless of that, shouldn't those other permutations have dirs in them? Adding some additional debugging to gn_processor.py
, I see this:
args ('MOZ_DEBUG', '1') ('OS_TARGET', 'Linux') ('CPU_ARCH', 'ppc64') ('MOZ_X11', '1')
common_dirs third_party/libwebrtc/modules/desktop_capture/desktop_capture_generic_gn,third_party/libwebrtc/modules/desktop_capture/desktop_capture_gn,third_party/libwebrtc/modules/desktop_capture/primitives_gn
args ('MOZ_DEBUG', '1') ('OS_TARGET', 'Linux') ('CPU_ARCH', 'ppc64') ('MOZ_X11', None)
common_dirs
args ('MOZ_DEBUG', None) ('OS_TARGET', 'Linux') ('CPU_ARCH', 'ppc64') ('MOZ_X11', '1')
common_dirs
args ('MOZ_DEBUG', None) ('OS_TARGET', 'Linux') ('CPU_ARCH', 'ppc64') ('MOZ_X11', None)
common_dirs
Since common_dirs
gets &=
with the dir set, then these are lost. That explains the issue, so why aren't those showing up in the other permutations? Or is that the bug you mean?
Comment 7•2 years ago
|
||
They don't get added when MOZ_X11
is None
. That seems to be the difference.
Comment 8•2 years ago
|
||
(In reply to Dan Horák from comment #2)
Just a question, can't we add
diff --git a/third_party/libwebrtc/moz.build b/third_party/libwebrtc/moz.build index 8579f8bb3622..d9ca79d4fcb8 100644 --- a/third_party/libwebrtc/moz.build +++ b/third_party/libwebrtc/moz.build @@ -520,7 +520,10 @@ if CONFIG["CPU_ARCH"] == "ppc64" and CONFIG["OS_TARGET"] == "Linux": "/third_party/libwebrtc/api/audio_codecs/isac/audio_decoder_isac_float_gn", "/third_party/libwebrtc/api/audio_codecs/isac/audio_encoder_isac_float_gn", "/third_party/libwebrtc/modules/audio_coding/isac_c_gn", - "/third_party/libwebrtc/modules/audio_coding/isac_gn" + "/third_party/libwebrtc/modules/audio_coding/isac_gn", + "/third_party/libwebrtc/modules/desktop_capture/desktop_capture_generic_gn", + "/third_party/libwebrtc/modules/desktop_capture/desktop_capture_gn", + "/third_party/libwebrtc/modules/desktop_capture/primitives_gn" ] if CONFIG["CPU_ARCH"] == "x86" and CONFIG["OS_TARGET"] == "Linux":
as a workaround until there is a proper fix? I am aware we would lose the workaround when the moz.build file will be regenerated, but it would help our CI running green even with webrtc enabled on ppc64le.
The workaround is not enough since 109.
Comment 9•2 years ago
|
||
patch should just omit this line:
"/third_party/libwebrtc/modules/desktop_capture/desktop_capture_generic_gn",
this dir no longer exists, it was merged into 'desktop_capture_gn' subdir in
https://github.com/mozilla/gecko-dev/commit/83be899015dd5582ce609f181a93f14d7e426a69
Comment 10•2 years ago
|
||
simple updated patch:
diff --git a/third_party/libwebrtc/moz.build b/third_party/libwebrtc/moz.build
index 8579f8bb3622..d9ca79d4fcb8 100644
--- a/third_party/libwebrtc/moz.build
+++ b/third_party/libwebrtc/moz.build
@@ -520,7 +520,9 @@ if CONFIG["CPU_ARCH"] == "ppc64" and CONFIG["OS_TARGET"] == "Linux":
"/third_party/libwebrtc/api/audio_codecs/isac/audio_decoder_isac_float_gn",
"/third_party/libwebrtc/api/audio_codecs/isac/audio_encoder_isac_float_gn",
"/third_party/libwebrtc/modules/audio_coding/isac_c_gn",
- "/third_party/libwebrtc/modules/audio_coding/isac_gn"
+ "/third_party/libwebrtc/modules/audio_coding/isac_gn",
+ "/third_party/libwebrtc/modules/desktop_capture/desktop_capture_gn",
+ "/third_party/libwebrtc/modules/desktop_capture/primitives_gn"
]
if CONFIG["CPU_ARCH"] == "x86" and CONFIG["OS_TARGET"] == "Linux":
Comment 11•2 years ago
•
|
||
Description
•