aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorcathook <cat.hook31894@gmail.com>2013-11-27 12:57:03 +0800
committercathook <cat.hook31894@gmail.com>2013-11-27 12:57:03 +0800
commit53310435c1003c073510ca93b79a486dbd632e0d (patch)
tree9625baa426589e6c4ac6c3a9345d469ed824ab35
parentd4aaa5ab81cfb49b2e557ec1a49942ec7508fe4e (diff)
parent042a8a4ef723d46bd490e98ca9730180af0498be (diff)
downloadctl-feature-vector.tar
ctl-feature-vector.tar.gz
ctl-feature-vector.tar.bz2
ctl-feature-vector.tar.lz
ctl-feature-vector.tar.xz
ctl-feature-vector.tar.zst
ctl-feature-vector.zip
Merge branch 'feature-etc' into developfeature-vectorfeature-etc
-rw-r--r--Makefile12
1 files changed, 5 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index 25fb9ac..68e03d9 100644
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,5 @@
####################### path name ##########################
-PWD = $(shell pwd)
+PWD = .
LIB = $(PWD)/lib
OBJ = $(PWD)/obj
@@ -16,7 +16,7 @@ AR_OPT := cvr
EXAMPLE_CC := gcc $(GCC_OPT) -o
-OBJ_CC := gcc $(GCC_OPT) -c
+OBJ_CC := gcc $(GCC_OPT) -c -o
SLIB_CC := ar $(AR_OPT)
######################## targets ###########################
@@ -28,8 +28,8 @@ OBJFIL := $(foreach n,$(OBJECT),$(OBJ)/$(n).o)
TARGET := $(LIB)/libctl.a
-EMPFIL := $(EMP)/example.c
-EMPOUT := $(EMP)/example
+EMPFIL := example.c
+EMPOUT := example
######################## setting ###########################
.SUFFIXES:
@@ -47,9 +47,7 @@ $(TARGET): $(OBJFIL)
$(OBJFIL): $(OBJ)/%.o: $(SRC)/%.c $(INC)/%.h
@echo 'make object file .......... $@'
- @cd $(OBJ) && $(OBJ_CC) $<
-
-example: $(EMPOUT);
+ @$(OBJ_CC) $@ $<
$(EMPOUT): $(EMPFIL) $(TARGET)
@echo 'make test program for ...... $^'