package/asterisk: new package
Asterisk: the flagship of telephony on Linux. These are the lines of
code whose continuous mission is to power small and large enterprises
telephony systems, to boldly provide IP PBX where no one has done so
before.
But it is a hell to get compiled... :-(
For starters, it needs a host tool, menuselect, to prepare its build
configuration. Unfortunately, the way it handles menuselect does not
apply very well for cross-compilation: the main ./configure calls out to
menuselect's own ./configure, and of course that runs with the same
environement, which is wrong for cross-compilation (because of variables
like CC, CFLAGS and the likes).
Furthermore, the paths to menuselect are imbricated about everywhere in
the main Makefile, so making it find menuselect in PATH is a lost cause.
Instead, we just patch-out the handling of menuselect, build it as the
host variant and copy it in place.
Now, asterisk wants to install a default set of sound files (for
answering machine stuff, I guess). They come come pre-bundled in the
official archive [0], but the buildsystem will want to download (at
install time) the sha1 files for each sound archive, to validate that
said archive is correct. However, the download is done via plain http,
so it still risks an MITM attack. And for Buildroot, it is not always
possible to download at install time, so we patch-out the sha1 check.
[0] http://downloads.asterisk.org/pub/telephony/asterisk/releases/
The official archive contains the sound archives plus a full set of
documentation. This makes it very big. Unfortunately, the hosting site
is rather slow, topping at about ~204kbps. So we get the archive from
the official mirror on Github. But that archive is missing the sound
archives, so we download them separately.
Some tests, like the crypt() one, are broken and could not have ever
possibly worked at all. Worse, the FFmpeg test is looking for headers
that FFmpeg removed more than 10 years ago and are virtually no longer
available in any distro. So, FFmpeg support is definitely not tested
by upstream and can't possibly work at all. Finally, trying to run
test-code does not work in cross-compilation.
As a final stroke of genius, asterisk checks for the re-entrant variant
of res_ninit(), and concludes that all such functions are available,
including res_nsearch(). Uclibc-ng has the former but not the latter, so
the build fails. Since there is no cache variable for that check, we
can't pre-feed that result to configure, and fixing it is a bigger
endeavour. So we make asterisk depend on glibc for now, until someone
is brave enough to fix it.
Almost all features are disabled for now. Support for additional
features will be added in subsequent patches now that we have a working
base.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Romain Naour <romain.naour@openwide.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
[Arnout:
- make libilbc a mandatory dependency instead of using the bundled one;
- add license, license files, and license file hashes;
- minor spelling corrections;
- remove redundant trailing backslash reported by check-package;
- rewrap help text to 72 columns instead of 68]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
fixup
2017-09-09 23:39:07 +02:00
|
|
|
config BR2_PACKAGE_ASTERISK
|
|
|
|
bool "asterisk"
|
|
|
|
depends on BR2_INSTALL_LIBSTDCPP
|
2018-10-14 11:01:55 +02:00
|
|
|
depends on !BR2_STATIC_LIBS # dlfcn.h
|
package/asterisk: enable for uclibc toolchains
This patch extends the configure checks for re-entrant resolver
functions to fix uclibc builds.
Quoting Yann:
http://lists.busybox.net/pipermail/buildroot/2017-September/203004.html
"As a final stroke of genius, asterisk checks for the re-entrant variant
of res_ninit(), and concludes that all such functions are available,
including res_nsearch(). Uclibc-ng has the former but not the latter, so
the build fails. Since there is no cache variable for that check, we
can't pre-feed that result to configure, and fixing it is a bigger
endeavour. So we make asterisk depend on glibc for now, until someone
is brave enough to fix it."
Musl builds are still broken:
output/build/asterisk-16.0.0/include/asterisk/astmm.h:165:35:
error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘->’ token
Do_not_use_calloc__use_ast_calloc->fail(a, b)
output/build/asterisk-16.0.0/include/asterisk/astmm.h:169:77:
error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘->’ token
Do_not_use_free__use_ast_free_or_ast_std_free_for_remotely_allocated_memory->fail(a)
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-10-14 11:01:56 +02:00
|
|
|
depends on !BR2_TOOLCHAIN_USES_MUSL
|
2018-10-14 11:01:55 +02:00
|
|
|
depends on BR2_USE_MMU # libedit
|
2019-01-11 18:31:58 +01:00
|
|
|
depends on BR2_TOOLCHAIN_HAS_THREADS
|
2018-10-14 11:01:55 +02:00
|
|
|
depends on BR2_USE_WCHAR # libedit
|
package/asterisk: new package
Asterisk: the flagship of telephony on Linux. These are the lines of
code whose continuous mission is to power small and large enterprises
telephony systems, to boldly provide IP PBX where no one has done so
before.
But it is a hell to get compiled... :-(
For starters, it needs a host tool, menuselect, to prepare its build
configuration. Unfortunately, the way it handles menuselect does not
apply very well for cross-compilation: the main ./configure calls out to
menuselect's own ./configure, and of course that runs with the same
environement, which is wrong for cross-compilation (because of variables
like CC, CFLAGS and the likes).
Furthermore, the paths to menuselect are imbricated about everywhere in
the main Makefile, so making it find menuselect in PATH is a lost cause.
Instead, we just patch-out the handling of menuselect, build it as the
host variant and copy it in place.
Now, asterisk wants to install a default set of sound files (for
answering machine stuff, I guess). They come come pre-bundled in the
official archive [0], but the buildsystem will want to download (at
install time) the sha1 files for each sound archive, to validate that
said archive is correct. However, the download is done via plain http,
so it still risks an MITM attack. And for Buildroot, it is not always
possible to download at install time, so we patch-out the sha1 check.
[0] http://downloads.asterisk.org/pub/telephony/asterisk/releases/
The official archive contains the sound archives plus a full set of
documentation. This makes it very big. Unfortunately, the hosting site
is rather slow, topping at about ~204kbps. So we get the archive from
the official mirror on Github. But that archive is missing the sound
archives, so we download them separately.
Some tests, like the crypt() one, are broken and could not have ever
possibly worked at all. Worse, the FFmpeg test is looking for headers
that FFmpeg removed more than 10 years ago and are virtually no longer
available in any distro. So, FFmpeg support is definitely not tested
by upstream and can't possibly work at all. Finally, trying to run
test-code does not work in cross-compilation.
As a final stroke of genius, asterisk checks for the re-entrant variant
of res_ninit(), and concludes that all such functions are available,
including res_nsearch(). Uclibc-ng has the former but not the latter, so
the build fails. Since there is no cache variable for that check, we
can't pre-feed that result to configure, and fixing it is a bigger
endeavour. So we make asterisk depend on glibc for now, until someone
is brave enough to fix it.
Almost all features are disabled for now. Support for additional
features will be added in subsequent patches now that we have a working
base.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Romain Naour <romain.naour@openwide.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
[Arnout:
- make libilbc a mandatory dependency instead of using the bundled one;
- add license, license files, and license file hashes;
- minor spelling corrections;
- remove redundant trailing backslash reported by check-package;
- rewrap help text to 72 columns instead of 68]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
fixup
2017-09-09 23:39:07 +02:00
|
|
|
select BR2_PACKAGE_JANSSON
|
|
|
|
select BR2_PACKAGE_LIBCURL
|
2018-10-14 11:01:55 +02:00
|
|
|
select BR2_PACKAGE_LIBEDIT
|
package/asterisk: new package
Asterisk: the flagship of telephony on Linux. These are the lines of
code whose continuous mission is to power small and large enterprises
telephony systems, to boldly provide IP PBX where no one has done so
before.
But it is a hell to get compiled... :-(
For starters, it needs a host tool, menuselect, to prepare its build
configuration. Unfortunately, the way it handles menuselect does not
apply very well for cross-compilation: the main ./configure calls out to
menuselect's own ./configure, and of course that runs with the same
environement, which is wrong for cross-compilation (because of variables
like CC, CFLAGS and the likes).
Furthermore, the paths to menuselect are imbricated about everywhere in
the main Makefile, so making it find menuselect in PATH is a lost cause.
Instead, we just patch-out the handling of menuselect, build it as the
host variant and copy it in place.
Now, asterisk wants to install a default set of sound files (for
answering machine stuff, I guess). They come come pre-bundled in the
official archive [0], but the buildsystem will want to download (at
install time) the sha1 files for each sound archive, to validate that
said archive is correct. However, the download is done via plain http,
so it still risks an MITM attack. And for Buildroot, it is not always
possible to download at install time, so we patch-out the sha1 check.
[0] http://downloads.asterisk.org/pub/telephony/asterisk/releases/
The official archive contains the sound archives plus a full set of
documentation. This makes it very big. Unfortunately, the hosting site
is rather slow, topping at about ~204kbps. So we get the archive from
the official mirror on Github. But that archive is missing the sound
archives, so we download them separately.
Some tests, like the crypt() one, are broken and could not have ever
possibly worked at all. Worse, the FFmpeg test is looking for headers
that FFmpeg removed more than 10 years ago and are virtually no longer
available in any distro. So, FFmpeg support is definitely not tested
by upstream and can't possibly work at all. Finally, trying to run
test-code does not work in cross-compilation.
As a final stroke of genius, asterisk checks for the re-entrant variant
of res_ninit(), and concludes that all such functions are available,
including res_nsearch(). Uclibc-ng has the former but not the latter, so
the build fails. Since there is no cache variable for that check, we
can't pre-feed that result to configure, and fixing it is a bigger
endeavour. So we make asterisk depend on glibc for now, until someone
is brave enough to fix it.
Almost all features are disabled for now. Support for additional
features will be added in subsequent patches now that we have a working
base.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Romain Naour <romain.naour@openwide.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
[Arnout:
- make libilbc a mandatory dependency instead of using the bundled one;
- add license, license files, and license file hashes;
- minor spelling corrections;
- remove redundant trailing backslash reported by check-package;
- rewrap help text to 72 columns instead of 68]
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
fixup
2017-09-09 23:39:07 +02:00
|
|
|
select BR2_PACKAGE_LIBILBC
|
|
|
|
select BR2_PACKAGE_LIBXML2
|
|
|
|
select BR2_PACKAGE_SQLITE
|
|
|
|
select BR2_PACKAGE_UTIL_LINUX
|
|
|
|
select BR2_PACKAGE_UTIL_LINUX_LIBUUID
|
|
|
|
help
|
|
|
|
Asterisk is an open source framework for building
|
|
|
|
communications applications. Asterisk turns an ordinary
|
|
|
|
computer into a communications server. Asterisk powers IP PBX
|
|
|
|
systems, VoIP gateways, conference servers and other custom
|
|
|
|
solutions. It is used by small businesses, large businesses,
|
|
|
|
call centers, carriers and government agencies, worldwide.
|
|
|
|
Asterisk is free and open source.
|
|
|
|
|
|
|
|
http://www.asterisk.org/
|
|
|
|
|
2019-01-11 18:31:58 +01:00
|
|
|
comment "asterisk needs a glibc or uClibc toolchain w/ C++, dynamic library, threads, wchar"
|
2018-10-14 11:01:55 +02:00
|
|
|
depends on BR2_USE_MMU
|
package/asterisk: enable for uclibc toolchains
This patch extends the configure checks for re-entrant resolver
functions to fix uclibc builds.
Quoting Yann:
http://lists.busybox.net/pipermail/buildroot/2017-September/203004.html
"As a final stroke of genius, asterisk checks for the re-entrant variant
of res_ninit(), and concludes that all such functions are available,
including res_nsearch(). Uclibc-ng has the former but not the latter, so
the build fails. Since there is no cache variable for that check, we
can't pre-feed that result to configure, and fixing it is a bigger
endeavour. So we make asterisk depend on glibc for now, until someone
is brave enough to fix it."
Musl builds are still broken:
output/build/asterisk-16.0.0/include/asterisk/astmm.h:165:35:
error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘->’ token
Do_not_use_calloc__use_ast_calloc->fail(a, b)
output/build/asterisk-16.0.0/include/asterisk/astmm.h:169:77:
error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘->’ token
Do_not_use_free__use_ast_free_or_ast_std_free_for_remotely_allocated_memory->fail(a)
Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2018-10-14 11:01:56 +02:00
|
|
|
depends on BR2_TOOLCHAIN_USES_MUSL || !BR2_INSTALL_LIBSTDCPP \
|
2019-01-11 18:31:58 +01:00
|
|
|
|| BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HAS_THREADS \
|
|
|
|
|| !BR2_USE_WCHAR
|