-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
34 lines (22 loc) · 850 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
34
# Use the default go compiler
GO_BUILDFLAGS=-compiler gc
# Or uncomment the line below to use the gccgo compiler, which may
# or may not be faster than gc and which may or may not compile...
# GO_BUILDFLAGS=-compiler gccgo -gccgoflags '-static-libgcc -O4 -Ofast -march=native'
CGO_CFLAGS_ALLOW='(-fno-schedule-insns|-malign-double|-ffast-math)'
.PHONY: all clkernels clean realclean hooks
all: clkernels
go install -v $(GO_BUILDFLAGS) github.com/mumax/3cl/cmd/...
clkernels:
cd ./opencl && $(MAKE)
hooks: .git/hooks/post-commit .git/hooks/pre-commit
.git/hooks/post-commit: post-commit
ln -sf $(CURDIR)/$< $@
.git/hooks/pre-commit: pre-commit
ln -sf $(CURDIR)/$< $@
clean:
rm -frv $(GOPATH)/pkg/*/github.com/mumax/3cl/*
rm -frv $(GOPATH)/bin/mumax3*
cd ./opencl && $(MAKE) clean
realclean: clean
cd ./opencl && ${MAKE} realclean