-
Notifications
You must be signed in to change notification settings - Fork 329
/
build_linux_portable.sh
executable file
·70 lines (57 loc) · 4.27 KB
/
build_linux_portable.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
67
68
69
70
#!/bin/bash -x
export QMAKE_PATH=/usr/bin/qmake
export X_SOURCE_PATH=$PWD
export X_BUILD_NAME=die_linux_portable
export X_RELEASE_VERSION=$(cat "release_version.txt")
source build_tools/linux.sh
check_file $QMAKE_PATH
if [ -z "$X_ERROR" ]; then
make_init
if [ ! -f "$X_SOURCE_PATH/build/release/die" ]; then
make_build "$X_SOURCE_PATH/die_source.pro"
cd "$X_SOURCE_PATH/gui_source"
make_translate "gui_source_tr.pro"
cd "$X_SOURCE_PATH"
fi
check_file "$X_SOURCE_PATH/build/release/die"
check_file "$X_SOURCE_PATH/build/release/diec"
check_file "$X_SOURCE_PATH/build/release/diel"
if [ -z "$X_ERROR" ]; then
mkdir -p $X_SOURCE_PATH/release/$X_BUILD_NAME/base
mkdir -p $X_SOURCE_PATH/release/$X_BUILD_NAME/base/platforms
mkdir -p $X_SOURCE_PATH/release/$X_BUILD_NAME/base/sqldrivers
cp -f $X_SOURCE_PATH/build/release/die $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -f $X_SOURCE_PATH/build/release/diec $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -f $X_SOURCE_PATH/build/release/diel $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -R $X_QT_INSTALL_PLUGINS/platforms/libqxcb.so $X_SOURCE_PATH/release/$X_BUILD_NAME/base/platforms/
cp -R $X_QT_INSTALL_PLUGINS/sqldrivers/qsqlite.dll $X_SOURCE_PATH/release/$X_BUILD_NAME/base/sqldrivers/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Core.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Svg.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Gui.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Sql.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Widgets.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5OpenGL.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5DBus.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5XcbQpa.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5ScriptTools.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Script.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Lr $X_QT_INSTALL_LIBS/libQt5Network.so.5 $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Rf $X_SOURCE_PATH/XStyles/qss/ $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Rf $X_SOURCE_PATH/XInfoDB/info/ $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Rf $X_SOURCE_PATH/Detect-It-Easy/db/ $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Rf $X_SOURCE_PATH/Detect-It-Easy/db_custom/ $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
cp -Rf $X_SOURCE_PATH/XYara/yara_rules/ $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
mkdir -p $X_SOURCE_PATH/release/$X_BUILD_NAME/base/lang/
cp -f $X_SOURCE_PATH/gui_source/translation/*.qm $X_SOURCE_PATH/release/$X_BUILD_NAME/base/lang/
mkdir -p $X_SOURCE_PATH/release/$X_BUILD_NAME/base/signatures/
cp -f $X_SOURCE_PATH/signatures/crypto.db $X_SOURCE_PATH/release/$X_BUILD_NAME/base/signatures/
cp -Rf $X_SOURCE_PATH/images $X_SOURCE_PATH/release/$X_BUILD_NAME/base/
create_run_shell $X_SOURCE_PATH/release/$X_BUILD_NAME/die.sh die
create_run_shell $X_SOURCE_PATH/release/$X_BUILD_NAME/diec.sh diec
create_run_shell $X_SOURCE_PATH/release/$X_BUILD_NAME/diel.sh diel
cd $X_SOURCE_PATH/release
make_targz $X_BUILD_NAME $X_SOURCE_PATH/release/die_${X_RELEASE_VERSION}_portable_${X_OS_VERSION}_${X_ARCHITECTURE}
cd $X_SOURCE_PATH
make_clear
fi
fi