makefile find cpp

#######################################

ELF=main

DEBUG=-g


LIB= -lpthread -lrt -lstdc++

#######################################
CC=g++ $(DEBUG) $(LIB)
CXX=g++ $(DEBUG) $(LIB)
SRC=$(shell find -name '*.cpp')
OBJ=$(SRC:.cpp=.o)
$(ELF):$(OBJ)
$(OBJ):
clean:
	rm -f $(ELF) $(OBJ)

  

posted on 2020-08-10 08:49  lydstory  阅读(248)  评论(0)    收藏  举报

导航