典型的makefile写法,(注意每一行的前面若有空格,是tab,不是space)
#Source file
SRC = Test.c
#Object file
OBJ =
#Output execution file
PROGRAM =
#Compiler
CC = gcc
#Include
INCLUDE =
#Linker Parameter
LIB = -lpthread
#Options for development
#CFLAGS = -ansi -g -Wall -O2
all: $(PROGRAM)
$(PROGRAM): $(OBJ)
(CC) -o $(PROGRAM) $(LIB) $(OBJ)
clean:
-rm *.o
阅读(1232) | 评论(0) | 转发(1) |