#ifndef _REBOUND_INTERNAL_H
#define _REBOUND_INTERNAL_H
#ifdef _WIN32
#define _NO_CRT_STDIO_INLINE
#include <WinSock2.h>
#define _WINSOCKAPI_
#include <windows.h>
typedef struct reb_timeval {
int64_t tv_sec;
int64_t tv_usec;
} reb_timeval;
int gettimeofday(struct reb_timeval * tp, struct timezone * tzp);
#include <stdarg.h>
int asprintf(char **strp, const char *fmt, ...);
int vasprintf(char **strp, const char *fmt, va_list ap);
int rand_r (unsigned int *seed);
void usleep(__int64 usec);
#include <io.h>
#define REB_STR_RED
#define REB_STR_RED_BOLD
#define REB_STR_YELLOW_BOLD
#define REB_STR_BOLD
#define REB_STR_GREEN
#define REB_STR_RESET
#else
#define reb_timeval timeval
#include <sys/time.h>
#include <unistd.h>
#include <pthread.h>
#define REB_STR_RED "\033[31m"
#define REB_STR_RED_BOLD "\033[1;31m"
#define REB_STR_YELLOW_BOLD "\033[1;33m"
#define REB_STR_BOLD "\033[1m"
#define REB_STR_GREEN "\033[32m"
#define REB_STR_RESET "\033[0m"
#endif
#ifndef GITHASH
#define GITHASH notavailable0000000000000000000000000001
#endif
#include <signal.h>
extern volatile sig_atomic_t reb_sigint;
void reb_sigint_handler(int signum);
REB_API extern const char* reb_build_str; REB_API extern const char* reb_version_str; REB_API extern const char* reb_githash_str; REB_API extern const char* reb_logo[26]; REB_API extern const unsigned char reb_favicon_png[]; REB_API extern const unsigned int reb_favicon_len;
REB_API extern const size_t reb_messages_max_N;
REB_API extern const uint32_t reb_string_size_max;
REB_API void reb_free(void* p);
REB_API int reb_pop_message(char** messages, char* const buf);
enum REB_MESSAGE_TYPE {
REB_MESSAGE_TYPE_INFO = 'i',
REB_MESSAGE_TYPE_ERROR = 'e',
REB_MESSAGE_TYPE_WARNING = 'w',
};
void reb_message(char*** messages, int save_messages, enum REB_MESSAGE_TYPE type, const char* const msg);
REB_API int reb_check_fp_contract();
REB_API void reb_omp_set_num_threads(int num_threads);
int reb_strcmp_ignore_whitespace(const char *s1, const char *s2);
REB_API char** reb_integrators_registered(); extern struct reb_integrator_configuration* reb_integrator_configurations_custom;
#endif