Commit Graph

3174 Commits

Author SHA1 Message Date
Jussi Pakkanen 469a758c32 Merge pull request #1320 from centricular/fix-llvmir-and-assembly
Fix llvmir and assembly
2017-01-23 20:42:47 +02:00
Nirbheek Chauhan 23f3cec9d0 Force installation dir options to be inside prefix
With the exception of things like sysconfdir (/etc), every other
installation directory option must be inside the prefix.

Also move the prefix checks to coredata.py since prefix can also be set
from inside project() with default_options and via mesonconf. Earlier
you could set prefix to a relative path that way.

This also allows us to return consistent values for get_option('xxxdir')
regardless of whether relative paths are passed or absolute paths are
passed while setting options on the command-line, via mesonconf, or via
default_options in project(). Now the returned path will *always* be
relative to the prefix.

Includes a unit test for this, and a failing test.

Closes #1299
2017-01-23 20:34:45 +02:00
Nirbheek Chauhan f762e896d2 mintro.py: Assume the current dir is a builddir if not specified
Also fix running with backends other than Ninja by not assuming that
install.dat is always available.
2017-01-22 22:12:44 +02:00
Nirbheek Chauhan d9c31d4a24 tests/4 qt: Force the use of -std=c++11
Qt5 now requires this, and if no -std option is passed to clang, it does
not enable C++ 11 features and we get a build failures.
2017-01-21 20:17:21 +05:30
Nirbheek Chauhan f71136b89e Print the problematic headers in these assertions 2017-01-21 20:17:21 +05:30
Nirbheek Chauhan 7b3957afbd Fix targets with generated LLVM IR and Assembly sources
These two are also C-like sources, so don't ignore them in
backends/ninjabackend.py:generate_target() when we call
is_source() on the list of generated sources for that target.

Closes #1318
2017-01-21 20:17:21 +05:30
Nirbheek Chauhan 86a0c39f4b Add test for generated assembly
We weren't testing for this and it was broken
2017-01-21 20:17:21 +05:30
Nirbheek Chauhan f934598865 Add a test for generated LLVM IR files 2017-01-20 02:10:58 +05:30
Jussi Pakkanen 577a9b40d5 Merge pull request #1312 from centricular/print-pkgdep-error-osx
Fix pkg-config error handling on OS X
2017-01-18 21:27:52 +02:00
Mike Sinkovsky 550761d97b cleanup: @staticmethod 2017-01-18 21:22:47 +02:00
Mike Sinkovsky dac8351ff1 cleanup: Unbound local variable 2017-01-18 21:22:47 +02:00
Mike Sinkovsky c9423cc3a8 cleanup: Replace assignment with augmented assignment 2017-01-18 21:22:47 +02:00
Mike Sinkovsky 969be1f679 cleanup: Remove redundant parentheses 2017-01-18 21:22:47 +02:00
Mike Sinkovsky 1d177fb127 cleanup: Unused local variables 2017-01-18 21:22:47 +02:00
Mike Sinkovsky 22eed4c417 cleanup: Redundant character escape 2017-01-18 21:22:47 +02:00
Nirbheek Chauhan 705612f7cf pkgdep: Print found message after setting cargs/libs
Fetching cflags and libs can also fail if, for instance, the pkg-config
file for a dependency needed by this package isn't found. Without this,
we will print "Found: YES" and then "Found: NO".
2017-01-17 15:39:02 +05:30
Nirbheek Chauhan 2d31851d3b Print pkg-config error when framework dep isn't found
Without this, macOS users can't figure out why a particular dependency
wasn't found because the pkg-config error message gets masked by the
fresh and useless DependencyException.
2017-01-17 15:39:01 +05:30
Nirbheek Chauhan e441a74282 Derive all exceptions correctly from base exceptions
Don't need to define __init__ and manually call the parent init. Doing
so messes up the error message you get by doing str(exception) because
it includes the current class name in it repeatedly.
2017-01-17 15:39:01 +05:30
Jussi Pakkanen 11f9425a5e Can use targets directly in test arguments. 2017-01-15 21:54:26 +02:00
Jussi Pakkanen cfc33ac421 Merge pull request #1303 from mesonbuild/buildonall
Add kwarg build_by_default
2017-01-15 21:28:10 +02:00
Jussi Pakkanen 7a28f387e2 More readable total statistics. 2017-01-15 21:27:32 +02:00
Jussi Pakkanen 21d8505825 build_by_default it is. 2017-01-15 20:14:46 +02:00
Jussi Pakkanen 72a346dacf Merge pull request #1257 from QuLogic/generator-files
Add support for Files passed to generators.
2017-01-15 20:10:05 +02:00
Nirbheek Chauhan 0bc44da702 tests/common/126: Also skip unsupported CPUs here
Related to https://github.com/mesonbuild/meson/pull/1289 and
https://github.com/mesonbuild/meson/issue/1287
2017-01-15 19:48:26 +02:00
Jussi Pakkanen 58878b998d Get rid of hasattr. 2017-01-15 19:45:23 +02:00
Jussi Pakkanen db8ad2a4bd Add test for build_on_all. 2017-01-15 19:45:23 +02:00
Jussi Pakkanen b1087f011c Moved detection of targets to build on all into own function. 2017-01-15 19:45:23 +02:00
Jussi Pakkanen 7abc7c64b0 Created base class for all targets and moved common functionality there. 2017-01-15 19:45:23 +02:00
Jussi Pakkanen 4aea0276f0 Merge pull request #1279 from trhd/master
mesontest: Improve test suite selection.
2017-01-15 19:38:28 +02:00
Hemmo Nieminen 5833bd6735 tests: Add a test for new test suite selection. 2017-01-13 00:09:52 +02:00
Hemmo Nieminen b90956c2f2 mesontest: Improve test suite selection.
Suite option can now be given to specify in more detail which tests should
be run.
2017-01-12 22:17:12 +02:00
Elliott Sales de Andrade 78b030cf19 Add support for Files passed to generators.
I need this for windows.compile_resources to be able to use
configure_file results, but it may have other benefits.
2017-01-12 03:25:08 -05:00
Mike Sinkovsky eea0670872 style: disable flake8 warnings E241, E251, E305, E401 2017-01-11 12:33:27 -05:00
Mike Sinkovsky 5b626ab4cb style: [E1**] Indentation 2017-01-11 12:33:27 -05:00
Mike Sinkovsky 0dd1e33898 style: [E251] unexpected spaces around keyword / parameter equals 2017-01-11 12:33:27 -05:00
Mike Sinkovsky ab4f7b56ce style: [E272] multiple spaces before keyword 2017-01-11 12:33:27 -05:00
Mike Sinkovsky 3adf5aed81 style: [E402] module level import not at top of file 2017-01-11 12:33:27 -05:00
Mike Sinkovsky 77515ee541 style: [E303] too many blank lines (2) 2017-01-11 12:33:27 -05:00
Mike Sinkovsky 84902cb93a style: [E301] expected 1 blank line, found 0 2017-01-11 12:33:27 -05:00
Mike Sinkovsky f9344b03a8 style: [E721] do not compare types, use 'isinstance()' 2017-01-11 12:33:27 -05:00
Mike Sinkovsky bf14cec81b style: [E712] comparison to True should be 'if cond is True:' or 'if cond:' 2017-01-11 12:33:27 -05:00
Mike Sinkovsky c8981bdd1b style: [E711] comparison to None should be 'if cond is None:' 2017-01-11 12:33:27 -05:00
Mike Sinkovsky e9a891fe25 style: [E502] the backslash is redundant between brackets 2017-01-11 12:33:27 -05:00
Jussi Pakkanen 34caf6471c Merge pull request #787 from mesonbuild/py3module
Created a Python 3 module for simpler building of Python extension mo…
2017-01-09 16:36:00 -05:00
Jussi Pakkanen 6ac9a8e738 Add .find_python() method. Supersedes #777. 2017-01-09 21:23:18 +02:00
Jussi Pakkanen fbabe8ad85 There are two different kinds of extensions: modules that create new
objects directly and snippets that just call into interpreter methods.
2017-01-09 21:11:48 +02:00
Jussi Pakkanen 24221d71cc Created a Python 3 module for simpler building of Python extension modules. 2017-01-09 21:07:23 +02:00
Jussi Pakkanen 9cf0991a1d Merge pull request #1278 from mesonbuild/newmodules
Bring some order to modules
2017-01-09 14:03:15 -05:00
Nirbheek Chauhan 747d4f2b03 We only need Ninja 1.5.x for the core code
This change helps us run on older distros such as Ubuntu LTS which is
very lazy in updating even non-core and stable packages such as Ninja.

Ninja 1.6.x is only needed for running the tests.
2017-01-09 14:03:03 -05:00
Jussi Pakkanen 340781c515 Fix Gnome module. 2017-01-09 20:04:52 +02:00