Guest User

Untitled

a guest
Feb 18th, 2019
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. TARGET := $(MAKECMDGOALS)
  2. CXX_FLAGS := -std=c++11
  3.  
  4. $(TARGET): force-clean
  5. g++ $(TARGET).cpp $(CXX_FLAGS) -o $(TARGET) && ./$(TARGET)
  6.  
  7. force-clean:
  8. \rm -f $(TARGET)
  9.  
  10.  
  11. # given source file name: 100.cpp
  12. # just enter `make 100` to build and run it
  13. # if you have a lot of "single c++ file", it's your good friend!
Add Comment
Please, Sign In to add comment