Jo-Philipp Wich [Fri, 26 Jun 2015 14:38:42 +0000 (16:38 +0200)]
open-plc-utils: fix musl and fortify source compatibility
- Include `poll.h` at the top of `ether/readpacket.c` to avoid nested
declaration errors caused by fortify source headers
- Add missing `sys/select.h` include to `serial/serial.c`
Jo-Philipp Wich [Fri, 26 Jun 2015 13:44:52 +0000 (15:44 +0200)]
opennhrp: fix musl compatibility
- Add `fcntl.h` to `nrhp/opennhrp.c` for `open()`, `O_WRONLY` etc.
- Add missing `sys/types.h` include to `nrhp/nrhp_common.h` to provide
required `u_int*_t` types under musl
Jo-Philipp Wich [Fri, 26 Jun 2015 12:51:16 +0000 (14:51 +0200)]
postfix: fix musl compatibility
The current package patches `makedefs` to probe for the existance
of the `nsl` and `resolv` libraries but uses the wrong variables
for the prefix, leading to `makedefs` probing the host directories,
not the staging dir ones.
Replace `$PKG_BUILD_DIR` with `$STAGING_DIR` to perform the library
tests in the correct directory.
Fixes the following error spotted by doing test builds against musl
which does not provide a `libnsl`:
.../mips-openwrt-linux-musl/bin/ld: cannot find -lnsl
collect2: error: ld returned 1 exit status
make: *** [master] Error 1
Jo-Philipp Wich [Fri, 26 Jun 2015 09:51:23 +0000 (11:51 +0200)]
pthsem: fix musl and fortify source compatibility
This commit addresses two issues encountered while building pthsem for
x86_64/musl:
1) Autoconf incorrectly assumes a broken Glibc and thus falls back
to Linux compatibility code which runs into an unsupported
platform error with musl libc. Since musl provides a proper
implementation of `sigaltstack(2)`, force configure to use the
POSIX compliant code when musl libc is used.
2) The `pth_syscall.c` file undefines various libc function names
which breaks the indirection set up by fortify-source headers,
therefore forcibly disable fortify source in the OpenWrt Makefile.
Daniel Golle [Thu, 4 Jun 2015 10:52:31 +0000 (12:52 +0200)]
libmicrohttpd: get rid of OpenSSL dependency
Depending on both, GnuTLS and OpenSSL doesn't make sense, we should
use either TLS implementation but not both. Use GnuTLS for now and
get rid of OpenSSL dependency by explicitely telling the package's
build-system to do so using CONFIGURE_ARGS.
If future uses of libmicrohttpd require OpenSSL, it probably makes
most sense to build several variants of the package, i.e.
libmicrohttpd-openssl as well as libmicrohttpd-gnutls. As with most
packages making use of any TLS implementation, these are build-time
decissions resulting in conflicting variants of the same package
which cannot be installed simultanously.
The shadowsocks source uses the name `encrypt` which is already reserved by
the `unistd.h` header. Rename the local `encrypt` and `decrypt` functions to
`crypto_encrypt` and `crypto_decrypt` in order to prevent clashes with the
standard headers.
Fixes the following build error oberserved on the buildbot:
In file included from client.c:19:0:
crypto.h:18:5: error: conflicting types for 'encrypt'
int encrypt(int sockfd, struct link *ln);
^
In file included from .../staging_dir/toolchain-mipsel_mips32_gcc-4.8-linaro_musl-1.1.10/include/fortify/unistd.h:20:0,
from client.c:12:
.../staging_dir/toolchain-mipsel_mips32_gcc-4.8-linaro_musl-1.1.10/include/unistd.h:145:6: note: previous declaration of 'encrypt' was here
void encrypt(char *, int);
^
make[3]: *** [sslocal] Error 1
Jo-Philipp Wich [Thu, 25 Jun 2015 15:26:37 +0000 (17:26 +0200)]
snort: fix build with CONFIG_PKG_CHECK_FORMAT_SECURITY
The configure script incorrectly mangles `CFLAGS` by attempting to remove
`-Werror` from it, thus turning `-Werror=format-security` into just
`=format-security` which will cause subsequent autoconf tests to fail.
Patch out the custom `CFLAGS` mangling to fix the build.
Jo-Philipp Wich [Thu, 25 Jun 2015 14:42:52 +0000 (16:42 +0200)]
squid: fix musl compatibility
Change `sys/signal.h` include to just `signal.h`. The build otherwise fails
due to `-Werror` with the following message:
In file included from rfcnb-io.c:43:0:
.../staging_dir/toolchain-mipsel_mips32_gcc-4.8-linaro_musl-1.1.10/include/sys/signal.h:1:2: error: #warning redirecting incorrect #include <sys/signal.h> to <signal.h> [-Werror=cpp]
#warning redirecting incorrect #include <sys/signal.h> to <signal.h>
^
cc1: all warnings being treated as errors
Jo-Philipp Wich [Thu, 25 Jun 2015 14:30:32 +0000 (16:30 +0200)]
sstp-client: fix musl compatibility
- Ship a `net/ppp_defs.h` replacement header since musl does not provide one
but `pppd/pppd.h` provided by pppd is needing it.
- Add missing `sys/types.h` includes
Jo-Philipp Wich [Thu, 25 Jun 2015 10:54:05 +0000 (12:54 +0200)]
c-ares: fix build with CONFIG_PKG_FORTIFY_SOURCE*
When fortify source is enabled, the c-ares configure script will abort with:
configure: CFLAGS error: CFLAGS may only be used to specify C compiler flags, not macro definitions. Use CPPFLAGS for: -D_FORTIFY_SOURCE=1
Change the OpenWrt Makefile to move any -D flags from TARGET_CFLAGS to
TARGET_CPPFLAGS in order to satisfy `configure`.
Nicolas Thill [Mon, 22 Jun 2015 23:06:36 +0000 (01:06 +0200)]
erlang: fix musl compatibility
gethostbyname_r is available when _GNU_SOURCE is defined, add a patch to check for it instead of __GLIBC__, build with -D_GNU_SOURCE, bump release number
Derek LaHousse [Fri, 19 Jun 2015 16:16:31 +0000 (12:16 -0400)]
ipsec-tools: Make compatible with musl
Based on changes at http://git.alpinelinux.org/cgit/aports/plain/main/ipsec-tools/musl-cdefs.patch
Removed references to "login" and "logout" functions, as musl utmp
doesn't.
Bump PKG_RELEASE
Karl Palsson [Sun, 21 Jun 2015 17:41:15 +0000 (17:41 +0000)]
libev: Update to 4.20
Minor release, changes from upstream:
- prefer noexcept over throw () with C++ 11.
- update ecb.h due to incompatibilities with c11.
- fix a potential aliasing issue when reading and writing
watcher callbacks.
Daniel Golle [Sun, 21 Jun 2015 11:53:07 +0000 (13:53 +0200)]
i2c-tools: import from oldpackages
- license and maintainer added
- bumped to recent release source tarball instead of SVN source
- add archive.org mirror to work-around the lm-sensors.org domain
currently being broken...
Prefer linux/if_ether.h over netinet/if_ether.h if available since the
musl libc if_ether.h header does not allow mixing with kernel headers,
it will result in a struct ethhdr redefinition error.