summaryrefslogtreecommitdiff
path: root/mesonbuild/backend/vs2010backend.py
Commit message (Collapse)AuthorAgeFilesLines
* use real pathlib moduleDylan Baker2020-11-201-1/+1
| | | | | We added the _pathlib module to work around defeciencies in python 3.5's implementation, since we now rely on 3.6 lets drop this
* vs: add static_from_buildtype to b_vscrtPeter Harris2020-10-141-0/+7
|
* Add win_subsystem kwarg. Closes #7765.Jussi Pakkanen2020-10-071-2/+7
|
* pathlib: Fix resolve() by overriding it in Python 3.5Daniel Mensinger2020-10-041-2/+2
|
* Merge pull request #7762 from jon-turney/meson-exe-output-improveJussi Pakkanen2020-09-291-7/+7
|\ | | | | Improve the output for meson wrapped commands
| * Improve description of meson wrapped custom commandsJon Turney2020-09-201-7/+7
| | | | | | | | | | | | I've always found ninja reporting 'a meson_exe.py custom command' unclear and confusing. Instead say we are invoking a custom command, wrapped by meson, and why.
* | compilers/VS: fix build to use optimization and debug flagsVili VÀinölÀ2020-09-291-10/+20
|/ | | | | | | | - Fixed using debug and optimization built-in options in MSVC. - Fixed that VS backend does not create pdb files in release mode. VS implicitly adds the debug fields if left out. - Fix that it is possible to add debug info with ninja backend with optimizations.
* backends: Treat build target as generator only when it's the first argNirbheek Chauhan2020-09-171-1/+1
| | | | | Otherwise it might be an argument to a script that just inspects the binary itself.
* Remove redudant checks in vs2010 backendVili VÀinölÀ2020-09-131-6/+3
| | | | | - Implicit include dirs was checked twice in a row - Add define only if it does not yet exist rather than remove.
* Add VS include directories to projects as wellVili VÀinölÀ2020-09-131-2/+3
| | | | | | - "Go To Document" action previously only worked on c/cpp files which had the include directories set but it was not possible to move from header to another header.
* typing: more fixesDaniel Mensinger2020-09-081-2/+2
|
* compilers: Return CompilerArgs from compiler instanceDylan Baker2020-06-221-5/+4
| | | | | | | Since the CompileArgs class already needs to know about the compiler, and we really need at least per-lanaguage if not per-compiler CompilerArgs classes, let's get the CompilerArgs instance from the compiler using a method.
* compilers: Split CompilerArgs into a separate moduleDylan Baker2020-06-221-1/+1
| | | | | I've also moved this out of the compilers pacakge because we're soon going to need it in linkers, and that creates some serious spagetti
* Add exception handling to be also written to the VS project xmlVili VÀinölÀ2020-06-151-0/+12
| | | | When changing meson option cpp_eh, it was passed to cl with AdditionalOptions and resulted in unsuppressable warning "cl : command line warning D9025: overriding '/EHs' with '/EHa'"
* backend/vs: Fix OpenMP supportPeter Harris2020-06-061-17/+17
| | | | | | | Use the IDE's OpenMP flag instead of adding /openmp to additional arguments. The IDE appears to override /openmp in additional arguments with the IDE setting, which defaults to false, leading to binaries built without OpenMP.
* Build private directory name from output file name.Jussi Pakkanen2020-05-191-0/+3
|
* backend/vs: Fix b_vscrt=from_buildtype for debugoptimizedPeter Harris2020-05-141-2/+2
| | | | | | | | | | | | The ninja backend only uses the debug C runtime for 'debug', not for 'debugoptimized'. The ninja backend always uses the DLL C runtime for all configurations. The documentation matches the ninja backend. Make the visual studio backend follow the documentation (and the precedent set by the ninja backend).
* Fix incremental debug builds in VSGustavoLCR2020-05-041-1/+2
|
* backend/vs: Fix build when not all languages have pchPeter Harris2020-04-241-10/+4
| | | | | | | | | | | | | | It is not unheard-of for a project to use pch for C++ but not for C (because C usually builds fast enough anyway, so it's not worth the developer overhead of maintaining the pch file). This code was trying to optimize the vcxproj file size by detecting "only one language", but it was only looking at the number of pch-languages defined. This is incorrect when pch is not defined for all languages in use. Instead of tweaking the optimization further, remove it. This makes the vs backend behave more like the ninja backend.
* Compiler options per langJohn Ericson2020-04-201-7/+11
| | | | | | | | | | | A current rather untyped storage of options is one of the things that contributes to the options code being so complex. This takes a small step in synching down by storing the compiler options in dicts per language. Future work might be replacing the langauge strings with an enum, and defaultdict with a custom struct, just like `PerMachine` and `MachineChoice`.
* Handle BuildTarget as custom_target() argument #6914Marc-André Lureau2020-04-111-1/+1
|
* Fixes meson bug to allow arm64 buildJesse Natalie2020-04-101-1/+5
|
* backend/vs: Fix link of wmain / wWinMain based appsPeter Harris2020-04-041-5/+0
| | | | | | | | | Executables may have an entry point of wmain or wWinMain. These executables link successfully with ninja. Rather than add more flags to executable() in meson.build, remove the EntryPointSymbol override. This makes the vs backend behave more like the ninja backend. Fixes #6698
* backend/vs: Fix debug information and runtime checksPeter Harris2020-04-031-6/+6
| | | | | | | Both DebugInformationFormat and BasicRuntimeChecks need to be in clconf (not type_config) for Visual Studio to recognize them. Fixes #6699
* backend: refactor: set self.interpreter in the constructorDaniel Mensinger2020-01-281-9/+10
|
* vs: Write checksums in PE binaries (DLLs and EXEs)Nirbheek Chauhan2020-01-221-0/+4
| | | | | | | | | | This is needed for detecting data corruption, and its absence (or an incorrect value) is also used as a hint by anti-viruses that the binary may be malware. Flag is only supported by MSVC `link.exe`, not `lld-link.exe` https://docs.microsoft.com/en-us/cpp/build/reference/release-set-the-checksum
* Prevent the presence of duplicated items in .vcxproj filesLuca Bacci2019-11-301-22/+43
| | | | | | | | | | | | | | | | Visual Studio refuses to open projects that present duplicated items, for example: <ItemGroup> <CLInclude Include="glib-enumtypes.h"/> <CLInclude Include="glib-enumtypes.h"/> </ItemGroup> Note that MSBuild handles duplicated items without any issue, this is useful only for compatibility with the VS IDE. See pull request mesonbuild#6151 Fixes issue mesonbuild#6147
* backends: choose whether to serialize in as_meson_exe_cmdlinePaolo Bonzini2019-07-191-6/+7
| | | | | This removes more duplicate code between custom targets and generators. In addition, generators can now have arguments with newlines in them.
* vs2010backend: always serialize executables for generatorsPaolo Bonzini2019-07-191-12/+14
| | | | Do the same as for custom targets.
* backends: hide meson --internal exe cmdline from backendsPaolo Bonzini2019-07-191-9/+7
| | | | | | Return the command line from serialize_executable, which is then renamed to as_meson_exe_cmdline. This avoids repeating code that is common to custom targets and generators.
* vs backend: commandrunner.py takes source dir firstXavier Claessens2019-07-101-1/+1
|
* Add alias_target() functionXavier Claessens2019-07-101-1/+6
|
* Purge `is_cross` and friends without changing user interfacesJohn Ericson2019-06-091-14/+10
| | | | | | | | | | | | In most cases instead pass `for_machine`, the name of the relevant machines (what compilers target, what targets run on, etc). This allows us to use the cross code path in the native case, deduplicating the code. As one can see, environment got bigger as more information is kept structured there, while ninjabackend got a smaller. Overall a few amount of lines were added, but the hope is what's added is a lot simpler than what's removed.
* Moved RuntimeLibrary property to ItemDefinitionGroup/ClCompilefilippocrocchini2019-06-081-9/+10
|
* Merge pull request #5311 from mensinda/flake8PluginsJussi Pakkanen2019-05-021-3/+3
|\ | | | | Added flake8 plugins and some code fixes
| * Fixed unnecessary .items()Daniel Mensinger2019-04-291-3/+3
| |
| * Fix unused variables warningsDaniel Mensinger2019-04-291-1/+1
| |
* | Added special handling of CustomTargetIndex in VS backendTheQwertiest2019-04-291-1/+5
| |
* | Added custom_target[i] support for link_with and link_wholeTheQwertiest2019-04-291-2/+8
|/
* vs2010backend: emit dependencies for generatorsPaolo Bonzini2019-04-161-0/+3
| | | | | | This is the VS-specific part of the previous commit; the Visual Studio backend was ignoring dependencies, add an AdditionalInputs element similar to what add_custom_build does.
* vs2010backend: fix flake8 issuePaolo Bonzini2019-04-161-1/+0
| | | | mesonbuild/backend/vs2010backend.py:506:9: F841 local variable action is assigned to but never used
* Add VS2019 backend CI and docs.Anton Kochkov2019-04-161-1/+1
|
* Add support for VS2019. Closes #4640.Jussi Pakkanen2019-04-101-0/+4
|
* Move the optimization options in the compiler configSteve Lhomme2019-03-021-22/+21
| | | | They have no effect in the "Configuration" PropertyGroup at least in VS2017
* auto generate msvc pch source file if none is provided by the userNicolas Schneider2019-03-011-8/+19
|
* vs: add support for `build_always_stale` for custom targetsNicolas Schneider2019-02-241-4/+14
|
* vs: use CustomBuild instead of CustomBuildStep for custom targetsNicolas Schneider2019-02-211-5/+2
| | | | | This allows to view the build step in VS and reuses the same concept that we use for run targets instead of maintaining two different behaviors.
* Merge pull request #4917 from nioncode/vs-fixTargetDependenciesJussi Pakkanen2019-02-161-10/+26
|\ | | | | vs: use project references in vcxproj instead of the sln file
| * vs: link dependencies of link_whole targetsNicolas Schneider2019-02-131-6/+15
| | | | | | | | | | Otherwise, msbuild will not create any output for targets that don't have any sources.
| * vs: do not automatically link dependenciesNicolas Schneider2019-02-131-0/+4
| |