Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
Salvatore Previti committed Aug 11, 2021
1 parent 4f339c5 commit ce3148d
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 23 deletions.
3 changes: 1 addition & 2 deletions binding.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@
"cflags_cc": ["-O3", "-std=c++14"],
"sources": [
"src/cpp/v8utils/v8utils.cpp",
"src/cpp/RoaringBitmap32.cpp",
"src/cpp/roaring.cpp",
"src/cpp/RoaringBitmap32.cpp"
],
"conditions": [
[
Expand Down
21 changes: 21 additions & 0 deletions src/cpp/RoaringBitmap32.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include <stdio.h>

#include "roaring.h"

#include "RoaringBitmap32.h"

#define MAX_SERIALIZATION_ARRAY_SIZE_IN_BYTES 0x00FFFFFF
Expand Down Expand Up @@ -1886,3 +1888,22 @@ void RoaringBitmap32BufferedIterator::WeakCallback(v8::WeakCallbackInfo<RoaringB
RoaringBitmap32BufferedIterator * p = info.GetParameter();
delete p;
}

/////////////////// ROARING LIBRARY ///////////////////

#define printf(...) ((void)0)
#define fprintf(...) ((void)0)

#if defined(__clang__)
# pragma clang diagnostic push
# pragma clang diagnostic ignored "-Wunused-variable"
#endif

#include "CRoaringUnityBuild/roaring.c"

#if defined(__clang__)
# pragma clang diagnostic pop
#endif

#undef printf
#undef fprintf
19 changes: 0 additions & 19 deletions src/cpp/roaring.cpp

This file was deleted.

4 changes: 2 additions & 2 deletions src/cpp/roaring.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#ifndef __ROARING__H__
#define __ROARING__H__
#ifndef __SP_ROARING__H__
#define __SP_ROARING__H__

#include <assert.h>
#include <stddef.h>
Expand Down

0 comments on commit ce3148d

Please sign in to comment.