Some unix headers for win32
This commit is contained in:
parent
09bbdcd95a
commit
39b82940d7
14
moo/mooutils/moowin32/mingw/fnmatch.h
Normal file
14
moo/mooutils/moowin32/mingw/fnmatch.h
Normal file
@ -0,0 +1,14 @@
|
||||
#ifndef MOO_FNMATCH_H
|
||||
#define MOO_FNMATCH_H
|
||||
|
||||
// #include "mooutils/mooutils-misc.h"
|
||||
// #include "mooutils/mooutils-fs.h"
|
||||
|
||||
#define fnmatch _moo_win32_fnmatch
|
||||
|
||||
int _moo_win32_fnmatch (const char *pattern,
|
||||
const char *string,
|
||||
int flags);
|
||||
|
||||
|
||||
#endif /* MOO_FNMATCH_H */
|
11
moo/mooutils/moowin32/mingw/netinet/in.h
Normal file
11
moo/mooutils/moowin32/mingw/netinet/in.h
Normal file
@ -0,0 +1,11 @@
|
||||
#ifndef MOO_NETINET_IN_H
|
||||
#define MOO_NETINET_IN_H
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
#define ntohl g_ntohl
|
||||
#define ntohs g_ntohs
|
||||
#define htonl g_htonl
|
||||
#define htons g_htons
|
||||
|
||||
#endif /* MOO_NETINET_IN_H */
|
22
moo/mooutils/moowin32/mingw/sys/mman.h
Normal file
22
moo/mooutils/moowin32/mingw/sys/mman.h
Normal file
@ -0,0 +1,22 @@
|
||||
#ifndef MOO_SYS_MMAN_H
|
||||
#define MOO_SYS_MMAN_H
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
#define mmap _moo_win32_mmap
|
||||
#define munmap _moo_win32_munmap
|
||||
|
||||
void *_moo_win32_mmap (gpointer start,
|
||||
guint64 length,
|
||||
int prot,
|
||||
int flags,
|
||||
int fd,
|
||||
guint64 offset);
|
||||
int _moo_win32_munmap (gpointer start,
|
||||
gsize length);
|
||||
|
||||
#define PROT_READ 1
|
||||
#define MAP_SHARED 1
|
||||
#define MAP_FAILED ((gpointer) -1)
|
||||
|
||||
#endif /* MOO_SYS_MMAN_H */
|
@ -22,11 +22,6 @@ AM_CFLAGS = \
|
||||
$(MOO_W_NO_SIGN_COMPARE)\
|
||||
$(MOO_W_NO_UNUSED)
|
||||
|
||||
EXTRA_DIST = \
|
||||
win32/fnmatch.h \
|
||||
win32/netinet/in.h \
|
||||
win32/sys/mman.h
|
||||
|
||||
if MOO_OS_MINGW
|
||||
AM_CFLAGS += -I$(srcdir)/win32 -DHAVE_MMAP
|
||||
AM_CFLAGS += -DHAVE_MMAP $(MOO_WIN32_CFLAGS)
|
||||
endif
|
||||
|
@ -1,4 +0,0 @@
|
||||
#ifndef FNMATCH_H
|
||||
#define FNMATCH_H
|
||||
#include <winsock2.h>
|
||||
#endif /* FNMATCH_H */
|
@ -1,4 +0,0 @@
|
||||
#ifndef NETINET_IN_H
|
||||
#define NETINET_IN_H
|
||||
#include "mooutils/mooutils-misc.h"
|
||||
#endif /* NETINET_IN_H */
|
@ -1,9 +0,0 @@
|
||||
#ifndef SYS_MMAN_H
|
||||
#define SYS_MMAN_H
|
||||
|
||||
#include "mooutils/mooutils-misc.h"
|
||||
|
||||
#define mmap _moo_win32_mmap
|
||||
#define munmap _moo_win32_munmap
|
||||
|
||||
#endif /* SYS_MMAN_H */
|
Loading…
x
Reference in New Issue
Block a user