239 lines
7.6 KiB
Bash
239 lines
7.6 KiB
Bash
#!/usr/bin/bash
|
|
# JOBoRun : Jwm OpenBox Obarun RUNit
|
|
# Maintainer : Joe Bo Run <joborun@disroot.org>
|
|
# PkgSource : url="https://gittea.disroot.org/joborun-pkg/jobcore/$pkgname"
|
|
# Website : https://pozol.eu
|
|
#-----------------------------------------| DESCRIPTION |---------------------------------------
|
|
|
|
_upstream_name=license-list-data
|
|
_upstream_version=3.21
|
|
pkgname=licenses
|
|
pkgver=20231011
|
|
pkgrel=01
|
|
pkgdesc="A set of common license files"
|
|
url="https://www.archlinux.org/"
|
|
source=($_upstream_name-$_upstream_version.tar.gz::https://github.com/spdx/$_upstream_name/archive/refs/tags/v$_upstream_version.tar.gz
|
|
https://www.gnu.org/licenses/agpl-3.0.txt
|
|
https://www.gnu.org/licenses/fdl-1.2.txt
|
|
https://www.gnu.org/licenses/fdl-1.3.txt
|
|
https://www.gnu.org/licenses/gpl-2.0.txt
|
|
https://www.gnu.org/licenses/gpl-3.0.txt
|
|
https://www.gnu.org/licenses/lgpl-2.1.txt
|
|
https://www.gnu.org/licenses/lgpl-3.0.txt
|
|
)
|
|
|
|
prepare() {
|
|
local license
|
|
|
|
# create list of known SPDX license identifiers
|
|
{
|
|
for license in "$_upstream_name-$_upstream_version/text/"*.txt; do
|
|
printf "%s\n" "$(basename "${license//.txt/}")"
|
|
done
|
|
} > known_spdx_license_identifiers.txt
|
|
}
|
|
|
|
package() {
|
|
local license
|
|
local standard_licenses=(
|
|
AGPL-3.0-only
|
|
AGPL-3.0-or-later
|
|
Apache-2.0
|
|
Artistic-1.0-Perl
|
|
Artistic-2.0
|
|
BSL-1.0
|
|
CC0-1.0
|
|
CC-BY-1.0
|
|
CC-BY-2.0
|
|
CC-BY-2.5
|
|
CC-BY-3.0-AT
|
|
CC-BY-3.0
|
|
CC-BY-3.0-US
|
|
CC-BY-4.0
|
|
CC-BY-NC-1.0
|
|
CC-BY-NC-2.0
|
|
CC-BY-NC-2.5
|
|
CC-BY-NC-3.0
|
|
CC-BY-NC-4.0
|
|
CC-BY-NC-ND-1.0
|
|
CC-BY-NC-ND-2.0
|
|
CC-BY-NC-ND-2.5
|
|
CC-BY-NC-ND-3.0-IGO
|
|
CC-BY-NC-ND-3.0
|
|
CC-BY-NC-ND-4.0
|
|
CC-BY-NC-SA-1.0
|
|
CC-BY-NC-SA-2.0
|
|
CC-BY-NC-SA-2.5
|
|
CC-BY-NC-SA-3.0
|
|
CC-BY-NC-SA-4.0
|
|
CC-BY-ND-1.0
|
|
CC-BY-ND-2.0
|
|
CC-BY-ND-2.5
|
|
CC-BY-ND-3.0
|
|
CC-BY-ND-4.0
|
|
CC-BY-SA-1.0
|
|
CC-BY-SA-2.0
|
|
CC-BY-SA-2.0-UK
|
|
CC-BY-SA-2.1-JP
|
|
CC-BY-SA-2.5
|
|
CC-BY-SA-3.0-AT
|
|
CC-BY-SA-3.0
|
|
CC-BY-SA-4.0
|
|
CC-PDDC
|
|
CDDL-1.0
|
|
CDDL-1.1
|
|
CPL-1.0
|
|
EPL-1.0
|
|
EPL-2.0
|
|
GFDL-1.1-invariants-only
|
|
GFDL-1.1-invariants-or-later
|
|
GFDL-1.1-no-invariants-only
|
|
GFDL-1.1-no-invariants-or-later
|
|
GFDL-1.1-only
|
|
GFDL-1.1-or-later
|
|
GFDL-1.2-invariants-only
|
|
GFDL-1.2-invariants-or-later
|
|
GFDL-1.2-no-invariants-only
|
|
GFDL-1.2-no-invariants-or-later
|
|
GFDL-1.2-only
|
|
GFDL-1.2-or-later
|
|
GFDL-1.3-invariants-only
|
|
GFDL-1.3-invariants-or-later
|
|
GFDL-1.3-no-invariants-only
|
|
GFDL-1.3-no-invariants-or-later
|
|
GFDL-1.3-only
|
|
GFDL-1.3-or-later
|
|
GPL-2.0-only
|
|
GPL-2.0-or-later
|
|
GPL-3.0-linking-exception
|
|
GPL-3.0-linking-source-exception
|
|
GPL-3.0-only
|
|
GPL-3.0-or-later
|
|
GPL-CC-1.0
|
|
LGPL-2.0-only
|
|
LGPL-2.0-or-later
|
|
LGPL-2.1-only
|
|
LGPL-2.1-or-later
|
|
LGPL-3.0-linking-exception
|
|
LGPL-3.0-only
|
|
LGPL-3.0-or-later
|
|
LGPLLR
|
|
LPPL-1.0
|
|
LPPL-1.1
|
|
LPPL-1.2
|
|
LPPL-1.3a
|
|
LPPL-1.3c
|
|
MPL-1.0
|
|
MPL-1.1
|
|
MPL-2.0-no-copyleft-exception
|
|
MPL-2.0
|
|
PHP-3.01
|
|
PHP-3.0
|
|
PSF-2.0
|
|
Ruby
|
|
Unlicense
|
|
W3C
|
|
ZPL-1.1
|
|
ZPL-2.0
|
|
ZPL-2.1
|
|
)
|
|
local legacy_license_dir="$pkgdir/usr/share/licenses/common"
|
|
|
|
for license in "${standard_licenses[@]}"; do
|
|
install -vDm 644 "$_upstream_name-$_upstream_version/text/$license.txt" -t "$pkgdir/usr/share/licenses/spdx/"
|
|
done
|
|
install -vDm 644 known_spdx_license_identifiers.txt -t "$pkgdir/usr/share/licenses/"
|
|
|
|
# NOTE: all below license files and directories are provided for **legacy** compatibility only!
|
|
# Once all use in relevant downstreams have been removed, they will be deleted.
|
|
|
|
install -vDm 644 agpl-3.0.txt "$legacy_license_dir/"AGPL3/license.txt
|
|
ln -s AGPL3 "$legacy_license_dir/"AGPL
|
|
|
|
install -vdm 755 "$legacy_license_dir/Apache/"
|
|
ln -s ../../spdx/Apache-2.0.txt "$legacy_license_dir/Apache/license.txt"
|
|
ln -s Apache "$legacy_license_dir/"APACHE
|
|
|
|
install -vdm 755 "$legacy_license_dir/Artistic2.0/"
|
|
ln -s ../../spdx/Artistic-2.0.txt "$legacy_license_dir/Artistic2.0/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/Boost/"
|
|
ln -s ../../spdx/BSL-1.0.txt "$legacy_license_dir/Boost/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/CCPL/"
|
|
ln -s ../../spdx/CC-BY-3.0.txt "$legacy_license_dir/CCPL/cc-by-3.0.txt"
|
|
ln -s ../../spdx/CC-BY-NC-3.0.txt "$legacy_license_dir/CCPL/cc-by-nc-3.0.txt"
|
|
ln -s ../../spdx/CC-BY-NC-ND-3.0.txt "$legacy_license_dir/CCPL/cc-by-nc-nd-3.0.txt"
|
|
ln -s ../../spdx/CC-BY-NC-SA-3.0.txt "$legacy_license_dir/CCPL/cc-by-nc-sa-3.0.txt"
|
|
ln -s ../../spdx/CC-BY-ND-3.0.txt "$legacy_license_dir/CCPL/cc-by-nd-3.0.txt"
|
|
ln -s ../../spdx/CC-BY-SA-3.0.txt "$legacy_license_dir/CCPL/cc-by-sa-3.0.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/CDDL/"
|
|
ln -s ../../spdx/CDDL-1.0.txt "$legacy_license_dir/CDDL/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/CPL/"
|
|
ln -s ../../spdx/CPL-1.0.txt "$legacy_license_dir/CPL/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/EPL/"
|
|
ln -s ../../spdx/EPL-1.0.txt "$legacy_license_dir/EPL/license.txt"
|
|
|
|
install -vDm 644 gpl-2.0.txt "$legacy_license_dir/"GPL2/license.txt
|
|
install -vDm 644 gpl-3.0.txt "$legacy_license_dir/"GPL3/license.txt
|
|
ln -s GPL2 "$legacy_license_dir/"GPL
|
|
|
|
install -vDm 644 fdl-1.2.txt "$legacy_license_dir/"FDL1.2/license.txt
|
|
install -vDm 644 fdl-1.3.txt "$legacy_license_dir/"FDL1.3/license.txt
|
|
ln -s FDL1.2 "$legacy_license_dir/"FDL
|
|
|
|
install -vDm 644 lgpl-2.1.txt "$legacy_license_dir/"LGPL2.1/license.txt
|
|
install -vDm 644 lgpl-3.0.txt "$legacy_license_dir/"LGPL3/license.txt
|
|
ln -s LGPL2.1 "$legacy_license_dir/"LGPL
|
|
|
|
install -vdm 755 "$legacy_license_dir/LPPL/"
|
|
ln -s ../../spdx/LPPL-1.3c.txt "$legacy_license_dir/LPPL/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/MPL/"
|
|
ln -s ../../spdx/MPL-1.1.txt "$legacy_license_dir/MPL/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/MPL2/"
|
|
ln -s ../../spdx/MPL-2.0.txt "$legacy_license_dir/MPL2/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/PerlArtistic/"
|
|
ln -s ../../spdx/Artistic-1.0-Perl.txt "$legacy_license_dir/PerlArtistic/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/PHP/"
|
|
ln -s ../../spdx/PHP-3.01.txt "$legacy_license_dir/PHP/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/PSF/"
|
|
ln -s ../../spdx/PSF-2.0.txt "$legacy_license_dir/PSF/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/Ruby/"
|
|
ln -s ../../spdx/Ruby.txt "$legacy_license_dir/Ruby/license.txt"
|
|
ln -s Ruby "$legacy_license_dir/RUBY"
|
|
|
|
install -vdm 755 "$legacy_license_dir/Unlicense/"
|
|
ln -s ../../spdx/Unlicense.txt "$legacy_license_dir/Unlicense/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/W3C/"
|
|
ln -s ../../spdx/W3C.txt "$legacy_license_dir/W3C/license.txt"
|
|
|
|
install -vdm 755 "$legacy_license_dir/ZPL/"
|
|
ln -s ../../spdx/ZPL-2.1.txt "$legacy_license_dir/ZPL/license.txt"
|
|
}
|
|
|
|
#---- arch license gpg-key & sha256sums ----
|
|
|
|
arch=(x86_64)
|
|
|
|
license=(custom:none)
|
|
|
|
sha256sums=(7f7a4ffb4aa2d6ac32610a629a6fe127e5d5a3a5e41774b555dccc9284f3e149 # license-list-data-3.21.tar.gz
|
|
0d96a4ff68ad6d4b6f1f30f713b18d5184912ba8dd389f86aa7710db079abcb0 # agpl-3.0.txt
|
|
d8e94ae5fdb5433fcae2961aeb1a8cf17174d6f4a0465d24bf37dd8a038bd439 # fdl-1.2.txt
|
|
110535522396708cea37c72a802c5e7e81391139f5f7985631c93ef242b206a4 # fdl-1.3.txt
|
|
8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 # gpl-2.0.txt
|
|
3972dc9744f6499f0f9b2dbf76696f2ae7ad8af9b23dde66d6af86c9dfb36986 # gpl-3.0.txt
|
|
dc626520dcd53a22f727af3ee42c770e56c97a64fe3adb063799d8ab032fe551 # lgpl-2.1.txt
|
|
e3a994d82e644b03a792a930f574002658412f62407f5fee083f2555c5f23118) # lgpl-3.0.txt
|
|
|
|
## be1de306d3f6a11ea9d6f8f51f8d033111c88f015a1c1c9358090db887356d71 licenses-20231011-01-x86_64.pkg.tar.lz
|