Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 35 lines (25 sloc) 0.725 kb
924e579 Jack Moffitt Build with make instead of rustpkg.
metajack authored
1 VPATH=%VPATH%
2
3 RUSTC ?= rustc
4 RUSTFLAGS ?=
67bc47b Matt Brubeck Rebuild when external dependencies change
mbrubeck authored
5 EXT_DEPS ?=
6b5af96 Simon Sapin Generate documentation with rustdoc
SimonSapin authored
6 RUSTDOC ?= rustdoc
7 RUSTDOC_FLAGS ?=
8 RUSTDOC_TARGET ?= doc
924e579 Jack Moffitt Build with make instead of rustpkg.
metajack authored
9
427a5bb Jack Moffitt Cargoify rust-layers
metajack authored
10 RUST_SRC=$(shell find $(VPATH)/src -type f -name '*.rs')
924e579 Jack Moffitt Build with make instead of rustpkg.
metajack authored
11
12 .PHONY: all
13 all: librust-layers.dummy
14
427a5bb Jack Moffitt Cargoify rust-layers
metajack authored
15 librust-layers.dummy: src/lib.rs $(RUST_SRC) $(EXT_DEPS)
37b5fe7 Lars Bergstrom Produce dylib and rlib
larsbergstrom authored
16 $(RUSTC) $(RUSTFLAGS) $< --out-dir .
924e579 Jack Moffitt Build with make instead of rustpkg.
metajack authored
17 touch $@
18
427a5bb Jack Moffitt Cargoify rust-layers
metajack authored
19 rust-layers-test: src/lib.rs $(RUST_SRC)
924e579 Jack Moffitt Build with make instead of rustpkg.
metajack authored
20 $(RUSTC) $(RUSTFLAGS) $< -o $@ --test
21
6b5af96 Simon Sapin Generate documentation with rustdoc
SimonSapin authored
22 .PHONY: doc
23 doc: $(RUSTDOC_TARGET)/layers/index.html
24
427a5bb Jack Moffitt Cargoify rust-layers
metajack authored
25 $(RUSTDOC_TARGET)/layers/index.html: src/lib.rs $(RUST_SRC) $(EXT_DEPS)
6b5af96 Simon Sapin Generate documentation with rustdoc
SimonSapin authored
26 $(RUSTDOC) $(RUSTDOC_FLAGS) $< -o $(RUSTDOC_TARGET)
27
924e579 Jack Moffitt Build with make instead of rustpkg.
metajack authored
28 .PHONY: check
29 check: rust-layers-test
30 ./rust-layers-test $(TEST)
31
32 .PHONY: clean
33 clean:
400a013 Lars Bergstrom Clean rlib files
larsbergstrom authored
34 rm -f *.o *.a *.so *.dylib *.rlib *.dll *.dummy *-test
Something went wrong with that request. Please try again.