Skip to content

Commit

Permalink
alloca.h breaks the build on openbsd/freebsd
Browse files Browse the repository at this point in the history
  • Loading branch information
zshipko committed Nov 12, 2014
1 parent 4417d08 commit 2b0ec2b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
4 changes: 3 additions & 1 deletion lib/3rdparty/sfmt/SFMT.c
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,9 @@ void sfmt_fill_array64(sfmt_t * sfmt, uint64_t *array, int size) {
* @param size the size of the array
* @param rsize the size of each record in the array
*/
#include <alloca.h>
#if !defined(__OpenBSD__) && !defined(__FreeBSD__)
#include <alloca.h>
#endif

void sfmt_genrand_shuffle(sfmt_t * sfmt, void *array, int size, int rsize) {
int i, j;
Expand Down
5 changes: 4 additions & 1 deletion lib/ccv.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,10 @@
#include <float.h>
#include <math.h>
#include <assert.h>
#include <alloca.h>

#if !defined(__OpenBSD__) && !defined(__FreeBSD__)
#include <alloca.h>
#endif

#define CCV_PI (3.141592653589793)
#define ccmalloc malloc
Expand Down

0 comments on commit 2b0ec2b

Please sign in to comment.