From c9e3f86a8913523fb1ca366ecb724e0fea2bd4dd Mon Sep 17 00:00:00 2001 From: Tiiffi Date: Thu, 27 Oct 2016 03:23:32 +0300 Subject: [PATCH] Makefile improvements. --- Makefile | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 1c3e5da..ee829ac 100644 --- a/Makefile +++ b/Makefile @@ -1,8 +1,15 @@ -# Cross comple, eg. +# if you want to cross compile # export PATH=$PATH:/path/to/compiler/bin # export CROSS_COMPILE=arm-none-linux-gnueabi- # make -all: - $(CROSS_COMPILE)gcc -std=gnu99 -pedantic -Wall -Wextra -O2 -s -o mcrcon mcrcon.c +CC = gcc +CFLAGS = -std=gnu11 -Wall -Wextra -Wpedantic -O2 + +all: + $(CROSS_COMPILE)$(CC) $(CFLAGS) -o mcrcon mcrcon.c + +clean: + rm -f mcrcon +