From d40f5989a2f410c57211f7fcab656646f1151fc8 Mon Sep 17 00:00:00 2001 From: actor168 <1083687649@qq.com> Date: Tue, 17 Oct 2023 11:01:06 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BC=96=E8=AF=91?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/tools/combine/iosdiag/latency/Makefile | 2 +- source/tools/detect/cgroup/cpuacct_load/Makefile | 2 +- source/tools/detect/cgroup/memcg_usage/Makefile | 2 +- source/tools/detect/net/PingTrace/Makefile | 7 ++++--- source/tools/detect/pmu/hw_event/Makefile | 2 +- source/tools/detect/sched/offcpu/Makefile | 2 +- 6 files changed, 9 insertions(+), 8 deletions(-) diff --git a/source/tools/combine/iosdiag/latency/Makefile b/source/tools/combine/iosdiag/latency/Makefile index 7ad4403c..8f9727e1 100644 --- a/source/tools/combine/iosdiag/latency/Makefile +++ b/source/tools/combine/iosdiag/latency/Makefile @@ -2,7 +2,7 @@ newdirs += . csrcs += $(filter-out $(wildcard *.bpf.c), $(wildcard *.c)) bpfsrcs += $(wildcard *.bpf.c) -CFLAGS += -static +CFLAGS += target = latency diff --git a/source/tools/detect/cgroup/cpuacct_load/Makefile b/source/tools/detect/cgroup/cpuacct_load/Makefile index 1f2ff3d4..a008d63c 100644 --- a/source/tools/detect/cgroup/cpuacct_load/Makefile +++ b/source/tools/detect/cgroup/cpuacct_load/Makefile @@ -2,7 +2,7 @@ newdirs += . csrcs += $(filter-out $(wildcard *.bpf.c), $(wildcard *.c)) bpfsrcs += $(wildcard *.bpf.c) -CFLAGS += -static +CFLAGS += target = cpuacct_load diff --git a/source/tools/detect/cgroup/memcg_usage/Makefile b/source/tools/detect/cgroup/memcg_usage/Makefile index 3b8501db..72762467 100644 --- a/source/tools/detect/cgroup/memcg_usage/Makefile +++ b/source/tools/detect/cgroup/memcg_usage/Makefile @@ -2,7 +2,7 @@ newdirs += . csrcs += $(filter-out $(wildcard *.bpf.c), $(wildcard *.c)) bpfsrcs += $(wildcard *.bpf.c) -CFLAGS += -static +CFLAGS += target = memcg_usage diff --git a/source/tools/detect/net/PingTrace/Makefile b/source/tools/detect/net/PingTrace/Makefile index 7929209c..bbb36f90 100644 --- a/source/tools/detect/net/PingTrace/Makefile +++ b/source/tools/detect/net/PingTrace/Makefile @@ -1,5 +1,5 @@ LDFLAGS += -l:liblog4cpp.a -lncurses -lz -pthread -ltinfo -ldl -CFLAGS += -std=c++11 -static +CFLAGS += -std=c++11 INCLUDES += -Isrc/ -Isrc/bpf -I$(SRC)/lib/internal/ebpf/coolbpf/third/libbpf/src newdirs := $(shell find src/ -type d) @@ -8,7 +8,8 @@ bpfsrcs := $(wildcard src/bpf_prog/*.bpf.c) target := pingtrace DEP_PKG_INSTALL_1 := "wget https://sourceforge.net/projects/log4cpp/files/log4cpp-1.1.x%20%28new%29/log4cpp-1.1/log4cpp-1.1.3.tar.gz --no-check-certificate@tar -xzf log4cpp-1.1.3.tar.gz -C ./@cd log4cpp@./configure@make@make install" -DEP_PKG_INSTALL_2 := "git clone https://github.com/Tencent/rapidjson.git@cd rapidjson@git submodule update --init@mkdir build@cd build@cmake ..@make install" -DEP_PKG_INSTALL_3 := "git clone https://github.com/CLIUtils/CLI11.git@cd CLI11@git checkout 34c4310d9907f6a6c2eb5322fa7472474800577c@git submodule update --init@mkdir build@cd build@cmake ..@make install" +DEP_PKG_INSTALL_2 := "git clone https://ghproxy.com/https://github.com/Tencent/rapidjson.git@cd rapidjson@git submodule update --init@mkdir build@cd build@cmake ..@make install" +DEP_PKG_INSTALL_3 := "git clone https://ghproxy.com/https://github.com/CLIUtils/CLI11.git@cd CLI11@git checkout 34c4310d9907f6a6c2eb5322fa7472474800577c@git submodule update --init@mkdir build@cd build@cmake ..@make install" +DEP_PKG_INSTALL_4 := "wget https://fossies.org/linux/misc/ncurses-6.4.tar.gz --no-check-certificate@tar -zxf ncurses-6.4.tar.gz@cd ncurses-6.4@./configure && make -j && make install@ln -sf /usr/lib/libncurses.a /usr/lib/libtinfo.a" include $(SRC)/mk/ccbpf.mk diff --git a/source/tools/detect/pmu/hw_event/Makefile b/source/tools/detect/pmu/hw_event/Makefile index d697ca29..605a3296 100644 --- a/source/tools/detect/pmu/hw_event/Makefile +++ b/source/tools/detect/pmu/hw_event/Makefile @@ -1,4 +1,4 @@ -EXTRA_LDFLAGS += -static +EXTRA_LDFLAGS += OBJECTS = $(patsubst %.c, %.o, $(wildcard *.c)) mods:= $(OBJECTS) diff --git a/source/tools/detect/sched/offcpu/Makefile b/source/tools/detect/sched/offcpu/Makefile index c9871ad8..9cb63a44 100644 --- a/source/tools/detect/sched/offcpu/Makefile +++ b/source/tools/detect/sched/offcpu/Makefile @@ -5,6 +5,6 @@ bpfsrcs := $(wildcard bpf/*.bpf.c) csrcs := $(wildcard *.c) target := offcputime EXTRA_LDFLAGS += -lrt -lsysak -EXTRA_CFLAGS += -static +EXTRA_CFLAGS += include $(SRC)/mk/bpf.mk -- Gitee From 5fcbc8a6f5974e50b436f126aa1352925a4c7f46 Mon Sep 17 00:00:00 2001 From: actor168 <1083687649@qq.com> Date: Tue, 17 Oct 2023 11:04:32 +0800 Subject: [PATCH 2/2] =?UTF-8?q?fix:=20exec=E4=BC=9A=E7=9F=AD=E8=B7=AF?= =?UTF-8?q?=E5=90=8E=E7=BB=AD=E6=89=A7=E8=A1=8C=E6=94=B9=E4=B8=BAbash?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 002b8225..544df821 100755 --- a/configure +++ b/configure @@ -117,7 +117,7 @@ check_packages_depend() { echo "cd $PWD" >> $SH_ABS_PATH done chmod +x $SH_ABS_PATH - exec ./$PACKAGEBUILD_TMP/$BUILD_SH + bash ./$PACKAGEBUILD_TMP/$BUILD_SH cd $PWD } -- Gitee