summaryrefslogtreecommitdiff
path: root/mesonbuild/backend/backends.py
Commit message (Collapse)AuthorAgeFilesLines
...
* style: [E502] the backslash is redundant between bracketsMike Sinkovsky2017-01-111-4/+4
|
* Merge pull request #1263 from centricular/meson_exe_deterministicJussi Pakkanen2017-01-021-3/+8
|\ | | | | serialise_executable: Name the data file deterministically
| * serialise_executable: Name the data file deterministicallyNirbheek Chauhan2016-12-311-3/+8
| | | | | | | | Closes #1062
* | style: fix E124 violationsIgor Gnatenko2017-01-011-2/+2
| | | | | | | | | | | | E124: closing bracket does not match visual indentation Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
* | style: fix E225 violationsIgor Gnatenko2017-01-011-1/+1
|/ | | | | | E225: missing whitespace around operator Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
* Fix space before :.Jussi Pakkanen2016-12-311-2/+2
|
* Do not automatically set warning flags if buildtype is 'plain'Matthias Klumpp2016-12-231-1/+1
|
* ldc: Protect linker flags from deduplicationMatthias Klumpp2016-12-211-1/+1
| | | | | This is the better way to pass arguments through to the linker when compiling D code with LDC.
* Merge pull request #1233 from mesonbuild/wip/ignatenko/code-styleJussi Pakkanen2016-12-211-3/+1
|\ | | | | Trivial cleanups in code
| * tree-wide: remove blank lines at EOFIgor Gnatenko2016-12-191-1/+0
| | | | | | | | Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
| * tree-wide: remove trailing whitespacesIgor Gnatenko2016-12-191-2/+2
| | | | | | | | Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
| * tree-wide: remove unused variablesIgor Gnatenko2016-12-191-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ./mesonbuild/scripts/regen_checker.py:35:5: F841 local variable 'scriptdir' is assigned to but never used scriptdir = os.path.split(__file__)[0] ^ ./mesonbuild/scripts/yelphelper.py:84:13: F841 local variable 'symfile' is assigned to but never used symfile = os.path.join(install_dir, m) ^ ./mesonbuild/backend/backends.py:164:13: F841 local variable 'lang' is assigned to but never used lang = comp.get_language() ^ ./mesonbuild/backend/ninjabackend.py:1286:9: F841 local variable 'scriptdir' is assigned to but never used scriptdir = self.environment.get_script_dir() ^ ./mesonbuild/backend/vs2010backend.py:736:9: F841 local variable 'additional_options_set' is assigned to but never used additional_options_set = True ^ Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
* | Merge pull request #1227 from centricular/ninja-clean-recursive-dir-deleteJussi Pakkanen2016-12-201-0/+9
|\ \ | | | | | | run_project_tests.py: Also do ninja clean on tests
| * | Use a script to clean-up custom-target output dirsNirbheek Chauhan2016-12-191-0/+9
| |/ | | | | | | | | | | | | | | | | The script will manually delete all custom_target outputs that are directories instead of files. This is needed because on platforms other than Windows, Ninja only deletes directories while cleaning if they are empty. Closes #1220
* | Cache the scripts used for postconf and install phasesNirbheek Chauhan2016-12-201-1/+1
|/ | | | | | | | | | | Cache the absolute dir that the script is searched in and the name of the script. These are the only two things that change. Update the test to test for both #1235 and the case when a script of the same name is in a different directory (which also covers the subproject case). Closes #1235
* fix some of pylint's undefined-variableIgor Gnatenko2016-12-191-0/+1
| | | | | | | | | | | | | | | | | ************* Module mesonbuild.modules.rpm E:106,29: Unsupported format character '{' (0x7b) at index 16 (bad-format-character) ************* Module mesonbuild.modules E: 12,14: Undefined variable 'MesonException' (undefined-variable) ************* Module mesonbuild.modules.gnome E:699,69: Undefined variable 'sargs' (undefined-variable) ************* Module mesonbuild.wrap.wrap E:103,25: Undefined variable 'checkoutdir' (undefined-variable) ************* Module mesonbuild.backend.backends E: 83,16: Undefined variable 'mlog' (undefined-variable) ************* Module mesonbuild.backend.ninjabackend E:254,105: Undefined variable 't' (undefined-variable) Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
* gnome.mkenums: Use absolute paths for all commandline argsNirbheek Chauhan2016-12-151-9/+10
| | | | | | Closes #973 test cases/vala/8 generated sources/ tests this.
* Pass --gresources to valac for each compiled gresourceNirbheek Chauhan2016-12-151-13/+22
| | | | | | | | Without this, the user has to both compile the resource with gnome.compile_resources, pass that to the target sources, and also pass --gresources=/path/to/gres.xml to vala_args in the target. With this, we will do that automatically.
* Query the target itself for the dynamic linkerNirbheek Chauhan2016-12-131-28/+10
| | | | | | | | | This greatly improves the logic for determining the linker. Previously, we would completely break if a target contained only extracted objects and we were using more than one compiler in our project. This also fixes determination of the linker if our target only contains generated objc++ sources, and other funky combinations.
* Also use objects to populate target compilersNirbheek Chauhan2016-12-131-0/+2
| | | | | | | | | This avoids us having no compilers at all for targets that are composed entirely of objects with no sources. Now we will always have a compiler for a target even if it is composed entirely of objects generated with custom targets unless it has completely unknown sources.
* Only check for unity compat when doing unity buildsNirbheek Chauhan2016-11-241-6/+2
| | | | | | | Also don't bother setting self.unity_compatible since it will never be checked. Closes #1097
* Removed Valgrind from core.Jussi Pakkanen2016-11-181-3/+2
|
* Add new add_project_[link]_args functionsThibault Saunier2016-11-121-0/+1
| | | | Fixes 979
* Fix regex used in custom target evaluationNirbheek Chauhan2016-11-121-2/+8
| | | | | | | | | Instead of using a whitelist, use a blacklist. Also print a more useful error if the regex fails to match. Use an underscore in the gir test to trigger this. Fixes #436
* vala: Fix compiled object extractionNirbheek Chauhan2016-11-121-0/+3
| | | | Fixes #791
* backends: Output depfiles in same directory as targetPatrick Griffis2016-11-091-4/+1
|
* custom_target: Substitute @OUTPUT@ and @INPUT properlyNirbheek Chauhan2016-11-091-26/+43
| | | | | | | They weren't being substituted if they were a part of a command argument, ala --output=@OUTPUT@, etc. Closes https://github.com/mesonbuild/meson/issues/824
* Implement mlog.warning and use it everywhere for warningsNirbheek Chauhan2016-11-081-2/+2
| | | | | | Prepends the string with 'WARNING:' in ANSI yellow. Closes https://github.com/mesonbuild/meson/issues/961
* Use a cross linker when cross compiling.Jussi Pakkanen2016-11-061-5/+9
|
* Allow running native executable in cross buildMark Schulte2016-10-271-1/+5
| | | | | | Make so both executable() targets that are marked as native and external programs (which are usually build tools compiled for the host machine) are not supposed to be run with the exe wrapper.
* Add support for extracting objects in unity buildsNirbheek Chauhan2016-10-211-44/+37
| | | | | | | | | | Not only does extract_all_objects() now work properly again, extract_objects() also works if you specify a subset of sources all of which have been compiled into a single unified object. So, for instance, this allows you to extract all the objects corresponding to the C sources compiled into a target consisting of C and C++ sources.
* Print a useful error when unable to determine linkerNirbheek Chauhan2016-10-211-1/+1
|
* Ninja: Consolidate generated sources handlingNirbheek Chauhan2016-10-191-0/+13
| | | | | | | | | | | | Pre-calculate the output directory for GeneratedList and CustomTarget so we can directly use the same code for both while compiling C/C++ files and headers. There is no reason to have separate branches for GeneratedList and CustomTarget since both can be used in almost exactly the same way for generating sources. This is going to used next for adding generated sources support to Vala.
* CustomTarget: Use get_outputs() instead of get_filename()Nirbheek Chauhan2016-10-191-14/+16
| | | | | | | | get_filename() made no sense for CustomTarget since it can have multiple outputs. Also use get_outputs() for GeneratedList since it has the same meaning and remove unused set_generated(). As a side-effect, we now install all the outputs of a CustomTarget.
* Add no-warning args while building Vala C codeNirbheek Chauhan2016-10-141-2/+5
| | | | | | | | | | | This is done by adding a new compiler method called 'no_warn_args' which returns the argument(s) required for the compiler to emit no warnings for that compilation. This take care of not disabling warnings for C code compiled into the BuildTarget. Also includes tests for ensuring all this. https://github.com/mesonbuild/meson/issues/864
* Add cross-platform PIC support for static librariesNirbheek Chauhan2016-10-081-0/+2
| | | | | | | | | | | | With C/C++, on Windows you don't need to pass any arguments for a static library to be PIC. On UNIX platforms you need to pass -fPIC. Other languages such as D have compiler-specific PIC arguments required for PIC support in static libraries on UNIX platforms. This kwarg allows people to specify which static libraries should be built with PIC support. This is usually used for static libraries that will be linked into shared libraries.
* Merge pull request #803 from centricular/generated-sources-header-depsJussi Pakkanen2016-10-011-1/+0
|\ | | | | ninja backend: Fix header deps of generated source compiles
| * backends: Remove self.dep_rules dead codeNirbheek Chauhan2016-10-021-1/+0
| | | | | | | | | | | | self.dep_rules is not set anywhere by anything, so this code always results in a no-op. If it didn't result in a no-op, it would need to be seriously rewritten because it has bitrotten and makes no sense anymore.
* | Fix missing comma in backend.Backend.dedup_arguments()Sam Thursfield2016-10-011-1/+1
| | | | | | | | | | This error meant that -I flags passed to the compiler were never actually deduplicated.
* | Merge pull request #814 from centricular/heavy-cleanup-compilers-buildtargetsJussi Pakkanen2016-09-301-21/+0
|\ \ | | | | | | Heavy cleanup in compilers and BuildTarget
| * | Use per-target compilers while generating targetsNirbheek Chauhan2016-09-271-21/+0
| |/ | | | | | | | | | | This is definitely more correct since it takes into account the cross-compilation status. We also now do the Java and CSharp sanity checks on the BuildTarget level instead of in the Ninja backend.
* | Deduplicate command line arguments. Slight improvement to #671.Jussi Pakkanen2016-09-281-0/+21
|/
* ninja: Fix checking of exe_wrapper for CustomTargets (#806)Nirbheek Chauhan2016-09-251-1/+1
| | | It was making a trivially incorrect check
* Revert #737. Closes #773.Jussi Pakkanen2016-09-121-0/+19
|
* Merge pull request #684 from mesonbuild/pdbJussi Pakkanen2016-09-111-0/+6
|\ | | | | Create pdb files with MSVC
| * ninjabackend: Add support for installing .pdb filesNirbheek Chauhan2016-09-111-0/+6
| | | | | | | | | | | | .pdb files are files created by MSVC which have debug symbols. These are created when /ZI or /Zi is passed to the compiler and /DEBUG to the linker.
* | Merge branch 'QuLogic-context-managers'Jussi Pakkanen2016-09-011-25/+34
|\ \
| * | Use context manager for file I/O.Elliott Sales de Andrade2016-08-271-25/+34
| | | | | | | | | | | | | | | There are a few cases where a context manager cannot be used, such as the logger.
* | | Stop "fixing" command line in CustomTargets. (#737)Elliott Sales de Andrade2016-09-011-1/+0
| | |
* | | Use absolute paths for dep files in Visual Studio.Jussi Pakkanen2016-09-011-1/+4
| | |