-
Notifications
You must be signed in to change notification settings - Fork 4
/
make_tarball.sh
66 lines (56 loc) · 1.84 KB
/
make_tarball.sh
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
#!/bin/sh -
VERSION=1.2.0
TAGVERSION=`echo $VERSION | tr \. _`
DEST=tmp/mtp-target
CDEST=$DEST/client
SDEST=$DEST/server
# create directories
rm -rf tmp
mkdir tmp
mkdir $DEST
mkdir $CDEST
mkdir $SDEST
mkdir $DEST/lib
# copy client files
cp -a client/src/client $CDEST
strip $CDEST/client
cp -a client/data $CDEST
cp -a client/cache $CDEST
cp -a client/mtp_target_default.cfg $CDEST
echo "#!/bin/sh -" >>$CDEST/launch.sh
echo "export LD_LIBRARY_PATH=\$LD_LIBRARY_PATH:../lib" >>$CDEST/launch.sh
echo "./client" >>$CDEST/launch.sh
chmod 700 $CDEST/launch.sh
# copy server files
cp -a server/src/mtp_target_service $SDEST
strip $SDEST/mtp_target_service
cp -a server/data $SDEST
cp -a server/mtp_target_service_default.cfg $SDEST
echo "#!/bin/sh -" >>$SDEST/launch.sh
echo "export LD_LIBRARY_PATH=\$LD_LIBRARY_PATH:../lib" >>$SDEST/launch.sh
echo "./mtp_target_service" >>$SDEST/launch.sh
chmod 700 $SDEST/launch.sh
# copy libs
strip $HOME/install/release/lib/*.so
cp -a $HOME/install/release/lib/libnel3d.so.0.0.4 $DEST/lib
cp -a $HOME/install/release/lib/libnel3d.so.0 $DEST/lib
cp -a $HOME/install/release/lib/libnelnet.so.0.0.4 $DEST/lib
cp -a $HOME/install/release/lib/libnelnet.so.0 $DEST/lib
cp -a $HOME/install/release/lib/libnelmisc.so.0.0.4 $DEST/lib
cp -a $HOME/install/release/lib/libnelmisc.so.0 $DEST/lib
cp -a $HOME/install/release/lib/libnel_drv_opengl.so.0.0.0 $DEST/lib
cp -a $HOME/install/release/lib/libnel_drv_opengl.so.0 $DEST/lib
cp /usr/lib/libfreetype.so.6 $DEST/lib
cp /usr/lib/liblua50.so.5.0 $DEST/lib
cp /usr/lib/libxml2.so.2 $DEST/lib
cp /usr/lib/libz.so.1 $DEST/lib
cp /usr/lib/libstlport_gcc.so.4.6 $DEST/lib
cp /usr/lib/libjpeg.so.62 $DEST/lib
cp /lib/libcrypt.so.1 $DEST/lib
cvs -z3 -q tag -F release_$TAGVERSION
# tar and send
rm -f mtp-target-*.tar.bz2
cd tmp
tar jcvf ../mtp-target-$VERSION.tar.bz2 mtp-target
cd ..
ftp ftpperso.free.fr