Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / scripts / mono-package-runtime
1 #!/bin/sh
2
3 if test x$2 = x; then
4    echo usage is: mono-package-runtime MONO_INSTALL_PREFIX LABEL
5    echo The file will be created in the current directory
6    exit 1
7 fi
8
9 prefix=$1
10 output=$2
11 if test ! -d $prefix; then
12    echo the specified path is not a directory: $prefix
13    exit 1
14 fi
15
16 if test -e $output.zip; then
17    echo The output file already exists, refusing to overwrite: $output.zip
18    exit 1
19 fi
20
21 if test ! -e $prefix/bin/mono; then
22    echo The $prefix does not contains a bin/mono
23    exit 1
24 fi
25
26 if test ! -d $prefix/lib/mono/4.5; then
27    echo The $prefix does not contains a lib/mono/4.5
28    exit 1
29 fi
30
31 o=`pwd`/$output
32
33 cd $prefix
34 (zip -u $o.zip bin/mono lib/mono/4.5/mscorlib.dll lib/mono/4.5/System*dll lib/mono/4.5/Mono.CSharp.dll lib/mono/4.5/Microsoft*dll lib/mono/4.5/FSharp*.dll lib/mono/4.5/I18N*dll lib/mono/4.5/Accessibility.dll lib/mono/4.5/RabbitMQ.Client.dll lib/mono/4.5/ICSharpCode.SharpZipLib.dll lib/mono/4.5/CustomMarshalers.dll etc/mono/config etc/mono/4.5/machine.config etc/mono/4.5/web.config lib/mono/4.5/Mono.Cairo.dll lib/mono/4.5/Mono.Data.Sqlite.dll lib/mono/4.5/Mono.Posix.dll lib/mono/4.5/Mono.Security.*dll lib/mono/4.5/Mono.Simd.dll)
35 echo Created file $o.zip
36