CMake: various small non-functional improvements
PATCH 1/1 CMake: various small non-functional improvements
These are based on review comments for the 2.6 backport. But since they apply to the original master implementation as well, I address them in this separate patch.
- Add documentation to contrib/cmake/*.py
- Fix grammar in README.cmake.md
- Update a TODO in CMakeLists.txt to better reflect the status quo
- Fix indentation in unit_tests' Makefile.am
---
This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master.
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/342
This mail reflects revision 1 of this Change. Acked-by according to Gerrit (reflected above):
Manual changes:
- Fixed Lev's name in Acked-by line.
CMakeLists.txt +1 -1
@@ -291,7 +291,7 @@ configure_file(config.h.cmake.in config.h) configure_file(include/openvpn-plugin.h.in openvpn-plugin.h) -# TODO remove later when msvc-config.h is removed and we can always include config.h +# TODO we should remove the need for this, and always include config.h add_definitions(-DHAVE_CONFIG_H) include_directories(${CMAKE_CURRENT_BINARY_DIR})
README.cmake.md +1 -1
@@ -24,7 +24,7 @@ ----------- The following tools are expected to be present on the system, you -can them install with a package manager of your choice (e.g. +can install them with a package manager of your choice (e.g. chocolatey, winget) or manually: * CMake
contrib/cmake/git-version.py +8 -0
@@ -22,6 +22,14 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. # +# Usage: ./git-version.py [directory] +# Find a good textual representation of the git commit currently checked out. +# Make that representation available as CONFIGURE_GIT_REVISION in +# <directory>/config-version.h. +# It will prefer a tag name if it is checked out exactly, otherwise will use +# the branch name. 'none' if no branch is checked out (detached HEAD). +# This is used to enhance the output of openvpn --version with Git information. + import os import sys import subprocess
contrib/cmake/parse-version.m4.py +6 -0
@@ -22,6 +22,12 @@ # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. # +# Usage: ./parse-version.m4.py m4file [directory] +# Read <m4file>, extract all lines looking like M4 define(), and translate +# them into CMake style set(). Those are then written out to file +# <directory>/version.cmake. +# Intended to be used on top-level version.m4 file. + import os import re import sys
tests/unit_tests/openvpn/Makefile.am +1 -1
@@ -110,7 +110,7 @@ -Wl,--wrap=parse_line \ -Wl,--wrap=rand_bytes tls_crypt_testdriver_SOURCES = test_tls_crypt.c mock_msg.c mock_msg.h \ - mock_win32_execve.c \ + mock_win32_execve.c \ $(top_srcdir)/src/openvpn/argv.c \ $(top_srcdir)/src/openvpn/base64.c \ $(top_srcdir)/src/openvpn/buffer.c \
Quoted 18 lines · Frank Lichtenheld
These are based on review comments for the 2.6 backport. But since they apply to the original master implementation as well, I address them in this separate patch.
- Add documentation to contrib/cmake/*.py
- Fix grammar in README.cmake.md
- Update a TODO in CMakeLists.txt to better reflect the status quo
- Fix indentation inunit_tests' Makefile.amChange-Id I4e16767ee221e1aefdd18d13b3411c27d8dd844aSigned-off-by Frank Lichtenheld <[email protected]...>Acked-by Lev Stipakov <[email protected]...>---
This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master.
Quoted 7 lines
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/342
This mail reflects revision 1 of this Change. Acked-by according to Gerrit (reflected above):Acked-by lstipakov <[email protected]...>Manual changes:
- Fixed Lev's name in Acked-by line.
This is a test email for an idea of mine to resolve the current issues in integrating Gerrit into our workflow by extracting all the information about a reviewed change from Gerrit and submit them to the list in the traditional format so that Gert can apply the usual process for merging.
Feedback welcome.
I will post the script for review as well.
Regards,
Signature · 1 line
Frank Lichtenheld
Your patch has been applied to the master branch.
Since this is documentation and a lone tab, nothing much to test here (but documentation is good :-) ).
commit 95cc5faa16833acaf12a4d273c5c848984fc73ce (master)
Author: Frank Lichtenheld Date: Tue Sep 19 17:56:35 2023 +0200
CMake: various small non-functional improvements
Signed-off-by: Frank Lichtenheld <[email protected]...>
Acked-by: Lev Stipakov <[email protected]...>
Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/342
Message-Id: <[email protected]...>
URL: https://www.mail-archive.com/[email protected]/msg27043.html
Signed-off-by: Gert Doering <[email protected]...>--
kind regards,
Gert Doering