Created
May 23, 2017 16:23
-
-
Save psqq/28db5d02db4a703a4e01e913915fdfad to your computer and use it in GitHub Desktop.
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
| file(GLOB SRCS "*.cpp") | |
| add_executable(hello ${SRCS}) | |
| set_property(TARGET hello PROPERTY CXX_STANDARD 11) |
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
| #include <iostream> | |
| using namespace std; | |
| void hello() { | |
| cout << "Hello, World!" << endl; | |
| } |
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
| void hello(); | |
| int main() { | |
| hello(); | |
| } |
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: build clean rebuild | |
| all: build | |
| clean: | |
| rm -r build | |
| build: | |
| mkdir -p build | |
| cd build && cmake .. && make && cp hello .. | |
| rebuild: clean build |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment