ajout de mingw
This commit is contained in:
@@ -1,11 +1,19 @@
|
|||||||
COMPILER = g++
|
COMPILER = g++
|
||||||
|
WINDOWS_COMPILE = x86_64-w64-mingw32-g++
|
||||||
|
WINDOWS_LD_FLAG = --static
|
||||||
COMPILE_FLAG = -c
|
COMPILE_FLAG = -c
|
||||||
LD_FLAG = -o
|
LD_FLAG = -Wall -o
|
||||||
OBJDIR=./objs/
|
OBJDIR=./objs/
|
||||||
SRC=./src/
|
SRC=./src/
|
||||||
SRCS=$(shell ls src/* | grep "\.c")
|
SRCS=$(shell ls src/* | grep "\.c")
|
||||||
|
|
||||||
ALL : build link clean
|
ALL : build link clean
|
||||||
|
windows : winswitch build winlink clean
|
||||||
|
|
||||||
|
winswitch :
|
||||||
|
echo "building"
|
||||||
|
$(eval COMPILER = $(WINDOWS_COMPILE))
|
||||||
|
$(eval LD_FLAG = $(WINDOWS_LD_FLAG) $(LD_FLAG) )
|
||||||
|
|
||||||
build :
|
build :
|
||||||
mkdir -p ${OBJDIR}
|
mkdir -p ${OBJDIR}
|
||||||
@@ -17,6 +25,12 @@ build :
|
|||||||
link:
|
link:
|
||||||
${COMPILER} objs/* ${LD_FLAG} run
|
${COMPILER} objs/* ${LD_FLAG} run
|
||||||
|
|
||||||
|
winlink:
|
||||||
|
-rm run.exe
|
||||||
|
${COMPILER} objs/* ${LD_FLAG} run.exe
|
||||||
|
|
||||||
|
winrun:
|
||||||
|
WINEDEBUG=-all wine run.exe
|
||||||
|
|
||||||
clean :
|
clean :
|
||||||
@echo ""
|
@echo ""
|
||||||
|
|||||||
Reference in New Issue
Block a user