Skip to content
Snippets Groups Projects
  1. Nov 28, 2017
  2. Nov 20, 2017
  3. Nov 19, 2017
    • Corey Farrell's avatar
      Build: Fix OSX build issues. · b4f7f825
      Corey Farrell authored
      OSX does not support 'readlink -f' or 'sed -r'.  Replace readlink with
      the GNU make macro 'realpath'.  Replace sed with grep in one place, cut
      in the other.
      
      ASTERISK-27332
      
      Change-Id: I5d34ecca905384decb22ead45c913ae5e8aff748
      b4f7f825
  4. Nov 10, 2017
    • Corey Farrell's avatar
      Build: Make function constructor/destructor attributes mandatory. · e9f8b317
      Corey Farrell authored
      This change causes the configure script to fail if the C compiler does
      not support both function attributes constructor and destructor.  These
      were already required as modules cannot function without these attributes
      and Asterisk requires modules.
      
      This also has AST_GCC_ATTRIBUTE set a variable
      ax_cv_have_func_attribute_$1.  This is the same variable name used by
      autoconf-archive's AX_GCC_FUNC_ATTRIBUTE, used for the same purpose.
      
      Change-Id: Id68e8a1447f2a6d707c54b56350e7bfdb33fb663
      e9f8b317
  5. Nov 06, 2017
    • Corey Farrell's avatar
      configure: Add autoconf check for libopusfile. · 4013bfa5
      Corey Farrell authored
      This check is being added to make it easier for end-users of third party
      open source Opus modules.  This was removed by ASTERISK-26426 but only
      the module needed to be removed.
      
      Change-Id: I62b9cd0c4fa8a77596ab0e042948a643a1152677
      4013bfa5
  6. Oct 25, 2017
    • Corey Farrell's avatar
      Build System: Fix --disable-xmldoc option. · 5553adb8
      Corey Farrell authored
      The configure option to disable XML documentation does not currently
      work.  This patch makes it effective, but also causes an ABI change by
      removing the ast_xmldoc_* symbols.  Disabling xmldoc also prevents docs
      from being automatically generated, but they can still be manually
      generated with 'make doc/core-en_US.xml'.
      
      ASTERISK-26639
      
      Change-Id: Ifac562340c09f80c83e0203de098fcac93bf8c44
      5553adb8
  7. Oct 20, 2017
  8. Oct 18, 2017
  9. Oct 06, 2017
    • Matt Jordan's avatar
      res_corosync: Fix linking issue with Corosync 2.x · f4798faa
      Matt Jordan authored
      At some point in time in the history of Corosync (certainly within the
      2.x branch), the corosync_cfg_state_track function was removed.
      Unfortunately, the cfg library is only linked if this function is
      present. Without the cfg library being linked to res_corosync, loading
      of res_corosync will fail.
      
      This patch makes it so that detecting corosync's core libraries,
      determined by the COROSYNC external library checks, links both the cpg
      and cfg libraries with res_corosync.
      
      Change-Id: I674e9e1c8fea11c3bf81154aaa7c1fd43f945465
      f4798faa
  10. Aug 08, 2017
    • George Joseph's avatar
      Make --with-pjproject-bundled the default for Asterisk 15 · 305bd0d9
      George Joseph authored
      '--with-pjproject-bundled' is now the default when running
      ./configure. It can be disabled with '--without-pjproject-bundled'.
      
      To make building without an internet connection easier, a new
      ./configure option '--with-download-cache' was added that sets
      the cache for externals (like pjproject, the codecs and the DPMA),
      AND the sounds files.  It can also be specified as an environment
      variable named "AST_DOWNLOAD_CACHE".  The existing
      '--with-sounds-cache' option / SOUNDS_CACHE_DIR env variable and
      '--with-externals-cache' option / EXTERNALS_CACHE_DIR env variable
      remain and if specified, will override '--with-downloads-cache'.
      
      ASTERISK-27189
      
      Change-Id: Ifa9783fddf44aafadb060c9feba713dfa81d38ce
      305bd0d9
  11. Aug 03, 2017
    • Tzafrir Cohen's avatar
      Support GMIME 3.0 · 123c93a7
      Tzafrir Cohen authored
      Support building the Asterisk httpd with version 3.0 of gmime as
      well as earlier versions of that library.
      
      ASTERISK-27173
      
      Change-Id: I7e13dd05a3083ccb0df2dabf83110223f6a9fa8f
      123c93a7
  12. Aug 02, 2017
  13. Jul 20, 2017
  14. Jun 30, 2017
    • George Joseph's avatar
      pjproject_bundled: Allow passing configure options to bundled · f573e599
      George Joseph authored
      There wasn't any good way to pass options like --host or --build
      down to the pjproject configure which makes cross-compiling difficult.
      
      * Added a new PJPROJECT_CONFIGURE_OPTS environment variable which
        can be used to pass arbitrary options to pjproject configure.
      * Automatically set the pjproject configure --host and --build
        options to match those supplied for the asterisk configure.
      
      ASTERISK-27097 #close
      Reported-by: Kinsey Moore
      
      Change-Id: I5fa776e110262851173002a26ffe1172e4c35b2e
      f573e599
  15. Jun 08, 2017
    • David M. Lee's avatar
      CFLAGS for BIND8 support · fcb1a0d7
      David M. Lee authored
      Some systems (like macOS) require BIND_8_COMPAT to be defined so that
      the nameser libraries are, well, BIND8 compatible.
      
      Change-Id: If79fc27a64f90de1835b5aa3aadfa9be22bd16b0
      fcb1a0d7
  16. Jun 07, 2017
  17. May 26, 2017
    • Sean Bright's avatar
      res_srtp: Add support for libsrtp2 · 1f136fe8
      Sean Bright authored
      ASTERISK-25294 #close
      Reported by: Tzafrir Cohen
      
      ASTERISK-26976 #close
      Reported by: Alex
      
      Change-Id: I789b1c3d1ed31365bbd9339fa58ef36f48833c40
      1f136fe8
  18. Apr 24, 2017
    • Sean Bright's avatar
      core: Use eventfd for alert pipes on Linux when possible · 59203c51
      Sean Bright authored
      The primary win of switching to eventfd when possible is that it only
      uses a single file descriptor while pipe() will use two. This means for
      each bridge channel we're reducing the number of required file
      descriptors by 1, and - if you're using timerfd - we also now have 1
      less file descriptor per Asterisk channel.
      
      The API is not ideal (passing int arrays), but this is the cleanest
      approach I could come up with to maintain API/ABI.
      
      I've also removed what I believe to be an erroneous code block that
      checked the non-blocking flag on the pipe ends for each read. If the
      file descriptor is 'losing' its non-blocking mode, it is because of a
      bug somewhere else in our code.
      
      In my testing I haven't seen any measurable difference in performance.
      
      Change-Id: Iff0fb1573e7f7a187d5211ddc60aa8f3da3edb1d
      59203c51
  19. Apr 05, 2017
    • George Joseph's avatar
      pjproject_bundled: Add 3 upstream patches · 01e9eaf3
      George Joseph authored
      0035-r5572-svn-backport-dialog-transaction-deadlock.patch
      0036-r5573-svn-backport-ua-pjsua-transaction-deadlock.patch
      0037-r5576-svn-backport-session-timer-crash.patch
      
      Also removed the progress bar from wget download to stdout.
      
      ASTERISK-26905 #close
      Reported-by: Ross Beer
      
      Change-Id: I268fb3cf71a3bb24283ff0d24bd8b03239d81256
      01e9eaf3
  20. Apr 03, 2017
    • Corey Farrell's avatar
      core: Improve/simplify handling of required headers. · 8e360641
      Corey Farrell authored
      * Report failures if configure finds a required header is missing.
      * Deduplicate includes between asterisk.h, astmm.h and compat.h.
      * Unconditionally include headers in compat.h if required elsewhere.
      
      Change-Id: Ie67d0185ca71fbfb81c9bdfaebe46a49e3c56dc5
      8e360641
  21. Mar 30, 2017
    • Walter Doekes's avatar
      build: Fix deb build issues with fakeroot · a7d94f50
      Walter Doekes authored
      If DESTDIR is set, don't call ldconfig. Assume that DESTDIR is used to
      create a binary archive. The ldconfig call should be delegated to the
      archive postinst script. This fixes the case where fakeroot wraps 'make
      install' causing $EUID to be 0 even though it doesn't have permission to
      call ldconfig.
      
      The previous logic in configure.ac to detect and correct libdir
      has been removed as it was not completely accurate.  CentOS 64-bit
      users should again specifiy --libdir=/usr/lib64 when configuring
      to prevent install to /usr/lib.
      
      Updated Makefile:check-old-libdir to check for orphans in
      lib64 when installing to lib as well as orphans in lib when installing
      to lib64.
      
      Updated Makefile and main/Makefile uninstall targets to remove the
      orphans using the new logic.
      
      ASTERISK-26705
      
      Change-Id: I51739d4a03e60bff38be719b8d2ead0007afdd51
      a7d94f50
  22. Mar 27, 2017
  23. Mar 14, 2017
    • Matt Jordan's avatar
      configure: Don't use the progress bar with curl when downloading to stdout · 59130260
      Matt Jordan authored
      In some scenarios, such as when there may not be a terminal (such as
      inside a Docker container), curl will apparently direct the progress bar
      to stdout. This can cause extra data to be appended to a file curl'd
      down to stdout, resulting in md5 verification failures.
      
      This patch removes the progress bar, and tells curl to download the file
      silently.
      
      ASTERISK-26872 #close
      
      Change-Id: Ie860b020f627d4372b3e7ce9453de5faafeebe6c
      59130260
  24. Feb 23, 2017
    • George Joseph's avatar
      build: Execute ldconfig to build cache. (take two) · b0067bcf
      George Joseph authored
      On some platforms a multiarch approach is used for libraries.
      The build system does not take this into account and still
      places libraries into the lib directory if no --libdir is
      specified to configure. On initial startup this results in
      libasteriskssl.so not being found, as it is not in the multiarch
      lib directory.  To make matters worse, options were being passed
      to ldconfig on both Linux and FreeBSD that actually prevented
      the rebuild of the cache.
      
       * Fedora has a /usr/share/config.site that automatically tells
         autoconf to use /usr/lib64 but CentOS does not. This logic was
         copied to configure.ac and modified so systems like Ubuntu,
         which still use /usr/lib for 64-bit systems, aren't affected.
      
      Now that we have them in the correct directory...
      
      In order for the system loader to find libasteriskssl and
      libasteriskpj, one of 3 things has to happen...
      
        - The linker cache must be rebuilt including the directory
          where the libasterisk* libraries were installed.  Only root
          can rebuild the cache.  This was busted.
        - We have to link the asterisk binary with an rpath pointing
          to the directrory where the libasterisk* libraries were
          installed.  This makes things very complicated and will happen
          over the collective dead bodies of everyone who's had to
          package a distribution with an rpath.
        - Finally, you can start asterisk with LD_LIBRARY_PATH set to the
          directrory where the libasterisk* libraries were installed.
      
      There are no other options. So...
      
       * The invokation of ldconfig has been moved from main/Makefile
         to ASTTOPDIR/Makefile, the options have been removed, and
         DESTDIR/ASTLIBDIR appended.  If you aren't root, you will be
         warned after the "Asterisk Installation Compete" banner that
         you must re-run 'make install' as root, manually run
         'ldconfig DESTDIR/ASTLIBDIR' as root, or run asterisk with
         LD_LIBRARY_PATH.
      
      ASTERISK-26705
      
      Change-Id: I2a64b7c33a7d3e9bde20f47e3d3ab771977af982
      b0067bcf
    • frahaase's avatar
      Binaural synthesis (confbridge): Adds binaural synthesis to bridge_softmix. · 094c26aa
      frahaase authored
      Adds binaural synthesis to bridge_softmix (via convolution using libfftw3).
      Binaural synthesis is conducted at 48kHz.
      For a conference, only one spatial representation is rendered.
      The default rendering is applied for mono-capable channels.
      
      ASTERISK-26292
      
      Change-Id: Iecdb381b6adc17c961049658678f6219adae1ddf
      094c26aa
  25. Feb 17, 2017
  26. Feb 15, 2017
    • George Joseph's avatar
      res_pjsip_pubsub: Correctly implement persisted subscriptions · 4bdf5d32
      George Joseph authored
      This patch fixes 2 original issues and more that those 2 exposed.
      
      * When we send a NOTIFY, and the client either doesn't respond or
        responds with a non OK, pjproject only calls our
        pubsub_on_evsub_state callback, no others.  Since
        pubsub_on_evsub_state (which does the sub_tree cleanup) does not
        expect to be called back without the other callbacks being called
        first, it just returns leaving the sub_tree orphaned.  Now
        pubsub_on_evsub_state checks the event for PJSIP_EVENT_TSX_STATE
        which is what pjproject will set to tell us that it was the
        transaction that timed out or failed and not the subscription
        itself timing our or being terminated by the client. If is
        TSX_STATE, pubsub_on_evsub_state now does the proper cleanup
        regardless of the state of the subscription.
      
      * When a client renews a subscription, we don't update the
        persisted subscription with the new expires timestamp.  This causes
        subscription_persistence_recreate to prune the subscription if/when
        asterisk restarts.  Now, pubsub_on_rx_refresh calls
        subscription_persistence_update to apply the new expires timestamp.
        This exposed other issues however...
      
      * When creating a dialog from rdata (which sub_persistence_recreate
        does from the packet buffer) there must NOT be a tag on the To
        header (which there will be when a client refreshes a
        subscription).  If there is one, pjsip_dlg_create_uas will fail.
        To address this, subscription_persistence_update now accepts a flag
        that indicates that the original packet buffer must not be updated.
        New subscribes don't set the flag and renews do.  This makes sure
        that when the rdata is recreated on asterisk startup, it's done
        from the original subscribe packet which won't have the tag on To.
      
      * When creating a dialog from rdata, we were setting the dialog's
        remote (SUBSCRIBE) cseq to be the same as the local (NOTIFY) cseq.
        When the client tried to resubscribe after a restart with the
        correct cseq, we'd reject the request with an Invalid CSeq error.
      
      * The acts of creating a dialog and evsub by themselves when
        recreating a subscription does NOT restart pjproject's subscription
        timer.  The result was that even if we did correctly recreate the
        subscription, we never removed it if the client happened to go away
        or send a non-OK response to a NOTIFY.  However, there is no
        pjproject function exposed to just set the timer on an evsub that
        wasn't created by an incoming subscribe request.  To address this,
        we create our own timer using ast_sip_schedule_task.  This timer is
        used only for re-establishing subscriptions after a restart.
      
        An earlier approach was to add support for setting pjproject's
        timer (via a pjproject patch) and while that patch is still included
        here, we don't use that call at the moment.
      
      While addressing these issues, additional debugging was added and
      some existing messages made more useful.  A few formatting changes
      were also made to 'pjsip show scheduled tasks' to make displaying
      the subscription timers a little more friendly.
      
      ASTERISK-26696
      ASTERISK-26756
      
      Change-Id: I8c605fc1e3923f466a74db087d5ab6f90abce68e
      4bdf5d32
    • Dennis Guse's avatar
      Binaural synthesis (confbridge): Adds utils/conf_bridge_binaural_hrir_importer · b58de2fa
      Dennis Guse authored
      Adds the import tool for converting a HRIR database to hrirs.h
      
      ASTERISK-26292
      
      Change-Id: I51eb31b54c23ffd9b544bdc6a09d20c112c8a547
      b58de2fa
  27. Dec 16, 2016
    • David M. Lee's avatar
      configure: fix with-pjproject-bundled · 147b8e63
      David M. Lee authored
      The AC_ARG_WITH macro's shell variable is withval; not enableval. Purely
      coincidentally, the option would work when --enable-dev-mode is given.
      
      Also fixed a portability problem with bootstrap.sh, since -printf is not
      a portable option for find.
      
      Change-Id: I0f0e5b1a934b5af5737713834361e9c95b96b376
      147b8e63
  28. Nov 18, 2016
    • George Joseph's avatar
      pjproject_bundled: Improve reliability of pjproject download · d3f070c7
      George Joseph authored
      The download process now has a timeout which will cause wget to retry
      if it stops retrieving data for 5 seconds and fetch and curl to timeout
      if the whole retrieval take smore than 30 seconds.
      
      If the tarball retrieval works, the MD5SUM file is retrieved from
      the downloads site and the md5 checksum is verified.
      
      If either the tarball retrieval or MD5SUM retrieval fails, or the
      checksums don't match, the entire process is retried once.  If it
      fails again, any incomplete tarball is deleted.
      
      .DELETE_ON_ERROR: was also added to the Makefile.  Not only does
      this delete the tarball on failure, it till also delete corrupted
      library files from the pjproject source directory should they
      fail to build correctly.
      
      Tested all the way back to FreeBSD 9, CentOS 6, Debian 6 and
      Ubuntu 14.
      
      Change-Id: Iea7d33b96a31622ab1b6e54baebaf271959514e1
      d3f070c7
  29. Nov 16, 2016
  30. Nov 14, 2016
    • George Joseph's avatar
      cli: Fix ast_el_read_char to work with libedit >= 3.1 · 72da2ef9
      George Joseph authored
      Libedit 3.1 is not build with unicode on as a default and so the
      prototype for the el_gets callback changed from expecting a char buffer
      to accepting a wchar buffer.  If ast_el_read_char isn't changed,
      the cli reads garbage from teh terminal.
      
      Added a configure test for (*el_rfunc_t)(EditLine *, wchar_t *) and
      updated ast_el_read_char to use the HAVE_ define to detemrine whether
      to use char or wchar.
      
      ASTERISK-26592 #close
      
      Change-Id: I9099b46f68e06d0202ff80e53022a2b68b08871a
      72da2ef9
    • Tzafrir Cohen's avatar
      Add support for building RADIUS with radcli · 97a75e38
      Tzafrir Cohen authored
      Radcli is yet another RADIUS client library, generally compatible with
      freeradius and radiusclient-ng.
      
      This commit adds autoconf option for detecting it as well and changes
      cdr_radius and cel_radius to use its header file in that case.
      
      ASTERISK-26540 #close
      
      Change-Id: I271f0715406334874865ffbce0b354b3a2ca148f
      97a75e38
  31. Nov 10, 2016
    • George Joseph's avatar
      build: Fix default values for some SANITIZER options · edea4112
      George Joseph authored
      2 of the sanitizers didn't have default values so in systems that
      don't support sanitizers menuselect would spit out warnings.  They
      were harmless but confusing.  They've now been set to "0".
      
      Change-Id: I08dc495e3b83f1feac3160b421f538c375fc5d58
      edea4112
  32. Nov 02, 2016
    • Tzafrir Cohen's avatar
      autoconf: more variants for OSARCH linux-gnu · 6a99f007
      Tzafrir Cohen authored
      There are quite a few odd GNU/Linux platforms. Just call all of them
      linux-gnu.
      
      Specifically this fixes building the Debian platforms mips64el and x32.
      And maybe also others.
      
      ASTERISK-26546 #close
      
      Change-Id: I06ec4bd7f0ee1c84b6b24d81538223b07c4174b1
      6a99f007
  33. Oct 24, 2016
    • George Joseph's avatar
      pjproject_bundled: Fixed various build issues · 16c23b57
      George Joseph authored
      * CFLAGS is now properly set when using older gcc.
      * All third-party pjproject targets have been removed.  This fixes
        an issue with older libsrtp in some distros.
      * Manually removing the source directory now causes a rebuild.
      * EXTERNALS_CACHE_DIR is now properly checked.
      * Whitespace fixes.
      
      Change-Id: I98fec6847efc5602a9f41cb95096fd660a49fa60
      16c23b57
  34. Oct 14, 2016
    • Corey Farrell's avatar
      Fix issues with bundled pjproject cached download. · aa39a876
      Corey Farrell authored
      Previously when testing I had a preexisting makeopts in ASTTOPDIR.  The
      ordering of configure.ac causes --with-externals-cache to be processed
      after third-party configure.  In cases where the Asterisk clone is
      cleaned it would cause pjproject to be downloaded to /tmp.  This
      moves processing of the externals cache and sounds cache to happen
      before third-party configure.
      
      This also addresses a possible issue with the third-party Makefile.  If
      TMPDIR is set by the environment it would override the path given to
      --with-externals-cache.
      
      ASTERISK-26416
      
      Change-Id: Ifab7f35bfcd5a31a31a3a4353cc26a68c8c6592d
      aa39a876
  35. Oct 12, 2016
  36. Oct 10, 2016
    • George Joseph's avatar
      bundled_pjproject: Add tests for programs used by the Makefile, et al. · 5fb848ee
      George Joseph authored
      Added tests for bzip2, tar, patch, sed and nm to configure.ac.
      
      Set DOWNLOAD_TO_STDOUT to a working command line regardless of
      whether the download program is wget, curl or fetch.
      
      Added a 'configure.m4' file to the third-party directory which takes
      care of calling any third-party project setup.  Had to move some
      pjproject_bundled stuff up in configure.ac so it was called before
      the third-party configure macro.
      
      The pjproject tarball is now downloaded to the externals_cache_dir if
      it was specified on the ./configure command line
      
      Removed regeneration of the pjproject aconfigure file.  It was only
      needed for an old patch that no longer applies.
      
      Converted the tests for symbols to explicit tests since we know that
      they're now available in the bundled version.  Saves a little time
      during configure.
      
      ASTERISK-26416 #close
      Reported-by: Corey Farrell
      
      Change-Id: Id1d94251c0155f8dd41b7de7067f35cfbaafbb9b
      (cherry picked from commit e6b0053d)
      (cherry picked from commit a0d02f38)
      5fb848ee
Loading