summaryrefslogtreecommitdiffstats
path: root/src/scripts/generate_version_h
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2019-01-28 17:55:59 +0100
committerThomas F Herbert <therbert@redhat.com>2019-03-05 12:08:05 -0500
commit3262adc55c2b39693a473e16593d07192d7cf916 (patch)
tree9d32e1b541fa6c6affddafc6c0272b4299812e60 /src/scripts/generate_version_h
parentd302022440a3698c7ec81340bfb67cab2a5b71ea (diff)
cmake: fix out-of-git-tree build
Cherry picked from master: 6077c97a JIRA: VPP-1577 Change-Id: Ib94637ec09799c23f3179599b54a2be6e2768425 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/scripts/generate_version_h')
-rwxr-xr-xsrc/scripts/generate_version_h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/scripts/generate_version_h b/src/scripts/generate_version_h
index 993a682954b..f4705489c87 100755
--- a/src/scripts/generate_version_h
+++ b/src/scripts/generate_version_h
@@ -22,7 +22,7 @@ cat > ${1} << __EOF__
#define VPP_BUILD_DATE "$(date)"
#define VPP_BUILD_USER "$(whoami)"
#define VPP_BUILD_HOST "$(hostname)"
-#define VPP_BUILD_TOPDIR "$(git rev-parse --show-toplevel)"
+#define VPP_BUILD_TOPDIR "$(git rev-parse --show-toplevel 2> /dev/null)"
#define VPP_BUILD_VER "$(scripts/version)"
#endif
__EOF__