File: Makefile

package info (click to toggle)
camlmix 1.3.1-6
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 240 kB
  • sloc: ml: 496; makefile: 89
file content (56 lines) | stat: -rw-r--r-- 1,021 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
53
54
55
56
# Type `make' for native code
# Type `make byte' for byte code instead of native code

VERSION = 1.3.1
export VERSION

PACKS = camlp-streams
SOURCES = \
  version.ml lexer.mli lexer.mll \
  parser_directive.mly directive.ml main.ml
RESULT = camlmix

.PHONY: default native byte all opt install www version force clean veryclean

default: native
native: version nc
byte: version bc

ifndef PREFIX
  PREFIX := $(shell dirname `which ocaml`)/..
endif
export PREFIX

all: byte
opt: native
install:
	install -m 0755 $(addsuffix $(EXE), \
			$(sort $(BCRESULT) $(NCRESULT))) $(PREFIX)/bin/

www: all test install archive

version:
	contents='let version = "$(VERSION)"'; \
	  if test "`cat version.ml`" != "$$contents"; then \
	    echo "$$contents" > version.ml;\
	  fi

.PHONY: examples
examples:
	cd examples && $(MAKE)

force:
	$(MAKE) clean
	$(MAKE)
	$(MAKE) archive

TRASH = META.mlx.ml langmix.* camlmix.exe *~

clean::
	cd examples && $(MAKE) clean


LIBS = unix

OCAMLMAKEFILE = OCamlMakefile
include $(OCAMLMAKEFILE)