mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-25 20:25:28 +03:00
testing/dotnet31-runtime: new aport
This commit is contained in:
parent
d163048a26
commit
f71566a753
3 changed files with 211 additions and 0 deletions
174
testing/dotnet31-runtime/APKBUILD
Normal file
174
testing/dotnet31-runtime/APKBUILD
Normal file
|
@ -0,0 +1,174 @@
|
|||
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
||||
|
||||
#
|
||||
# Variables for dotnet build version 3.1
|
||||
# This APKBUILD is designed to be the same for version 5.0 and under
|
||||
# except for the variables in this first section
|
||||
#
|
||||
|
||||
pkgname=dotnet31-runtime
|
||||
pkgver=3.1.22
|
||||
_bldver=3.1.416-r0
|
||||
pkgrel=0
|
||||
|
||||
# Following for dotnet build version 3.1 and up
|
||||
_pkgver_macro=${pkgver%.*}
|
||||
_pkgver_prior=${pkgver%.*.*}
|
||||
_pkgver_name=${_pkgver_macro//[.0]}
|
||||
_bldver_ver=${_bldver/-*}
|
||||
pkgdesc="The .NET $_pkgver_macro Core runtime"
|
||||
pkgrel=0
|
||||
arch="x86_64"
|
||||
url=https://www.microsoft.com/net/core
|
||||
license="MIT"
|
||||
depends="dotnet$_pkgver_name-hostfxr"
|
||||
makedepends="dotnet$_pkgver_name-build=$_bldver"
|
||||
subpackages="
|
||||
aspnetcore$_pkgver_name-runtime:aspnetcore_runtime:noarch
|
||||
aspnetcore$_pkgver_name-targeting-pack:aspnetcore_targeting_pack:noarch
|
||||
dotnet$_pkgver_name-apphost-pack:apphost_pack
|
||||
dotnet$_pkgver_name-host:host
|
||||
dotnet$_pkgver_name-host-zsh-completion:zshcomp
|
||||
dotnet$_pkgver_name-host-bash-completion:bashcomp
|
||||
dotnet$_pkgver_name-host-doc:doc
|
||||
dotnet$_pkgver_name-hostfxr:hostfxr
|
||||
dotnet$_pkgver_name-targeting-pack:targeting_pack:noarch
|
||||
"
|
||||
options="!check" # No test suite
|
||||
source="dotnet.sh"
|
||||
builddir="$srcdir"
|
||||
|
||||
# Function forces dependency on non-virtual host subpackages
|
||||
# Overrides so that dependency to virtual host subpackage
|
||||
# can be explicitely set from within subpackage functions
|
||||
scan_symlink_targets() {
|
||||
return
|
||||
}
|
||||
|
||||
build() {
|
||||
return
|
||||
}
|
||||
|
||||
package() {
|
||||
install -dm 755 \
|
||||
"$pkgdir"/usr/share/dotnet/shared \
|
||||
"$pkgdir"/usr/share/licenses \
|
||||
"$pkgdir"/usr/share/zsh/site-functions \
|
||||
"$pkgdir"/usr/share/bash-completion/completions \
|
||||
"$pkgdir"/usr/share/man
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/shared/Microsoft.NETCore.App "$pkgdir"/usr/share/dotnet/shared/.
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/docs "$pkgdir"/usr/share/man/man1
|
||||
install -m 755 /usr/share/dotnet/build/$_bldver_ver/comp/register-completions.zsh "$pkgdir"/usr/share/zsh/site-functions/_dotnet
|
||||
install -m 755 /usr/share/dotnet/build/$_bldver_ver/comp/register-completions.bash "$pkgdir"/usr/share/bash-completion/completions/_dotnet
|
||||
ln -s dotnet-host "$pkgdir"/usr/share/licenses/dotnet$_pkgver_name-runtime
|
||||
}
|
||||
|
||||
host() {
|
||||
pkgdesc="A generic driver for the .NET Core Command Line Interface"
|
||||
provides="dotnet-host=$pkgver"
|
||||
provider_priority=$_pkgver_prior
|
||||
|
||||
install -dm 755 \
|
||||
"$subpkgdir"/etc/profile.d \
|
||||
"$subpkgdir"/usr/bin \
|
||||
"$subpkgdir"/usr/share/dotnet \
|
||||
"$subpkgdir"/usr/share/licenses/dotnet-host
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/dotnet "$subpkgdir"/usr/share/dotnet/.
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/LICENSE.txt "$subpkgdir"/usr/share/licenses/dotnet-host/.
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/ThirdPartyNotices.txt "$subpkgdir"/usr/share/licenses/dotnet-host/.
|
||||
ln -s /usr/share/dotnet/dotnet "$subpkgdir"/usr/bin/dotnet
|
||||
install -Dm 644 "$srcdir"/dotnet.sh -t "$subpkgdir"/etc/profile.d/
|
||||
}
|
||||
|
||||
hostfxr() {
|
||||
pkgdesc="The .NET host resolver contains the logic to resolve and select the right version of the .NET SDK or runtime to use."
|
||||
depends="dotnet-host"
|
||||
provides="dotnet-hostfxr-$_pkgver_macro=$pkgver"
|
||||
provider_priority=$_pkgver_prior
|
||||
|
||||
install -dm 755 \
|
||||
"$subpkgdir"/usr/share/dotnet \
|
||||
"$subpkgdir"/usr/share/licenses
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/host "$subpkgdir"/usr/share/dotnet/.
|
||||
ln -s dotnet-host "$subpkgdir"/usr/share/licenses/dotnet$_pkgver_name-hostfxr
|
||||
}
|
||||
|
||||
aspnetcore_runtime() {
|
||||
pkgdesc="The ASP.NET $_pkgver_macro Core runtime"
|
||||
depends="dotnet$_pkgver_name-runtime"
|
||||
provides="aspnetcore-runtime-$_pkgver_macro=$pkgver"
|
||||
provider_priority=$_pkgver_prior
|
||||
|
||||
install -dm 755 \
|
||||
"$subpkgdir"/usr/share/dotnet/shared \
|
||||
"$subpkgdir"/usr/share/licenses
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/shared/Microsoft.AspNetCore.App "$subpkgdir"/usr/share/dotnet/shared/.
|
||||
ln -s dotnet-host "$subpkgdir"/usr/share/licenses/aspnetcore$_pkgver_name-runtime
|
||||
}
|
||||
|
||||
apphost_pack() {
|
||||
pkgdesc="The .NET $_pkgver_macro Core apphost pack"
|
||||
provides="dotnet-apphost-pack-$_pkgver_macro=$pkgver"
|
||||
|
||||
install -dm 755 \
|
||||
"$subpkgdir"/usr/share/dotnet/packs \
|
||||
"$subpkgdir"/usr/share/licenses
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/packs/Microsoft.NETCore.App.Host.* "$subpkgdir"/usr/share/dotnet/packs/.
|
||||
ln -s dotnet-host "$subpkgdir"/usr/share/licenses/dotnet$_pkgver_name-apphost-pack
|
||||
}
|
||||
|
||||
targeting_pack() {
|
||||
pkgdesc="The .NET $_pkgver_macro Core targeting pack"
|
||||
provides="dotnet-targeting-pack-$_pkgver_macro=$pkgver"
|
||||
|
||||
install -dm 755 \
|
||||
"$subpkgdir"/usr/share/dotnet/packs \
|
||||
"$subpkgdir"/usr/share/licenses
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/packs/Microsoft.NETCore.App.Ref "$subpkgdir"/usr/share/dotnet/packs/.
|
||||
ln -s dotnet-host "$subpkgdir"/usr/share/licenses/dotnet$_pkgver_name-targeting-pack
|
||||
}
|
||||
|
||||
aspnetcore_targeting_pack() {
|
||||
pkgdesc="The ASP.NET $_pkgver_macro Core targeting pack"
|
||||
provides="aspnetcore-targeting-pack-$_pkgver_macro=$pkgver"
|
||||
|
||||
install -dm 755 \
|
||||
"$subpkgdir"/usr/share/dotnet/packs \
|
||||
"$subpkgdir"/usr/share/licenses
|
||||
|
||||
cp -r /usr/share/dotnet/build/$_bldver_ver/packs/Microsoft.AspNetCore.App.Ref "$subpkgdir"/usr/share/dotnet/packs/.
|
||||
ln -s dotnet-host "$subpkgdir"/usr/share/licenses/aspnetcore$_pkgver_name-targeting-pack
|
||||
}
|
||||
|
||||
zshcomp() {
|
||||
default_zshcomp
|
||||
pkgdesc="zsh completion for .NET $_pkgver_macro"
|
||||
depends="dotnet-host"
|
||||
provides="dotnet-host-zsh-completion=$pkgver"
|
||||
provider_priority=$_pkgver_prior
|
||||
}
|
||||
|
||||
bashcomp() {
|
||||
default_bashcomp
|
||||
pkgdesc="bash completion for .NET $_pkgver_macro"
|
||||
depends="dotnet-host"
|
||||
provides="dotnet-host-bash-completion=$pkgver"
|
||||
provider_priority=$_pkgver_prior
|
||||
}
|
||||
|
||||
doc() {
|
||||
default_doc
|
||||
pkgdesc="Docs for .NET $_pkgver_macro"
|
||||
provides="dotnet-host-doc=$pkgver"
|
||||
provider_priority=$_pkgver_prior
|
||||
}
|
||||
sha512sums="
|
||||
e61b9e3e5a2305646a616d598378230c9755c5dd5363692cc363f8f4add3807563c324dd86f3a7ae9d358c82d730608e7b293935a2b6c81c0c0f62d752a0a1cf dotnet.sh
|
||||
"
|
25
testing/dotnet31-runtime/README.md
Normal file
25
testing/dotnet31-runtime/README.md
Normal file
|
@ -0,0 +1,25 @@
|
|||
# Description
|
||||
APKBUILD for dotnet31-runtime. Note that this doesn't actually build anything.
|
||||
It depends on dotnet31-build, which handles the actual dotnet build process
|
||||
This is a workaround to abuild / lua-aports not supporting custom pkgver
|
||||
for subpackages. While there are pending MRs for this feature, the feature
|
||||
is yet to be introduced. See abuild!137 and lua-aports!4
|
||||
|
||||
# Generated packages
|
||||
* aspnetcore31-runtime
|
||||
* aspnetcore31-targeting-pack
|
||||
* dotnet31-apphost-pack (used by dotnet31-runtime)
|
||||
* dotnet31-host (provides dotnet-host)
|
||||
* dotnet31-host-zsh-completion (provides dotnet-host-zsh-completion)
|
||||
* dotnet31-host-bash-completion (provides dotnet-host-bash-completion)
|
||||
* dotnet31-host-doc (docs for dotnet31)
|
||||
* dotnet31-hostfxr (provides fxr for host)
|
||||
* dotnet31-runtime
|
||||
* dotnet31-targeting-pack
|
||||
|
||||
# How to build dotnet31 stack
|
||||
* Build testing/dotnet31-stage0 (provides prebuilt bits for first bootstrap bld)
|
||||
* Build testing/dotnet31-bootstrap (provides "tainted" SDK for first build)
|
||||
* Build testing/dotnet31-build ("untainted" build of dotnet)
|
||||
* Build testing/dotnet31-runtime (packages runtime bits from dotnet31-build)
|
||||
* Build testing/dotnet31-sdk (packages sdk bits from dotnet31-build)
|
12
testing/dotnet31-runtime/dotnet.sh
Normal file
12
testing/dotnet31-runtime/dotnet.sh
Normal file
|
@ -0,0 +1,12 @@
|
|||
# Set location for AppHost lookup
|
||||
[ -z "$DOTNET_ROOT" ] && export DOTNET_ROOT=/usr/share/dotnet
|
||||
|
||||
# Add dotnet tools directory to PATH
|
||||
DOTNET_TOOLS_PATH="$HOME/.dotnet/tools"
|
||||
case "$PATH" in
|
||||
*"$DOTNET_TOOLS_PATH"* ) true ;;
|
||||
* ) PATH="$PATH:$DOTNET_TOOLS_PATH" ;;
|
||||
esac
|
||||
|
||||
# Extract self-contained executables under HOME to avoid multi-user issues from using the default '/var/tmp'
|
||||
[ -z "$DOTNET_BUNDLE_EXTRACT_BASE_DIR" ] && export DOTNET_BUNDLE_EXTRACT_BASE_DIR="${XDG_CACHE_HOME:-"$HOME"/.cache}/dotnet_bundle_extract"
|
Loading…
Add table
Add a link
Reference in a new issue