[Libreoffice-commits] core.git: bin/gbuild-to-ide Makefile.in
Mike Kaganski (via logerrit)
logerrit at kemper.freedesktop.org
Fri Oct 8 12:54:24 UTC 2021
Makefile.in | 3 +--
bin/gbuild-to-ide | 11 +++++------
2 files changed, 6 insertions(+), 8 deletions(-)
New commits:
commit 27d1cc61b4f58e8ec25463275bee36c96b66b938
Author: Mike Kaganski <mike.kaganski at collabora.com>
AuthorDate: Fri Oct 8 09:56:51 2021 +0200
Commit: Mike Kaganski <mike.kaganski at collabora.com>
CommitDate: Fri Oct 8 14:53:48 2021 +0200
Simplify VS IDE integration generation
Do not require the IDE version in vs*-ide-integration. Instead, use
VCVER environment variable, that is set in configure, to obtain
the toolset for the VCPROJ files. When introducing support for new
VS version, the 'VisualStudioIntegrationGenerator.retrieve_toolset'
method needs to be updated synchronously to list the toolset.
This simplifies the make command to
make vs-ide-integration
TODO: also set the toolset in configure, to simplify the code here,
and also in places like external/python3/ExternalProject_python3.mk
(see commit c156a8c708f74dd31e1ef024edc578c3915619cb).
Change-Id: I95960029a933be2cab96898eee6be6ca6bc5794a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123162
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski at collabora.com>
diff --git a/Makefile.in b/Makefile.in
index a71a203d3558..116b1e6bd7c1 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -483,8 +483,7 @@ endef
$(foreach ide,\
codelite \
- vs2019 \
- vs2022 \
+ vs \
kdevelop \
vim \
qtcreator \
diff --git a/bin/gbuild-to-ide b/bin/gbuild-to-ide
index f349a3058aab..8e9d8ba157a6 100755
--- a/bin/gbuild-to-ide
+++ b/bin/gbuild-to-ide
@@ -916,7 +916,7 @@ class VisualStudioIntegrationGenerator(IdeIntegrationGenerator):
def __init__(self, gbuildparser, ide):
IdeIntegrationGenerator.__init__(self, gbuildparser, ide)
- self.toolset = self.retrieve_toolset(ide)
+ self.toolset = self.retrieve_toolset()
self.solution_directory = self.gbuildparser.builddir
self.configurations = {
'Build': {
@@ -936,9 +936,9 @@ class VisualStudioIntegrationGenerator(IdeIntegrationGenerator):
}
}
- def retrieve_toolset(self, ide):
- ide_toolset_map = {'vs2019': 'v142', 'vs2022': 'v143'}
- return ide_toolset_map[ide]
+ def retrieve_toolset(self):
+ ide_toolset_map = {'160': 'v142', '170': 'v143'}
+ return ide_toolset_map[os.environ['VCVER']]
def module_make_command(self, targets):
return '%(sh)s -c "PATH=\\"/bin:$PATH\\";BUILDDIR=\\"%(builddir)s\\" %(makecmd)s -rsC %(location)s ' + targets + '"'
@@ -1870,8 +1870,7 @@ if __name__ == '__main__':
'eclipsecdt': EclipseCDTIntegrationGenerator,
'kdevelop': KdevelopIntegrationGenerator,
'xcode': XcodeIntegrationGenerator,
- 'vs2019': VisualStudioIntegrationGenerator,
- 'vs2022': VisualStudioIntegrationGenerator,
+ 'vs': VisualStudioIntegrationGenerator,
'vim': VimIntegrationGenerator,
'debug': DebugIntegrationGenerator,
'qtcreator': QtCreatorIntegrationGenerator,
More information about the Libreoffice-commits
mailing list