From 148afbbeb55d7a6d2049a22dccf12eaa4940933b Mon Sep 17 00:00:00 2001 From: Stijn Tintel Date: Sun, 14 Aug 2022 00:52:24 +0300 Subject: [PATCH 1/3] vallumd: point PKG_SOURCE_URL to Codeberg The github repository has been archived; the project is now hosted on Codeberg. Update the PKG_SOURCE_URL accordingly. Gitea doesn't seem to add a version suffix to the directory in the tarball, so use a custom PKG_BUILD_DIR. Signed-off-by: Stijn Tintel --- net/vallumd/Makefile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/net/vallumd/Makefile b/net/vallumd/Makefile index 5edc128a5..8a20fd74c 100644 --- a/net/vallumd/Makefile +++ b/net/vallumd/Makefile @@ -9,11 +9,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vallumd PKG_VERSION:=0.2.0 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://codeload.github.com/stintel/vallumd/tar.gz/$(PKG_VERSION)? -PKG_HASH:=7c1baffa3f7889c9c6f2795aac134c50a309ef201764d5ce6bbbce5d657416c0 +PKG_SOURCE_URL:=https://codeberg.org/stintel/vallumd/archive/$(PKG_VERSION).tar.gz? +PKG_HASH:=b4459e9bec2eab2b1a88ea1830333145033f0ddb7ae1c6ccae83560227ce8253 +PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) PKG_MAINTAINER:=Stijn Tintel PKG_LICENSE:=GPL-3.0 From b40d47f259b19415a0542042adb7b99e40a959be Mon Sep 17 00:00:00 2001 From: Stijn Tintel Date: Fri, 18 Nov 2022 08:31:35 +0200 Subject: [PATCH 2/3] vallumd: bump to 0.2.1 Signed-off-by: Stijn Tintel --- net/vallumd/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/net/vallumd/Makefile b/net/vallumd/Makefile index 8a20fd74c..49341aa6c 100644 --- a/net/vallumd/Makefile +++ b/net/vallumd/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vallumd -PKG_VERSION:=0.2.0 -PKG_RELEASE:=2 +PKG_VERSION:=0.2.1 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://codeberg.org/stintel/vallumd/archive/$(PKG_VERSION).tar.gz? -PKG_HASH:=b4459e9bec2eab2b1a88ea1830333145033f0ddb7ae1c6ccae83560227ce8253 +PKG_HASH:=eb48bf42295f1b33b2c0a5cf2ca18e8712ec42b95fc1e859e657b2bd56dec95e PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) PKG_MAINTAINER:=Stijn Tintel From 1136e0ac3ca4eacd2de0ca51db0a2e652e0f8cce Mon Sep 17 00:00:00 2001 From: Stijn Tintel Date: Fri, 18 Nov 2022 08:43:31 +0200 Subject: [PATCH 3/3] vallumd: bump to 0.2.2 Add upstream patch to fix building from source tarballs. Signed-off-by: Stijn Tintel --- net/vallumd/Makefile | 4 +- ...skip-git-magic-if-no-.git-dir-exists.patch | 78 +++++++++++++++++++ 2 files changed, 80 insertions(+), 2 deletions(-) create mode 100644 net/vallumd/patches/001-CMake-skip-git-magic-if-no-.git-dir-exists.patch diff --git a/net/vallumd/Makefile b/net/vallumd/Makefile index 49341aa6c..75b2470da 100644 --- a/net/vallumd/Makefile +++ b/net/vallumd/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=vallumd -PKG_VERSION:=0.2.1 +PKG_VERSION:=0.2.2 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://codeberg.org/stintel/vallumd/archive/$(PKG_VERSION).tar.gz? -PKG_HASH:=eb48bf42295f1b33b2c0a5cf2ca18e8712ec42b95fc1e859e657b2bd56dec95e +PKG_HASH:=f88cafce41cc118862869268b5e6c9b315a6f084aa8a498d4484e9dac49c575c PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) PKG_MAINTAINER:=Stijn Tintel diff --git a/net/vallumd/patches/001-CMake-skip-git-magic-if-no-.git-dir-exists.patch b/net/vallumd/patches/001-CMake-skip-git-magic-if-no-.git-dir-exists.patch new file mode 100644 index 000000000..82a659dfb --- /dev/null +++ b/net/vallumd/patches/001-CMake-skip-git-magic-if-no-.git-dir-exists.patch @@ -0,0 +1,78 @@ +From b70137d0cc62be7f43816a3ba33b7c3e6a2fbd4e Mon Sep 17 00:00:00 2001 +From: Stijn Tintel +Date: Fri, 18 Nov 2022 09:19:02 +0200 +Subject: [PATCH] CMake: skip git magic if no .git dir exists + +The checks to fail CMake if git describe isn't working break build when +building from source tarballs. + +Test if there is a git directory, and completely skip the git magic if +not. + +Fixes: f42e7beec46e ("CI: add explicit clone to fetch tags") +Signed-off-by: Stijn Tintel +--- + CMakeLists.txt | 51 +++++++++++++++++++++++++------------------------- + 1 file changed, 26 insertions(+), 25 deletions(-) + +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -9,35 +9,36 @@ set (VERSION_MAJOR 0) + set (VERSION_MINOR 2) + set (VERSION_PATCH 2) + +-execute_process(COMMAND git describe --tags --dirty +- OUTPUT_VARIABLE GIT_DESCRIBE +- OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET) +-execute_process(COMMAND git describe --abbrev=0 +- OUTPUT_VARIABLE GIT_LAST_TAG +- OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET) ++if (EXISTS .git/) ++ execute_process(COMMAND git describe --tags --dirty ++ OUTPUT_VARIABLE GIT_DESCRIBE ++ OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET) ++ execute_process(COMMAND git describe --abbrev=0 ++ OUTPUT_VARIABLE GIT_LAST_TAG ++ OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_QUIET) + +-string(LENGTH "${GIT_DESCRIBE}" GIT_DESCRIBE_LEN) +-string(LENGTH "${GIT_LAST_TAG}" GIT_LAST_TAG_LEN) ++ string(LENGTH "${GIT_DESCRIBE}" GIT_DESCRIBE_LEN) ++ string(LENGTH "${GIT_LAST_TAG}" GIT_LAST_TAG_LEN) + +-if (GIT_DESCRIBE_LEN EQUAL 0 OR GIT_LAST_TAG_LEN EQUAL 0) +- message(FATAL_ERROR "git describe output empty") +-endif () ++ if (GIT_DESCRIBE_LEN EQUAL 0 OR GIT_LAST_TAG_LEN EQUAL 0) ++ message(FATAL_ERROR "git describe output empty") ++ endif () + +-string(REGEX REPLACE "^${GIT_LAST_TAG}-" "" GIT_DESCRIBE_NOTAG "${GIT_DESCRIBE}") ++ string(REGEX REPLACE "^${GIT_LAST_TAG}-" "" GIT_DESCRIBE_NOTAG "${GIT_DESCRIBE}") + +-if (NOT "${GIT_DESCRIBE}" STREQUAL "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") +- if ("${GIT_LAST_TAG}" VERSION_LESS +- "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") +- string(REGEX REPLACE "^${GIT_LAST_TAG}-" +- "" VERSION_TWEAK "0-pre-${GIT_DESCRIBE_NOTAG}") +- else () +- string(REGEX REPLACE +- "^${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}-" +- "" VERSION_TWEAK "${GIT_DESCRIBE}") ++ if (NOT "${GIT_DESCRIBE}" STREQUAL "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") ++ if ("${GIT_LAST_TAG}" VERSION_LESS ++ "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}") ++ string(REGEX REPLACE "^${GIT_LAST_TAG}-" ++ "" VERSION_TWEAK "0-pre-${GIT_DESCRIBE_NOTAG}") ++ else () ++ string(REGEX REPLACE ++ "^${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}-" ++ "" VERSION_TWEAK "${GIT_DESCRIBE}") ++ endif () + endif () + endif () + +- + configure_file ( + "${PROJECT_SOURCE_DIR}/src/config.h.in" + "${PROJECT_BINARY_DIR}/config.h"