Skip to content

Commit

Permalink
....I..... [ZBX-21064] renamed pcre(2) *dir_lib to *lib_dir
Browse files Browse the repository at this point in the history
  • Loading branch information
Yur11 committed May 19, 2022
1 parent 2e795ec commit 5544631
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
20 changes: 10 additions & 10 deletions m4/pcre.m4
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ AC_DEFUN([LIBPCRE_CHECK_CONFIG],
withval="/usr"
fi
else
_libpcre_dir_lib="$withval/lib"
_libpcre_lib_dir="$withval/lib"
fi
fi
_libpcre_dir="$withval"
Expand All @@ -69,7 +69,7 @@ AC_DEFUN([LIBPCRE_CHECK_CONFIG],
),
[
_libpcre_dir="$withval"
_libpcre_dir_lib="$withval"
_libpcre_lib_dir="$withval"
LIBPCRE_LDFLAGS="-L$withval"
_libpcre_dir_set="yes"
]
Expand All @@ -81,7 +81,7 @@ AC_DEFUN([LIBPCRE_CHECK_CONFIG],
if test "x$enable_static_libs" = "xyes"; then
AC_REQUIRE([PKG_PROG_PKG_CONFIG])
PKG_PROG_PKG_CONFIG()
test -z "$PKG_CONFIG" -a -z "$_libpcre_dir_lib" && AC_MSG_ERROR([Not found pkg-config library])
test -z "$PKG_CONFIG" -a -z "$_libpcre_lib_dir" && AC_MSG_ERROR([Not found pkg-config library])
m4_pattern_allow([^PKG_CONFIG_LIBDIR$])
fi
Expand All @@ -90,25 +90,25 @@ AC_DEFUN([LIBPCRE_CHECK_CONFIG],
if test "x$enable_static" = "xyes"; then
LIBPCRE_LIBS=" $LIBPCRE_LIBS -lpthread"
elif test "x$enable_static_libs" = "xyes" -a -z "$PKG_CONFIG"; then
LIBPCRE_LIBS="$_libpcre_dir_lib/libpcre.a"
LIBPCRE_LIBS="$_libpcre_lib_dir/libpcre.a"
elif test "x$enable_static_libs" = "xyes"; then
test "x$static_linking_support" = "xno" -a -z "$_libpcre_dir_lib" && AC_MSG_ERROR(["Compiler not support statically linked libs from default folders"])
test "x$static_linking_support" = "xno" -a -z "$_libpcre_lib_dir" && AC_MSG_ERROR(["Compiler not support statically linked libs from default folders"])
if test -z "$_libpcre_dir_lib"; then
if test -z "$_libpcre_lib_dir"; then
PKG_CHECK_EXISTS(libpcre,[
LIBPCRE_LIBS=`$PKG_CONFIG --static --libs libpcre`
],[
AC_MSG_ERROR([Not found libpcre package])
])
else
AC_RUN_LOG([PKG_CONFIG_LIBDIR="$_libpcre_dir_lib/pkgconfig" $PKG_CONFIG --exists --print-errors libpcre]) || AC_MSG_ERROR(["Not found libpcre package in $_libpcre_dir/lib/pkgconfig"])
LIBPCRE_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre_dir_lib/pkgconfig" $PKG_CONFIG --static --libs libpcre`
test -z "$LIBPCRE_LIBS" && LIBPCRE_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre_dir_lib/pkgconfig" $PKG_CONFIG --libs libpcre`
AC_RUN_LOG([PKG_CONFIG_LIBDIR="$_libpcre_lib_dir/pkgconfig" $PKG_CONFIG --exists --print-errors libpcre]) || AC_MSG_ERROR(["Not found libpcre package in $_libpcre_dir/lib/pkgconfig"])
LIBPCRE_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre_lib_dir/pkgconfig" $PKG_CONFIG --static --libs libpcre`
test -z "$LIBPCRE_LIBS" && LIBPCRE_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre_lib_dir/pkgconfig" $PKG_CONFIG --libs libpcre`
fi
if test "x$static_linking_support" = "xno"; then
LIBPCRE_LIBS=`echo "$LIBPCRE_LIBS"|sed "s|-lpcre|$_libpcre_dir_lib/libpcre.a|g"`
LIBPCRE_LIBS=`echo "$LIBPCRE_LIBS"|sed "s|-lpcre|$_libpcre_lib_dir/libpcre.a|g"`
else
LIBPCRE_LIBS=`echo "$LIBPCRE_LIBS"|sed "s/-lpcre/${static_linking_support}static -lpcre ${static_linking_support}dynamic/g"`
fi
Expand Down
20 changes: 10 additions & 10 deletions m4/pcre2.m4
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ AC_DEFUN([LIBPCRE2_CHECK_CONFIG],
withval="/usr"
fi
else
_libpcre2_dir_lib="$withval/lib"
_libpcre2_lib_dir="$withval/lib"
fi
fi
_libpcre2_dir="$withval"
Expand All @@ -72,7 +72,7 @@ AC_DEFUN([LIBPCRE2_CHECK_CONFIG],
),
[
_libpcre2_dir="$withval"
_libpcre2_dir_lib="$withval"
_libpcre2_lib_dir="$withval"
LIBPCRE2_LDFLAGS="-L$withval"
_libpcre2_dir_set="yes"
]
Expand All @@ -85,7 +85,7 @@ AC_DEFUN([LIBPCRE2_CHECK_CONFIG],
if test "x$enable_static_libs" = "xyes"; then
AC_REQUIRE([PKG_PROG_PKG_CONFIG])
PKG_PROG_PKG_CONFIG()
test -z "$PKG_CONFIG" -a -z "$_libpcre2_dir_lib" && AC_MSG_ERROR([Not found pkg-config library])
test -z "$PKG_CONFIG" -a -z "$_libpcre2_lib_dir" && AC_MSG_ERROR([Not found pkg-config library])
m4_pattern_allow([^PKG_CONFIG_LIBDIR$])
fi
Expand All @@ -94,25 +94,25 @@ AC_DEFUN([LIBPCRE2_CHECK_CONFIG],
if test "x$enable_static" = "xyes"; then
LIBPCRE2_LIBS=" $LIBPCRE2_LIBS -lpthread"
elif test "x$enable_static_libs" = "xyes" -a -z "$PKG_CONFIG"; then
LIBPCRE2_LIBS="$_libpcre2_dir_lib/libpcre2-8.a"
LIBPCRE2_LIBS="$_libpcre2_lib_dir/libpcre2-8.a"
elif test "x$enable_static_libs" = "xyes"; then
test "x$static_linking_support" = "xno" -a -z "$_libpcre2_dir_lib" && AC_MSG_ERROR(["Compiler not support statically linked libs from default folders"])
test "x$static_linking_support" = "xno" -a -z "$_libpcre2_lib_dir" && AC_MSG_ERROR(["Compiler not support statically linked libs from default folders"])
if test -z "$_libpcre2_dir_lib"; then
if test -z "$_libpcre2_lib_dir"; then
PKG_CHECK_EXISTS(libpcre2-8,[
LIBPCRE2_LIBS=`$PKG_CONFIG --static --libs libpcre2-8`
],[
AC_MSG_ERROR([Not found libpcre2 package])
])
else
AC_RUN_LOG([PKG_CONFIG_LIBDIR="$_libpcre2_dir_lib/pkgconfig" $PKG_CONFIG --exists --print-errors libpcre2-8]) || AC_MSG_ERROR(["Not found libpcre2 package in $_libpcre2_dir/lib/pkgconfig"])
LIBPCRE2_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre2_dir_lib/pkgconfig" $PKG_CONFIG --static --libs libpcre2-8`
test -z "$LIBPCRE2_LIBS" && LIBPCRE2_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre2_dir_lib/pkgconfig" $PKG_CONFIG --libs libpcre2-8`
AC_RUN_LOG([PKG_CONFIG_LIBDIR="$_libpcre2_lib_dir/pkgconfig" $PKG_CONFIG --exists --print-errors libpcre2-8]) || AC_MSG_ERROR(["Not found libpcre2 package in $_libpcre2_dir/lib/pkgconfig"])
LIBPCRE2_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre2_lib_dir/pkgconfig" $PKG_CONFIG --static --libs libpcre2-8`
test -z "$LIBPCRE2_LIBS" && LIBPCRE2_LIBS=`PKG_CONFIG_LIBDIR="$_libpcre2_lib_dir/pkgconfig" $PKG_CONFIG --libs libpcre2-8`
fi
if test "x$static_linking_support" = "xno"; then
LIBPCRE2_LIBS=`echo "$LIBPCRE2_LIBS"|sed "s|-lpcre2-8|$_libpcre2_dir_lib/libpcre2-8.a|g"`
LIBPCRE2_LIBS=`echo "$LIBPCRE2_LIBS"|sed "s|-lpcre2-8|$_libpcre2_lib_dir/libpcre2-8.a|g"`
else
LIBPCRE2_LIBS=`echo "$LIBPCRE2_LIBS"|sed "s/-lpcre2-8/${static_linking_support}static -lpcre2-8 ${static_linking_support}dynamic/g"`
fi
Expand Down

0 comments on commit 5544631

Please sign in to comment.