1AR := ar 2CXX := g++ 3WINDRES := windres 4LIBS := $(LIBS) -static-libgcc -static-libstdc++ -Wl,-Bstatic -lstdc++ -lwinpthread 5# Static winpthread linking https://stackoverflow.com/a/28001261 6