diff options
-rw-r--r-- | Makefile | 9 | ||||
-rw-r--r-- | readme.md | 2 | ||||
-rw-r--r-- | sample/large.cpp | 2 |
3 files changed, 8 insertions, 5 deletions
@@ -13,6 +13,9 @@ ifeq ($(CPU),x86-64) endif SAMPLE_SRC=bench.cpp ecdh.cpp random.cpp rawbench.cpp vote.cpp pairing.cpp large.cpp +ifneq ($(MCL_MAX_OP_BIT_SIZE),) + CFLAGS+=-DMCL_MAX_OP_BIT_SIZE=$(MCL_MAX_OP_BIT_SIZE) +endif ################################################################## MCL_LIB=$(LIB_DIR)/libmcl.a all: $(MCL_LIB) @@ -27,9 +30,9 @@ endif ASM_OBJ=$(OBJ_DIR)/$(CPU).o LIB_OBJ=$(OBJ_DIR)/fp.o FUNC_LIST=src/func.list -USE_LLVM?=0 -ifeq ($(USE_LLVM),1) - CFLAGS+=-DMCL_USE_LLVM +MCL_USE_LLVM?=0 +ifeq ($(MCL_USE_LLVM),1) + CFLAGS+=-DMCL_USE_LLVM=1 LIB_OBJ+=$(ASM_OBJ) endif LLVM_SRC=src/base$(BIT).ll @@ -47,7 +47,7 @@ msbuild /p:Configuration=Release ### Build with LLVM
require clang 3.8 or over.
```
-make USE_LLVM=1 LLVM_VER=-3.8
+make MCL_USE_LLVM=1 LLVM_VER=-3.8
```
# License
diff --git a/sample/large.cpp b/sample/large.cpp index eb8d4e5..d7a627c 100644 --- a/sample/large.cpp +++ b/sample/large.cpp @@ -1,6 +1,6 @@ /* large prime sample for 64-bit arch - make USE_LLVM=1 CFLAGS_USER="-DMCL_MAX_OP_BIT_SIZE=768" + make MCL_USE_LLVM=1 MCL_MAX_OP_BIT_SIZE=768 */ #include <mcl/fp.hpp> #include <cybozu/benchmark.hpp> |