Created
February 5, 2018 06:35
-
-
Save smutch/e595dfb54ddc9097d583d40ba20ac662 to your computer and use it in GitHub Desktop.
make: Simple makefile to run a standard cmake build
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.PHONY: default config cleanbuild | |
default: build/Makefile | |
@make -C build --no-print-directory $(MFLAGS) | |
config: | |
@cmake . -Bbuild $(CMAKE_OPTS) | |
cleanbuild: | |
@rm -r build | |
build/Makefile: | |
@if [ ! -d "build" ]; then cmake . -Bbuild $(CMAKE_OPTS); fi | |
% :: build/Makefile | |
@make -C build --no-print-directory $@ $(MFLAGS) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment