Граф коммитов

76 Коммитов

Автор SHA1 Сообщение Дата
Mike Hommey f535e6cec9 Followup for bug 1539355: Make it work for the root directory. r=me
When an added file is not under an app or addon directory, its base
directory is ''. The code added in bug 1539355 would skip doing its
thing in that case, which it shouldn't.

Also revert the workaround from bug 1525762.
2019-03-31 07:27:43 +09:00
Kris Maglione 6dbe6f1959 Bug 1525762: Part 1j - Work around XPI omni.jar packaging issues. r=bustage CLOSED TREE
We have some convoluted packaging logic to automatically package any directory
with a manifest.json file as an XPI. Unfortunately, that logic also applies to
extensions that are supposed to be part of omni.ja.

It would be nice to have a cleaner way to filter out any resources which we've
already flagged to be part of omni.ja, but this patch takes the simpler
approach of just including anything that's in a modules/ directory, which is
whitelisted for omni.ja elsewhere.

--HG--
extra : source : d30967b60a03f8f4286c26f14342d50e03a59f9d
extra : amend_source : 2ddab7bd7ce2fb666d5335bf9941328d9dd7d66f
2019-03-22 17:29:21 -07:00
Mike Hommey 2a363e7418 Bug 1539355 - Don't package addons in resource directories as XPI in OmnijarFormatter. r=nalexander
The addons manager is going to support this usecase.

Depends on D25036

Differential Revision: https://phabricator.services.mozilla.com/D25037

--HG--
extra : moz-landing-system : lando
2019-03-27 22:33:10 +00:00
Mike Hommey 33c810b43c Bug 1539355 - Force callers of *Formatter.add_base to order their bases. r=nalexander
Practically speaking, it makes no difference, as only the calls to
add_base from tests weren't already ordered.

This allows a simpler approach for next change.

Differential Revision: https://phabricator.services.mozilla.com/D25036

--HG--
extra : moz-landing-system : lando
2019-03-27 22:19:32 +00:00
Noemi Erli cfaf79673c Backed out changeset e5117d2f9311 (bug 1533051) for Android xpcshell failures CLOSED TREE 2019-03-28 01:33:00 +02:00
Nick Alexander 3dce09e76f Bug 1533051 - Package GeckoView prefs at architecture-specific paths for Android fat AAR/GeckoView multi-architecture builds. r=glandium
Bug 1533425 makes Gecko try to load from $ARCH/greprefs.js, etc on
Android.  This patch teaches the packager to put preferences into
those architecture-specific locations for that code to find.

Differential Revision: https://phabricator.services.mozilla.com/D24984

--HG--
extra : moz-landing-system : lando
2019-03-27 17:35:26 +00:00
kerlyn 0f9d749554 Bug 1523835 - Added python/mozbuild/mozpack to the flake8 linter and solved the errors, r=ahal
Before this change linting python/mozbuild brought about many errors. Some of this errors could be fixed using |mach lint --fix|. The remaining errors where fixed in this bug.

Differential Revision: https://phabricator.services.mozilla.com/D20138

--HG--
extra : rebase_source : 8bd3d622d2221b981f08b8a080c1198b002cdc49
extra : amend_source : 3f6a70c1b7104a7c2d83e11fe911942771e331ea
2019-03-01 15:36:45 -05:00
Mike Hommey 6bfaa82f51 Bug 1531634 - Change how OMNIJAR_NAME is handled for fennec builds. r=nalexander
Fennec has a value of OMNIJAR_NAME that contains a directory, contrary
to other platforms, and relies in post-packaging, pre-unpacking steps to
accommodate with the difference.

With this change, we just make the packaging and unpacking steps aware
of this setup, and make allow them to pack/unpack resources in foo/
under foo/$OMNIJAR_NAME, whether $OMNIJAR_NAME is a file name or a path.

This will, further down the road, allow the packager code to handle jar
logs from PGO instrumentation without munging them.

Differential Revision: https://phabricator.services.mozilla.com/D21654

--HG--
extra : moz-landing-system : lando
2019-03-01 21:49:47 +00:00
Mike Hommey c7022eb656 Bug 1530587 - Don't optimize jars without preloading/reordering data. r=chmanchester
Optimizing jars without preloading/reordering data only moves the
jar central directory to the beginning of the file, which, without
preloading information, is not very useful. Let's just stop doing it if
there's not going to be preloading/reordering information at all.

Differential Revision: https://phabricator.services.mozilla.com/D21170

--HG--
extra : moz-landing-system : lando
2019-02-27 01:26:46 +00:00
Mike Hommey de6692d10a Bug 1528892 - Make preprocessor output more reproducible. r=froydnj
On CI, Windows builds start from different directories on every build,
except when sccache is enabled. This affects many build types, such as
l10n repacks, and the preprocessor likes to put full paths in its
output, which means it includes those different directories, making the
builds non reproducible.

This changes the preprocessor to replace the source and object
directories with generic strings.

Differential Revision: https://phabricator.services.mozilla.com/D20421

--HG--
extra : moz-landing-system : lando
2019-02-21 05:09:52 +00:00
Harry Twyford 70df5bbf20 Bug 1313429 - Add Touch Bar functionality to Firefox r=spohl,mikedeboer,flod
Adds Touch Bar functionality to Firefox across eight commits.

Differential Revision: https://phabricator.services.mozilla.com/D5496

--HG--
extra : moz-landing-system : lando
2019-01-22 17:13:33 +00:00
Mike Hommey 8f49277c52 Bug 1496995 - Account for all dictionaries when updating built_in_addons.json during l10n repack. r=nalexander
All directories are part of the langpack that is being merged in, but
when the langpack includes the english dictionary, it is not handled
at the same time as other dictionaries, because it is also part of the
original application.

Instead of trying to catch all places where a dictionary might be added
to the final repack, we wrap the formatter so that it tracks all of them
wherever they're added from, and updates the built_in_addons.json file
accordingly.

Differential Revision: https://phabricator.services.mozilla.com/D16785

--HG--
extra : moz-landing-system : lando
2019-01-18 21:53:16 +00:00
Nick Alexander 5d4e0021b0 Bug 1418464 - Part 1: XZ compress in the packager rather than package_fennec_apk.py. r=mshal
By doing this in the packager, it makes it easier to incorporate the
strip and XZ compress logic into the local Gradle build process.

To that end, this patch makes XZ compression a little more explicit in
package-manifest.in and lifts the logic next to the existing logic for
stripping.  Since we only want to XZ compress assets/ (and not libs/),
we need a new flag.

Differential Revision: https://phabricator.services.mozilla.com/D7314

--HG--
extra : moz-landing-system : lando
2018-10-09 18:35:22 +00:00
Ciure Andrei 148577fc45 Backed out 2 changesets (bug 1418464) for test_packager.py build bustages CLOSED TREE
Backed out changeset d6794cb231e1 (bug 1418464)
Backed out changeset cc793c2d8cee (bug 1418464)
2018-10-05 22:11:05 +03:00
Nick Alexander 2f10ff4106 Bug 1418464 - Part 1: XZ compress in the packager rather than package_fennec_apk.py. r=mshal
By doing this in the packager, it makes it easier to incorporate the
strip and XZ compress logic into the local Gradle build process.

To that end, this patch makes XZ compression a little more explicit in
package-manifest.in and lifts the logic next to the existing logic for
stripping.  Since we only want to XZ compress assets/ (and not libs/),
we need a new flag.

Differential Revision: https://phabricator.services.mozilla.com/D7314

--HG--
extra : moz-landing-system : lando
2018-10-05 18:29:12 +00:00
Mike Hommey 7fa84b1acd Bug 1489340 - Handle XPT files as blobs of data in packager. r=froydnj
We don't actually ship XPT files anymore, but it's still useful for the
packager code to handle old Firefox versions. But for that, we don't
really need the complexity of "linking" XPT files in a single unit per
directory. We can just as well keep the XPT files intact, as long as we
retain individual `interfaces` manifest entries for each.

And since those entries used to be all merged into one, we now instead
group them all together in manifests (which also happens to make it
easier on unit test changes).

Differential Revision: https://phabricator.services.mozilla.com/D5221

--HG--
extra : moz-landing-system : lando
2018-09-07 22:21:07 +00:00
Kris Maglione 30986431c7 Bug 1472491: Part 5a - Add BrowserTabChild actor. r=felipe
MozReview-Commit-ID: 38Y1xwkgxCx

--HG--
extra : rebase_source : 61a85af58f9f16b8e39b716e3df2d09b788fcb1a
2018-07-29 19:42:46 -07:00
Andrew Swan 09e5e4ef55 Bug 1479599 Recognize webextensions in packager r=glandium
MozReview-Commit-ID: KethvfCTf6G

--HG--
extra : rebase_source : 48a513cf4a195fe68d729234ac487682a71ff22a
extra : source : 443493f2db03743656866d49912d26c75ae18434
2018-07-31 21:51:02 -07:00
Kris Maglione 9b633c92ac Bug 1457321: Part 4 - Update built-in add-ons manifst during l10n repack. r=ted f=pike
This is slightly ugly, but is unfortunately necessary due to do the nature of
l10n repacks. Hopefully this can go away once we move to bundling lancpack
add-ons rather than repacking in the future.

MozReview-Commit-ID: JZUblVsEbZI

--HG--
extra : rebase_source : 60c9ced2184a52f52c7f2a8820021b14b1a66abf
2018-05-08 01:04:01 -07:00
Kris Maglione e2fecdd542 Bug 1457321: Part 2 - Add dictionaries to omnijar. r=ted
MozReview-Commit-ID: 4zqD8Di7Imb

--HG--
extra : rebase_source : 2fdf8d1429ed1de6c86fc9dc880af2aadcc2b84b
2018-04-27 15:43:38 -07:00
Zibi Braniecki 634e419761 Bug 1415432 - .ftl files repackaged multiple times. r=glandium 2017-11-07 22:16:16 -08:00
Zibi Braniecki c15f333a09 Bug 1413985 - Package .ftl files on repackage for both, source and AB_CD locales. r=glandium
When repackaging, we want to take all localization resources from the source package,
and add all localization resources from the repackage target locale.

This patch makes packager.l10n scan for `localization` directories in l10n_finder and
add them.

MozReview-Commit-ID: CRLP3bOAyDx

--HG--
extra : rebase_source : 3b1bc098aaed2481a1cc06fc86d0865e654a1b6e
2017-11-02 12:10:26 -07:00
Mike Hommey 45680ab0c7 Bug 1352595 - Add basic support for brotli compression to the packager. r=gps
Bug 1355661 added support for brotli streams in "jar" files handled by
Gecko, and bug 1355671 made us build the `bro` command line utility that
allows to compress and decompress brotli streams.

This change uses the `bro` command line utility in the packager so that
it can create and handle "jar" files using brotli streams.

However, the `bro` command line utility is not available to l10n
repacks. As, at the moment, we're only hoping that the outcome of using
brotli will be good, we avoid doing all the work to make those work and
just hook things enough to enable brotli, while ensuring l10n repacks
don't break. This involves forcing some files to be deflated, and to
disable some optimizations from the packager.

Things will need to be figured out more properly if the experiment
proves brotli to be worthwhile.

--HG--
extra : rebase_source : a2e0cff67dcaed465fd441ed5d2a7de94b6351c5
2017-08-18 05:37:18 +09:00
Chung-Sheng Fu e5b80e9a8f Bug 863246 - Move resources that need to be exposed to web content to locations that are marked as contentaccessible r=billm
MozReview-Commit-ID: ArhSHKPYOr8

--HG--
extra : rebase_source : 888f7ce8f9db809ad5abbe6340af74e9dfb1d73b
2017-06-08 17:52:46 +08:00
Sebastian Hengst 2e163c99b1 Backed out changeset 1bfbae351dd7 (bug 863246) 2017-08-25 16:43:44 +02:00
Chung-Sheng Fu bb279d6d5e Bug 863246 - Move resources that need to be exposed to web content to locations that are marked as contentaccessible r=billm
MozReview-Commit-ID: ArhSHKPYOr8

--HG--
extra : rebase_source : b0cf8d159ba6bfa6e7bcd9528ae2f9851185ac30
2017-06-08 17:52:46 +08:00
Zibi Braniecki 0c7d3529d7 Bug 1333980 - Introduce L10nRegistry.jsm. r=mossop
This patch introduces a new registry for localization resources to replace
ChromeRegistry. It uses asynchronous I/O and iterators to generate
permutations of possible sources of language resources for use in the new
Localization API.

In the initial form the API handles packages resources and has API for
interacting with the AddonsManager which will report language packs.

MozReview-Commit-ID: LfERDYMROh

--HG--
extra : rebase_source : 68a664c2c59a82b4dfcae66542c315a00ddae565
2017-06-02 10:36:08 +02:00
Wes Kocher a27358fe6a Backed out changeset 3cb5dfb73fa3 (bug 1333980) for browser_all_files_referenced.js failures a=backout
MozReview-Commit-ID: 8dZ1lcv6p9V
2017-08-08 13:52:23 -07:00
Zibi Braniecki c41553945d Bug 1333980 - Introduce L10nRegistry.jsm. r=mossop
This patch introduces a new registry for localization resources to replace
ChromeRegistry. It uses asynchronous I/O and iterators to generate
permutations of possible sources of language resources for use in the new
Localization API.

In the initial form the API handles packages resources and has API for
interacting with the AddonsManager which will report language packs.

MozReview-Commit-ID: LfERDYMROh

--HG--
extra : rebase_source : a6e5b790142e5afb1ce750478190e5ad87012f8d
2017-06-02 10:36:08 +02:00
Mike Hommey 74f132e11e Bug 1365419 - Fixup l10n packager after bug 780562. r=gps
The change to l10n packager from bug 780562 worked in practice because
no chrome category had exclusively manifest entries with flags, which
we're changing in this bug.

It turns out this was only due to a missing change in the patch for bug
780562.

--HG--
extra : rebase_source : 9f782e115f97063c97f165ed95eb4beeb72f86d0
2017-05-26 11:24:40 +09:00
Wes Kocher 9782406dd8 Backed out 4 changesets (bug 1365419) for android mochitest failures in test_bug583533.html a=backout
Backed out changeset d82aa6aec2c1 (bug 1365419)
Backed out changeset 9aafdd1ca0bd (bug 1365419)
Backed out changeset 261eecf8497f (bug 1365419)
Backed out changeset 1d9b50fadc05 (bug 1365419)

MozReview-Commit-ID: HkhXf1Dkkbk
2017-06-01 18:39:21 -07:00
Mike Hommey a95e3eb0b4 Bug 1365419 - Fixup l10n packager after bug 780562. r=gps
The change to l10n packager from bug 780562 worked in practice because
no chrome category had exclusively manifest entries with flags, which
we're changing in this bug.

It turns out this was only due to a missing change in the patch for bug
780562.

--HG--
extra : rebase_source : 3c8c31c37d8fb48bb99b1758bcd8ef5f32c71fe0
2017-05-26 11:24:40 +09:00
Mike Hommey b860fe5648 Bug 1366729 - Skip manifest entries that are packaged twice. r=gps
--HG--
extra : rebase_source : 0db515433e1e5dacaf6be0c0921af060c3ad644d
2017-05-23 08:00:15 +09:00
Mike Hommey ae2d9aa982 Bug 1366729 - Properly handle "multi-content" manifest entries after bug 1366169. r=gps
Some manifest entries (e.g. skin or locale) have an attached identifier,
and there can be different entries with different identifiers for the
same chrome name. The change from bug 1366169 would consider those as
errors, while they are the expected configuration.

--HG--
extra : rebase_source : ceb08da909121a2ac0a2cdaba7970e4594dde09f
2017-05-23 07:51:22 +09:00
Chris AtLee 5fa1f81924 Bug 1351071: Get rid of pre-generated startup cache r=glandium
MozReview-Commit-ID: BcWcqEKwGBv

--HG--
extra : source : 0f320509eddb30fdefd00d17179670381c3b6f78
2017-04-04 09:26:25 -04:00
Mike Hommey d1b2f93802 Bug 1366169 - Avoid reordered manifest entries creating unexpected overrides. r=gps
As described in changeset c94e87a18096, chrome manifest entries are
reordered and don't necessarily appear in the order they have in jar.mn.

And in some cases, the order does matter: when entries with flags are
followed by entries with more broad flags or no flags at all. Nobody
should be writing entries in that order on purpose, so error out during
packaging when we detect the pattern.

--HG--
extra : rebase_source : d9617bbcbd8560503c532a13c10c8afb0fd49411
2017-05-19 15:01:58 +09:00
Mike Hommey c3680170a7 Bug 780562 - Take locale chrome manifest flags into account when repacking l10n. r=gps
--HG--
extra : rebase_source : 5185b078260f0445cfe77f0416230c9ab0781f8b
2017-05-09 14:23:55 +09:00
Carsten "Tomcat" Book b47fe0286b Backed out changeset 0f320509eddb (bug 1351071) for slowness 2017-05-09 16:58:19 +02:00
Chris AtLee b7af545070 Bug 1351071: Get rid of pre-generated startup cache r=glandium
MozReview-Commit-ID: BcWcqEKwGBv

--HG--
extra : rebase_source : 4bd21805a89359a5a2ed7ffd2ee2b76cf1e9e634
2017-04-04 09:26:25 -04:00
Mike Hommey dc5d1e6adf Bug 1335309 - Change the default for find_executables to False. r=mshal
Back when the class was written, for the packaging code, it made sense
that the default was True. But now that it's used all over the place,
and that the vast majority of uses are with find_executables=False, it
makes more sense for that to be the default.

--HG--
extra : rebase_source : ff813735fc0d53093f348f20eb77ee03e9b09d4e
2017-01-31 14:06:15 +09:00
Mike Hommey dbdbf959b8 Bug 1335309 - Add explicit find_executables arguments to every use of FileFinder. r=mshal
And make it an error not to give it. While the default is True, we do
pass a value of False wherever it makes sense, which happens to be, in
most places.

This is an intermediate step to flip the default from True to False,
ensuring that we don't unwantedly switch some calls to False.

--HG--
extra : rebase_source : 432e03f032fef378af482581685583262e5d2661
2017-01-31 13:01:34 +09:00
aleth bb41ac3b46 Bug 1311122 - Ensure missing file errors get reported despite missing base path in l10n.py. r=glandium
--HG--
extra : rebase_source : 1171410b3a6df675c3551c694748202176e42cbf
2016-10-18 21:06:36 +02:00
aleth b8af6b7271 Bug 1311136 - Improve 'multiple locales' error message in l10n.py. r=glandium
--HG--
extra : rebase_source : f46d5120f962380f989ebd115cc44c08ef858eb8
2016-10-18 21:52:19 +02:00
Mike Hommey 94ad81b0b0 Bug 1295542 - Ensure at least an empty chrome.manifest next to each omnijar file. r=gps 2016-09-20 13:43:54 +09:00
Chris Manchester 309a20b1c8 Bug 1240134 - Re-factor UnpackFinder to contain a Finder instance it delegates to rather than inheriting from FileFinder. r=glandium
MozReview-Commit-ID: LKYCROED06S
2016-08-17 15:02:31 -07:00
Chris AtLee e1b0b79d4d Bug 1275998 - L10n repacks should use the same compression settings for omni.ja as en-US r=glandium
MozReview-Commit-ID: DwuERh5MjX7

--HG--
extra : rebase_source : f447a41ebe48ab075327e0c0f8372d72976b6333
2016-05-27 08:37:09 -04:00
Mike Hommey f485401df4 Bug 1226884 - Keep em:unpack addons unpacked after bug 1216371. r=gps
--HG--
extra : amend_source : 61a2914b964df0bdf1d523e7eb396b54403daa9f
2015-11-23 22:40:00 +01:00
Mike Hommey b6d285f055 Bug 1216371 - Pack addons that can be packed as XPIs. r=gps 2015-11-19 08:05:51 +09:00
Mike Hommey 3657509c31 Bug 1216371 - Distinguish between addons that can be packed and those that cannot in the packager. r=gps 2015-11-19 08:05:51 +09:00
Mike Hommey 01f29630c8 Bug 1216371 - Use the PiecemealFormatter for the OmniJarFormatter. r=gps 2015-11-19 08:05:51 +09:00