mirror of
https://github.com/GOSTSec/gostoclminer
synced 2025-01-14 16:58:03 +00:00
Patch to work on OSX
This commit is contained in:
parent
eaa7158afd
commit
4a9d9e0b1d
20
Makefile.osx
Normal file
20
Makefile.osx
Normal file
@ -0,0 +1,20 @@
|
||||
LIBS=-ljansson -lcurl
|
||||
|
||||
DEFS=
|
||||
DEBUGFLAGS=
|
||||
CFLAGS=-I/usr/local/include -O3 -Wformat $(DEBUGFLAGS) $(DEFS)
|
||||
LDFLAGS=-framework OpenCL -L/usr/local/lib
|
||||
HEADERS=
|
||||
|
||||
OBJS=miner.o ocl.o findnonce.o util.o
|
||||
|
||||
all: oclminer
|
||||
|
||||
%.o: %.c $(HEADERS)
|
||||
gcc -c $(CFLAGS) -o $@ $<
|
||||
|
||||
oclminer: $(OBJS)
|
||||
gcc $(CFLAGS) $(LDFLAGS) -o $@ $^ $(LIBS)
|
||||
|
||||
clean:
|
||||
-rm *.o oclminer
|
@ -1,6 +1,10 @@
|
||||
#define MAXTHREADS 2000000
|
||||
|
||||
#ifdef __APPLE_CC__
|
||||
#include <OpenCL/opencl.h>
|
||||
#else
|
||||
#include <CL/cl.h>
|
||||
#endif
|
||||
|
||||
typedef struct {
|
||||
cl_uint ctx_a; cl_uint ctx_b; cl_uint ctx_c; cl_uint ctx_d;
|
||||
|
Loading…
Reference in New Issue
Block a user