Revision 708e88c59dc2c2c0cce9d3758abd65e74b42807e authored by Pierre-Yves Strub on 16 January 2021, 08:38:18 UTC, committed by Pierre-Yves Strub on 16 January 2021, 08:38:18 UTC
1 parent 9dcb1a4
Raw File
Makefile.system
# -*- Makefile -*-

# --------------------------------------------------------------------
OCAML    := $(shell ocamlbuild -which ocamlc 2>/dev/null || echo false)
CC       := gcc
TAR      := tar
MACHINE  := $(shell $(OCAML) -ccopt -dumpmachine dummy.c 2>/dev/null)
UNAME    := $(shell uname -s)
EXE      :=

ifneq (,$(findstring CYGWIN,$(UNAME)))
  CC := $(MACHINE)-gcc
endif

ifneq (,$(findstring Darwin,$(UNAME)))
  TAR := gtar
endif

ifneq (,$(findstring mingw,$(MACHINE)))
EXE := .exe
endif

ifneq (,$(findstring cygwin,$(MACHINE)))
EXE := .exe
endif
back to top