diff options
author | Remi Collet <remi@remirepo.net> | 2025-08-05 10:50:21 +0200 |
---|---|---|
committer | Remi Collet <remi@php.net> | 2025-08-05 10:50:21 +0200 |
commit | 4d23bc286f33338bd6fba133db7ac9d6888a9ca9 (patch) | |
tree | 17e8d5e04547b2d69c91e7fa3667789205bd3340 | |
parent | f9f56766d56bef2133922ca8435fcb547d3855ab (diff) |
-rwxr-xr-x | makedeps.sh | 8 | ||||
-rw-r--r-- | redis-json.spec | 21 |
2 files changed, 20 insertions, 9 deletions
diff --git a/makedeps.sh b/makedeps.sh index 352df0d..99ce444 100755 --- a/makedeps.sh +++ b/makedeps.sh @@ -3,17 +3,17 @@ NAME=$(sed -n '/^Name:/{s/.* //;p}' *.spec) VERSION=$(sed -n '/^Version:/{s/.* //;p}' $NAME.spec) MODULE=$(sed -n '/^%global gh_proj/{s/.* //;p}' $NAME.spec) -if [ -f $MODULE-$VERSION.tar.gz ]; then +if [ -f $NAME-$VERSION.tgz ]; then echo "+ Unpack" - tar xf $MODULE-$VERSION.tar.gz + tar xf $NAME-$VERSION.tgz pushd $MODULE-$VERSION echo "+ Fetch" cargo vendor mycargo echo "+ Pack" - tar czf ../$MODULE-deps-$VERSION.tgz mycargo + tar czf ../$NAME-deps-$VERSION.tgz mycargo popd else - echo $MODULE-$VERSION.tar.gz missing + echo $NAME-$VERSION.tgz missing fi diff --git a/redis-json.spec b/redis-json.spec index 3813b86..7ce6885 100644 --- a/redis-json.spec +++ b/redis-json.spec @@ -27,11 +27,15 @@ Summary: JSON as native data type # (i) Redis Source Available License 2.0 (RSALv2); # (ii) the Server Side Public License v1 (SSPLv1); or # (iii) the GNU Affero General Public License version 3 (AGPLv3). -License: AGPL-3.0-only +# readies is BSD-3-Clause +# rust libraries are MIT, Apache-2.0, BSD-2-Clause +License: AGPL-3.0-only AND MIT AND Apache-2.0 AND BSD-2-Clause AND BSD-3-Clause URL: %{forgeurl} -Source0: %{forgesource} -Source1: makedeps.sh -Source2: %{gh_proj}-deps-%{version}.tgz +Source0: %{name}-%{version}.tgz +Source1: makesrc.sh +# get full git snapshot with submodules +Source2: %{name}-deps-%{version}.tgz +Source3: makedeps.sh BuildRequires: redis-devel >= 8.2 %if 0%{?fedora} || 0%{?rhel} >= 9 @@ -100,6 +104,13 @@ EOF : Required rust version grep -h rust-version mycargo/*/Cargo.toml Cargo.toml | sort -u | tail -n 8 +: Bundled projects Licenses +cp -p deps/readies/LICENSE LICENSE.readies # BSD-3-Clause +for proj in mycargo/*; do + for lic in $proj/LICENSE*; do + [ -f $lic ] && cp $lic $(basename $lic).$(basename $proj) + done +done %build %if 0%{?fedora} || 0%{?rhel} >= 9 @@ -115,7 +126,7 @@ install -Dpm640 %{cfgname} %{buildroot}%{redis_modules_cfg}/%{cfgname %files -%license LICENSE.txt +%license LICENSE* %license licenses/AGPLv3.txt %doc *.md %attr(0640, redis, root) %config(noreplace) %{redis_modules_cfg}/%{cfgname} |