blob: e27ee86c236937af22ca37f2d8c60e61fcee7fe3 (
plain)
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
|
# Maintainer: sehraf
# Contributor: stqn
# Set this to true to build and install retroshare-nogui
_build_nogui=true
# Set this to true to build and install the plugins
_build_feedreader=true
_build_voip=true
### Nothing to be changed below this line ###
_pkgname=retroshare
pkgname=${_pkgname}-git
pkgver=v0.6.0.RC2.r123.gb8459b3
pkgrel=1
pkgdesc="Serverless encrypted instant messenger with filesharing, chatgroups, e-mail."
arch=('i686' 'x86_64' 'armv6h' 'armv7h')
url="http://retroshare.sourceforge.net/"
license=('GPL' 'LGPL')
depends=('qt4' 'libupnp' 'libgnome-keyring' 'libxss' 'libmicrohttpd' 'sqlcipher')
makedepends=('git')
provides=("${_pkgname}")
conflicts=("${_pkgname}")
install='retroshare.install'
source=("${_pkgname}::git+https://github.com/RetroShare/RetroShare.git"
'retroshare.install')
sha256sums=('SKIP'
'47c23238cbfabb6f07b6a25666ee5941243176360ca28ec31378d94e87326ec1')
# Add missing dependencies if needed
[[ $_build_voip == true ]] && depends=(${depends[@]} 'speex' 'opencv')
[[ $_build_feedreader == true ]] && depends=(${depends[@]} 'curl' 'libxslt')
pkgver() {
cd "${srcdir}/${_pkgname}"
git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
cd "${srcdir}/${_pkgname}"
_qmake='qmake-qt4'
#
# BUILD HERE
#
msg "Compiling OpenPGP-SDK..."
cd openpgpsdk/src
$_qmake
make
cd ../..
msg "Compiling libbitdht..."
cd libbitdht/src
$_qmake
make
cd ../..
msg "Compiling pegmarkdown..."
cd supportlibs/pegmarkdown
$_qmake
make
cd ../..
msg "Compiling libretroshare..."
cd libretroshare/src
$_qmake
LANG=C ./version_detail.sh
make
cd ../..
msg "Compiling libresapi..."
cd libresapi/src
$_qmake
make
# i'm not 100% sure if this step is required
# it will download/update some JavaScript files
msg "Updating webui files..."
cd webui
make
cd ..
cd ../..
msg "Compiling retroshare-gui..."
cd retroshare-gui/src
$_qmake
LANG=C ./version_detail.sh
make
cd ../..
if [[ "$_build_voip" == "true" ]] ; then
msg "Compiling VOIP plugin..."
cd plugins/VOIP
$_qmake
make
cd ../..
fi
if [[ "$_build_feedreader" == "true" ]] ; then
msg "Compiling FeedReader plugin..."
cd plugins/FeedReader
$_qmake
make
cd ../..
fi
if [[ "$_build_nogui" == "true" ]]; then
msg "Compiling retroshare-nogui..."
cd retroshare-nogui/src
$_qmake
make
cd ../..
fi
}
package() {
cd "${srcdir}/${_pkgname}"
# Binaries
install -D -m 755 \
retroshare-gui/src/RetroShare06 \
"$pkgdir/usr/bin/retroshare"
if [[ "$_build_nogui" == "true" ]]; then
install -D -m 755 \
"retroshare-nogui/src/RetroShare06-nogui" \
"${pkgdir}/usr/bin/retroshare-nogui"
fi
# Webui files
install -d -m 655 "${pkgdir}/usr/share/RetroShare06/webui/"
for _file in $(ls libresapi/src/webfiles/); do
install -D -m 644 \
"libresapi/src/webfiles/${_file}" \
"${pkgdir}/usr/share/RetroShare06/webui/"
done
# Plugins
if [[ "$_build_voip" == "true" ]] ; then
install -D -m 755 \
"plugins/VOIP/libVOIP.so" \
"${pkgdir}/usr/lib/retroshare/extensions6/libVOIP.so"
fi
if [[ "$_build_feedreader" == "true" ]] ; then
install -D -m 755 \
"plugins/FeedReader/libFeedReader.so" \
"${pkgdir}/usr/lib/retroshare/extensions6/libFeedReader.so"
fi
# Applications menu entry
mkdir -p "$pkgdir/usr/share/applications"
cat >"$pkgdir/usr/share/applications/retroshare.desktop" <<EOF
[Desktop Entry]
Version=1.0
Type=Application
Name=RetroShare
GenericName=Sharing Network
Comment=Secure communication with your friends
Icon=/usr/share/pixmaps/retroshare_blue.png
Exec=/usr/bin/retroshare
Terminal=false
StartupNotify=true
Categories=Network;InstantMessaging;FileTransfer;Chat;Email;
EOF
install -D -m 644 \
"retroshare-gui/src/gui/images/logo/logo_512.png" \
"${pkgdir}/usr/share/pixmaps/retroshare_blue.png"
# bdboot (needed to bootstrap the DHT)
install -D -m 644 \
"libbitdht/src/bitdht/bdboot.txt" \
"${pkgdir}/usr/share/RetroShare06/bdboot.txt"
# Skins
cp -r "retroshare-gui/src/qss" "${pkgdir}/usr/share/RetroShare06/"
}
|