From 3dba1f05face918b92779c7249fa9d5015828c1d Mon Sep 17 00:00:00 2001 From: Artem Prilutskiy Date: Tue, 9 Aug 2016 14:20:46 +0300 Subject: [PATCH 1/6] Fixed issue with dependancy on librt --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index cb924ba..4ac91b3 100644 --- a/Makefile +++ b/Makefile @@ -7,10 +7,11 @@ PREFIX = $(DESTDIR)/opt/CronosAgent ifeq ($(OS), Linux) FLAGS += -rdynamic - KIND := $(shell grep -E "^6.0" /etc/debian_version > /dev/null ; echo $?) -ifneq ($(KIND), 0) +ifeq ($(shell lsb_release -i -s), Debian) +ifeq ($(shell grep -E "^6.0" /etc/debian_version > /dev/null ; echo $?), 0) LIBRARIES += rt endif +endif ifeq ($(USE_OPENSSL), yes) FLAGS += -DUSE_OPENSSL DEPENDENCIES += openssl From 10cebfbb9c406b80f65c4cd6282d837e238ef339 Mon Sep 17 00:00:00 2001 From: Artem Prilutskiy Date: Tue, 9 Aug 2016 14:44:51 +0300 Subject: [PATCH 2/6] .. --- OpenWRT/Makefile | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/OpenWRT/Makefile b/OpenWRT/Makefile index b62948d..b5cbffc 100644 --- a/OpenWRT/Makefile +++ b/OpenWRT/Makefile @@ -1,10 +1,12 @@ include $(TOPDIR)/rules.mk +X_DOLLAR:=$$ +X_SOURCE_DIR:=$(CURDIR)/source + PKG_NAME:=cronosagent PKG_VERSION:=$(shell grep -o -E '[0-9]+' $(CURDIR)/source/Version.h) PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_BUILD_DEPENDS:= -X_SOURCE_DIR:=$(CURDIR)/source include $(INCLUDE_DIR)/package.mk @@ -52,10 +54,10 @@ define Package/cronosagent/postinst /etc/init.d/cronosagent start grep cronosagent /etc/crontabs/root > /dev/null -if [ "$?" -eq "1" ] +if [ "$(X_DOLLAR)?" -eq "1" ] then cat << EOF >> /etc/crontabs/root -*/10 * * * * test -n "$(ls /etc/rc.d/S??cronosagent)" -a -z "$(pidof cronosagent)" && /etc/init.d/cronosagent start +*/10 * * * * test -n "$(X_DOLLAR)(ls /etc/rc.d/S??cronosagent)" -a -z "$(X_DOLLAR)(pidof cronosagent)" && /etc/init.d/cronosagent start EOF fi From ff52d4e79fb31bdd077d3572747311c879ec6c64 Mon Sep 17 00:00:00 2001 From: PD0ZRY Rudy Date: Tue, 9 Aug 2016 16:13:58 +0000 Subject: [PATCH 3/6] Update .gitlab-ci.yml --- .gitlab-ci.yml | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0fa945d..d39c534 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -19,4 +19,19 @@ debian_386_amd64: tags: - debian - i386 - - amd64 \ No newline at end of file + - amd64 + +debian_armv6: + stage: build + script: + - make debian-package + - cp ../cronos*.deb . + - rm ../cronos* + only: + - master + artifacts: + paths: + - cronos*.deb + tags: + - debian + - armv6 \ No newline at end of file From debc15abd58bcb7624ec522e8233f744fc746419 Mon Sep 17 00:00:00 2001 From: PD0ZRY Rudy Date: Tue, 9 Aug 2016 16:27:18 +0000 Subject: [PATCH 4/6] Update .gitlab-ci.yml --- .gitlab-ci.yml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d39c534..ac59f5c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,9 +1,3 @@ -before_script: - - sudo apt-get update -qq && sudo apt-get install -y -qq build-essential dpkg-dev libssl-dev debhelper -stages: - - build - - debian_386_amd64: stage: build script: @@ -21,7 +15,7 @@ debian_386_amd64: - i386 - amd64 -debian_armv6: +debian_armhf: stage: build script: - make debian-package From 845bae9c3487c71ee1f4a1ef2c397033ab2a33e4 Mon Sep 17 00:00:00 2001 From: PD0ZRY Rudy Date: Tue, 9 Aug 2016 16:32:40 +0000 Subject: [PATCH 5/6] Update .gitlab-ci.yml --- .gitlab-ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ac59f5c..9f27f27 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,6 @@ debian_386_amd64: stage: build + environment: master script: - make debian-package - ARCH=i386 make debian-package @@ -17,6 +18,7 @@ debian_386_amd64: debian_armhf: stage: build + environment: master script: - make debian-package - cp ../cronos*.deb . From 911195052c93a465d6b72d8e84b465286541cb02 Mon Sep 17 00:00:00 2001 From: PD0ZRY Rudy Date: Tue, 9 Aug 2016 16:36:17 +0000 Subject: [PATCH 6/6] Update .gitlab-ci.yml --- .gitlab-ci.yml | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9f27f27..a93f8b0 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,8 +1,21 @@ -debian_386_amd64: +debian_amd64: stage: build - environment: master script: - make debian-package + - cp ../cronos*.deb . + - rm ../cronos* + only: + - master + artifacts: + paths: + - cronos*.deb + tags: + - debian + - amd64 + +debian_386: + stage: build + script: - ARCH=i386 make debian-package - cp ../cronos*.deb . - rm ../cronos* @@ -14,11 +27,9 @@ debian_386_amd64: tags: - debian - i386 - - amd64 - + debian_armhf: stage: build - environment: master script: - make debian-package - cp ../cronos*.deb .