diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2018-05-16 01:00:59 +0300 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2018-06-18 22:02:56 +0300 |
commit | 6cf79f86ee0d966e3b42b8fd74871a5b1bc9fc97 (patch) | |
tree | be64eb856b50ab9a6e2d2b678037f5e42d7f7991 /mesonbuild/mesonmain.py | |
parent | 551f99ffffdb00aa8d45a97823446f83b797dbe9 (diff) | |
download | meson-6cf79f86ee0d966e3b42b8fd74871a5b1bc9fc97.zip meson-6cf79f86ee0d966e3b42b8fd74871a5b1bc9fc97.tar.gz meson-6cf79f86ee0d966e3b42b8fd74871a5b1bc9fc97.tar.bz2 |
Made install a top level Meson command.
Diffstat (limited to 'mesonbuild/mesonmain.py')
-rw-r--r-- | mesonbuild/mesonmain.py | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/mesonbuild/mesonmain.py b/mesonbuild/mesonmain.py index e74fb36..c9acf25 100644 --- a/mesonbuild/mesonmain.py +++ b/mesonbuild/mesonmain.py @@ -20,7 +20,6 @@ import cProfile as profile from . import environment, interpreter, mesonlib from . import build -from . import mconf, mintro, mtest, rewriter, minit from . import mlog, coredata from .mesonlib import MesonException from .environment import detect_msys2_arch @@ -178,9 +177,6 @@ def run_script_command(args): elif cmdname == 'cleantrees': import mesonbuild.scripts.cleantrees as abc cmdfunc = abc.run - elif cmdname == 'install': - import mesonbuild.scripts.meson_install as abc - cmdfunc = abc.run elif cmdname == 'commandrunner': import mesonbuild.scripts.commandrunner as abc cmdfunc = abc.run @@ -270,23 +266,32 @@ def run(original_args, mainfile): args = remaining_args cmd_name = args[0] if cmd_name == 'test': + from . import mtest return mtest.run(remaining_args) elif cmd_name == 'setup': args = remaining_args # FALLTHROUGH like it's 1972. + elif cmd_name == 'install': + from . import minstall + return minstall.run(remaining_args) elif cmd_name == 'introspect': + from . import mintro return mintro.run(remaining_args) elif cmd_name == 'rewrite': + from . import rewriter return rewriter.run(remaining_args) elif cmd_name == 'configure': try: + from . import mconf return mconf.run(remaining_args) except MesonException as e: mlog.exception(e) sys.exit(1) elif cmd_name == 'wrap': + from .wrap import wraptool return wraptool.run(remaining_args) elif cmd_name == 'init': + from . import minit return minit.run(remaining_args) elif cmd_name == 'runpython': import runpy |