diff options
author | 2016-03-02 09:05:51 -0500 | |
---|---|---|
committer | 2016-03-02 09:05:51 -0500 | |
commit | a4e9a86d683dcf583dc7354db614ecc637da86a1 (patch) | |
tree | f406b5426e467ce0f2183497f4bf8dee24de0cfd /platform | |
parent | cleanup (diff) | |
parent | Fix exclusion while building tarball (diff) | |
download | firejail-a4e9a86d683dcf583dc7354db614ecc637da86a1.tar.gz firejail-a4e9a86d683dcf583dc7354db614ecc637da86a1.tar.zst firejail-a4e9a86d683dcf583dc7354db614ecc637da86a1.zip |
Merge pull request #345 from jgriffiths/more_rpm_fixes
More rpm fixes
Diffstat (limited to 'platform')
-rwxr-xr-x | platform/rpm/mkrpm.sh | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/platform/rpm/mkrpm.sh b/platform/rpm/mkrpm.sh index e600c6bdd..b63340e43 100755 --- a/platform/rpm/mkrpm.sh +++ b/platform/rpm/mkrpm.sh | |||
@@ -6,7 +6,8 @@ | |||
6 | # current working directory. | 6 | # current working directory. |
7 | 7 | ||
8 | name=$1 | 8 | name=$1 |
9 | version=$2 | 9 | # Strip any trailing prefix from the version like -rc1 etc |
10 | version=$(echo "$2" | sed 's/\-.*//g') | ||
10 | 11 | ||
11 | if [[ ! -f platform/rpm/${name}.spec ]]; then | 12 | if [[ ! -f platform/rpm/${name}.spec ]]; then |
12 | echo error: spec file not found for name \"${name}\" | 13 | echo error: spec file not found for name \"${name}\" |
@@ -32,7 +33,7 @@ sed -e "s/__NAME__/${name}/g" -e "s/__VERSION__/${version}/g" platform/rpm/${nam | |||
32 | # FIXME: We could parse RELNOTES and create a %changelog section here | 33 | # FIXME: We could parse RELNOTES and create a %changelog section here |
33 | 34 | ||
34 | # Copy the source to build into a tarball | 35 | # Copy the source to build into a tarball |
35 | tar czf ${tmpdir}/SOURCES/${name}-${version}.tar.gz . --transform "s/^./${name}-${version}/" --exclude='.git/*' | 36 | tar czf ${tmpdir}/SOURCES/${name}-${version}.tar.gz . --transform "s/^./${name}-${version}/" --exclude='./.git*' --exclude='./test*' |
36 | 37 | ||
37 | # Build the files (rpm, debug rpm and source rpm) | 38 | # Build the files (rpm, debug rpm and source rpm) |
38 | rpmbuild --quiet --define "_topdir ${tmpdir}" -ba ${tmp_spec_file} | 39 | rpmbuild --quiet --define "_topdir ${tmpdir}" -ba ${tmp_spec_file} |