summaryrefslogtreecommitdiff
path: root/mesonbuild/backend/vs2010backend.py
Commit message (Collapse)AuthorAgeFilesLines
* Added install target to VS. Closes #3841.vsinstallJussi Pakkanen2018-07-221-0/+77
|
* Visual Studio: Implement startup projectNiklas Claesson2018-06-101-2/+11
|
* Move <lang>_args to coredata.compiler_optionsXavier Claessens2018-06-061-4/+5
|
* Add a new option for building with Apple bitcode supportNirbheek Chauhan2018-06-061-1/+2
| | | | | | Normally, people would just pass -fembed-bitcode in CFLAGS, but this conflicts with -Wl,-dead_strip_dylibs and -bundle, so we need it as an option so that those can be quietly disabled.
* Merge pull request #3372 from NickeZ/vs-sol-foldersJussi Pakkanen2018-04-261-20/+68
|\ | | | | Use visual studio solution directories
| * Use visual studio solution directoriesNiklas Claesson2018-04-171-17/+65
| | | | | | | | | | | | | | | | This implements support for visual studio solution directories. Projects will by default be put into directories that map their sub-directory name in the source folder. No directories are created if `--layout=flat` is used. Fixes: #2524
| * Fix vs flat layout bugNiklas Claesson2018-04-171-4/+4
| |
* | Fix using object extracted from a unity buildXavier Claessens2018-04-181-1/+1
|/ | | | | | | | | | | - determine_ext_objs: What matters is if extobj.target is a unity build, not if the target using those objects is a unity build. - determine_ext_objs: Return one object file per compiler, taking into account generated sources. - object_filename_from_source: No need to special-case unity build, it does the same thing in both code paths. - check_unity_compatible: For each compiler we must extract either none or all its sources, taking into account generated sources.
* Merge pull request #1852 from QuLogic/openmpJussi Pakkanen2018-04-171-3/+12
|\ | | | | Add an OpenMP dependency.
| * Add an OpenMP dependency.Elliott Sales de Andrade2018-04-171-3/+12
| | | | | | | | | | This works similarly to the thread dependency which stores the various inconsistent flags in each compiler.
* | Open build files with utf-8Nirbheek Chauhan2018-04-171-3/+3
|/
* VS backend: dedup AdditionalDependenciesPaul I2018-04-081-1/+2
|
* Merge pull request #2976 from dzabraev/fix-reversed-orderJussi Pakkanen2018-03-251-1/+2
|\ | | | | Fix bug include_directories(['p1','p2']) add -Ip2 -Ip1 (reversed order)
| * keep include paths orderMaxim Dzabraev2018-02-111-1/+2
| |
* | Enable b_ndebug on VisualStudioCCompilerAleksey Filippov2018-03-231-1/+1
| |
* | Use target.get_id() instead of basename and type_suffix concatenation at ↔Aleksey Filippov2018-03-151-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | call site Fixes the bug with flat layout and identical target names in subprojects. Without this change directories are not created with subproject prefix and they can collide. Remove dead makedirs code in Backend.__init__(), during initialization of backend build.targets is empty. Create output directories in Vs2010Backend.generate_projects() instead. Also use double blank line in run_unittests.py according to https://www.python.org/dev/peps/pep-0008/#blank-lines.
* | Fix flake8 'imported but unused' reportsJon Turney2018-03-031-1/+1
|/ | | | | | | | | | | | | | | | $ flake8 | grep F401 ./meson.py:17:1: F401 'mesonbuild.mesonlib' imported but unused ./meson.py:18:1: F401 'locale' imported but unused ./run_unittests.py:24:1: F401 'sys' imported but unused ./mesonbuild/minit.py:2:1: F401 'pyclbr.Function' imported but unused ./mesonbuild/minit.py:18:1: F401 'os' imported but unused ./mesonbuild/backend/vs2010backend.py:15:1: F401 'sys' imported but unused ./mesonbuild/backend/xcodebackend.py:19:1: F401 'sys' imported but unused ./mesonbuild/dependencies/ui.py:20:1: F401 'shutil' imported but unused ./mesonbuild/modules/python3.py:15:1: F401 'sys' imported but unused ./mesonbuild/modules/unstable_icestorm.py:15:1: F401 '..compilers' imported but unused ./mesonbuild/modules/unstable_icestorm.py:15:1: F401 '..mlog' imported but unused ./test cases/common/98 gen extra/srcgen3.py:3:1: F401 'os' imported but unused
* Use os.path: basename() and dirname() instead of split()Aleksey Filippov2018-01-301-1/+1
| | | | | | | | | | | | According to Python documentation[1] dirname and basename are defined as follows: os.path.dirname() = os.path.split()[0] os.path.basename() = os.path.split()[1] For the purpose of better readability split() is replaced by appropriate function if only one part of returned tuple is used. [1]: https://docs.python.org/3/library/os.path.html#os.path.split
* Merge pull request #2764 from mesonbuild/generatorpathJussi Pakkanen2018-01-131-2/+3
|\ | | | | Generator outputs can have path segments
| * Fix Windows.generatorpathJussi Pakkanen2017-12-211-2/+3
| |
| * Can declare file generation in one dir and use the output in another.Jussi Pakkanen2017-12-181-1/+1
| |
* | Modify exception raised when msvc pch is badly specifiedChristophe Gouiran2018-01-071-1/+1
| |
* | Fix MSVC backend crashes when `c_pch` or `cpp_pch` is not an arrayChristophe Gouiran2018-01-061-14/+22
| |
* | Fail Visual Studio version detection if VSINSTALLDIR is not setGabrĂ­el ArthĂșr PĂ©tursson2017-12-301-4/+3
|/ | | | | | The Visual Studio Developer Command Prompt always sets the VSINSTALLDIR environment variable. If not, we probably have a broken environment and won't get very far anyway.
* custom target: Consider all build depends while serializingNirbheek Chauhan2017-12-021-0/+3
| | | | | | | | | | Currently, we only consider the build depends of the Executable being run when serializing custom targets. However, this is not always sufficient, for example if the executable loads modules at runtime or if the executable is actually a python script that loads a built module. For these cases, we need to set PATH on Windows correctly or the custom target will fail to run at build time complaining about missing DLLs.
* VS: Add /DEBUG to linker to generate debug informationNiklas Claesson2017-11-301-3/+7
|
* Review fixes.Jussi Pakkanen2017-11-211-2/+2
|
* Replaced sys.executable use with the mesonlib equivalent.Jussi Pakkanen2017-11-201-4/+5
|
* Merge pull request #2313 from dcbaker/fix-2180Jussi Pakkanen2017-10-011-11/+30
|\ | | | | link_whole should be considered a source for targets
| * vs: Fix link_whole usage with the vs backendNirbheek Chauhan2017-09-301-8/+21
| | | | | | | | | | | | | | /WHOLEARCHIVE must go to AdditionalOptions, not AdditionalDependencies and we must add a project reference to trick msbuild/visual studio into building a target that is built from only libraries linked in via /WHOLEARCHIVE.
| * vs: Fix detection of options vs libraries in link argsNirbheek Chauhan2017-09-301-0/+2
| |
| * vs: Add a helper for adding a project referenceNirbheek Chauhan2017-09-301-3/+7
| |
* | Implement capture for generatorsNiklas Claesson2017-09-291-0/+10
| |
* | Allow CustomTarget's to be indexedDylan Baker2017-09-271-1/+3
| | | | | | | | | | | | | | | | | | | | | | This allows a CustomTarget to be indexed, and the resulting indexed value (a CustomTargetIndex type), to be used as a source in other targets. This will confer a dependency on the original target, but only inserts the source file returning by index the original target's outputs. This can allow a CustomTarget that creates both a header and a code file to have it's outputs split, for example. Fixes #1470
* | Merge pull request #2357 from LukeShu/flake8Jussi Pakkanen2017-09-221-5/+2
|\ \ | |/ |/| Bring into compliance with flake8
| * flake8: Clean up complained-about unused importsLuke Shumaker2017-09-211-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also adds a "# noqa: F401" comment on an unused "import lzma", which we are using it in a try/except block that is being used to check if the lzma module is importable; of course it is unused. v2: This turned out to be a little tricky. mesonbuild/modules/__init__.py had the "unused" import: from ..interpreterbase import permittedKwargs, noKwargs However, that meant that the various modules could do things like: from . import noKwargs # "." is "mesonbuild.modules" Which breaks when you remove __init__.py's "unused" import. I could have tagged that import with "# noqa: F401", but instead I chose to have each of the module import directly from "..interpreterbase" instead of ".".
| * flake8: Perform suggested whitespace/formatting changesLuke Shumaker2017-09-211-4/+2
| | | | | | | | | | This only touches newlines, spaces, and (occaisionally) commas. Anything else is left for another commit.
* | Add @PLAINNAME@ and @BASENAME@ to arguments argument for GeneratorNiklas Claesson2017-09-201-1/+1
|/ | | | Fixes #1282
* Merge pull request #1943 from QuLogic/duplicate-namesJussi Pakkanen2017-09-121-33/+1
|\ | | | | Fix creation of objects with duplicate names
| * Remove VS implementation of object name resolver.Elliott Sales de Andrade2017-08-141-33/+1
| | | | | | | | The upstream one should work properly now, one hopes.
* | backends: Add custom target inc dirs before target inc dirsNirbheek Chauhan2017-09-111-3/+5
| | | | | | | | | | | | Custom target include dirs must be overridable by target-specific include dirs otherwise in case of header name collisions, the user has no way to override this behaviour.
* | Make all functionality invokable via the main Meson binary,Jussi Pakkanen2017-08-181-13/+6
|/ | | | which can be a Windows .exe file.
* Use "meson test" in test invocations so it will not print the deprecation ↔Jussi Pakkanen2017-08-141-1/+2
| | | | warning.
* Add option to disable implicit include directories. Closes #2139.Jussi Pakkanen2017-08-051-3/+7
|
* Support implibs for executables on WindowsJon Turney2017-07-201-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | Add a boolean 'implib' kwarg to executable(). If true, it is permitted to use the returned build target object in link_with: On platforms where this makes sense (e.g. Windows), an implib is generated for the executable and used when linking. Otherwise, it has no effect. (Rather than checking if it is a StaticLibrary or SharedLibary, BuildTarget subclasses gain the is_linkable_target method to test if they can appear in link_with:) Also install any executable implib in a similar way to a shared library implib, i.e. placing the implib in the appropriate place Add tests of: - a shared_module containing a reference to a symbol which is known (at link time) to be provided by the executable - trying to link with non-implib executables (should fail) - installing the implib (This last one needs a little enhancement of the installed file checking as this is the first install test we have which needs to work with either MSVC-style or GCC-style implib filenames)
* Preserve -L -l pairings fetched from external depsNirbheek Chauhan2017-06-121-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | While adding link args for external deps, sometimes different libraries come from different prefixes, and an older version of the same library might be present in other prefixes and we don't want to accidentally pick that up. For example: /usr/local/lib/libglib-2.0.so /usr/local/lib/pkgconfig/glib-2.0.pc /usr/local/lib/libz.so /usr/local/lib/pkgconfig/zlib.pc /home/mesonuser/.local/lib/libglib-2.0.so /home/mesonuser/.local/lib/pkgconfig/glib-2.0.pc PKG_CONFIG_PATH="/home/mesonuser/.local/lib/pkgconfig/:/usr/local/lib/pkgconfig/" If a target uses `dependencies : [glib_dep, zlib_dep]`, it will end up using /usr/local/lib/libglib-2.0.so instead of /home/mesonuser/.local/lib/libglib-2.0.so despite using the pkg-config file in /home/mesonuser/.local/lib/pkgconfig because we reorder the -L flag and separate it from the -l flag. With this change, external link arguments will be added to the compiler list without de-dup or reordering. Closes https://github.com/mesonbuild/meson/issues/1718
* vs: Always check VSINSTALLDIR in case VisualStudioVersion is unsetNirbheek Chauhan2017-06-091-17/+15
| | | | | | | This happened on the CI, so it could happen on people's machines too: https://ci.appveyor.com/project/jpakkane/meson/build/2870/job/p2n70hg01vp3dkgl https://ci.appveyor.com/project/jpakkane/meson/build/2870/job/7ifh64mi1999guxt
* fix WarningLevel in vcxproj #1913Bug2017-06-081-3/+3
| | | | - VS 2010-2015 expect <WarningLevel> to be inside <ClCompile> - WarningLevel now correctly reflects VisualStudioCCompiler.get_warn_args
* Fix cross environment pollution.Ole André Vadla RavnÄs2017-05-211-8/+10
| | | | | | | Environment variables like CFLAGS and LDFLAGS should not affect the cross environment. Fixes #1772
* vs: surround project guid with '{}'Nicolas Schneider2017-05-091-4/+4
| | | | Closes #1672.