Avoid hard-coding the Version field in the generated spec file.
Unified · Split
| @@ -27,8 +27,6 @@ else · 26 unmodified lines | |||
| 27 | M=DEL | 27 | M=DEL |
| 28 | fi | 28 | fi |
| 29 | 29 | ||
| 30 | __KERNELRELEASE=$(echo $KERNELRELEASE | sed -e "s/-/_/g") | ||
| 31 | |||
| 32 | # We can label the here-doc lines for conditional output to the spec file | 30 | # We can label the here-doc lines for conditional output to the spec file |
| 33 | # | 31 | # |
| 34 | # Labels: | 32 | # Labels: |
| @@ -43,7 +41,7 @@ sed -e '/^DEL/d' -e 's/^\t*//' <<EOF · 8 unmodified lines | |||
| 43 | 41 | ||
| 44 | Name: kernel | 42 | Name: kernel |
| 45 | Summary: The Linux Kernel | 43 | Summary: The Linux Kernel |
| 46 | Version: $__KERNELRELEASE | 44 | Version: %(echo %{KERNELRELEASE} | sed -e 's/-/_/g') |
| 47 | Release: $(cat .version 2>/dev/null || echo 1) | 45 | Release: $(cat .version 2>/dev/null || echo 1) |
| 48 | License: GPL | 46 | License: GPL |
| 49 | Group: System Environment/Kernel | 47 | Group: System Environment/Kernel |