diff mbox series

[v6,04/13,FIXUP] meson: Avoid double-quoting strings

Message ID 20220829013327.5791-5-laurent.pinchart@ideasonboard.com
State New
Headers show
Series Add support for meson building | expand

Commit Message

Laurent Pinchart Aug. 29, 2022, 1:33 a.m. UTC
The GIT_SHA, GIT_COMMIT_CNT and GIT_COMMIT_DATE macros from the
generated config.h file are wrapped with STRING() in source code. Don't
use set_quoted() in meson.build in order to avoid double-quoting them.

After switching to meson, set_quoted() would be better, with the
STRING() macro removed from the sources.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 meson.build | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/meson.build b/meson.build
index bad3ce0015f9..aec69a9bc3f6 100644
--- a/meson.build
+++ b/meson.build
@@ -298,14 +298,14 @@  add_project_link_arguments(cpp_arguments, language : 'cpp')
 
 git_sha = run_command(prog_git, '-C', meson.project_source_root(), 'rev-parse', '--short=12', 'HEAD',
                       check : true).stdout().strip()
-conf.set_quoted('GIT_SHA', git_sha)
+conf.set('GIT_SHA', git_sha)
 git_commit_cnt = run_command(prog_git, '-C', meson.project_source_root(), 'rev-list', '--count', 'HEAD',
                              check : true).stdout().strip()
-conf.set_quoted('GIT_COMMIT_CNT', '-' + git_commit_cnt)
+conf.set('GIT_COMMIT_CNT', '-' + git_commit_cnt)
 git_commit_date = run_command(prog_git, '-C', meson.project_source_root(), 'show', '--quiet',
                               '--date=format-local:%F %T', '--format=%cd',
                               env : ['TZ=UTC'], check : true).stdout().strip()
-conf.set_quoted('GIT_COMMIT_DATE', git_commit_date)
+conf.set('GIT_COMMIT_DATE', git_commit_date)
 
 man_pages = []