Add buildsys

FossilOrigin-Name: e5461ff8527693d6fead8581236f625852d55c2a3d7577e4eac219c7031e774f
This commit is contained in:
Jonathan Schleifer 2024-07-20 14:32:55 +00:00
parent acb5cb42f3
commit cbf07a9ef5
48 changed files with 6326 additions and 14 deletions

15
enet/Makefile Normal file
View file

@ -0,0 +1,15 @@
STATIC_LIB_NOINST = libenet.a
SRCS = callbacks.c \
host.c \
list.c \
memory.c \
packet.c \
peer.c \
protocol.c \
unix.c \
win32.c
include ../buildsys.mk
CPPFLAGS += -Iinclude

View file

@ -11,9 +11,9 @@ extern "C"
#endif
#include <stdlib.h>
#include <string.h>
#ifdef WIN32
#ifdef _WIN32
#include "enet/win32.h"
#else
#include "enet/unix.h"

View file

@ -1129,7 +1129,7 @@ enet_protocol_send_outgoing_commands (ENetHost * host, ENetEvent * event, int ch
enet_uint32 packetLoss = currentPeer -> packetsLost * ENET_PEER_PACKET_LOSS_SCALE / currentPeer -> packetsSent;
#ifdef ENET_DEBUG
#ifdef WIN32
#ifdef _WIN32
printf (
#else
fprintf (stderr,

View file

@ -2,7 +2,7 @@
@file unix.c
@brief ENet Unix system specific functions
*/
#ifndef WIN32
#ifndef _WIN32
#include <sys/types.h>
#include <sys/socket.h>
@ -25,7 +25,7 @@
#include <sys/poll.h>
#endif
#ifndef HAS_SOCKLEN_T
#if 0
typedef int socklen_t;
#endif

View file

@ -2,7 +2,7 @@
@file win32.c
@brief ENet Win32 system specific functions
*/
#ifdef WIN32
#ifdef _WIN32
#include <time.h>
#define ENET_BUILDING_LIB 1