#!/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 |---------------------------------------

pkgname=licenses
pkgver=20220125
pkgrel=02
pkgdesc="A set of common license files"
url="https://www.archlinux.org/"
source=(
  https://www.gnu.org/licenses/agpl-3.0.txt
  apache-2.0.txt::https://www.apache.org/licenses/LICENSE-2.0.txt
  artistic-2_0.txt
  boost-1.0.txt::https://www.boost.org/LICENSE_1_0.txt
  cc-by-3.0.txt
  cc-by-nc-3.0.txt
  cc-by-nc-nd-3.0.txt
  cc-by-nc-sa-3.0.txt
  cc-by-nd-3.0.txt
  cc-by-sa-3.0.txt
  cc-readme.txt
  cddl-1.0.txt
  cpl-1.0.txt
  eclipse-1.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
  https://www.latex-project.org/lppl.txt
  mpl-1.1.txt::https://www.mozilla.org/media/MPL/1.1/index.txt
  mpl-2.0.txt::https://www.mozilla.org/media/MPL/2.0/index.txt
  perlartistic.txt
  php-3.01.txt::https://www.php.net/license/3_01.txt
  python-2.txt
  ruby-license.txt
  unlicense.txt::https://unlicense.org/UNLICENSE
  w3c.txt
  ZopePublicLicense.txt
)

package() {
  local _license_dir="$pkgdir/usr/share/licenses/common"

  install -vDm 644 agpl-3.0.txt "$_license_dir/"AGPL3/license.txt
  ln -s AGPL3 "$_license_dir/"AGPL

  install -vDm 644 apache-2.0.txt "$_license_dir/"Apache/license.txt
  ln -s Apache "$_license_dir/"APACHE

  install -vDm 644 artistic-2_0.txt "$_license_dir/"Artistic2.0/license.txt

  install -vDm 644 boost-1.0.txt "$_license_dir/"Boost/license.txt

  install -vDm 644 cc-by-3.0.txt -t "$_license_dir/"CCPL/
  install -vDm 644 cc-by-nc-3.0.txt -t "$_license_dir/"CCPL/
  install -vDm 644 cc-by-nc-nd-3.0.txt -t "$_license_dir/"CCPL/
  install -vDm 644 cc-by-nc-sa-3.0.txt -t "$_license_dir/"CCPL/
  install -vDm 644 cc-by-nd-3.0.txt -t "$_license_dir/"CCPL/
  install -vDm 644 cc-by-sa-3.0.txt -t "$_license_dir/"CCPL/
  install -vDm 644 cc-readme.txt -t "$_license_dir/"CCPL/

  install -vDm 644 cddl-1.0.txt "$_license_dir/"CDDL/license.txt

  install -vDm 644 cpl-1.0.txt "$_license_dir/"CPL/license.txt

  install -vDm 644 eclipse-1.0.txt "$_license_dir/"EPL/license.txt

  install -vDm 644 gpl-2.0.txt "$_license_dir/"GPL2/license.txt
  install -vDm 644 gpl-3.0.txt "$_license_dir/"GPL3/license.txt
  ln -s GPL2 "$_license_dir/"GPL

  install -vDm 644 fdl-1.2.txt "$_license_dir/"FDL1.2/license.txt
  install -vDm 644 fdl-1.3.txt "$_license_dir/"FDL1.3/license.txt
  ln -s FDL1.2 "$_license_dir/"FDL

  install -vDm 644 lgpl-2.1.txt "$_license_dir/"LGPL2.1/license.txt
  install -vDm 644 lgpl-3.0.txt "$_license_dir/"LGPL3/license.txt
  ln -s LGPL2.1 "$_license_dir/"LGPL

  install -vDm 644 lppl.txt "$_license_dir/"LPPL/license.txt

  install -vDm 644 mpl-1.1.txt "$_license_dir/"MPL/license.txt

  install -vDm 644 mpl-2.0.txt "$_license_dir/"MPL2/license.txt

  install -vDm 644 perlartistic.txt "$_license_dir/"PerlArtistic/license.txt

  install -vDm 644 php-3.01.txt "$_license_dir/"PHP/license.txt

  install -vDm 644 python-2.txt "$_license_dir/"PSF/license.txt

  install -vDm 644 ruby-license.txt "$_license_dir/"RUBY/license.txt

  install -vDm 644 unlicense.txt "$_license_dir/"Unlicense/license.txt

  install -vDm 644 w3c.txt "$_license_dir/"W3C/license.txt

  install -vDm 644 ZopePublicLicense.txt "$_license_dir/"ZPL/license.txt
}


#---- arch license gpg-key & sha256sums ----

arch=(x86_64)

license=(custom:none)

sha256sums=(0d96a4ff68ad6d4b6f1f30f713b18d5184912ba8dd389f86aa7710db079abcb0  # agpl-3.0.txt
	cfc7749b96f63bd31c3c42b5c471bf756814053e847c10f3eb003417bc523d30  # apache-2.0.txt
	f2e0707902c4cd92155bb081a6eb0d77ebab789eafb212659fa6f44fcdca531b  # artistic-2_0.txt
	c9bff75738922193e67fa726fa225535870d2aa1059f91452c411736284ad566  # boost-1.0.txt
	896318172b9bf75b9c863df45c38495a968c3e711c405ed03a2a47eb0ed896e3  # cc-by-3.0.txt
	150775691f276de61f7e244e2e1250313b55f0648b1c1b06015c6348994d6787  # cc-by-nc-3.0.txt
	db1f35b12da8faedece276d01f90a238c429a2d6a3dd727587ce5cb162684395  # cc-by-nc-nd-3.0.txt
	95f13d3047233ade320b4fce712d1b17de395649d6958c4254f1c21148cc7de8  # cc-by-nc-sa-3.0.txt
	baefca0b2da73617d2791390c7893f46d690e36f9ff6f791808c0b4be359d202  # cc-by-nd-3.0.txt
	e550f7bd34d25b04bb0a3fac7f3981d51b41df363d21f35952ee27da259039a2  # cc-by-sa-3.0.txt
	ba17f78e76d11463e8419b6771522f0e219428fe15da415f6ebb3808a4377ceb  # cc-readme.txt
	8778a2687ad7936c20ab77bedc4d28a788e853637ef3edc39708100dd0c90cef  # cddl-1.0.txt
	fe53ee559be099a8c964e95817c55d2a40ef43630150b11c292ccab7b2dd425d  # cpl-1.0.txt
	8367b0edc81df80e6b42eb1b71f783111224e058cb3da37894d065d2deb7ab0a  # eclipse-1.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
	5f05fcf6ef25a6c31bccd2df7c0c46b23107bbeb2ce5cdba74efb5cc357f4dbb  # lppl.txt
	f849fc26a7a99981611a3a370e83078deb617d12a45776d6c4cada4d338be469  # mpl-1.1.txt
	3f3d9e0024b1921b067d6f7f88deb4a60cbe7a78e76c64e3f1d7fc3b779b9d04  # mpl-2.0.txt
	5e8219a37b4c1a146096f17862ef7d6ce689b2137c0161a3936c358a28014169  # perlartistic.txt
	0967ad6cf4b7fe81d38709d7aaef3fecb3bd685be7eebb37b864aa34c991baa7  # php-3.01.txt
	4516a0f2f58e8d6f4ac77c14261cab67d386fa9afa2e79ee09dff190a6eae9f4  # python-2.txt
	f5eb1b2956d5f7a67b2e5722a3749bc2fe86f9c580f2e3f5a08519cf073b5864  # ruby-license.txt
	7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c  # unlicense.txt
	ec2f99fa32da2236c60b1054f8967ccce5175370de5215e8f018cb7be397512e  # w3c.txt
	281c83248297ed2070a2e61ac140e707697511a6a065ba3808cbfa6de5bb5611) #  ZopePublicLicense.txt

##  56d29fa7d59c14b7b11e7acf3a02bd24b9a23b1e8ed74af1c0d48be4cc46be05  licenses-20220125-02-x86_64.pkg.tar.lz


