OSX fixes and default compile

It should built on OSX 10.11 now
It will build bitmsghash.so by default
This commit is contained in:
mailchuck 2015-11-08 11:22:17 +01:00
parent 425667ee31
commit 15200356fe
Signed by untrusted user who does not match committer: PeterSurda
GPG Key ID: 0C5F50C0B5F37D87

View File

@ -1,14 +1,19 @@
all: UNAME_S := $(shell uname -s)
@echo "This compiles and tests the C PoW library, it's not necessary to run PyBitmessage" ifeq ($(UNAME_S),Darwin)
CCFLAGS += -I/usr/local/Cellar/openssl/1.0.2d_1/include
LDFLAGS += -L/usr/local/Cellar/openssl/1.0.2d_1/lib
endif
all: bitmsghash.so
powtest: powtest:
./testpow.py ./testpow.py
bitmsghash.so: bitmsghash.o bitmsghash.so: bitmsghash.o
g++ bitmsghash.o -shared -fPIC -lpthread -lcrypto -o bitmsghash.so g++ bitmsghash.o -shared -fPIC -lpthread -lcrypto $(LDFLAGS) -o bitmsghash.so
bitmsghash.o: bitmsghash.o:
g++ -Wall -O3 -march=native -fPIC -c bitmsghash.cpp g++ -Wall -O3 -march=native -fPIC $(CCFLAGS) -c bitmsghash.cpp
clean: clean:
rm -f bitmsghash.o bitmsghash.so rm -f bitmsghash.o bitmsghash.so