From e212e28efffa2d6380a823764d4245585936bd86 Mon Sep 17 00:00:00 2001 From: Miro HronĨok Date: Mar 03 2022 17:20:33 +0000 Subject: Drop redundant Source and Patch numbers See https://lists.fedoraproject.org/archives/list/packaging@lists.fedoraproject.org/thread/BG5SVFAKGNVDJFHGZARABWGW2RRHN22G/ Since RPM 4.15, numbering Sources and Patches is redundant. I've left the numbers in examples where they matter. --- diff --git a/guidelines/modules/ROOT/examples/golang/golang-cloud-google-go.spec b/guidelines/modules/ROOT/examples/golang/golang-cloud-google-go.spec index c5bfafa..3a2ad6c 100644 --- a/guidelines/modules/ROOT/examples/golang/golang-cloud-google-go.spec +++ b/guidelines/modules/ROOT/examples/golang/golang-cloud-google-go.spec @@ -29,7 +29,7 @@ Summary: Google Cloud client libraries for Go # Upstream license specification: Apache-2.0 License: ASL 2.0 URL: %{gourl} -Source0: %{gosource} +Source: %{gosource} %if %{without bootstrap} BuildRequires: golang(github.com/golang/mock/gomock) diff --git a/guidelines/modules/ROOT/examples/golang/golang-github-sirupsen-logrus.spec b/guidelines/modules/ROOT/examples/golang/golang-github-sirupsen-logrus.spec index 8b3f861..e83eaec 100644 --- a/guidelines/modules/ROOT/examples/golang/golang-github-sirupsen-logrus.spec +++ b/guidelines/modules/ROOT/examples/golang/golang-github-sirupsen-logrus.spec @@ -18,7 +18,7 @@ Release: 1%{?dist} Summary: Structured logger for Go License: MIT URL: %{gourl} -Source0: %{gosource} +Source: %{gosource} BuildRequires: golang(golang.org/x/crypto/ssh/terminal) BuildRequires: golang(github.com/stretchr/testify/assert) diff --git a/guidelines/modules/ROOT/examples/golang/golang-github-stretchr-testify.spec b/guidelines/modules/ROOT/examples/golang/golang-github-stretchr-testify.spec index 7bfbe6f..84faa82 100644 --- a/guidelines/modules/ROOT/examples/golang/golang-github-stretchr-testify.spec +++ b/guidelines/modules/ROOT/examples/golang/golang-github-stretchr-testify.spec @@ -21,7 +21,7 @@ Release: 1%{?dist} Summary: Tools for testifying that your code will behave as you intend License: BSD URL: %{gourl} -Source0: %{gosource} +Source: %{gosource} BuildRequires: golang(github.com/davecgh/go-spew/spew) BuildRequires: golang(github.com/pmezard/go-difflib/difflib) diff --git a/guidelines/modules/ROOT/examples/golang/golang-gopkg-square-jose-2.spec b/guidelines/modules/ROOT/examples/golang/golang-gopkg-square-jose-2.spec index f3cc8e5..ea08bb3 100644 --- a/guidelines/modules/ROOT/examples/golang/golang-gopkg-square-jose-2.spec +++ b/guidelines/modules/ROOT/examples/golang/golang-gopkg-square-jose-2.spec @@ -26,7 +26,7 @@ Summary: An implementation of JOSE standards (JWE, JWS, JWT) in Go # json/ is BSD License: ASL 2.0 and BSD URL: %{gourl} -Source0: %{gosource} +Source: %{gosource} BuildRequires: golang(golang.org/x/crypto/ed25519) BuildRequires: golang(golang.org/x/crypto/pbkdf2) diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-0-source-minimal.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-0-source-minimal.spec index 391f421..ac1266c 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-0-source-minimal.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-0-source-minimal.spec @@ -59,8 +59,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-1-source-full.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-1-source-full.spec index 2e21f48..8b7ec9b 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-1-source-full.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-1-source-full.spec @@ -79,8 +79,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-2-alternative-import-path-minimal.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-2-alternative-import-path-minimal.spec index f5f72d0..72ba86a 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-2-alternative-import-path-minimal.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-2-alternative-import-path-minimal.spec @@ -38,8 +38,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-3-alternative-import-path-full.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-3-alternative-import-path-full.spec index a0e308c..58d75bd 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-3-alternative-import-path-full.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-3-alternative-import-path-full.spec @@ -64,8 +64,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-4-binary-minimal.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-4-binary-minimal.spec index 19e1e8f..c578324 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-4-binary-minimal.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-4-binary-minimal.spec @@ -37,8 +37,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-5-binary-full.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-5-binary-full.spec index 2c227a7..c98b731 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-5-binary-full.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-5-binary-full.spec @@ -54,8 +54,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/golang/spectemplate-go-7-manual.spec b/guidelines/modules/ROOT/examples/golang/spectemplate-go-7-manual.spec index f11fe12..a524b72 100644 --- a/guidelines/modules/ROOT/examples/golang/spectemplate-go-7-manual.spec +++ b/guidelines/modules/ROOT/examples/golang/spectemplate-go-7-manual.spec @@ -27,8 +27,8 @@ Name: %{goname} Version: Release: 1%{?dist} Summary: -URL: %{gourl} -Source0: %{gosource} +URL: %{gourl} +Source: %{gosource} %description %{common_description} diff --git a/guidelines/modules/ROOT/examples/ocaml-example.spec b/guidelines/modules/ROOT/examples/ocaml-example.spec index 0a1c5d2..8377c97 100644 --- a/guidelines/modules/ROOT/examples/ocaml-example.spec +++ b/guidelines/modules/ROOT/examples/ocaml-example.spec @@ -8,7 +8,7 @@ Summary: OCaml library for fooing bars License: LGPL+ URL: https://www.example.com/foolib -Source0: https://www.example.com/foolib-1.2.3.tar.gz +Source: https://www.example.com/foolib-1.2.3.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: ocaml, ocaml-findlib-devel diff --git a/guidelines/modules/ROOT/examples/python-example.spec b/guidelines/modules/ROOT/examples/python-example.spec index 044cdf2..3ef7da9 100644 --- a/guidelines/modules/ROOT/examples/python-example.spec +++ b/guidelines/modules/ROOT/examples/python-example.spec @@ -7,7 +7,7 @@ Summary: Example python module License: MIT URL: https://pypi.python.org/pypi/example -Source0: %{pypi_source} +Source: %{pypi_source} BuildArch: noarch diff --git a/guidelines/modules/ROOT/examples/rust-ripgrep.spec b/guidelines/modules/ROOT/examples/rust-ripgrep.spec index 6de6efe..93bb6b6 100644 --- a/guidelines/modules/ROOT/examples/rust-ripgrep.spec +++ b/guidelines/modules/ROOT/examples/rust-ripgrep.spec @@ -16,7 +16,7 @@ Source: %{crates_source} # Initial patched metadata # * No simd # * No jemalloc -Patch0: ripgrep-fix-metadata.diff +Patch: ripgrep-fix-metadata.diff ExclusiveArch: %{rust_arches} diff --git a/guidelines/modules/ROOT/pages/D.adoc b/guidelines/modules/ROOT/pages/D.adoc index 3c51aab..dd8a088 100644 --- a/guidelines/modules/ROOT/pages/D.adoc +++ b/guidelines/modules/ROOT/pages/D.adoc @@ -63,7 +63,7 @@ Summary: Does foo in D Group: Development/Libraries License: LGPLv2+ URL: https://anywhere.com/ -Source0: https://anywhere.com/%{name}-%{version}.tar.bz2 +Source: https://anywhere.com/%{name}-%{version}.tar.bz2 BuildRequires: ldc Requires: tango diff --git a/guidelines/modules/ROOT/pages/Drupal7.adoc b/guidelines/modules/ROOT/pages/Drupal7.adoc index 6731932..fae0195 100644 --- a/guidelines/modules/ROOT/pages/Drupal7.adoc +++ b/guidelines/modules/ROOT/pages/Drupal7.adoc @@ -148,7 +148,7 @@ Summary: __SUMMARY__ Group: Applications/Publishing License: GPLv2+ URL: https://drupal.org/project/%{module} -Source0: https://ftp.drupal.org/files/projects/%{module}-7.x-%{version}.tar.gz +Source: https://ftp.drupal.org/files/projects/%{module}-7.x-%{version}.tar.gz Source1: %{name}-RPM-README.txt BuildArch: noarch @@ -204,7 +204,7 @@ Summary: __SUMMARY__ Group: Applications/Publishing License: GPLv2+ URL: https://drupal.org/project/%{theme} -Source0: https://ftp.drupal.org/files/projects/%{theme}-7.x-%{version}.tar.gz +Source: https://ftp.drupal.org/files/projects/%{theme}-7.x-%{version}.tar.gz Source1: %{name}-RPM-README.txt BuildArch: noarch diff --git a/guidelines/modules/ROOT/pages/FontsPolicy.adoc b/guidelines/modules/ROOT/pages/FontsPolicy.adoc index b4b49f8..cf8838d 100644 --- a/guidelines/modules/ROOT/pages/FontsPolicy.adoc +++ b/guidelines/modules/ROOT/pages/FontsPolicy.adoc @@ -433,7 +433,7 @@ Then package sources are declared the usual way. .Source declarations [source,RPMSpec] ---- -Source0: +Source: Source10: [number]-%{fontpkgname}.conf ---- diff --git a/guidelines/modules/ROOT/pages/Golang.adoc b/guidelines/modules/ROOT/pages/Golang.adoc index c31cae3..f6b8954 100644 --- a/guidelines/modules/ROOT/pages/Golang.adoc +++ b/guidelines/modules/ROOT/pages/Golang.adoc @@ -485,7 +485,7 @@ Release: 1%{?dist} Summary: License: URL: %{gourl} -Source0: %{gosource} +Source: %{gosource} ---- You can replace them with manual definitions. diff --git a/guidelines/modules/ROOT/pages/Haskell.adoc b/guidelines/modules/ROOT/pages/Haskell.adoc index ec998b2..9936bb9 100644 --- a/guidelines/modules/ROOT/pages/Haskell.adoc +++ b/guidelines/modules/ROOT/pages/Haskell.adoc @@ -27,7 +27,7 @@ Summary: @SUMMARY@ License: @LICENSE@ URL: https://hackage.haskell.org/package/%{pkg_name} -Source0: https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz +Source: https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz BuildRequires: ghc-Cabal-devel BuildRequires: ghc-rpm-macros @@ -100,7 +100,7 @@ Summary: @SUMMARY@ License: @LICENSE@ URL: https://hackage.haskell.org/package/%{name} -Source0: https://hackage.haskell.org/package/%{name}-%{version}/%{name}-%{version}.tar.gz +Source: https://hackage.haskell.org/package/%{name}-%{version}/%{name}-%{version}.tar.gz BuildRequires: ghc-Cabal-devel BuildRequires: ghc-rpm-macros @@ -140,7 +140,7 @@ Summary: @SUMMARY@ License: @LICENSE@ URL: https://hackage.haskell.org/package/%{name} -Source0: https://hackage.haskell.org/package/%{name}-%{version}/%{name}-%{version}.tar.gz +Source: https://hackage.haskell.org/package/%{name}-%{version}/%{name}-%{version}.tar.gz BuildRequires: ghc-Cabal-devel BuildRequires: ghc-rpm-macros diff --git a/guidelines/modules/ROOT/pages/Lisp.adoc b/guidelines/modules/ROOT/pages/Lisp.adoc index 59b10c4..fde8f0f 100644 --- a/guidelines/modules/ROOT/pages/Lisp.adoc +++ b/guidelines/modules/ROOT/pages/Lisp.adoc @@ -50,7 +50,7 @@ Summary: # see normal package guidelines (SNPG) Group: # SNPG License: # SNPG URL: # SNPG -Source0: # SNPG +Source: # SNPG BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: common-lisp-controller diff --git a/guidelines/modules/ROOT/pages/MinGW.adoc b/guidelines/modules/ROOT/pages/MinGW.adoc index c43bdcf..3e25433 100644 --- a/guidelines/modules/ROOT/pages/MinGW.adoc +++ b/guidelines/modules/ROOT/pages/MinGW.adoc @@ -465,7 +465,7 @@ Summary: MinGW compiled example library License: LGPLv2+ URL: https://fedoraproject.org -Source0: https://fedoraproject.org/example-%{version}.tar.bz2 +Source: https://fedoraproject.org/example-%{version}.tar.bz2 BuildArch: noarch diff --git a/guidelines/modules/ROOT/pages/Octave.adoc b/guidelines/modules/ROOT/pages/Octave.adoc index 5babb98..31fe836 100644 --- a/guidelines/modules/ROOT/pages/Octave.adoc +++ b/guidelines/modules/ROOT/pages/Octave.adoc @@ -29,7 +29,7 @@ The following macros are defined in /etc/rpm/macros.octave in the octave 3.4.0 ( # Run an octave command - quietly with no startup files %octave_cmd() -# Build Source0 into a package tar file in a temporary location +# Build Source into a package tar file in a temporary location %octave_pkg_build # Install a package. We use the octave pkg install command to install the @@ -92,7 +92,7 @@ Summary: Image processing for Octave Group: Applications/Engineering License: GPLv2+ URL: https://octave.sourceforge.io/image/ -Source0: https://downloads.sourceforge.net/octave/%{octpkg}-%{version}.tar.gz +Source: https://downloads.sourceforge.net/octave/%{octpkg}-%{version}.tar.gz BuildRequires: octave-devel @@ -153,7 +153,7 @@ Summary: Actuarial functions for Octave Group: Applications/Engineering License: GPLv2+ URL: https://octave.sourceforge.io -Source0: https://downloads.sourceforge.net/octave/%{octpkg}-%{version}.tar.gz +Source: https://downloads.sourceforge.net/octave/%{octpkg}-%{version}.tar.gz BuildArch: noarch BuildRequires: octave-devel diff --git a/guidelines/modules/ROOT/pages/PatchUpstreamStatus.adoc b/guidelines/modules/ROOT/pages/PatchUpstreamStatus.adoc index becf594..6c5efdc 100644 --- a/guidelines/modules/ROOT/pages/PatchUpstreamStatus.adoc +++ b/guidelines/modules/ROOT/pages/PatchUpstreamStatus.adoc @@ -6,7 +6,7 @@ All patches in Fedora spec files *SHOULD* have a comment above them about their .... # https://bugzilla.gnome.org/show_bug.cgi?id=12345 -Patch0: gnome-panel-fix-frobnicator.patch +Patch: gnome-panel-fix-frobnicator.patch .... The above is perfectly acceptable; but if you prefer, a brief comment about what the patch does above can be helpful: @@ -14,7 +14,7 @@ The above is perfectly acceptable; but if you prefer, a brief comment about what .... # Don't crash with frobnicator applet # https://bugzilla.gnome.org/show_bug.cgi?id=12345 -Patch0: gnome-panel-fix-frobnicator.patch +Patch: gnome-panel-fix-frobnicator.patch .... Sending patches upstream and adding this comment will help ensure that Fedora is acting as a good FLOSS citizen (see https://docs.fedoraproject.org/en-US/package-maintainers/Staying_Close_to_Upstream_Projects/[Staying Close to Upstream Projects]). It will help others (and even you) down the line in package maintenance by knowing what patches are likely to appear in a new upstream release. @@ -25,12 +25,12 @@ You can indicate that you have sent the patch upstream and any known status: .... # Sent upstream via email 20080407 -Patch0: foobar-fix-the-bar.patch +Patch: foobar-fix-the-bar.patch .... .... # Upstream has applied this in SVN trunk -Patch0: foobar-fix-the-baz.patch +Patch: foobar-fix-the-baz.patch .... === Fedora-specific (or rejected upstream) patches @@ -39,7 +39,7 @@ It may be that some patches truly are Fedora-specific; in that case, say so: .... # This patch is temporary until we land the long term System.loadLibrary fix in OpenJDK -Patch0: jna-jni-path.patch +Patch: jna-jni-path.patch .... == Why upstream? diff --git a/guidelines/modules/ROOT/pages/Python.adoc b/guidelines/modules/ROOT/pages/Python.adoc index 158fc8e..aa08e23 100644 --- a/guidelines/modules/ROOT/pages/Python.adoc +++ b/guidelines/modules/ROOT/pages/Python.adoc @@ -1175,7 +1175,7 @@ Summary: Example Python library License: MIT URL: https://github.com/fedora-python/Pello -Source0: %{url}/archive/v%{version}/Pello-%{version}.tar.gz +Source: %{url}/archive/v%{version}/Pello-%{version}.tar.gz BuildArch: noarch BuildRequires: python3-devel @@ -1245,7 +1245,7 @@ Summary: ... License: ... URL: https://... -Source0: %{url}/archive/v%{version}/...-%{version}.tar.gz / %{pypi_source ...} +Source: %{url}/archive/v%{version}/...-%{version}.tar.gz / %{pypi_source ...} BuildArch: noarch / BuildRequires: gcc BuildRequires: python3-devel diff --git a/guidelines/modules/ROOT/pages/Python_Appendix.adoc b/guidelines/modules/ROOT/pages/Python_Appendix.adoc index 6184538..910fb6f 100644 --- a/guidelines/modules/ROOT/pages/Python_Appendix.adoc +++ b/guidelines/modules/ROOT/pages/Python_Appendix.adoc @@ -47,7 +47,7 @@ Summary: An example python module License: MIT URL: https://pypi.python.org/pypi/%{srcname} -Source0: %pypi_source +Source: %pypi_source BuildArch: noarch @@ -202,7 +202,7 @@ Summary: An example python module License: MIT URL: https://pypi.python.org/pypi/%{srcname} -Source0: %pypi_source +Source: %pypi_source BuildArch: noarch diff --git a/guidelines/modules/ROOT/pages/R.adoc b/guidelines/modules/ROOT/pages/R.adoc index 5403dac..ae47a06 100644 --- a/guidelines/modules/ROOT/pages/R.adoc +++ b/guidelines/modules/ROOT/pages/R.adoc @@ -41,7 +41,7 @@ Summary: Adds foo functionality for R License: GPLv2+ URL: https://CRAN.R-project.org/package=%{packname} -Source0: %{url}&version=%{version}#/%{packname}_%{version}.tar.gz +Source: %{url}&version=%{version}#/%{packname}_%{version}.tar.gz BuildRequires: R-devel BuildRequires: tex(latex) diff --git a/guidelines/modules/ROOT/pages/RPM_Source_Dir.adoc b/guidelines/modules/ROOT/pages/RPM_Source_Dir.adoc index 2fbb882..997ccbc 100644 --- a/guidelines/modules/ROOT/pages/RPM_Source_Dir.adoc +++ b/guidelines/modules/ROOT/pages/RPM_Source_Dir.adoc @@ -7,9 +7,9 @@ This is done to ensure that Fedora SRPMS are properly generated. If a Source# it *Incorrect Use:* .... -Source1: php.conf -Source2: php.ini -Source3: macros.php +Source: php.conf +Source: php.ini +Source: macros.php ... diff --git a/guidelines/modules/ROOT/pages/Ruby.adoc b/guidelines/modules/ROOT/pages/Ruby.adoc index 02caa74..98b9750 100644 --- a/guidelines/modules/ROOT/pages/Ruby.adoc +++ b/guidelines/modules/ROOT/pages/Ruby.adoc @@ -412,7 +412,7 @@ Release: 3%{?dist} Group: Development/Languages License: ASL 2.0 and MIT URL: https://incubator.apache.org/deltacloud -Source0: https://rubygems.org/gems/%{name}-%{version}.gem +Source: https://rubygems.org/gems/%{name}-%{version}.gem Requires: rubygem-haml #... Requires(post): chkconfig diff --git a/guidelines/modules/ROOT/pages/SourceURL.adoc b/guidelines/modules/ROOT/pages/SourceURL.adoc index c2982bb..c3e8179 100644 --- a/guidelines/modules/ROOT/pages/SourceURL.adoc +++ b/guidelines/modules/ROOT/pages/SourceURL.adoc @@ -5,9 +5,9 @@ One of the design goals of rpm is to cleanly separate upstream source from vendo The most common case is where upstream distributes source as a tar.gz, tar.bz2 or zip archive that we can download from an upstream website. In these cases you must use a full URL to the package in the SourceX: line. For example: .... -Source0: https://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz +Source: https://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz -Source0: https://ftp.gnome.org/pub/GNOME/sources/gnome-common/2.12/gnome-common-2.12.0.tar.bz2 +Source: https://ftp.gnome.org/pub/GNOME/sources/gnome-common/2.12/gnome-common-2.12.0.tar.bz2 .... [NOTE] @@ -81,7 +81,7 @@ In some cases you may want to pull sources from upstream's revision control syst # following commands to generate the tarball: # svn export -r 250 https://www.example.com/svn/foo/trunk foo-20070221 # tar -cJvf foo-20070221.tar.xz foo-20070221 -Source0: foo-20070221.tar.xz +Source: foo-20070221.tar.xz .... When pulling from revision control, please remember to use a Name-version-release compatible with the xref:Versioning.adoc[Versioning] Guidelines. In particular, check the section on xref:Versioning.adoc#_complex_versioning[Complex versioning]. @@ -94,7 +94,7 @@ Some upstream packages include patents or trademarks that we are not allowed to From the spec: .... -Source0: libfoo-1.0-nopatents.tar.gz +Source: libfoo-1.0-nopatents.tar.gz # libfoo contains patented code that we cannot ship. Therefore we use # this script to remove the patented code before shipping it. # Download the upstream tarball and invoke this script while in the @@ -124,7 +124,7 @@ it is rather unpleasant to use in a Source: URL. Instead, files.pythonhosted.org can be used trough the `+%{pypi_source}+` macro. .... -Source0: %{pypi_source} +Source: %{pypi_source} .... See more about the macro in the xref:Python.adoc#_source_files_from_pypi[Python guidelines]. @@ -134,7 +134,7 @@ See more about the macro in the xref:Python.adoc#_source_files_from_pypi[Python For packages hosted on sourceforge, use .... -Source0: https://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz +Source: https://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz .... changing ".tar.gz" to whatever matches the upstream distribution. Note that we are using downloads.sourceforge.net instead of an arbitrarily chosen mirror. You may use the package name/package version instead of the %\{name} and %\{version} macros, of course. @@ -174,9 +174,9 @@ Once the commit hash and git tag are known, you can define them in your spec fil For the source tarball, you can use the following syntax: .... -Source0: https://github.com/OWNER/PROJECT/archive/%{commit}/%{name}-%{shortcommit}.tar.gz [GitHub] -Source0: https://bitbucket.org/OWNER/PROJECT/get/%{commit}.tar.gz#/%{name}-%{shortcommit}.tar.gz [BitBucket] -Source0: https://gitlab.com/OWNER/PROJECT/-/archive/%{commit}/%{name}-%{shortcommit}.tar.gz [GitLab] +Source: https://github.com/OWNER/PROJECT/archive/%{commit}/%{name}-%{shortcommit}.tar.gz [GitHub] +Source: https://bitbucket.org/OWNER/PROJECT/get/%{commit}.tar.gz#/%{name}-%{shortcommit}.tar.gz [BitBucket] +Source: https://gitlab.com/OWNER/PROJECT/-/archive/%{commit}/%{name}-%{shortcommit}.tar.gz [GitLab] ... %prep @@ -198,9 +198,9 @@ Bitbucket uses the %\{shortcommit} identifier as part of the archive directory s For the source tarball, you can use the following syntax: .... -Source0: https://github.com/OWNER/PROJECT/archive/%{gittag}/%{name}-%{version}.tar.gz [GitHub] -Source0: https://bitbucket.org/OWNER/PROJECT/get/%{gittag}.tar.gz#/%{name}-%{version}.tar.gz [BitBucket] -Source0: https://gitlab.com/OWNER/PROJECT/-/archive/%{gittag}/%{name}-%{version}.tar.gz [GitLab] +Source: https://github.com/OWNER/PROJECT/archive/%{gittag}/%{name}-%{version}.tar.gz [GitHub] +Source: https://bitbucket.org/OWNER/PROJECT/get/%{gittag}.tar.gz#/%{name}-%{version}.tar.gz [BitBucket] +Source: https://gitlab.com/OWNER/PROJECT/-/archive/%{gittag}/%{name}-%{version}.tar.gz [GitLab] ... %prep @@ -218,7 +218,7 @@ Using %\{version} in the SourceX: makes it easier for you to bump the version of When upstream has URLs for the download that do not end with the tarball name rpm will be unable to parse the tarball out of the source URL. One workaround for many cases is to construct a URL where the tarball is listed in a "URL fragment": .... -Source0: https://example.com/foo/1.0/download.cgi#/%{name}-%{version}.tar.gz +Source: https://example.com/foo/1.0/download.cgi#/%{name}-%{version}.tar.gz .... rpm will then use %\{name}-%\{version}.tar.gz as the tarball name. If you use `+spectool -g foo.spec+` to download the tarball, it will rename the tarball for you. @@ -229,5 +229,5 @@ Sometimes this does not work because the upstream cgi tries to parse the fragmen # Mysql has a mirror redirector for its downloads # You can get this tarball by following a link from: # https://dev.mysql.com/downloads/mysql/5.1.html - Source0: mysql-5.1.31.tar.gz + Source: mysql-5.1.31.tar.gz .... diff --git a/guidelines/modules/ROOT/pages/SugarActivityGuidelines.adoc b/guidelines/modules/ROOT/pages/SugarActivityGuidelines.adoc index 84df30d..587576d 100644 --- a/guidelines/modules/ROOT/pages/SugarActivityGuidelines.adoc +++ b/guidelines/modules/ROOT/pages/SugarActivityGuidelines.adoc @@ -49,7 +49,7 @@ Summary: Journal for Sugar Group: Sugar/Activities License: GPLv2+ URL: http://wiki.laptop.org/go/Journal -Source0: journal-activity-%{version}.tar.bz2 +Source: journal-activity-%{version}.tar.bz2 Source1: sugar-journal-checkout.sh BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) diff --git a/guidelines/modules/ROOT/pages/WordPress_plugin_packaging_guidelines.adoc b/guidelines/modules/ROOT/pages/WordPress_plugin_packaging_guidelines.adoc index b7aa335..a9adf0d 100644 --- a/guidelines/modules/ROOT/pages/WordPress_plugin_packaging_guidelines.adoc +++ b/guidelines/modules/ROOT/pages/WordPress_plugin_packaging_guidelines.adoc @@ -39,7 +39,7 @@ Group: Applications/Publishing # under the GPL unless otherwise stated in the plugin source. License: GPLv3+ URL: https://wordpress.org/plugins/%{plugin_name}/ -Source0: https://downloads.wordpress.org/plugin/%{plugin_name}.%{version}.zip +Source: https://downloads.wordpress.org/plugin/%{plugin_name}.%{version}.zip BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) Requires: wordpress BuildArch: noarch diff --git a/guidelines/modules/ROOT/pages/index.adoc b/guidelines/modules/ROOT/pages/index.adoc index 3f3b7d7..d81f4f2 100644 --- a/guidelines/modules/ROOT/pages/index.adoc +++ b/guidelines/modules/ROOT/pages/index.adoc @@ -2657,7 +2657,7 @@ For example: .... # https://bugzilla.gnome.org/show_bug.cgi?id=12345 -Patch0: gnome-panel-fix-frobnicator.patch +Patch: gnome-panel-fix-frobnicator.patch .... The above is perfectly acceptable; @@ -2667,7 +2667,7 @@ a brief comment about what the patch does above can be helpful: .... # Don't crash with frobnicator applet # https://bugzilla.gnome.org/show_bug.cgi?id=12345 -Patch0: gnome-panel-fix-frobnicator.patch +Patch: gnome-panel-fix-frobnicator.patch .... Sending patches upstream and adding this comment @@ -2682,12 +2682,12 @@ You can indicate that you have sent the patch upstream and any known status: .... # Sent upstream via email 20080407 -Patch0: foobar-fix-the-bar.patch +Patch: foobar-fix-the-bar.patch .... .... # Upstream has applied this in SVN trunk -Patch0: foobar-fix-the-baz.patch +Patch: foobar-fix-the-baz.patch .... ==== Fedora-specific (or rejected upstream) patches @@ -2696,7 +2696,7 @@ It may be that some patches truly are Fedora-specific; in that case, say so: .... # This patch is temporary until we land the long term System.loadLibrary fix in OpenJDK -Patch0: jna-jni-path.patch +Patch: jna-jni-path.patch .... === Applying Patches