From ca372318b39302ca6bccebcd6e6687173889e6ec Mon Sep 17 00:00:00 2001 From: Erik Henriksson Date: Mon, 1 Aug 2011 19:22:49 +0200 Subject: [PATCH] *Added makefile for osx *Added INSTALL file *Changed one include for running oclvanitygen on osx *Added some files to .gitignore --- INSTALL | 7 +++++++ Makefile.osx | 16 ++++++++++++++++ oclvanitygen.c | 7 +++++++ 3 files changed, 30 insertions(+) create mode 100644 INSTALL create mode 100644 Makefile.osx diff --git a/INSTALL b/INSTALL new file mode 100644 index 0000000..a818d6b --- /dev/null +++ b/INSTALL @@ -0,0 +1,7 @@ +Linux: +make vanitygen +make oclvanitygen + +OSX: +make -f Makefile.osx vanitygen +make -f Makefile.osx vanitygen \ No newline at end of file diff --git a/Makefile.osx b/Makefile.osx new file mode 100644 index 0000000..a16ddda --- /dev/null +++ b/Makefile.osx @@ -0,0 +1,16 @@ +LIBS=-lpcre -lcrypto -lm -lpthread +CFLAGS=-ggdb -O3 -Wall +OBJS=vanitygen.o oclvanitygen.o pattern.o +PROGS=vanitygen +TESTS= + +all: $(PROGS) + +vanitygen: vanitygen.o pattern.o + $(CC) $^ -o $@ $(CFLAGS) $(LIBS) + +oclvanitygen: oclvanitygen.o pattern.o + $(CC) $^ -o $@ $(CFLAGS) $(LIBS) -framework OpenCL + +clean: + rm -f $(OBJS) $(PROGS) $(TESTS) diff --git a/oclvanitygen.c b/oclvanitygen.c index 882ce54..d123ff0 100644 --- a/oclvanitygen.c +++ b/oclvanitygen.c @@ -28,7 +28,14 @@ #include #include +#ifdef __APPLE__ +#include +#ifndef CL_CALLBACK +#define CL_CALLBACK +#endif +#else #include +#endif #include "pattern.h"