diff --git a/install_meson.py b/install_meson.py index 187ca414e..8a2c48da5 100755 --- a/install_meson.py +++ b/install_meson.py @@ -42,7 +42,10 @@ if options.prefix[0] != '/': print('Error, prefix must be an absolute path.') sys.exit(1) -install_root = os.path.join(options.destdir, options.prefix[1:]) +if options.destdir == '': + install_root = options.prefix +else: + install_root = os.path.join(options.destdir, options.prefix[1:]) script_dir = os.path.join(install_root, 'share/meson-' + version) bin_dir = os.path.join(install_root, 'bin') diff --git a/readme.txt b/readme.txt index f7c0ae54e..ec563ca32 100644 --- a/readme.txt +++ b/readme.txt @@ -4,6 +4,18 @@ system. Dependencies: Python3 and Python-Ply +Installing from source + +You can run Meson directly from a revision control checkout. +Installing it system-wide is simple. + +Configure step: None +Compile step: ./compile_meson.py +Install step: [sudo] ./install_meson.py --prefix /your/prefix --destdir /destdir/path + +The default value of prefix is /usr/local. The default value of destdir +is empty. + Running: Meson requires that you have a source directory and a build directory @@ -19,5 +31,6 @@ can do things like this: cd source_root; mkdir build; cd build; meson.py .. cd source_root; mkdir build; meson.py build + For questions contact the mailing list at https://lists.sourceforge.net/lists/listinfo/meson-devel