aboutsummaryrefslogtreecommitdiffhomepage
path: root/Makefile
diff options
context:
space:
mode:
authorbakpakin <calsrose@gmail.com>2023-01-21 10:37:34 -0600
committerbakpakin <calsrose@gmail.com>2023-01-21 10:37:34 -0600
commit93b469885a145d4e917bc29e5ac72a17b5aaba4c (patch)
treefa60d8d1ddf3605f175ff8f226a6dc40d48f1bc9 /Makefile
parentDon't compile library loading code on windows if it is disabled. (diff)
Initial Mingw support with Makefile.
Also add a macro JANET_MSVC to distinguish between a windows build (JANET_WINDOWS) and a build with msvc.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile6
1 files changed, 6 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index b4248f31..ebc5eaf0 100644
--- a/Makefile
+++ b/Makefile
@@ -77,6 +77,12 @@ ifeq ($(shell uname -o), Android)
endif
endif
+# Mingw
+ifeq ($(findstring MINGW,$(UNAME)), MINGW)
+ CLIBS:=-lws2_32 -lpsapi -lwsock32
+ LDFLAGS:=
+endif
+
$(shell mkdir -p build/core build/c build/boot)
all: $(JANET_TARGET) $(JANET_LIBRARY) $(JANET_STATIC_LIBRARY) build/janet.h