Change HAS_NASM to USE_NASM. The makefile does not etect it automatically

pull/392/head
Jeffrey Walton 2017-03-14 18:38:37 -04:00
parent d8570a3435
commit 354502d59d
No known key found for this signature in database
GPG Key ID: B36AB348921B1838
2 changed files with 7 additions and 7 deletions

View File

@ -55,7 +55,7 @@ HAS_SOLIB_VERSION := $(IS_LINUX)
IS_X32 ?= 0
# Set to 1 if you used NASM to build rdrand-{x86|x32|x64}
HAS_NASM ?= 0
USE_NASM ?= 0
# Fixup for X32
ifeq ($(IS_X32),1)
@ -470,7 +470,7 @@ endif
# List cryptlib.cpp first, then cpu.cpp, then integer.cpp to tame C++ static initialization problems.
OBJS := $(SRCS:.cpp=.o)
ifeq ($(HAS_NASM),1)
ifeq ($(USE_NASM),1)
ifeq ($(IS_X64),1)
OBJS += rdrand-x64.o
else ifeq ($(IS_X32),1)
@ -766,7 +766,7 @@ endif
endif
# Run rdrand-nasm.sh to create the object files
ifeq ($(HAS_NASM),1)
ifeq ($(USE_NASM),1)
rdrand.o: rdrand.h rdrand.cpp rdrand.S
$(CXX) $(strip $(CXXFLAGS)) -DNASM_RDRAND_ASM_AVAILABLE=1 -DNASM_RDSEED_ASM_AVAILABLE=1 -c rdrand.cpp
rdrand-x86.o: ;

View File

@ -25,10 +25,10 @@
/////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////
// For Linux, install NASM, run rdrand-nasm.asm, add the apppropriate
// object file to the Makefile's LIBOBJS (rdrand-x{86|32|64}.o). After
// that, define these. They are not enabled by default because they
// are not easy to cut-in in the Makefile.
// For Linux, NASM is optional. Run rdrand-nasm.sh, and then make
// with "USE_NASM" like so: USE_NASM=1 make -j 4. The makefile
// will add the appropriate defines when building rdrand.cpp,
// and add the appropriate object file during link.
#if 0
#define NASM_RDRAND_ASM_AVAILABLE 1