diff --git a/fix-direct-scl_source-help-output.patch b/fix-direct-scl_source-help-output.patch new file mode 100644 index 0000000000000000000000000000000000000000..a4a4d4e2f4712ee8b4ce5cfd8f3afb25dc60bc9e --- /dev/null +++ b/fix-direct-scl_source-help-output.patch @@ -0,0 +1,33 @@ +From 54ca3bd3293bd9815712d7d8aaf1fe45f13e5d5e Mon Sep 17 00:00:00 2001 +From: Pavel Raiskup +Date: Fri, 11 Oct 2019 12:41:11 +0200 +Subject: [PATCH] fix direct 'scl_source --help' output + +Wrap everything into 'if then else fi' statement, so we don't actually need 'return' statement. Without this wrapping hack, we'd need either 'exit' statement (if executed by /usr/bin/scl_source) or 'return' for 'source scl_source'. For more info see #20. +--- + shell/scl_source | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/shell/scl_source b/shell/scl_source +index b0036bd..294740f 100755 +--- a/shell/scl_source ++++ b/shell/scl_source +@@ -9,8 +9,7 @@ Options: + + if [ $# -eq 0 -o $1 = "-h" -o $1 = "--help" ]; then + echo "$_scl_source_help" +- return 0 +-fi ++else # main operation mode + + + if [ -z "$_recursion" ]; then +@@ -73,3 +72,5 @@ if [ $_recursion == "false" ]; then + _scl_scriptlet_name="" + _recursion="false" + fi ++ ++fi # main operation mode +-- +2.23.0 + diff --git a/scl-utils.spec b/scl-utils.spec index 33b6c41faaee230023fb0a7ed6fcd1b3e8e9856b..249f3abb4ba8b8248809ce4d5197f06d95e0fa88 100644 --- a/scl-utils.spec +++ b/scl-utils.spec @@ -3,7 +3,7 @@ Name: scl-utils Epoch: 1 Version: 2.0.2 -Release: 1 +Release: 2 Summary: Utilities for alternative packaging License: GPLv2+ URL: https://github.com/sclorg/scl-utils @@ -15,6 +15,7 @@ Buildrequires: rpm-devel Requires: %{_bindir}/modulecmd Patch1: 0003-Scl-utils-layout-patch-from-fedora-famillecollet.com.patch Patch100: scl-utils-2.0.2-rhbz-1728450.patch +Patch101: fix-direct-scl_source-help-output.patch %description Run-time utility for alternative packaging. @@ -69,5 +70,8 @@ ln -s prefixes conf %{_rpmconfigdir}/brp-scl-python-bytecompile %changelog +* Fri Oct 08 2021 wangyue - 2.0.2-2 +- fix direct scl_source --help output + * Tue Sep 7 2021 zhengyaohui - 2.0.2-1 - package init