Commit 1b2e4d3a29996a750c66204d934417092927b733

Thomas de Grivel 2023-02-15T01:45:29

wip shpkg_ci

diff --git a/share/shpkg/shpkg.subr b/share/shpkg/shpkg.subr
index 410d57c..2804e30 100644
--- a/share/shpkg/shpkg.subr
+++ b/share/shpkg/shpkg.subr
@@ -396,7 +396,7 @@ shpkg_build () {
         if [ "x${SHPKG_REPO_DIR}" = "x" ]; then
             err 1 "shpkg_build: unknown repo: $SHPKG_REPO"
         fi
-        shpkg_build_status "${SHPKG_REPO}" running
+        shpkg_build_status "${SHPKG_REPO}" running 2>/dev/null || true
         SHPKG_REPO_OBJ_DIR="${SHPKG_OBJ_DIR}/${SHPKG_REPO_DIR}"
         SHPKG_REPO_SRC_DIR="${SHPKG_SRC_DIR}/${SHPKG_REPO_DIR}"
         SHPKG_REPO_VERSION="$(shpkg_version "${SHPKG_REPO}")"
@@ -407,22 +407,24 @@ shpkg_build () {
             if [ -f "${SHPKG_REPO_SRC_DIR}/Makefile" ]; then
 		( verbose 1 cd "${SHPKG_REPO_SRC_DIR}"
                   if verbose 1 make -j "${SHPKG_NCPU}"; then
-                      shpkg_build_status "${SHPKG_REPO}" ok
+                      shpkg_build_status "${SHPKG_REPO}" ok 2>/dev/null || true
                   else
-                      shpkg_build_status "${SHPKG_REPO}" ko
+                      shpkg_build_status "${SHPKG_REPO}" ko 2>/dev/null || true
                       false
                   fi ; )
             elif [ -f "${SHPKG_SRC_DIR}/${SHPKG_REPO_DIR}/CMakeLists.txt" ]; then
-		cmake -j "${SHPKG_NCPU}" --build "${SHPKG_REPO_OBJ_DIR}"
+		if verbose 1 cmake -j "${SHPKG_NCPU}" --build "${SHPKG_REPO_OBJ_DIR}"; then
+                    shpkg_build_status "${SHPKG_REPO}" ok 2>/dev/null || true
+                else
+                    shpkg_build_status "${SHPKG_REPO}" ko 2>/dev/null || true
+                    false
+                fi
             fi
             shpkg__tag_write build-done
 	fi
     done
 }
 
-shpkg_build_status () {
-}
-
 shpkg_checksum () {
     find . -type f | cut -c 3- | while read F; do
         "shpkg_${SHPKG_SHA256}" "$F"