First build with JSON RPC parsing

No responses or real functionality implemented
This commit is contained in:
Aaron Cook 2026-05-19 09:26:43 -05:00
commit fcc15f5b68
9 changed files with 3910 additions and 0 deletions

43
Makefile Normal file
View file

@ -0,0 +1,43 @@
CC:=clang
BUILD_DIR:=build
CFLAGS= \
-pthread \
-Wall \
-MMD \
-g
LDFLAGS= \
-lpthread
INCLUDES= \
-Isrc \
-Ilibraries
SRCS= \
libraries/cJSON/cJSON.c \
src/json_rpc.c \
src/main.c
OBJS=$(addprefix $(BUILD_DIR)/,$(addsuffix .o,$(basename $(SRCS))))
DEPS=$(addprefix $(BUILD_DIR)/,$(addsuffix .d,$(basename $(SRCS))))
BIN=$(BUILD_DIR)/bin/pawn_lsp
.PHONY: pawn_lsp clean
pawn_lsp: $(BIN)
$(BIN): $(OBJS)
mkdir -p $(dir $@)
$(CC) $(CFLAGS) $(LDFLAGS) $(INCLUDES) -o $(BIN) $(OBJS)
$(BUILD_DIR)/%.o: %.c
mkdir -p $(dir $@)
$(CC) $(CFLAGS) $(INCLUDES) -c $< -o $@
clean:
rm -rf $(BUILD_DIR)
-include $(DEPS)