Use rand/srand instead of random/srandom on Windows

random/srandom are not C standard functions.
Use standard rand/srand on Windows.
This commit is contained in:
مهدي شينون (Mehdi Chinoune) 2024-06-11 16:18:53 +01:00
parent 83f7bf651c
commit a16a3d5115
2 changed files with 8 additions and 0 deletions

View File

@ -8,6 +8,10 @@
#define nmax 30
#ifdef _WIN32
#define random rand
#endif
extern void dgemv_(const char *, const int *, const int *, const double *,
double *, const int *, double *, const int *, const double *, double *,
const int *);

View File

@ -9,6 +9,10 @@
#include "pbecor.h"
#ifdef _WIN32
#define srandom srand
#endif
// evaluate bee exchange energy and its derivatives de/drho and ( de/d|grad rho| ) / |grad rho|
#pragma acc routine seq
void beefx_(double *r, double *g, double *e, double *dr, double *dg, int *addlda)