/
perl.json
34 lines (34 loc) · 2.36 KB
/
perl.json
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
{
"homepage": "http://strawberryperl.com",
"version": "5.28.1.1",
"license": "Artistic-1.0-Perl|GPL-1.0-only",
"architecture": {
"64bit": {
"url": "http://strawberryperl.com/download/5.28.1.1/strawberry-perl-5.28.1.1-64bit-portable.zip",
"hash": "sha1:51dbc993d93069190606e2534bd64b9c9bf1b9e3"
},
"32bit": {
"url": "http://strawberryperl.com/download/5.28.1.1/strawberry-perl-5.28.1.1-32bit-portable.zip",
"hash": "sha1:241a11fd0c3a51bade0aea222d4c7b7dc623a642"
}
},
"post_install": [
"",
"# enable idiomatic access to user's home directory",
"## remove HomeDir section from portable.perl (disables Portable.pm override of File::HomeDir)",
"## NOTE: conversion to byte[] (via char[]) avoids adding an extra trailing newline to the output file",
"[byte[]][char[]]((Get-Content -raw $dir\\portable.perl) -replace \"(?ms)^HomeDir:.*?^(?=\\S)\",\"\") | Set-Content $dir\\portable.perl -encoding byte",
"# rewrite portable ar, cc, dlltool, and ld locations",
"[byte[]][char[]]((Get-Content -raw $dir\\portable.perl) -replace '(?ms)^(Config:.*?$)(\\s+archlib:.*?$)',('$1'+\"`n ar: c/bin/ar\"+'$2') ) | Set-Content $dir\\portable.perl -encoding byte",
"[byte[]][char[]]((Get-Content -raw $dir\\portable.perl) -replace '(?ms)^(\\s+binexp:.*?$)(\\s+incpath:.*?$)',('$1'+\"`n cc: c/bin/gcc`n cpp: 'c/bin/gcc -E'`n cpprun: 'c/bin/gcc -E'`n cppstdin: 'c/bin/gcc -E'`n dlltool: c/bin/dlltool\"+'$2') ) | Set-Content $dir\\portable.perl -encoding byte",
"[byte[]][char[]]((Get-Content -raw $dir\\portable.perl) -replace '(?ms)^(\\s+ld:.*?$)(\\s+_libpthfix_part1:.*?$)',(\" _ld_prefix: c/bin`n\"+' ld: $$_ld_prefix\\g++'+'$2') ) | Set-Content $dir\\portable.perl -encoding byte",
"# copy c/bin DLLs to perl/bin directory for apps which might depend on DLLs in the strawberry standard c directory (eg, Net::SSLeay which requires 'LIBEAY32__.DLL' and 'SSLEAY32__.DLL' via '.../vendor/lib/auto/Net/SSLeay/SSLeay.xs.dll')",
"Copy-Item \"$dir\\c\\bin\\*.dll\" \"$dir\\perl\\bin\"",
"# rename any clashing executable",
"# * `pip` (from Perl Installation Program, if present); reserved for Python",
"Move-Item \"$dir\\perl\\bin\\pip\" \"$dir\\perl\\bin\\perl-pip\" -ea silent",
"Move-Item \"$dir\\perl\\bin\\pip.bat\" \"$dir\\perl\\bin\\perl-pip.bat\" -ea silent"
],
"env_add_path": ["perl\\site\\bin", "perl\\bin"],
"bin": ["c\\bin\\dmake.exe", "c\\bin\\gmake.exe"]
}