From 5c3899e093ad6761cd259d56e0e380de406c9d32 Mon Sep 17 00:00:00 2001 From: 8dcc <8dcc.git@gmail.com> Date: Thu, 20 Jul 2023 01:27:58 +0200 Subject: [PATCH] Change compiler, add globals object file Use g++ because of the sdk's headers Add includes Remove write-strings warning --- Makefile | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index d8124ca..82f3a7c 100644 --- a/Makefile +++ b/Makefile @@ -1,9 +1,11 @@ -CC=gcc -CFLAGS=-Wall -Wextra -m32 -fPIC +# Need to use g++ because the sdk headers use classes +CC=g++ +INCLUDES=-Isrc/sdk/common -Isrc/sdk/public -Isrc/sdk/pm_shared -Isrc/sdk/engine +CFLAGS=-Wall -Wextra -Wno-write-strings -m32 -fPIC $(INCLUDES) LDFLAGS= -OBJS=obj/main.c.o +OBJS=obj/main.c.o obj/globals.c.o BIN=libhlcheat.so .PHONY: clean all inject @@ -16,7 +18,7 @@ clean: rm -f $(OBJS) rm -f $(BIN) -inject: +inject: $(BIN) bash ./inject.sh # -------------------------------------------