Move OS defines to nmrpd.h

This commit is contained in:
Joseph C. Lehner 2016-02-02 12:14:28 +02:00
parent 129f30da7c
commit c53185dfbf
2 changed files with 12 additions and 11 deletions

View file

@ -5,17 +5,7 @@
#include <stdio.h>
#include <pcap.h>
#include "ethsock.h"
#if defined(_WIN32) || defined(_WIN64)
#define NMRPFLASH_WINDOWS
#elif defined(__linux__)
#define NMRPFLASH_LINUX
#elif defined(__APPLE__) && defined(__MACH__)
#define NMRPFLASH_OSX
#elif defined(__unix__)
#define NMRPFLASH_UNIX
#warning "nmrp-flash is not fully supported on your operating system"
#endif
#include "nmrpd.h"
#if defined(NMRPFLASH_WINDOWS)
#include <winsock2.h>

11
nmrpd.h
View file

@ -22,6 +22,17 @@
#include <stdint.h>
#include <stdbool.h>
#if defined(_WIN32) || defined(_WIN64)
#define NMRPFLASH_WINDOWS
#elif defined(__linux__)
#define NMRPFLASH_LINUX
#elif defined(__APPLE__) && defined(__MACH__)
#define NMRPFLASH_OSX
#elif defined(__unix__)
#define NMRPFLASH_UNIX
#warning "nmrp-flash is not fully supported on your operating system"
#endif
#define NMRPD_VERSION "0.9"
enum nmrp_op {