-
Notifications
You must be signed in to change notification settings - Fork 12
/
Makefile
33 lines (26 loc) · 862 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
LIBS=-lpcre -lcrypto -lm -lpthread
CFLAGS=-g -O3 -Wall -pthread -std=gnu99
OBJS=vanitygen.o pattern.o util.o sha3.o hex.o
PROGS=vanity oclvanity
PLATFORM=$(shell uname -s)
ifeq ($(PLATFORM),Darwin)
OPENCL_LIBS=-framework OpenCL
LIBS+=-L/usr/local/opt/openssl/lib
CFLAGS+=-I/usr/local/opt/openssl/include
else ifeq ($(PLATFORM),NetBSD)
LIBS+=`pcre-config --libs`
CFLAGS+=`pcre-config --cflags`
else
OPENCL_LIBS=-lOpenCL
endif
most: vanity
all: $(PROGS)
vanity: vanitygen.o pattern.o util.o sha3.o hex.o
$(CC) $^ -o $@ $(CFLAGS) $(LIBS)
@objcopy --only-keep-debug $@ [email protected]
@objcopy --strip-debug --strip-unneeded $@
@objcopy [email protected] $@
oclvanity: oclvanitygen.o oclengine.o pattern.o util.o sha3.o hex.o
$(CC) $^ -o $@ $(CFLAGS) $(LIBS) $(OPENCL_LIBS)
clean:
rm -rf $(OBJS) $(PROGS) $(TESTS) bin obj *.o *.oclbin *.exe *.dbg