diff --git a/mockbuild_test/generate_sourcerpms.sh b/mockbuild_test/generate_sourcerpms.sh index d4faa2c..49a7a6f 100755 --- a/mockbuild_test/generate_sourcerpms.sh +++ b/mockbuild_test/generate_sourcerpms.sh @@ -10,9 +10,6 @@ fi DIST_RELEASE=$1 -STRATISD_SPEC_VERSION=$(rpmspec -q --srpm --qf "%{version}\n" stratisd.spec) -STRATISCLI_SPEC_VERSION=$(rpmspec -q --srpm --qf "%{version}\n" stratis-cli.spec) - if [ -z "$DIST_RELEASE" ]; then echo "Usage: $0 centos-stream | fedora-rawhide" exit 1 @@ -66,10 +63,10 @@ cd upstream git clone https://github.com/stratis-storage/stratisd git clone https://github.com/stratis-storage/stratis-cli cd stratisd -../../../release_management/create_artifacts.py ../../SOURCES/ --pre-release --specfile-path=../../SPECS/stratisd.spec stratisd "$STRATISD_SPEC_VERSION" --vendor-method=filtered +../../../release_management/create_artifacts.py ../../SOURCES/ --pre-release --specfile-path=../../SPECS/stratisd.spec stratisd --vendor-method=filtered cd .. cd stratis-cli -../../../release_management/create_artifacts.py ../../SOURCES/ --pre-release --specfile-path=../../SPECS/stratis-cli.spec stratis-cli "$STRATISCLI_SPEC_VERSION" +../../../release_management/create_artifacts.py ../../SOURCES/ --pre-release --specfile-path=../../SPECS/stratis-cli.spec stratis-cli cd ../.. # Remove the "Requires: stratisd" line in stratis-cli.spec. diff --git a/mockbuild_test/mockbuild.sh b/mockbuild_test/mockbuild.sh index 1669a1e..d0501ee 100755 --- a/mockbuild_test/mockbuild.sh +++ b/mockbuild_test/mockbuild.sh @@ -10,9 +10,6 @@ fi DIST_RELEASE=$1 -STRATISD_SPEC_VERSION=$(rpmspec -q --srpm --qf "%{version}\n" stratisd.spec) -STRATISCLI_SPEC_VERSION=$(rpmspec -q --srpm --qf "%{version}\n" stratis-cli.spec) - if [ -z "$DIST_RELEASE" ]; then echo "Usage: $0 centos-stream | fedora-rawhide" exit 1 @@ -79,12 +76,15 @@ cd upstream git clone https://github.com/stratis-storage/stratisd git clone https://github.com/stratis-storage/stratis-cli cd stratisd -../../../release_management/create_artifacts.py ../../SOURCES/ stratisd "$STRATISD_SPEC_VERSION" --vendor-method=filtered +../../../release_management/create_artifacts.py --specfile-path=../../SPECS/stratisd.spec ../../SOURCES/ stratisd --vendor-method=filtered cd .. cd stratis-cli -../../../release_management/create_artifacts.py ../../SOURCES/ stratis-cli "$STRATISCLI_SPEC_VERSION" +../../../release_management/create_artifacts.py --specfile-path=../../SPECS/stratis-cli.spec ../../SOURCES/ stratis-cli cd ../.. +STRATISD_SPEC_VERSION=$(rpmspec -q --srpm --qf "%{version}\n" SPECS/stratisd.spec) +STRATISCLI_SPEC_VERSION=$(rpmspec -q --srpm --qf "%{version}\n" SPECS/stratis-cli.spec) + mock --buildsrpm -r $MOCKCONFIG --spec SPECS/stratisd.spec --sources SOURCES/ --resultdir=SRPMS/stratisd/ mock --buildsrpm -r $MOCKCONFIG --spec SPECS/stratis-cli.spec --sources SOURCES/ --resultdir=SRPMS/stratis-cli/ mock --rebuild -r $MOCKCONFIG SRPMS/stratisd/stratisd-"$STRATISD_SPEC_VERSION"-D.$DIST.src.rpm --resultdir=RPMS/stratisd/ diff --git a/mockbuild_test/stratis-cli.spec b/mockbuild_test/stratis-cli.spec index 8f7ef56..c392f74 100644 --- a/mockbuild_test/stratis-cli.spec +++ b/mockbuild_test/stratis-cli.spec @@ -1,5 +1,5 @@ Name: stratis-cli -Version: 3.7.0 +Version: V Release: D%{?dist} Summary: Command-line tool for interacting with the Stratis daemon @@ -21,7 +21,7 @@ BuildRequires: python3-wcwidth %endif # Require the version of stratisd that supports a compatible D-Bus interface -Requires: (stratisd >= 3.7.0 with stratisd < 4.0.0) +Requires: (stratisd >= VS with stratisd < 4.0.0) # Exclude the same arches for stratis-cli as are excluded for stratisd ExclusiveArch: %{rust_arches} noarch diff --git a/mockbuild_test/stratisd.spec b/mockbuild_test/stratisd.spec index 33d6620..c6bcb3b 100644 --- a/mockbuild_test/stratisd.spec +++ b/mockbuild_test/stratisd.spec @@ -4,7 +4,7 @@ %global dracutdir %(pkg-config --variable=dracutdir dracut) Name: stratisd -Version: 3.7.0 +Version: V Release: D%{?dist} Summary: Daemon that manages block devices to create filesystems diff --git a/release_management/create_artifacts.py b/release_management/create_artifacts.py index c444564..00d1ad5 100755 --- a/release_management/create_artifacts.py +++ b/release_management/create_artifacts.py @@ -75,7 +75,6 @@ def main(): ) stratisd_parser.set_defaults(func=_stratisd_artifacts) - stratisd_parser.add_argument("version", action="store", help="version") stratisd_parser.add_argument( "--vendor-method", action="store", @@ -89,7 +88,6 @@ def main(): ) stratis_cli_parser.set_defaults(func=_stratis_cli_artifacts) - stratis_cli_parser.add_argument("version", action="store", help="version") parser.set_defaults(func=lambda _: parser.error("missing sub-command")) @@ -115,9 +113,6 @@ def _stratisd_artifacts(namespace): (source_version, _) = get_package_info(manifest_abs_path, "stratisd") - if source_version != namespace.version: - raise RuntimeError("Version mismatch.") - pre_release_suffix = calc_pre_release_suffix() if namespace.pre_release else None specfile_path = namespace.specfile_path @@ -166,9 +161,6 @@ def _stratis_cli_artifacts(namespace): (source_version, _) = get_python_package_info("stratis-cli") - if source_version != namespace.version: - raise RuntimeError("Version mismatch.") - pre_release_suffix = calc_pre_release_suffix() if namespace.pre_release else None specfile_path = namespace.specfile_path