Просмотр исходного кода

Give a specific name for linux executable

DricomDragon 5 лет назад
Родитель
Сommit
4527c4ba45
1 измененных файлов с 5 добавлено и 3 удалено
  1. 5 3
      makefile

+ 5 - 3
makefile

@@ -1,5 +1,7 @@
-hello.out: main.cpp
-	g++ main.cpp -o hello.out
+linux-artifact-name = hello-linux.out
+
+$(linux-artifact-name): main.cpp
+	g++ main.cpp -o $(linux-artifact-name)
 
 clean:
-	rm hello.out
+	rm $(linux-artifact-name)