mirror of
https://codeberg.org/scip/pcp.git
synced 2025-12-17 12:00:56 +01:00
yet another try to fix #4, now tested on another linux system
This commit is contained in:
@@ -5,6 +5,22 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined __linux__ || defined __GNU__ || defined __GLIBC__
|
||||||
|
# ifndef _DEFAULT_SOURCE
|
||||||
|
# define _DEFAULT_SOURCE 1
|
||||||
|
# endif
|
||||||
|
#
|
||||||
|
# ifndef _XOPEN_SOURCE
|
||||||
|
# define _XOPEN_SOURCE 1
|
||||||
|
# endif
|
||||||
|
#
|
||||||
|
# ifndef _GNU_SOURCE
|
||||||
|
# define _GNU_SOURCE 1
|
||||||
|
# endif
|
||||||
|
#else
|
||||||
|
# define _BSD_SOURCE 1
|
||||||
|
#endif
|
||||||
|
|
||||||
#include "pcp/config.h"
|
#include "pcp/config.h"
|
||||||
#include "pcp/base85.h"
|
#include "pcp/base85.h"
|
||||||
#include "pcp/buffer.h"
|
#include "pcp/buffer.h"
|
||||||
|
|||||||
@@ -26,6 +26,22 @@
|
|||||||
#ifndef _HAVE_PCP_MGMT_H
|
#ifndef _HAVE_PCP_MGMT_H
|
||||||
#define _HAVE_PCP_MGMT_H
|
#define _HAVE_PCP_MGMT_H
|
||||||
|
|
||||||
|
#if defined __linux__ || defined __GNU__ || defined __GLIBC__
|
||||||
|
# ifndef _DEFAULT_SOURCE
|
||||||
|
# define _DEFAULT_SOURCE 1
|
||||||
|
# endif
|
||||||
|
#
|
||||||
|
# ifndef _XOPEN_SOURCE
|
||||||
|
# define _XOPEN_SOURCE 1
|
||||||
|
# endif
|
||||||
|
#
|
||||||
|
# ifndef _GNU_SOURCE
|
||||||
|
# define _GNU_SOURCE 1
|
||||||
|
# endif
|
||||||
|
#else
|
||||||
|
# define _BSD_SOURCE 1
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <sodium.h>
|
#include <sodium.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|||||||
@@ -23,12 +23,6 @@
|
|||||||
#ifndef _HAVE_PCP_H
|
#ifndef _HAVE_PCP_H
|
||||||
#define _HAVE_PCP_H
|
#define _HAVE_PCP_H
|
||||||
|
|
||||||
#if defined __linux__ || defined __GNU__ || defined __GLIBC__
|
|
||||||
#define _DEFAULT_SOURCE 1
|
|
||||||
#else
|
|
||||||
#define _BSD_SOURCE 1
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|||||||
Reference in New Issue
Block a user