Merge pull request #6185 from opensourcerouting/build-assorted-20200408

assorted build fixes
This commit is contained in:
Donald Sharp 2020-04-08 13:29:45 -04:00 committed by GitHub
commit c189a11d7f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 2 deletions

View File

@ -860,7 +860,7 @@ fi
AC_SUBST([EXTRAVERSION])
if test "$with_pkg_git_version" = "yes"; then
if test -d "${srcdir}/.git"; then
if test -e "${srcdir}/.git"; then
AC_DEFINE([GIT_VERSION], [1], [include git version info])
else with_pkg_git_version="no"
AC_MSG_WARN([--with-pkg-git-version given, but this is not a git checkout])

View File

@ -90,6 +90,7 @@ check_PROGRAMS += \
endif
tests/lib/cli/test_commands_defun.c: vtysh/vtysh_cmd.c
mkdir -p tests/lib/cli
sed \
-e 's%"vtysh/vtysh\.h"%"tests/helpers/c/tests.h"%' \
-e 's/vtysh_init_cmd/test_init_cmd/' \
@ -99,6 +100,7 @@ tests/lib/cli/test_commands_defun.c: vtysh/vtysh_cmd.c
CLEANFILES += tests/lib/cli/test_commands_defun.c
tests/isisd/test_fuzz_isis_tlv_tests.h: $(top_srcdir)/tests/isisd/test_fuzz_isis_tlv_tests.h.gz
mkdir -p tests/isisd
gzip -d < $(top_srcdir)/tests/isisd/test_fuzz_isis_tlv_tests.h.gz > "$@"
CLEANFILES += tests/isisd/test_fuzz_isis_tlv_tests.h

View File

@ -3,11 +3,18 @@
# YANG module to C wrapper
# written 2018 by David Lamparter, placed in Public Domain.
import sys, string, re
import sys
import os
import string
import re
inname = sys.argv[1]
outname = sys.argv[2]
outdir = os.path.dirname(os.path.abspath(outname))
if not os.path.isdir(outdir):
os.makedirs(outdir)
# these are regexes to avoid a compile-time/host dependency on yang-tools
# or python-yang. Cross-compiling FRR is already somewhat involved, no need
# to make it even harder.