From 74f00fed897b2b2882e880f1c6dad353d8e4572e Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Fri, 12 Jun 2020 11:42:19 +0800 Subject: [PATCH 01/11] add install --- runtime/GNUmakefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/runtime/GNUmakefile b/runtime/GNUmakefile index 8691fa7..216eee1 100644 --- a/runtime/GNUmakefile +++ b/runtime/GNUmakefile @@ -65,6 +65,12 @@ clean: clean-all: clean rm -f libgtest.a testHelper/GeneratedCode.cc +install: libNanoLog.a + install -d $(DESTDIR)$(PREFIX)/lib/ + install -m 644 libNanoLog.a $(DESTDIR)$(PREFIX)/lib/ + install -d $(DESTDIR)$(PREFIX)/include/ + install -m 644 NanoLogCpp17.h $(DESTDIR)$(PREFIX)/include/ + install -m 755 decompressor $(DESTDIR)$(PREFIX)/bin/ # Automatic rules to build *.h dependencies. Taken from # https://stackoverflow.com/questions/2394609/makefile-header-dependencies depend: .depend From e40a9f04507d7f2dada3c2409895b188f990d6cc Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Fri, 19 Jun 2020 18:14:29 +0800 Subject: [PATCH 02/11] add necessary headers --- runtime/GNUmakefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/runtime/GNUmakefile b/runtime/GNUmakefile index 216eee1..144da76 100644 --- a/runtime/GNUmakefile +++ b/runtime/GNUmakefile @@ -68,8 +68,12 @@ clean-all: clean install: libNanoLog.a install -d $(DESTDIR)$(PREFIX)/lib/ install -m 644 libNanoLog.a $(DESTDIR)$(PREFIX)/lib/ - install -d $(DESTDIR)$(PREFIX)/include/ - install -m 644 NanoLogCpp17.h $(DESTDIR)$(PREFIX)/include/ + install -d $(DESTDIR)$(PREFIX)/include/NanoLog/ + install -m 644 NanoLogCpp17.h $(DESTDIR)$(PREFIX)/include/NanoLog/ + install -m 644 Common.h $(DESTDIR)$(PREFIX)/include/NanoLog/ + install -m 644 Cycles.h $(DESTDIR)$(PREFIX)/include/NanoLog/ + install -m 644 Packer.h $(DESTDIR)$(PREFIX)/include/NanoLog/ + install -m 644 NanoLog.h $(DESTDIR)$(PREFIX)/include/NanoLog/ install -m 755 decompressor $(DESTDIR)$(PREFIX)/bin/ # Automatic rules to build *.h dependencies. Taken from # https://stackoverflow.com/questions/2394609/makefile-header-dependencies From 0f5e3e8552baa593f461b8e462f83aa380a7e322 Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Mon, 22 Jun 2020 17:36:46 +0800 Subject: [PATCH 03/11] :wrench: all header --- runtime/GNUmakefile | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/runtime/GNUmakefile b/runtime/GNUmakefile index 144da76..f5f0bff 100644 --- a/runtime/GNUmakefile +++ b/runtime/GNUmakefile @@ -69,11 +69,7 @@ install: libNanoLog.a install -d $(DESTDIR)$(PREFIX)/lib/ install -m 644 libNanoLog.a $(DESTDIR)$(PREFIX)/lib/ install -d $(DESTDIR)$(PREFIX)/include/NanoLog/ - install -m 644 NanoLogCpp17.h $(DESTDIR)$(PREFIX)/include/NanoLog/ - install -m 644 Common.h $(DESTDIR)$(PREFIX)/include/NanoLog/ - install -m 644 Cycles.h $(DESTDIR)$(PREFIX)/include/NanoLog/ - install -m 644 Packer.h $(DESTDIR)$(PREFIX)/include/NanoLog/ - install -m 644 NanoLog.h $(DESTDIR)$(PREFIX)/include/NanoLog/ + install -m 644 *.h $(DESTDIR)$(PREFIX)/include/NanoLog/ install -m 755 decompressor $(DESTDIR)$(PREFIX)/bin/ # Automatic rules to build *.h dependencies. Taken from # https://stackoverflow.com/questions/2394609/makefile-header-dependencies @@ -84,3 +80,4 @@ depend: .depend $(CXX) $(CXX_ARGS) $(INCLUDES) -MM $^ > ./.depend; include .depend + From a6dbf8a83454d9fd91996ef5219e8ba5027bcdef Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Mon, 22 Jun 2020 17:40:25 +0800 Subject: [PATCH 04/11] ci --- .github/workflows/ci.yaml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 66b88d3..605e530 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -45,3 +45,12 @@ jobs: cd ${GITHUB_WORKSPACE}/integrationTest make clean-all > /dev/null ./run.sh + + - name: Install Runtime + run: | + cd ${GITHUB_WORKSPACE}/runtime + make clean-all + make -j10 + make install + cd ${GITHUB_WORKSPACE}/sample + make -j10 > /dev/null From 99d7f8949bb7a8db310f318c76ed803c1b297d29 Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Mon, 22 Jun 2020 17:40:55 +0800 Subject: [PATCH 05/11] prefix --- runtime/GNUmakefile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/runtime/GNUmakefile b/runtime/GNUmakefile index f5f0bff..e8be5ec 100644 --- a/runtime/GNUmakefile +++ b/runtime/GNUmakefile @@ -64,7 +64,10 @@ clean: clean-all: clean rm -f libgtest.a testHelper/GeneratedCode.cc - + +ifeq ($(PREFIX),) + PREFIX := /usr/local +endif install: libNanoLog.a install -d $(DESTDIR)$(PREFIX)/lib/ install -m 644 libNanoLog.a $(DESTDIR)$(PREFIX)/lib/ From dbfde687eda2e98608975fb3de8e60b4082b30be Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Mon, 22 Jun 2020 17:49:54 +0800 Subject: [PATCH 06/11] fix ci --- .github/workflows/ci.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 605e530..8ef728c 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -48,6 +48,8 @@ jobs: - name: Install Runtime run: | + cd ${GITHUB_WORKSPACE} + git submodule update --init cd ${GITHUB_WORKSPACE}/runtime make clean-all make -j10 From 99e2903e05ddac03977c4c610c3bbc055aeb67d5 Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Wed, 24 Jun 2020 19:35:00 +0800 Subject: [PATCH 07/11] sudo --- .github/workflows/ci.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8ef728c..e2f94c1 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -53,6 +53,4 @@ jobs: cd ${GITHUB_WORKSPACE}/runtime make clean-all make -j10 - make install - cd ${GITHUB_WORKSPACE}/sample - make -j10 > /dev/null + sudo make install From cb9ad8bc6656b3cba6aad5425010d78c3349351b Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Wed, 24 Jun 2020 19:42:08 +0800 Subject: [PATCH 08/11] add system link sample for ci --- sample/GNUmakefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sample/GNUmakefile b/sample/GNUmakefile index f3a6450..8576a9a 100644 --- a/sample/GNUmakefile +++ b/sample/GNUmakefile @@ -43,3 +43,6 @@ decompressor: libNanoLog.a clean-all: clean @rm -f libNanoLog.a decompressor $(MAKE) clean-all -C $(NANOLOG_RUNTIME_DIR) + +sampleApplication_system: main.o + $(CXX) $(CXXFLAGS) -o sampleApplication main.o -L/usr/local/lib/ -lNanoLog -pthread -lrt From fe3db1c39d95883bcf7b2c539ef374d741cb7834 Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Wed, 24 Jun 2020 19:42:25 +0800 Subject: [PATCH 09/11] Update ci.yaml --- .github/workflows/ci.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index e2f94c1..6c65e75 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -54,3 +54,5 @@ jobs: make clean-all make -j10 sudo make install + cd ${GITHUB_WORKSPACE}/sample + make sampleApplication_system From 2a7dbcff634c7699b2572ea9bf689169f07398ce Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Thu, 2 Jul 2020 20:33:32 +0800 Subject: [PATCH 10/11] system header --- sample/GNUmakefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sample/GNUmakefile b/sample/GNUmakefile index 8576a9a..cb2cb34 100644 --- a/sample/GNUmakefile +++ b/sample/GNUmakefile @@ -43,6 +43,9 @@ decompressor: libNanoLog.a clean-all: clean @rm -f libNanoLog.a decompressor $(MAKE) clean-all -C $(NANOLOG_RUNTIME_DIR) - -sampleApplication_system: main.o - $(CXX) $(CXXFLAGS) -o sampleApplication main.o -L/usr/local/lib/ -lNanoLog -pthread -lrt + +main-install.o: main.cc + $(CXX) -I /usr/local/include -c -o $@ $< $(CXXFLAGS) + +sampleApplication_system: main-install.o + $(CXX) $(CXXFLAGS) -o sampleApplication main-install.o -L/usr/local/lib/ -lNanoLog -pthread -lrt From 4ff8ce6ceb3eda6bd53cfd4460fe3e90eb3d37fd Mon Sep 17 00:00:00 2001 From: xgdgsc Date: Thu, 2 Jul 2020 20:38:44 +0800 Subject: [PATCH 11/11] inc --- sample/GNUmakefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sample/GNUmakefile b/sample/GNUmakefile index cb2cb34..db2d4fe 100644 --- a/sample/GNUmakefile +++ b/sample/GNUmakefile @@ -45,7 +45,7 @@ clean-all: clean $(MAKE) clean-all -C $(NANOLOG_RUNTIME_DIR) main-install.o: main.cc - $(CXX) -I /usr/local/include -c -o $@ $< $(CXXFLAGS) + $(CXX) -I /usr/local/include/NanoLog/ -c -o $@ $< $(CXXFLAGS) sampleApplication_system: main-install.o $(CXX) $(CXXFLAGS) -o sampleApplication main-install.o -L/usr/local/lib/ -lNanoLog -pthread -lrt