From 08b148eaae0bf5121022acae9cc91e27cbf37263 Mon Sep 17 00:00:00 2001
From: guowenxue <guowenxue@gmail.com>
Date: Sat, 24 May 2025 17:57:29 +0800
Subject: [PATCH] update devsn in socketd project
---
project/socketd/makefile | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/project/socketd/makefile b/project/socketd/makefile
index 2c72631..0ff2b49 100644
--- a/project/socketd/makefile
+++ b/project/socketd/makefile
@@ -12,7 +12,7 @@
#*******************************************************************************
PRJ_PATH=$(shell pwd)
-APP_NAME = client
+APP_NAME = sock_client
BUILD_ARCH=$(shell uname -m)
ifneq ($(findstring $(BUILD_ARCH), "x86_64" "i386"),)
@@ -24,9 +24,6 @@
# common CFLAGS for our source code
CFLAGS = -Wall -Wshadow -Wundef -Wmaybe-uninitialized -D_GNU_SOURCE
-
-# sub-directory need to entry and compile
-SUBDIR=booster sqlite
# sub-directory compiled to a library and need to link
SRCS=booster
@@ -40,18 +37,20 @@
CFLAGS+=-I ${PRJ_PATH}/sqlite/install/include
LDFLAGS+=-L ${PRJ_PATH}/sqlite/install/lib
LDFLAGS+=-lsqlite3
-
LDFLAGS+=-lpthread
+# sub-directory need to entry and compile
+SUBDIR=sqlite ${SRCS}
+
all: entry subdir
- ${CROSS_COMPILE}gcc ${CFLAGS} client.c -o client ${LDFLAGS}
+ ${CROSS_COMPILE}gcc ${CFLAGS} sock_client.c -o sock_client ${LDFLAGS}
entry:
@echo "Building ${APP_NAME} on ${BUILD_ARCH}"
subdir:
@for dir in ${SUBDIR} ; do if [ ! -e $${dir} ] ; then ln -s ../$${dir}; fi; done
- @for dir in ${SUBDIR} ; do make -C $${dir} ; done
+ @for dir in ${SUBDIR} ; do make CFLAGS="${CFLAGS}" -C $${dir} ; done
install:
cp ${APP_NAME} /tftp
@@ -64,4 +63,5 @@
@for dir in ${SUBDIR} ; do if [ -e $${dir} ] ; then make clean -C $${dir}; fi; done
@rm -f ${APP_NAME}
@rm -f cscope.* tags
+ @rm -f *.log *.db
--
Gitblit v1.9.1