File: Makefile

package info (click to toggle)
ocaml 4.11.1-4
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 34,304 kB
  • sloc: ml: 290,481; ansic: 45,162; sh: 19,565; asm: 3,783; makefile: 3,618; awk: 254; perl: 45; fortran: 21; cs: 9
file content (52 lines) | stat: -rw-r--r-- 1,654 bytes parent folder | download
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#**************************************************************************
#*                                                                        *
#*                                 OCaml                                  *
#*                                                                        *
#*                 Xavier Clerc, SED, INRIA Rocquencourt                  *
#*                                                                        *
#*   Copyright 2010 Institut National de Recherche en Informatique et     *
#*     en Automatique.                                                    *
#*                                                                        *
#*   All rights reserved.  This file is distributed under the terms of    *
#*   the GNU Lesser General Public License version 2.1, with the          *
#*   special exception on linking described in the file LICENSE.          *
#*                                                                        *
#**************************************************************************

.NOTPARALLEL:

TOPDIR = ../..
COMPFLAGS ?=
RUNTIME_VARIANT ?=

include $(TOPDIR)/Makefile.tools

libraries := testing.cmi testing.cma lib.cmo

# If the native compiler is enabled, then also compile testing.cmxa
ifeq "$(NATIVE_COMPILER)" "true"
libraries += testing.cmxa
endif

all: $(libraries)

testing.cma: testing.cmo
	$(OCAMLC) -a -linkall -o $@ $<

testing.cmxa: testing.cmx
	$(OCAMLOPT) -a -linkall -o $@ $<

testing.cmo : testing.cmi

%.cmi: %.mli
	$(OCAMLC) -c $<

%.cmo: %.ml
	$(OCAMLC) -c $<

%.cmx: %.ml
	$(OCAMLOPT) -c $<

.PHONY: clean
clean:
	rm -f *.cm* *.o *.obj *.a *.lib