Add libnazgul.h header

* Prevent loops & re-declarations in headers
This commit is contained in:
Glenn Y. Rolland 2019-09-16 17:15:55 +02:00
parent 96ab2bed39
commit 996d7158a8
3 changed files with 17 additions and 1 deletions

8
src/libnazgul.h Normal file
View file

@ -0,0 +1,8 @@
#ifndef _LIBNAZGUL
#define _LIBNAZGUL 1
#include "nzg_global.h"
#include "nzg_iface.h"
#include "nzg_proto.h"
#endif

View file

@ -6,6 +6,11 @@
#define MSGSPACE_DEFAULT_MODE 0600
typedef char * msgSpaceId;
typedef char * msgSpaceListElemId;
typedef char * msgSpacePoolDataId;
typedef char * msgSpacePoolId;
typedef char * msgSpaceQueueDataId;
typedef char * msgSpaceQueueId;
typedef struct MsgPool {
@ -16,7 +21,6 @@ typedef struct MsgSpace {
} msgSpace;
typedef char * msgSpaceListElemId;
typedef struct MsgSpaceListElem {
void * id;
@ -25,5 +29,6 @@ typedef struct MsgSpaceListElem {
msgSpaceListElemId next;
} * msgSpaceList, msgSpaceListElem;
#endif
/* */

View file

@ -1,3 +1,5 @@
#ifndef _NZG_PROTO
#define _NZG_PROTO 1
char **msgSpaceIdList(void);
@ -18,3 +20,4 @@ msgSpace *msgSpaceOpen(msgSpaceId spaceId);
void msgSpaceDelete(msgSpaceId spaceId);
msgSpaceId msgSp2nzgId(msgSpaceId spaceId);
#endif