View difference between Paste ID: hk43VQBQ and
SHOW:
|
|
- or go back to the newest paste.
1 | - | |
1 | + | #!/bin/bash |
2 | ||
3 | # generic architecture script | |
4 | ARCHITECTURE=`uname -m` | |
5 | ||
6 | # create the '/opt/rainlendar2/lib' directory | |
7 | sudo mkdir /opt/rainlendar2/lib | |
8 | ||
9 | # go to '/opt/rainlendar2/lib' directory | |
10 | cd /opt/rainlendar2/lib | |
11 | ||
12 | # download the curl-7.23.1-2 package (stdout) | xz decompression | tar decompression (only libcurl.so* files + stripping filenames: 'usr/lib/libcurl*' -> 'libcurl*') | |
13 | curl http://arm.konnichi.com/2012/01/01/core/os/${ARCHITECTURE}/curl-7.23.1-2-${ARCHITECTURE}.pkg.tar.xz | xzcat - | sudo tar xf - --strip 2 usr/lib/libcurl.so{,.4{,.2.0}} | |
14 | ||
15 | # go to '/opt/rainlendar2' directory | |
16 | cd .. | |
17 | ||
18 | # move the binary 'rainlendar2' into 'rainlendar2.bin' | |
19 | sudo mv rainlendar2{,.bin} | |
20 | ||
21 | # create a 'rainlendar2' launcher with the LD_LIBRARY_PATH pointing to '/opt/rainlendar2/lib' | |
22 | echo -e '#!'"/bin/bash\n\nLD_LIBRARY_PATH=`pwd`/lib `pwd`/rainlendar2.bin\n" | sudo tee -a rainlendar2 | |
23 | ||
24 | # add the execute permission to the 'rainlendar2' | |
25 | sudo chmod +x rainlendar2 |