aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbloodstalker <thabogre@gmail.com>2018-11-09 12:24:19 +0000
committerbloodstalker <thabogre@gmail.com>2018-11-09 12:24:19 +0000
commit64e37df7332cf8cc7530826f2cb367ce8d738c61 (patch)
treea4ef25da666c78069fab9b277899c5c62434010d
parentupdate (diff)
downloadcgrep-64e37df7332cf8cc7530826f2cb367ce8d738c61.tar.gz
cgrep-64e37df7332cf8cc7530826f2cb367ce8d738c61.zip
update
Diffstat (limited to '')
-rw-r--r--.gitmodules3
m---------cfe-extra0
-rw-r--r--cgrep.cpp1
-rw-r--r--makefile22
4 files changed, 20 insertions, 6 deletions
diff --git a/.gitmodules b/.gitmodules
new file mode 100644
index 0000000..d456833
--- /dev/null
+++ b/.gitmodules
@@ -0,0 +1,3 @@
+[submodule "cfe-extra"]
+ path = cfe-extra
+ url = https://github.com/bloodstalker/cfe-extra
diff --git a/cfe-extra b/cfe-extra
new file mode 160000
+Subproject 0d705a39d07eed0392181c2ba49ac2d10eef17e
diff --git a/cgrep.cpp b/cgrep.cpp
index 4f66876..615d435 100644
--- a/cgrep.cpp
+++ b/cgrep.cpp
@@ -8,6 +8,7 @@
/*************************************************************************************************/
/*included modules*/
/*project headers*/
+#include "./cfe-extra/cfe_extra.h"
/*standard headers*/
#include <cassert>
#include <cstdlib>
diff --git a/makefile b/makefile
index 019f91f..2fad74a 100644
--- a/makefile
+++ b/makefile
@@ -98,16 +98,25 @@ depend:.depend
%.ocov:%.cpp
$(CXX) $(CXX_FLAGS) $(COV_CXX) -c $< -o $@
-$(TARGET): $(TARGET).o
+./cfe-extra/cfe_extra.o:./cfe-extra/cfe_extra.cpp
+ $(CXX) $(CXX_FLAGS) -c $< -o $@
+
+./cfe-extra/cfe_extra.odbg:./cfe-extra/cfe_extra.cpp
+ $(CXX) $(CXX_FLAGS) -g -c $< -o $@
+
+./cfe-extra/cfe_extra.ocov:./cfe-extra/cfe_extra.cpp
+ $(CXX) $(CXX_FLAGS) $(COV_CXX) -c $< -o $@
+
+$(TARGET): $(TARGET).o ./cfe-extra/cfe_extra.o
$(CXX) $^ $(LD_FLAGS) -o $@
-$(TARGET)-static: $(TARGET).o
+$(TARGET)-static: $(TARGET).o ./cfe-extra/cfe_extra.o
$(CXX) $^ $(LD_FLAGS) -static -o $@
-$(TARGET)-dbg: $(TARGET).odbg
+$(TARGET)-dbg: $(TARGET).odbg ./cfe-extra/cfe_extra.odbg
$(CXX) $^ $(LD_FLAGS) -g -o $@
-$(TARGET)-cov: $(TARGET).ocov
+$(TARGET)-cov: $(TARGET).ocov ./cfe-extra/cfe_extra.ocov
$(CXX) $^ $(LD_FLAGS) $(COV_LD) -o $@
cov: runcov
@@ -134,10 +143,10 @@ tags:$(SRCS)
%.dis: %.o
objdump -r -d -M intel -S $< > $@
-$(TARGET).so: $(TARGET).o
+$(TARGET).so: $(TARGET).o ./cfe-extra/cfe_extra.o
$(CXX) $^ $(LD_FLAGS) -shared -o $@
-$(TARGET).a: $(TARGET).o
+$(TARGET).a: $(TARGET).o ./cfe-extra/cfe_extra.o
ar rcs $(TARGET).a $(TARGET).o
runcov: $(TARGET)-cov
@@ -158,6 +167,7 @@ clean:
deepclean: clean
- rm tags
- rm .depend
+ - $(MAKE) -C ./cfe-extra clean
help:
@echo "--all is the default target, runs $(TARGET) target"