configure.ac: Fix --with-cligen=dir
Fix CFLAGS and LDFLAGS when this option is used. It needs to look for headers under $includedir and for libraries under $libdir.
This commit is contained in:
parent
7275a68c75
commit
989aa25428
1 changed files with 7 additions and 8 deletions
15
configure.ac
15
configure.ac
|
|
@ -179,15 +179,14 @@ SH_SUFFIX=".so"
|
||||||
LIBSTATIC_SUFFIX=".a"
|
LIBSTATIC_SUFFIX=".a"
|
||||||
|
|
||||||
# This is for cligen
|
# This is for cligen
|
||||||
AC_ARG_WITH([cligen], AS_HELP_STRING([--with-cligen=dir],[Use CLIGEN installation in this dir]))
|
AC_ARG_WITH([cligen], [AS_HELP_STRING([--with-cligen=dir], [Use CLIGEN installation in this dir])], [
|
||||||
|
CLIGEN_DIR="$withval"
|
||||||
|
])
|
||||||
|
AC_SUBST(CLIGEN_DIR)
|
||||||
if test -n "${CLIGEN_DIR}" -a -d "${CLIGEN_DIR}"; then
|
if test -n "${CLIGEN_DIR}" -a -d "${CLIGEN_DIR}"; then
|
||||||
with_cligen=${CLIGEN_DIR}
|
echo "Using CLIGEN here: ${CLIGEN_DIR}"
|
||||||
fi
|
CPPFLAGS="-I${CLIGEN_DIR}$(eval echo ${includedir}) ${CPPFLAGS}"
|
||||||
if test -d "${with_cligen}"; then
|
LDFLAGS="-L${CLIGEN_DIR}$(eval echo ${libdir}) ${LDFLAGS}"
|
||||||
echo "Using CLIGEN here: ${with_cligen}"
|
|
||||||
CPPFLAGS="-I${with_cligen}/include ${CPPFLAGS}"
|
|
||||||
LDFLAGS="-L${with_cligen}/lib ${LDFLAGS}"
|
|
||||||
test -d "$with_cligen" && CLIGEN_PREFIX="$with_cligen"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Disable/enable yang patch
|
# Disable/enable yang patch
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue