on 239c8ca help sign in
Idris-dev/config.mk
43 lines 927 B history raw
1CC ?=cc
2AR ?=ar
3RANLIB ?=ranlib
5CABAL :=cabal
6# IDRIS_ENABLE_STATS should not be set in final release
7# Any flags defined here which alter the RTS API must also be added to src/IRTS/CodegenC.hs
8CFLAGS :=-O2 -Wall -DHAS_PTHREAD -DIDRIS_ENABLE_STATS $(CFLAGS)
10#CABALFLAGS :=
11## Disable building of Effects
12#CABALFLAGS :=-f NoEffects
14ifneq (, $(findstring bsd, $(MACHINE)))
15 GMP_INCLUDE_DIR :=
16else
17 GMP_INCLUDE_DIR :=-I/usr/local/include
18endif
20MACHINE := $(shell $(CC) -dumpmachine)
21ifneq (, $(findstring darwin, $(MACHINE)))
22 OS :=darwin
23else
24ifneq (, $(findstring cygwin, $(MACHINE)))
25 OS :=windows
26else
27ifneq (, $(findstring mingw, $(MACHINE)))
28 OS :=windows
29else
30 OS :=unix
31endif
32endif
33endif
35ifeq ($(OS),darwin)
36 SHLIB_SUFFIX :=.dylib
37else
38ifeq ($(OS),windows)
39 SHLIB_SUFFIX :=.DLL
40else
41 SHLIB_SUFFIX :=.so
42endif
43endif