summaryrefslogtreecommitdiffstats
path: root/lang/referenceassemblies-pcl/Makefile
blob: 55ece9f19279e315cf4052cd102ed366151c5719 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# Created by: David Naylor <dbn@dragon.local>
# $FreeBSD$

PORTNAME=	referenceassemblies-pcl
PORTVERSION=	4.6
PORTREVISION=	1
CATEGORIES=	lang
MASTER_SITES=	https://download.microsoft.com/download/B/7/9/B79993DE-10E7-457A-B22B-4A918086A989/:ms \
		http://download.mono-project.com/repo/debian/pool/main/r/referenceassemblies-pcl/:mono
DISTFILES=	NetFx_PortableLibraryReferenceAssemblies46.exe:ms \
		referenceassemblies-pcl_2014.04.14.orig.tar.bz2:mono

MAINTAINER=	mono@FreeBSD.org
COMMENT=	Microsoft .Net Portable Class Library Reference Assemblies

LICENSE=	EULA
LICENSE_NAME=	Microsoft software license terms for Microsoft .Net Portable Class Library Reference Assemblies - 4.6
LICENSE_FILE=	${FILESDIR}/EULA.txt
LICENSE_PERMS=	dist-mirror dist-sell pkg-mirror pkg-sell auto-accept

EXTRACT_DEPENDS=	cabextract:archivers/cabextract

NO_BUILD=	yes
NO_ARCH=	yes
PLIST_SUB=	PKGNAME=${PKGNAME}

NETPORTABLEDIR=	lib/mono/xbuild-frameworks/.NETPortable
PRADIR=		PortableReferenceAssemblies-2014-04-14/

do-extract:
.for file in u4 a1
	cabextract -d ${WRKDIR} -F ${file} ${DISTDIR}/NetFx_PortableLibraryReferenceAssemblies46.exe
.endfor
	${MV} ${WRKDIR}/u4 ${WRKDIR}/EULA.rtf
	cabextract -d ${WRKDIR} ${WRKDIR}/a1
	${RM} ${WRKDIR}/a1

do-install:
	${MKDIR} ${STAGEDIR}${PREFIX}/${NETPORTABLEDIR}
# XXX: tar(1)'s 'g' flag is broken on FreeBSD<11.
#      Repeat the pattern as a workaround.
	tar -xC ${STAGEDIR}${PREFIX}/${NETPORTABLEDIR} -f ${WRKDIR}/PortableReferenceAssemblies.zip \
		-s'|\\|/|g' \
		-s'|\\|/|g' \
		-s'|\\|/|g' \
		-s'|\\|/|g'
	tar -xC ${STAGEDIR}${PREFIX}/${NETPORTABLEDIR} -f ${DISTDIR}/referenceassemblies-pcl_2014.04.14.orig.tar.bz2 \
		-s'|${PRADIR}||g' \
		--include ${PRADIR}v4.0/Profile/Profile102 \
		--include ${PRADIR}v4.0/Profile/Profile225 \
		--include ${PRADIR}v4.0/Profile/Profile240 \
		--include ${PRADIR}v4.0/Profile/Profile255 \
		--include ${PRADIR}v4.0/Profile/Profile328 \
		--include ${PRADIR}v4.0/Profile/Profile336 \
		--include ${PRADIR}v4.0/Profile/Profile344 \
		--include ${PRADIR}v4.0/Profile/Profile92 \
		--include ${PRADIR}v4.5/Profile/Profile111 \
		--include ${PRADIR}v4.5/Profile/Profile259 \
		--include ${PRADIR}v4.6/Profile/Profile151 \
		--include ${PRADIR}v4.6/System.Runtime.WindowsRuntime.UI.Xaml.dll \
		--include ${PRADIR}v4.6/System.Runtime.WindowsRuntime.dll \
		--include '*/Windows 8.xml' \
		--include '*/Windows 8.1.xml' \
		--include '*/Windows Phone Silverlight 8.xml'
	${MKDIR} ${STAGEDIR}${PREFIX}/share/licenses/${PKGNAME}
	${INSTALL_DATA} ${WRKDIR}/EULA.rtf ${STAGEDIR}${PREFIX}/share/licenses/${PKGNAME}/EULA.rtf

.include <bsd.port.mk>
OpenPOWER on IntegriCloud