1
0
mirror of https://https.git.savannah.gnu.org/git/gnulib.git synced 2026-08-26 19:46:51 +00:00

43 Commits

Author SHA1 Message Date
Dmitry Selyutin 679e16886f vfs: multiple overrides in lookup routine 2018-07-05 22:27:09 +03:00
Dmitry Selyutin 99b64e290d vfs: normalize file path after concatenation 2018-06-30 16:30:26 +03:00
Dmitry Selyutin 97a2a07e5f vfs: simplify some code parts 2018-06-30 16:30:02 +03:00
Dmitry Selyutin c0e63bb2f2 vfs: deprecate unused "backup" parameter 2018-06-29 01:44:29 +03:00
Dmitry Selyutin 28a06d2ff9 remove debugging leftovers 2018-06-28 00:55:04 +03:00
Dmitry Selyutin fdd742b223 minor code cleanup 2018-02-10 19:01:32 +03:00
Dmitry Selyutin ecea1586e6 simplify properties; improve performance 2018-02-04 13:13:13 +03:00
Dmitry Selyutin cee75f5910 refactored generators; bugfix; tests Makefile.am 2018-01-29 19:08:46 +03:00
Dmitry Selyutin 5b8fc9cba4 read-only modules; module cache; various fixes
Since gnulib-tool does not modify modules, it is OK to initialize each
module only once. Moreover, since most of the time is spent upon
executing transitive closures and each transitive closure stores all
modules into different lists, it is also a good idea to calculate the
hash only once for read-only modules. These simple additions make
gnulib-tool much faster than before, since each module is initialized
only once-per-run and has a constant hash value.

For example, an invocation of pygnulib.py inside wget2 takes about 0.5
seconds until it completes gnulib-comp.m4 generation; previously it used
to take up to 8 seconds. Needless to say that performing the same task
is much slower when using the good old gnulib-tool: in my experiments
it takes about a minute to complete gnulib-comp.m4 generation.

Some of the TransitiveClosure methods considered useful enough to be
also present as a part of Database class. The refactoring also revealed
that conditional modules computation was implemented incorrectly; this
code was fixed. Moreover, this part of functionality was moved into the
__init__ section, which also saves several milliseconds since it is not
necessary to check whether conditional modules table exists upon each
conditional() invocation.
2018-01-13 18:42:02 +03:00
Dmitry Selyutin 962ee91a49 dummy singleton; update module hash and properties 2018-01-11 22:17:31 +03:00
Dmitry Selyutin 23f7be63fd generic cleanup; bug fixes; gnulib-comp generator
In order to implement correct gnulib-comp.m4 generation, the whole
conditional dependencies calculation algorithm had to be rewritten.
This patch fixes transitive closure algorithm so that it handles all
conditions correctly. Most of the transitive closure functionality was
separated into a standalone TransitiveClosure class to provide a fast
access to transitive closure results (thus incorporating almost all
functionality of the pygnulib.module.Database class).

The transitive closure is usually performed twice: the base one checks
dependencies for the base set of modules, while the full one also takes
the corresponding tests into account. A standalone Database class was
created to perform both closures in one shot and provide an easy access
to all required module and file lists. This allowed to incorporate some
code from the main script: dummy module handling, libtests.a presense,
module and file lists processing.

Yet another small change is that there is a special DummyModule object,
representing the well-known gnulib dummy module. It was created since
the original gnulib dummy module is unlikely to change quite often, so
it acts like special placeholder value.

Finally the naming convention was changed to longer names again.
2018-01-07 23:55:40 +03:00
Dmitry Selyutin ff3a5a6407 miscellaneousfixes; po files and gnulib-cache generation 2017-12-17 23:14:19 +03:00
Dmitry Selyutin 3a4c6e77de vfs: eliminate weird pylint warning 2017-12-12 00:58:08 +03:00
Dmitry Selyutin a8ce88e46c vfs: use absolute paths during backup 2017-12-02 00:45:06 +03:00
Dmitry Selyutin d5b1e7c3a2 vfs: relative/absolute paths; relative symlinks 2017-12-02 00:42:08 +03:00
Dmitry Selyutin 31e219f6b3 support multiple override directories 2017-12-01 10:26:13 +03:00
Dmitry Selyutin b05a55bb4c vfs: standalone filesystem functions 2017-11-30 22:52:30 +03:00
Dmitry Selyutin b67345cb1e vfs: base VFS __enter__ and __exit__ methods 2017-10-22 23:46:08 +03:00
Dmitry Selyutin b654caf3d7 vfs: lookup: freestanding again; return VFS 2017-10-22 23:27:28 +03:00
Dmitry Selyutin 8464a64618 style: prefer using a single underscore 2017-10-22 23:13:50 +03:00
Dmitry Selyutin 84f24363ea vfs: basic file operations 2017-10-22 22:30:14 +03:00
Dmitry Selyutin 71dfa2d20a vfs: __contains__ is a part of base VFS 2017-10-22 22:30:14 +03:00
Dmitry Selyutin 265262a81a vfs: base and full prefix separation 2017-10-22 22:30:00 +03:00
Dmitry Selyutin 000d698bad vfs: implement Project.mkdir method 2017-10-22 12:18:36 +03:00
Dmitry Selyutin 88fb191a9b vfs: return path/state upon lookup 2017-10-20 23:03:09 +03:00
Dmitry Selyutin 5def4d9860 vfs: remove backup indirection layer 2017-10-20 22:46:49 +03:00
Dmitry Selyutin 1969829ed7 vfs: make patch path a property 2017-10-20 22:46:49 +03:00
Dmitry Selyutin 823cfa7b2e vfs: split base class into base and project 2017-10-20 17:05:21 +03:00
Dmitry Selyutin 6c75197032 vfs: (stream, path) instead of (path, type) 2017-10-20 10:09:58 +03:00
Dmitry Selyutin 5bcdffc914 vfs: fix copy-paste bug 2017-10-20 10:03:06 +03:00
Dmitry Selyutin 24804b00a7 vfs: per-instance patch binary path 2017-10-20 09:58:06 +03:00
Dmitry Selyutin 5e72758dd3 vfs: integrate file operations into the base VFS 2017-10-19 10:10:13 +03:00
Dmitry Selyutin 7c895486be vfs: remove strange doc string 2017-10-18 10:51:02 +03:00
Dmitry Selyutin 5f222e0611 vfs: normalize paths 2017-10-18 00:09:46 +03:00
Dmitry Selyutin 123294a46e vfs: rename 'kwargs' argument to 'table' 2017-10-17 23:51:25 +03:00
Dmitry Selyutin 66c7c364cb vfs: simplify code; pure virtual operations 2017-10-17 22:26:03 +03:00
Dmitry Selyutin ae7e0bbcf3 vfs: remove unused variable inside base VFS 2017-10-08 22:08:56 +03:00
Dmitry Selyutin 10cb473447 vfs: simplify table handling 2017-10-08 18:52:52 +03:00
Dmitry Selyutin eadaafc691 vfs: use "root" argument instead of "gnulib" 2017-10-05 10:03:21 +03:00
Dmitry Selyutin 58e5a446b1 vfs: discard config module dependency 2017-10-05 10:03:21 +03:00
Dmitry Selyutin 3beaafa3bc vfs: implement lookup function 2017-10-05 10:03:21 +03:00
Dmitry Selyutin 5e78c4ae4c vfs: do not raise error on non-existent files 2017-10-05 10:03:21 +03:00
Dmitry Selyutin e3d2c38fe3 vfs: rename filesystem to vfs 2017-10-05 10:03:21 +03:00