aboutsummaryrefslogtreecommitdiff
path: root/utils/tini
diff options
context:
space:
mode:
authorIlya Lipnitskiy <ilya.lipnitskiy@gmail.com>2021-02-20 16:02:15 -0800
committerIlya Lipnitskiy <ilya.lipnitskiy@gmail.com>2021-02-20 16:02:15 -0800
commit5d8d4fbbcb5c5de9370711c19bb3510210989a98 (patch)
treed0754921833f413b7eb93fb6bb1b1c8a22fb0498 /utils/tini
parentd651082447b4392399a40ea1ae11d0bce4bfe83a (diff)
treewide: Run refresh on all packages
The crude loop I wrote to come up with this changeset: find -L package/feeds/packages/ -name patches | \ sed 's/patches$/refresh/' | sort | xargs make Signed-off-by: Ilya Lipnitskiy <ilya.lipnitskiy@gmail.com>
Diffstat (limited to 'utils/tini')
1 files changed, 17 insertions, 20 deletions
diff --git a/utils/tini/patches/001-override-git-version.patch b/utils/tini/patches/001-override-git-version.patch
index e1870d079..bd6484991 100644
--- a/utils/tini/patches/001-override-git-version.patch
+++ b/utils/tini/patches/001-override-git-version.patch
@@ -6,14 +6,12 @@ Date: Sat Oct 31 16:53:39 2020 +1000
* This to help when building from source snapshots
that don't have the .git file structure.
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 332b361..3f6f44b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -13,27 +13,37 @@ if(MINIMAL)
add_definitions(-DTINI_MINIMAL=1)
endif()
-
+
-# Extract git version and dirty-ness
-execute_process (
- COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" log -n 1 --date=local --pretty=format:%h
@@ -21,24 +19,11 @@ index 332b361..3f6f44b 100644
- RESULT_VARIABLE git_version_check_ret
- OUTPUT_VARIABLE tini_VERSION_GIT
-)
--
--execute_process(
-- COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" status --porcelain --untracked-files=no
-- WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
-- OUTPUT_VARIABLE git_dirty_check_out
--)
--
--if("${git_version_check_ret}" EQUAL 0)
-- set(tini_VERSION_GIT " - git.${tini_VERSION_GIT}")
-- if(NOT "${git_dirty_check_out}" STREQUAL "")
-- set(tini_VERSION_GIT "${tini_VERSION_GIT}-dirty")
-- endif()
+# Set the git version
+if (NOT "${TINI_VERSION_GIT}" STREQUAL "")
+ # Set by the user directly
+ set(tini_VERSION_GIT "${TINI_VERSION_GIT}")
- else()
-- set(tini_VERSION_GIT "")
++else()
+ # Extract git version
+ execute_process (
+ COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" log -n 1 --date=local --pretty=format:%h
@@ -46,7 +31,12 @@ index 332b361..3f6f44b 100644
+ RESULT_VARIABLE git_version_check_ret
+ OUTPUT_VARIABLE tini_VERSION_GIT
+ )
-+
+
+-execute_process(
+- COMMAND git --git-dir "${PROJECT_SOURCE_DIR}/.git" --work-tree "${PROJECT_SOURCE_DIR}" status --porcelain --untracked-files=no
+- WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
+- OUTPUT_VARIABLE git_dirty_check_out
+-)
+ if("${git_version_check_ret}" EQUAL 0)
+ # Extract git dirty-ness
+ execute_process(
@@ -54,7 +44,14 @@ index 332b361..3f6f44b 100644
+ WORKING_DIRECTORY "${PROJECT_SOURCE_DIR}"
+ OUTPUT_VARIABLE git_dirty_check_out
+ )
-+
+
+-if("${git_version_check_ret}" EQUAL 0)
+- set(tini_VERSION_GIT " - git.${tini_VERSION_GIT}")
+- if(NOT "${git_dirty_check_out}" STREQUAL "")
+- set(tini_VERSION_GIT "${tini_VERSION_GIT}-dirty")
+- endif()
+-else()
+- set(tini_VERSION_GIT "")
+ if(NOT "${git_dirty_check_out}" STREQUAL "")
+ set(tini_VERSION_GIT "${tini_VERSION_GIT}-dirty")
+ endif()
@@ -66,5 +63,5 @@ index 332b361..3f6f44b 100644
+if(NOT ${tini_VERSION_GIT} STREQUAL "")
+ set(tini_VERSION_GIT " - git.${tini_VERSION_GIT}")
endif()
-
+
# Flags