Skip to content

Instantly share code, notes, and snippets.

@nathantypanski
Created July 31, 2014 05:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nathantypanski/948b488121ce00a3fb11 to your computer and use it in GitHub Desktop.
Save nathantypanski/948b488121ce00a3fb11 to your computer and use it in GitHub Desktop.
SRCDIR = src
PROGRAM_NAME = myprog
all: $(PROGRAM_NAME)
.PHONY: clean $(PROGRAM_NAME)
$(PROGRAM_NAME): $(SRCDIR)/$(PROGRAM_NAME).rs
rustc -L. $(SRCDIR)/$(PROGRAM_NAME).rs
clean :
$(RM) $(PROGRAM_NAME)
run: ${PROGRAM_NAME}
./${PROGRAM_NAME}
test:
rustc --test --out-dir . src/$(PROGRAM_NAME).rs
RUST_LOG=debug RUST_TEST_TASKS=1 ./$(PROGRAM_NAME)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment