forked from kactus2/kactus2dev
-
Notifications
You must be signed in to change notification settings - Fork 0
/
configure
executable file
·47 lines (40 loc) · 1.37 KB
/
configure
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
#!/bin/sh
# Change this to your Qt binaries directory.
QTBIN_PATH=""
echo "Configuring Kactus2..."
echo ""
print_success() {
if [ -f "Makefile" ];
then
echo ""
echo "Kactus2 has now been configured. Run make to start the build."
echo "To install, run make install after the build has completed."
else
echo ""
echo "The makefile was not created."
fi
}
# Auto search QTBIN_PATH when empty and qmake already installed.
if [ -z ${QTBIN_PATH} ]; then
if command -v qmake6 >/dev/null 2>&1; then
# Default to qmake6, which will exist on some linux distributions.
QTBIN_PATH=$(qmake6 -query QT_INSTALL_BINS)/
elif command -v qmake >/dev/null 2>&1; then
# qmake exists on the vast majority of linux distributions.
QTBIN_PATH=$(qmake -query QT_INSTALL_BINS)/
fi
fi
# Generate compressed help files.
echo "Generating compressed help files..."
if command -v ${QTBIN_PATH}qhelpgenerator >/dev/null 2>&1; then
${QTBIN_PATH}qhelpgenerator Help/kactus2help.qhcp -o Help/Kactus2Help.qhc
else
echo "Qhelpgenerator not found. Please set variable QTBIN_PATH to Qt binary files."
fi
if command -v ${QTBIN_PATH}qmake >/dev/null 2>&1; then
echo "Running qmake..."
${QTBIN_PATH}qmake Kactus2_Solution.pro
print_success
else
echo "Qmake not found. Please set variable QTBIN_PATH to Qt binary files."
fi