summaryrefslogtreecommitdiff
path: root/mesonbuild/scripts
Commit message (Collapse)AuthorAgeFilesLines
* gtkdoc: Pass the linker down to gtkdoc-scangobjXavier Claessens2017-11-071-1/+2
| | | | Closes #2540
* MSI: Fix regenerate with visual studioNiklas Claesson2017-10-191-3/+5
| | | | Fixes #2461
* Create the .po file with the `update_po` subcommand if it doesn't existCorentin Noël2017-10-071-1/+4
|
* Made man page gzip creation deterministic. Closes #2363.Jussi Pakkanen2017-09-231-1/+3
|
* Merge pull request #2216 from ebassi/yelp-linguasJussi Pakkanen2017-09-141-0/+4
|\ | | | | Support LINGUAS for gnome.yelp() languages
| * Re-use gettext.read_linguas in yelphelperEmmanuele Bassi2017-08-181-16/+1
| |
| * Support LINGUAS for gnome.yelp() languagesEmmanuele Bassi2017-08-181-0/+19
| | | | | | | | | | | | | | | | | | Listing all languages inside meson.build for the Yelp-based manual localisation is error-prone, and it also requires parsing and modifying Meson files from external tools. Just like we do for i18n, we can use an ancillary `LINGUAS` file in the help source sub-directory to list all the help languages.
* | install: Also ignore PermissionError for selinuxNirbheek Chauhan2017-09-041-1/+1
| | | | | | | | | | | | | | When the user does not have permissions to run `selinuxenabled`, a PermissionError is raised instead of FileNotFoundError. Closes https://github.com/mesonbuild/meson/issues/2257
* | Remove leftover debug print statement in meson_install.pyGabríel Arthúr Pétursson2017-08-201-1/+1
| |
* | Make all functionality invokable via the main Meson binary,Jussi Pakkanen2017-08-182-8/+18
|/ | | | which can be a Windows .exe file.
* Exclude system sources from test coverageStefan Sonski2017-08-111-0/+1
| | | Exclude /usr/src/ from code coverage, this is included for e.g. gtest/gmock.
* Allow excluding files from `install_subdir`Elliott Sales de Andrade2017-08-061-5/+15
| | | | | | The install_subdir command now accepts a new `exclude` keyword argument that allows specified files to be excluded from the installed subdirectory.
* Remove directories created by ninja installPeter Hutterer2017-08-012-17/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce a DirMaker class that disassembles the path up to '/' and stores all directories in a list. That list is in creation order and pre-existing directories are ignored, i.e. creating the two paths '/usr/share/foo/bar/baz' and '/usr/share/foo/bar/boo' is stored as [ '/usr/share/foo', '/usr/share/foo/bar', '/usr/share/foo/bar/baz', '/usr/share/foo/bar/boo' ] This is on the assumption that /usr/share already existed. After all files have been installed, the list of created directories is appended in reverse order to the install log. The uninstall script then triggers rmdir on all directories. If a custom install script drops files into the directories, removing those will fail. This matches the current expectation, see the existing warning "Remember that files created by custom scripts have not been removed." Unfortunately, this makes the behavior on uninstall inconsistent. Assuming a non-existing prefix, ninja install && ninja uninstall removes all traces of the install. However, ninja install && ninja install && ninja uninstall removes the files only, not the directories as they already existed. This could be fixed by just unconditionally removing any (emtpy) directories that we drop files into, at the risk of removing system directories if empty. For example, one could imagine /etc/foo.conf.d/ to be removed in that case if it is empty. https://github.com/mesonbuild/meson/issues/2032
* meson_install: rename 'data' to 'd' for consistencyPeter Hutterer2017-08-011-3/+3
| | | | All other functions call it 'd', let's do it here too
* install: restore the SELinux context on installPeter Hutterer2017-07-311-0/+24
| | | | | | | | | | Try to restore the context for SELinux. If we fail on running 'selinuxenabled', quietly ignore the error and continue. If we fail on the actual restorecon call, we print a message but disable SELinux - chances are high that if one restorecon fails, others will too and that's likely a system setup issue. Fixes #1967
* Close files reliably.Jussi Pakkanen2017-07-181-0/+5
|
* gnome.gtkdoc: Handle absolute install_dirs correctlyNirbheek Chauhan2017-07-171-3/+5
| | | | | Must prepend DESTDIR in case it's absolute. Also document that by default it is relative to the gtk-doc html directory.
* Return explicit 0 as it is used in a sys.exit statement (just like every ↵Jussi Pakkanen2017-07-161-0/+1
| | | | other run function).
* Use sys.exit rather than plain exit.Jussi Pakkanen2017-07-161-1/+1
|
* Merge pull request #1920 from QuLogic/hg-distJussi Pakkanen2017-06-211-7/+29
|\ | | | | Add Mercurial dist support
| * Add Mercurial dist support.Elliott Sales de Andrade2017-06-131-4/+25
| |
| * Remove extraneous os.path.split()s.Elliott Sales de Andrade2017-06-131-3/+4
| | | | | | | | | | Since only one part is needed, they can be replaced by dirname, basename, or the originally joined file name.
* | gnome.yelp(): Handle file existing on symlinkPatrick Griffis2017-06-091-1/+5
| | | | | | | | Fixes #1921
* | gnome.yelp(): Handle platforms where symlink not supportedPatrick Griffis2017-06-091-2/+5
| |
* | gnome.yelp(): Make copies of media files when symlink is falsePatrick Griffis2017-06-091-1/+5
|/
* Merge pull request #1866 from ebassi/mkdb-argsJussi Pakkanen2017-06-071-1/+10
|\ | | | | Add mkdb_args support to gnome.gtkdoc()
| * Add mkdb_args support to gnome.gtkdoc()Emmanuele Bassi2017-05-281-1/+10
| | | | | | | | | | | | | | There are cases where we need to specify arguments to gtkdoc-mkdb, like telling it to scan extensions that are not '.h' and '.c'. Let's add a new named argument to gnome.gtkdoc(), as well as the plumbing needed for the gtk-doc helper script.
* | Allow empty extra arguments in gettext scriptRene Lopez2017-06-031-1/+1
| |
* | Whitespace tweaks to reduce Flake8 warningsAlistair Thomas2017-05-292-3/+3
|/
* Create helper function for a rmtree that works reliably on Windows.Jussi Pakkanen2017-05-211-1/+2
|
* Delete the correct directory in dist check.Elliott Sales de Andrade2017-05-171-1/+1
|
* Remove dead code paths.Elliott Sales de Andrade2017-05-171-2/+1
|
* Remove unused variables.Elliott Sales de Andrade2017-05-172-4/+4
|
* Remove unused imports.Elliott Sales de Andrade2017-05-171-2/+1
|
* Strip system directories and show coverage for files not executed at all. ↵Jussi Pakkanen2017-05-131-19/+37
| | | | Closes #1721.
* Moved coverage commands to a standalone script.Jussi Pakkanen2017-05-131-0/+61
|
* Add test and release notes.Jussi Pakkanen2017-05-121-1/+1
|
* Initialise submodules.Jussi Pakkanen2017-05-111-15/+37
|
* Test created tarball by doing a full build + test + install cycle.Jussi Pakkanen2017-05-111-22/+63
|
* Created a dist target. Closes #877.Jussi Pakkanen2017-05-111-0/+85
|
* Use American English: behaviour -> behaviorPeter Hutterer2017-05-041-1/+1
|
* Merge pull request #1587 from mesonbuild/tingping/msgfmt-datadirJussi Pakkanen2017-05-031-0/+35
|\ | | | | i18n: Improve data_dirs support
| * i18n: Add data_dirs kwarg to merge_file()Patrick Griffis2017-04-291-0/+35
| | | | | | | | | | | | For parity with gettext() Fixes #1565
* | Don't use len() to test emptiness vs not emptinessDylan Baker2017-05-022-2/+2
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Meson has a common pattern of using 'if len(foo) == 0:' or 'if len(foo) != 0:', however, this is a common anti-pattern in python. Instead tests for emptiness/non-emptiness should be done with a simple 'if foo:' or 'if not foo:' Consider the following: >>> import timeit >>> timeit.timeit('if len([]) == 0: pass') 0.10730923599840025 >>> timeit.timeit('if not []: pass') 0.030033907998586074 >>> timeit.timeit('if len(['a', 'b', 'c', 'd']) == 0: pass') 0.1154778649979562 >>> timeit.timeit("if not ['a', 'b', 'c', 'd']: pass") 0.08259823200205574 >>> timeit.timeit('if len("") == 0: pass') 0.089759664999292 >>> timeit.timeit('if not "": pass') 0.02340641999762738 >>> timeit.timeit('if len("foo") == 0: pass') 0.08848102600313723 >>> timeit.timeit('if not "foo": pass') 0.04032287199879647 And for the one additional case of 'if len(foo.strip()) == 0', which can be replaced with 'if not foo.isspace()' >>> timeit.timeit('if len(" ".strip()) == 0: pass') 0.15294511600222904 >>> timeit.timeit('if " ".isspace(): pass') 0.09413968399894657 >>> timeit.timeit('if len(" abc".strip()) == 0: pass') 0.2023209120015963 >>> timeit.timeit('if " abc".isspace(): pass') 0.09571301700270851 In other words, it's always a win to not use len(), when you don't actually want to check the length.
* Drop terminating fullstop from "Installing blah to blah" messagesPeter Hutterer2017-04-193-7/+7
| | | | | | | | Grammatically, this full stop isn't needed and with file names it has a potential to be confusing: Installing /foo/bar/filename.1 to /foo/bar/dirname. The full stop caused me to do a double-take more than once, so let's drop it.
* Do not obliterate old rpath because it might be used due to read only data ↵Jussi Pakkanen2017-04-171-3/+12
| | | | sharing. Closes #1619.
* gtkdochelper: Fix type file name optionRafael Fontenelle2017-04-131-1/+1
| | | | 'gtkdoc-scangobj' script was recently ported to Python (it was Perl), and it now requires providing '--type' option to specify the name of the file to store the types in. Without this option, 'gtkdockelper' will exit with error status 2 and will throw a message "gtkdoc-scangobj: error: unrecognized arguments: <typefile>"
* Merge pull request #1518 from centricular/mesonintrospect-evarJussi Pakkanen2017-04-082-6/+7
|\ | | | | Export MESONINTROSPECT to postconf/install/run_command scripts
| * Export MESONINTROSPECT to postconf/install/run_command scriptsNirbheek Chauhan2017-03-282-6/+7
| | | | | | | | | | | | | | | | | | Points to the `mesonintrospect.py` script corresponding to the currently-running version of Meson. Includes a test for all three methods of running scripts/commands. Closes https://github.com/mesonbuild/meson/issues/1385
* | Ignore install as non-existent user or groupJon Turney2017-04-061-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | 'test cases/common/12 data' and 'test cases/common/66 install subdir' both try to install something as 'root'. This user doesn't exist on Cygwin. Perhaps we should automatically convert this to some other user, but it's not clear which. For real projects, it's possibly better for the meson.build to explicitly handle this... 'test cases/common/12 data' also tries to install something with GID 0. There's no guarantee this group exists.