Skip to content

Commit

Permalink
bpo-45163: Restrict added libnetwork check to builds on Haiku. (GH-28729
Browse files Browse the repository at this point in the history
)

For example, without the guard the check could cause macOS
installer builds to fail to install on older supported macOS
releases where libnetwork is not available and is not needed
on any release.
  • Loading branch information
ned-deily committed Oct 5, 2021
1 parent bd627eb commit 0af08f3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
7 changes: 5 additions & 2 deletions configure
Expand Up @@ -10573,8 +10573,9 @@ if test "x$ac_cv_lib_socket_socket" = xyes; then :
fi
# SVR4 sockets

# Haiku system library
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lnetwork" >&5
case $ac_sys_system/$ac_sys_release in
Haiku*)
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lnetwork" >&5
$as_echo_n "checking for socket in -lnetwork... " >&6; }
if ${ac_cv_lib_network_socket+:} false; then :
$as_echo_n "(cached) " >&6
Expand Down Expand Up @@ -10614,6 +10615,8 @@ if test "x$ac_cv_lib_network_socket" = xyes; then :
LIBS="-lnetwork $LIBS"
fi

;;
esac

{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --with-libs" >&5
$as_echo_n "checking for --with-libs... " >&6; }
Expand Down
7 changes: 5 additions & 2 deletions configure.ac
Expand Up @@ -3099,8 +3099,11 @@ AC_SUBST(TZPATH)
AC_CHECK_LIB(nsl, t_open, [LIBS="-lnsl $LIBS"]) # SVR4
AC_CHECK_LIB(socket, socket, [LIBS="-lsocket $LIBS"], [], $LIBS) # SVR4 sockets

# Haiku system library
AC_CHECK_LIB(network, socket, [LIBS="-lnetwork $LIBS"], [], $LIBS)
case $ac_sys_system/$ac_sys_release in
Haiku*)
AC_CHECK_LIB(network, socket, [LIBS="-lnetwork $LIBS"], [], $LIBS)
;;
esac

AC_MSG_CHECKING(for --with-libs)
AC_ARG_WITH(libs,
Expand Down

0 comments on commit 0af08f3

Please sign in to comment.