Commit Graph

7 Commits

Author SHA1 Message Date
Mike Hommey
ce18ecc89e Bug 1289949 - Make mozpack.path properly handle paths on mingw python. r=gps
Mingw python has a different os.path setup from native python, and has
os.sep and os.altsep reversed. In that case, the normsep function was
doing the wrong thing, leading to all sorts of problems.

While fixing this, also ensure the corresponding unit test covers this
peculiarity, even when running under the native win32 python.
2016-07-28 18:50:57 +09:00
Mike Hommey
e5b6878f4b Bug 1253203 - Use mozpath functions for sandboxed os.path in configure.py. r=nalexander,r=chmanchester
Generally speaking, the configuration needs forward-slashes in paths.
We might as well make it hard(er) to set configuration items with
backslash separators on Windows by exposing mozpath.* functions in place
of os.path functions. The downside is that functions explicitly
importing os will still get the real os.path functions.
2016-03-08 15:41:32 +09:00
Gregory Szorc
9865b6f0c9 Bug 1176642 - Use absolute_import in mozpack; r=glandium 2015-06-25 12:13:55 -07:00
Gregory Szorc
6e66aefeb5 Bug 1134800 - Properly cache file matching patterns; r=glandium
The regular expression cache for mozpack.path.match was keyed off the
original pattern. However, that variable was mutated as part of the
function and the mutated result was subsequently stored as the cache
key. This effectively resulted in a 0% cache hit rate.

On some tests being written for bug 1132111 which involve a full
filesystem traversal for moz.build files and subsequent execution of
those files, the following timings are indicative of the impact of this
patch.

Before:
real 16.082s
user 14.760s
sys   1.318s

After:
real 6.345s
user 5.085s
sys  1.257s
2015-02-24 10:19:41 -08:00
Mike Hommey
acfa733d9c Bug 948275 - Use mozpack.path instead of os.path in mozbuild.frontend and mozbuild.backend modules. r=gps 2013-12-11 15:20:31 +09:00
Mike Hommey
92820ad3ba Bug 893976 - Use (cached) regular expressions for mozpack.path.match. r=gps 2013-07-30 08:57:27 +09:00
Mike Hommey
fc89f708a6 Bug 780561 - Import new packager code. r=gps 2013-01-23 11:23:14 +01:00