Merge pull request #126 from doughdemon/master

Compile with musl libc
This commit is contained in:
zdenop 2015-10-31 16:41:01 +01:00
commit be7497be97
4 changed files with 8 additions and 1 deletions

View File

@ -19,6 +19,10 @@
// See the License for the specific language governing permissions and
// limitations under the License.
#ifdef HAVE_CONFIG_H
#include "config_auto.h"
#endif
#include <ctype.h>
#include <math.h>
#include <stdarg.h>
@ -34,7 +38,7 @@
#include "tprintf.h"
// workaround for "'off_t' was not declared in this scope" with -std=c++11
#if !defined(off_t) && !defined(__APPLE__) && !defined(__CYGWIN__)
#if !defined(HAVE_OFF_T)
typedef long off_t;
#endif // off_t

View File

@ -105,6 +105,7 @@ check_functions(functions_list)
set(types_list
"long long int"
off_t
mbstate_t
wchar_t
_Bool

View File

@ -413,6 +413,7 @@ AC_CHECK_FUNCS([getline])
AC_CHECK_TYPES(wchar_t,,,[#include "wchar.h"])
AC_CHECK_TYPES(long long int)
AC_CHECK_TYPES(off_t,,,[#include "sys/types.h"])
AC_CHECK_TYPES(mbstate_t,,,[#include "wchar.h"])
# ----------------------------------------

View File

@ -38,6 +38,7 @@ struct addrinfo {
#include <stdlib.h>
#include <string.h>
#include <netdb.h>
#include <sys/select.h>
#include <sys/socket.h>
#ifdef __linux__
#include <sys/prctl.h>