Merge pull request #437 from micmac1/19-ast13-AST-2019-002-and-003
[feed/telephony.git] / net / asterisk-13.x / patches / 052-musl-libcap.patch
index 4df7f0c6d3cf449965cb06da1cada877aeb55892..1ea6118f3b4c0778a79201113ff7d0166e279d6d 100644 (file)
@@ -1,6 +1,6 @@
 --- a/configure.ac
 +++ b/configure.ac
-@@ -181,6 +181,9 @@ case "${host_os}" in
+@@ -175,6 +175,9 @@ case "${host_os}" in
       linux-gnu*)
       OSARCH=linux-gnu
       ;;
@@ -10,9 +10,9 @@
       kfreebsd*-gnu)
       OSARCH=kfreebsd-gnu
       ;;
-@@ -1402,9 +1405,11 @@ if test "${PBX_BFD}" = "0"; then
-   AST_EXT_LIB_CHECK([BFD], [bfd], [bfd_check_format], [bfd.h], [-ldl -liberty -lz])
- fi
+@@ -1509,9 +1512,11 @@ AST_EXT_LIB_CHECK([BFD], [bfd], [bfd_ope
+ # openSUSE requires -lz
+ AST_EXT_LIB_CHECK([BFD], [bfd], [bfd_openr], [bfd.h], [-ldl -liberty -lz])
  
 -if test "x${OSARCH}" = "xlinux-gnu" ; then
 +case "${OSARCH}" in
  AST_C_DEFINE_CHECK([DAHDI], [DAHDI_DEFAULT_MTU_MRU], [dahdi/user.h], [220])
 --- a/main/Makefile
 +++ b/main/Makefile
-@@ -47,7 +47,7 @@ AST_LIBS+=$(UUID_LIB)
+@@ -47,7 +47,7 @@ AST_LIBS+=$(AST_CLANG_BLOCKS_LIBS)
  AST_LIBS+=$(RT_LIB)
  AST_LIBS+=$(SYSTEMD_LIB)
  
 -ifneq ($(findstring $(OSARCH), linux-gnu uclinux linux-uclibc kfreebsd-gnu),)
 +ifneq ($(findstring $(OSARCH), linux-gnu uclinux linux-uclibc linux-musl kfreebsd-gnu),)
-   ifneq ($(findstring LOADABLE_MODULES,$(MENUSELECT_CFLAGS)),)
    AST_LIBS+=-ldl
-   endif
+   ifneq (x$(CAP_LIB),x)
+     AST_LIBS+=$(CAP_LIB)