Skip to content
This repository was archived by the owner on Jan 30, 2023. It is now read-only.

Commit 285de31

Browse files
committed
spkg-config for pcre
1 parent d765ee2 commit 285de31

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

build/pkgs/pcre/spkg-configure.m4

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
SAGE_SPKG_CONFIGURE([pcre], [
2+
AC_REQUIRE([SAGE_SPKG_CONFIGURE_BZIP2])
3+
AC_MSG_CHECKING([Installing bzip2? ])
4+
if test x$sage_spkg_install_bzip2 = xyes; then
5+
AC_MSG_RESULT([Yes. Install pcre as well.])
6+
sage_spkg_install_pcre=yes
7+
else
8+
AC_MSG_RESULT([No.])
9+
dnl First try checking for pcre with pkg-config
10+
PKG_CHECK_MODULES([PCRE], [libpcre >= 8.39 libpcreposix libpcrecpp], [], [
11+
dnl Fallback to manually grubbing around for headers and libs
12+
AC_CHECK_HEADERS([pcre.h pcrecpp.h pcreposix.h], [
13+
AC_SEARCH_LIBS([regexec], [pcreposix], [], [sage_spkg_install_pcre=yes])],
14+
[sage_spkg_install_pcre=yes])
15+
])
16+
fi
17+
])
18+

0 commit comments

Comments
 (0)