Previously, the set of WebIDL example interfaces to build was hardcoded
in the mozwebidlcodegen Python package. Unfortunately, the example
interfaces in that set were dependent on test-only bindings files,
resulting in build failures when tests were disabled (because those
test-only bindings were defined in a test directory).
In this patch, we now declare example interfaces in moz.build files
so the set of example interfaces lives next to the set of defined
bindings files. The example interfaces are defined in a test moz.build
file - in the same file declaring the bindings files that contain the
interfaces - so the example interfaces only get picked up if the
corresponding bindings are defined.
We could probably switch WebIDL moz.build variables to use lists with
flags. That would be good followup fodder. For now, let's fix the build.
--HG--
extra : rebase_source : 00070a6d560625bc84ab9b10d6848ea037f8f5ed
extra : amend_source : 0890ecef444ba58533fcfaa333773d78deafd7f3
WebIDL build system integration has been rewritten from the ground up.
Changes:
* GlobalGen.py, BindingGen.py, and ExampleGen.py have been removed in
favor of mozwebidl.py.
* Static .webidl files are now processed directly in their original location
and aren't copied to the object directory.
* Generated events <stem>.cpp files are now compiled into the unified
sources. Previously, only the <stem>Binding.cpp files were compiled
into unified sources.
* Exported .h files are now generated directly into their final location.
Previously, they were generated into the local directory then
installed in their final location.
* The list of globalgen-generated files now lives in Python and isn't
duplicated in 3 places.
* The make dependencies are much simpler as a result of using a single
command to perform all code generation. The auto-generated .pp file from
code generation sets up all dependencies necessary to reinvoke code
generation and Python takes care of dependency management.
--HG--
extra : rebase_source : e4918878274b22a412329c7cb18cc7138daf5dc6
WebIDL build system integration has been rewritten from the ground up.
Changes:
* GlobalGen.py, BindingGen.py, and ExampleGen.py have been removed in
favor of mozwebidl.py.
* Static .webidl files are now processed directly in their original location
and aren't copied to the object directory.
* Generated events <stem>.cpp files are now compiled into the unified
sources. Previously, only the <stem>Binding.cpp files were compiled
into unified sources.
* Exported .h files are now generated directly into their final location.
Previously, they were generated into the local directory then
installed in their final location.
* The list of globalgen-generated files now lives in Python and isn't
duplicated in 3 places.
* The make dependencies are much simpler as a result of using a single
command to perform all code generation. The auto-generated .pp file from
code generation sets up all dependencies necessary to reinvoke code
generation and Python takes care of dependency management.
--HG--
extra : rebase_source : bde37d7aab3bd224ca8611f3ba4aaf6311e2faab
The major changes are as follows:
1) The new algorithm no longer adjusts "argcount" based on the
interaction of trailing undefined and [TreatUndefinedAs=Missing]
arguments. We never implemented this; just asserted that we didn't
have to deal with this situation.
2) If the distinguishing argument is undefined and there is an
overload that has an optional argument at the distinguishing
argument index, that overload is selected.
The major changes are as follows:
1) The new algorithm no longer adjusts "argcount" based on the
interaction of trailing undefined and [TreatUndefinedAs=Missing]
arguments. We never implemented this; just asserted that we didn't
have to deal with this situation.
2) If the distinguishing argument is undefined and there is an
overload that has an optional argument at the distinguishing
argument index, that overload is selected.