1 Star 0 Fork 0

miao123456miao-2/port-mirroring

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Makefile 1015 Bytes
一键复制 编辑 原始数据 按行查看 历史
Mike Maraya 提交于 2015-11-23 19:22 . remove cppcheck from all
#
# Makefile for https://github.com/mmaraya/port-mirroring
#
# Copyright (c) 2015 Mike Maraya <mike[dot]maraya[at]gmail[dot]com>
# All rights reserved.
#
# This file is subject to the terms and conditions defined in
# https://github.com/mmaraya/port-mirroring/blob/master/LICENSE,
# which is part of this software package.
#
SHELL := /bin/sh
PROGRAM := port-mirroring
SRC_DIR := src
OBJ_DIR := obj
BIN_DIR := bin
INC_DIR := include
C_FILES := $(wildcard $(SRC_DIR)/*.c)
OBJ_FILES := $(addprefix $(OBJ_DIR)/,$(notdir $(C_FILES:.c=.o)))
LIB_FILES := -lpcap -lpthread
CC := cc
CC_FLAGS := -g -Wall -Wextra -Werror -I$(INC_DIR)
LD_FLAGS :=
.PHONY: all clean check
all: $(BIN_DIR)/$(PROGRAM)
$(BIN_DIR)/$(PROGRAM): $(OBJ_FILES)
@mkdir -p $(@D)
$(CC) $(LD_FLAGS) -o $@ $^ $(LIB_FILES)
$(OBJ_DIR)/%.o: $(SRC_DIR)/%.c
@mkdir -p $(@D)
$(CC) $(CC_FLAGS) -c -o $@ $<
clean:
rm -f $(BIN_DIR)/$(PROGRAM) $(OBJ_DIR)/*.o
check:
cppcheck --enable=all -I $(INC_DIR) $(SRC_DIR)/*.c
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/lishuang_miao/port-mirroring.git
git@gitee.com:lishuang_miao/port-mirroring.git
lishuang_miao
port-mirroring
port-mirroring
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385