From 4e19749f95f47cb329d408559b458c4ba9f9653a Mon Sep 17 00:00:00 2001
From: guowenxue <guowenxue@gmail.com>
Date: Fri, 27 Sep 2024 14:33:10 +0800
Subject: [PATCH] update booster makefile
---
hal/modules/makefile | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/hal/modules/makefile b/hal/modules/makefile
index 433e220..befd362 100644
--- a/hal/modules/makefile
+++ b/hal/modules/makefile
@@ -15,7 +15,7 @@
PWD=$(shell pwd)
INSTPATH=/tftp
-CROSS_COMPILE=arm-linux-gnueabihf-
+CROSS_COMPILE=/opt/gcc-aarch32-10.3-2021.07/bin/arm-none-linux-gnueabihf-
CC=${CROSS_COMPILE}gcc
LDFLAGS += -lm
@@ -26,7 +26,15 @@
SRCFILES = $(wildcard *.c)
BINARIES=$(SRCFILES:%.c=%)
-all: binaries install
+# libgpiod compile install path
+LIBS_PATH=install
+CFLAGS+=-I ${LIBS_PATH}/include
+LDFLAGS+=-L ${LIBS_PATH}/lib -lgpiod
+
+all: libs binaries install
+
+libs:
+ make -C libgpiod CROSS_COMPILE=${CROSS_COMPILE}
binaries: ${BINARIES}
@@ -40,6 +48,8 @@
@rm -f *.o *.lo $(BINARIES)
distclean: clean
- @rm -f tags cscope*
+ @rm -f tags cscope*
+ @make clean -C libgpiod
+ @rm -rf install
.PHONY: clean entry
--
Gitblit v1.9.1