Files
core-foundation-rs/Makefile.in
T
2013-08-16 14:46:53 -07:00

32 lines
539 B
Makefile

VPATH=%VPATH%
CC ?= gcc
CXX ?= g++
CXXFLAGS ?=
AR ?= ar
RUSTC ?= rustc
RUSTFLAGS ?=
RUST_SRC=$(shell find $(VPATH)/. -type f -name '*.rs')
.PHONY: all
all: librustiosurface.dummy
%.o: %.c
$(CC) $< -o $@ -c $(CFLAGS)
librustiosurface.dummy: io_surface.rc $(RUST_SRC)
$(RUSTC) $(RUSTFLAGS) $< --out-dir .
touch $@
rustiosurface-test: io_surface.rc $(RUST_SRC)
$(RUSTC) $(RUSTFLAGS) $< -o $@ --test
check: rustiosurface-test
./rustiosurface-test
.PHONY: clean
clean:
rm -f *.o *.a *.so *.dylib *.dll *.dummy rustiosurface-test