Skip to content

PHPC-754 replace libmongoc-priv with libmongoc #357

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions config.m4
Original file line number Diff line number Diff line change
Expand Up @@ -365,11 +365,11 @@ PHP_ARG_WITH(libmongoc, whether to use system libmongoc,
if test "$PHP_LIBMONGOC" != "no"; then
AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
AC_MSG_CHECKING(for libmongoc)
if test -x "$PKG_CONFIG" && $PKG_CONFIG --exists libmongoc-1.0 && $PKG_CONFIG --exists libmongoc-priv; then
if test -x "$PKG_CONFIG" && $PKG_CONFIG --exists libmongoc-1.0; then
if $PKG_CONFIG libmongoc-1.0 --atleast-version 1.3.3; then
LIBMONGOC_INC=`$PKG_CONFIG libmongoc-priv --cflags`
LIBMONGOC_LIB=`$PKG_CONFIG libmongoc-priv --libs`
LIBMONGOC_VER=`$PKG_CONFIG libmongoc-priv --modversion`
LIBMONGOC_INC=`$PKG_CONFIG libmongoc-1.0 --cflags`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't --atleast-version 1.3.3 need to be changed to 1.4.0?

Are there similar changes required for the libbson package dependency? I expect they need to be kept in sync.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

libbson never had -priv, so no, thats not needed.
Good spot on --atleast-version 1.3.3 should be bumped to 1.4.0 if you decide on making that the minimum version.

We did not try to compile current php master against 1.3.3 as it currently declares as its minimum. I guess that is not correct today before or after this patch.
Before this patch, you cannot build against system mongoc 1.4, even though you do seem to require it.

LIBMONGOC_LIB=`$PKG_CONFIG libmongoc-1.0 --libs`
LIBMONGOC_VER=`$PKG_CONFIG libmongoc-1.0 --modversion`
AC_MSG_RESULT(version $LIBMONGOC_VER found)

else
Expand Down