1 |
commit: a36219a050e6d671f2c796191b1273153b640a35 |
2 |
Author: Sobhan Mohammadpour <www.sobhan.mohammadpour <AT> gmail <DOT> com> |
3 |
AuthorDate: Mon Oct 23 12:28:39 2017 +0000 |
4 |
Commit: Mark Wright <gienah <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Oct 24 06:46:05 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a36219a0 |
7 |
|
8 |
sci-mathematics/rstudio: version bump to 1.1.368 |
9 |
|
10 |
Bump to 1.1.368. This also updates the clang pandoc patch |
11 |
Fixes bug 626056, thanks to Harris Landgarten for reporting, Sobhan |
12 |
Mohammadpour for adding the missing dependency in 1.1.383. |
13 |
Fixes bug 626062 by bumping rstudio to version 1.1.383 that builds with R 3.4. |
14 |
Thanks to Harris Landgarten for reporting, jstein, Volkmar Glauche, Bernd |
15 |
Feige and yuri for testing and helping, Sobhan Mohammadpour for bumping |
16 |
rstudio in PR #6003. |
17 |
Fixes bug 622254, thanks to jstein for reporting, Volkmar Glauche, Bernd Feige, |
18 |
Carl W. Harlow, Rolf S. Arvidson, Oleg, Alex and Sobhan Mohammadpour for |
19 |
testing and helping. |
20 |
Fixes bug 633936, thanks to Neil for reporting, François Valenduc and Bernd |
21 |
for helping. |
22 |
|
23 |
Suggested-by: Bernd Feige <Bernd.Feige <AT> gmx.net> |
24 |
Gentoo-bug: 626056, 626062. 622254, 633936 |
25 |
|
26 |
sci-mathematics/rstudio/Manifest | 1 + |
27 |
.../files/rstudio-1.1.357-clang-pandoc.patch | 76 +++++++ |
28 |
sci-mathematics/rstudio/rstudio-1.1.368.ebuild | 248 +++++++++++++++++++++ |
29 |
3 files changed, 325 insertions(+) |
30 |
|
31 |
diff --git a/sci-mathematics/rstudio/Manifest b/sci-mathematics/rstudio/Manifest |
32 |
index 728e003ec65..5d4b2fdc369 100644 |
33 |
--- a/sci-mathematics/rstudio/Manifest |
34 |
+++ b/sci-mathematics/rstudio/Manifest |
35 |
@@ -20,6 +20,7 @@ DIST rstudio-1.0.136.tar.gz 17786389 SHA256 bb6a8aa475e09dd090cd2b5ea505f578d270 |
36 |
DIST rstudio-1.0.143.tar.gz 17791067 SHA256 8ae88731b4474e5e2ff9030aa14e168903fe3a7ffc4fa716f497084a86801062 SHA512 46eaa88dd8332f18bb3a43de6e262d8a365860d9add78aea6a2d345784b239972c9c73bf0b56f1736b2981b8f688dbaf5a83c6848d170c0cf61d0e51dd636a82 WHIRLPOOL db1c11be240db3528e46d359c7d40d64068dfe5f7d915c4a6b690444f7f7fbc11f3898a6e262fa625bfab906f0cbfb2a8e3288a4fd20470423a99d992972fcda |
37 |
DIST rstudio-1.0.153.tar.gz 17790922 SHA256 79b90e21e56b114e28b03fd8543a208c55bb9d5f47a87fd29143d08b9a06f7a0 SHA512 d970a9bde88845e3fc6cdaff5233ffb65c03939c685c3fca0dd052246e065c7580b3f9bc4e053a79d2ecbb5f8c283d3fce7b97cc69e43176bd49587c736dab86 WHIRLPOOL c1f4c7bdc8e5a85af53411a35d736278b83f4732d2e273378fecc77cb075dff507147d56012682564edd58041c91cc051189eb38a7348d0827b76c7ac37bd54d |
38 |
DIST rstudio-1.0.44.tar.gz 17774065 SHA256 43ece6cfdd1a13ac0e17f2a50154a30a1a14ad6c1b3cf381cc6007988ce44a0f SHA512 a8b975dc517125a257e5f61db5bb137e133b02d738d55553770aa65e388cd112ce646b53b77dc069d1ca95ccd95979f4a57ad60b99fc3b91543cf61e737e8169 WHIRLPOOL 4ad472aed130451e81d8d8e3251d3bbd701a8b8e2fbddf17dc357f39335e33c75505f9443c2c7208e60a19c2767b9328134433e5d4fd22504813020712c658ef |
39 |
+DIST rstudio-1.1.368.tar.gz 20197144 SHA256 586573707a488b5f528680b932ba5f8ea6d07667cc5ae6426104e2abf5ddab75 SHA512 39cdf583d7dcd22338916cc0ea4f90681580e41663b2d3e04b2e650759c6b030c85ee111cdfe1f717f931932a9b7ca423a21585d69a785f056f754f6d50399a1 WHIRLPOOL e18ff21823638d458179819e0b0b234b80be2f095f5b7bf5b9ac0190b078f0d7acb51e8896cbfcf1ce33cd203ed4e9fbe097aac6eee62515cace1d2f08c08219 |
40 |
DIST selenium-java-2.37.0.zip 24625928 SHA256 0eebba65d8edb01c1f46e462907c58f5d6e1cb0ddf63660a9985c8432bdffbb7 SHA512 68624e82dbc751a25c50fad72702a98eb30d77fd4337d2a969f8e06bcc49e5f8c835cd27ec53772f3375014ddde1d5636936e966b75f3594a9f86aa18ba4e779 WHIRLPOOL eb6659aae26f3c78b6f998546b23d0636c9d00ed8a7f985db1463ac4bd483ccb3e643d84e2ca0f59e0636a8de79eb552ff1d68eb6f9c06907029f7552d8f7777 |
41 |
DIST selenium-server-standalone-2.37.0.jar 34730734 SHA256 97bc8c699037fb6e99ba7af570fb60dbb1b7ce30cde2448287a44ef65b13023e SHA512 b215446d42d2d1f69664349b6ae6dc53a532d3624c91254f0f4183d0ad764648792e5cc1126a55a1e60d9687d55200fed01d6d2f46cc3d853b1fa6ee38111018 WHIRLPOOL 20640591534f31f24825a9ed139589b182e8b60d86541bf0be104d3cc0280983f6566bd0459f2253ac3875b48a2798b205bac8f815a119fff6db625ce9bbc29e |
42 |
DIST shinyapps-0.98.1000.tar.gz 910095 SHA256 b95c512ae0a0fb4335878d9cfcf9073e2cb3ccfed73543abe27ea8878ed36d57 SHA512 3162317c4c20cfc1497e952a8235867084d629ae88407e6c465b3e208adb1dc97abfe6b9922e0374ddf4c8e38a76e112942bd312c54a66f74e6f2a3fe4c0a07c WHIRLPOOL ecc2bce78387cb42e9989163d8fca29220e66f085acde3323417058aebb624dafa8c0e1873c7d79e67324cbd5aad250ef9fcdbbc8f659d64482233b95d898a15 |
43 |
|
44 |
diff --git a/sci-mathematics/rstudio/files/rstudio-1.1.357-clang-pandoc.patch b/sci-mathematics/rstudio/files/rstudio-1.1.357-clang-pandoc.patch |
45 |
new file mode 100644 |
46 |
index 00000000000..28b0220912a |
47 |
--- /dev/null |
48 |
+++ b/sci-mathematics/rstudio/files/rstudio-1.1.357-clang-pandoc.patch |
49 |
@@ -0,0 +1,76 @@ |
50 |
+Index: rstudio-1.1.357/src/cpp/session/CMakeLists.txt |
51 |
+=================================================================== |
52 |
+--- rstudio-1.1.357.orig/src/cpp/session/CMakeLists.txt |
53 |
++++ rstudio-1.1.357/src/cpp/session/CMakeLists.txt |
54 |
+@@ -25,9 +25,6 @@ endif() |
55 |
+ if(NOT EXISTS "${RSTUDIO_DEPENDENCIES_DIR}/common/mathjax-26") |
56 |
+ message(FATAL_ERROR "Mathjax 2.6 not found (re-run install-dependencies script to install)") |
57 |
+ endif() |
58 |
+-if(NOT EXISTS "${RSTUDIO_DEPENDENCIES_DIR}/common/pandoc") |
59 |
+- message(FATAL_ERROR "pandoc not found (re-run install-dependencies script to install)") |
60 |
+-endif() |
61 |
+ |
62 |
+ # we often install embedded versions of these packages but don't do so currently |
63 |
+ |
64 |
+@@ -38,22 +35,6 @@ endif() |
65 |
+ # message(FATAL_ERROR "rsconnect package not found (re-run install-dependencies script to install)") |
66 |
+ # endif() |
67 |
+ |
68 |
+-# verify libclang is installed |
69 |
+-if(WIN32) |
70 |
+- set(LIBCLANG_VERSION "3.4") |
71 |
+-else() |
72 |
+- set(LIBCLANG_VERSION "3.5") |
73 |
+-endif() |
74 |
+-set(LIBCLANG_DIR "${RSTUDIO_DEPENDENCIES_DIR}/common/libclang/${LIBCLANG_VERSION}") |
75 |
+-if(NOT EXISTS "${LIBCLANG_DIR}") |
76 |
+- message(FATAL_ERROR "libclang ${LIBCLANG_VERSION} not found (re-run install-dependencies script to install)") |
77 |
+-endif() |
78 |
+-set(LIBCLANG_HEADERS_DIR "${RSTUDIO_DEPENDENCIES_DIR}/common/libclang/builtin-headers") |
79 |
+-if(NOT EXISTS "${LIBCLANG_HEADERS_DIR}") |
80 |
+- message(FATAL_ERROR "libclang builtin-headers not found (re-run install-dependencies script to install)") |
81 |
+-endif() |
82 |
+- |
83 |
+- |
84 |
+ # include files |
85 |
+ file(GLOB_RECURSE SESSION_HEADER_FILES "*.h*") |
86 |
+ |
87 |
+@@ -465,13 +446,6 @@ if (NOT RSTUDIO_SESSION_WIN64) |
88 |
+ install(DIRECTORY "resources/connections" |
89 |
+ DESTINATION ${RSTUDIO_INSTALL_SUPPORTING}/resources) |
90 |
+ |
91 |
+- # install pandoc |
92 |
+- set(PANDOC_BIN "${RSTUDIO_DEPENDENCIES_DIR}/common/pandoc/1.19.2.1") |
93 |
+- file(GLOB PANDOC_FILES "${PANDOC_BIN}/pandoc*") |
94 |
+- install(FILES ${PANDOC_FILES} |
95 |
+- PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE |
96 |
+- DESTINATION ${RSTUDIO_INSTALL_BIN}/pandoc) |
97 |
+- |
98 |
+ # install rmarkdown package |
99 |
+ # file(GLOB RMARKDOWN_PACKAGE "${RSTUDIO_DEPENDENCIES_DIR}/common/rmarkdown*.tar.gz") |
100 |
+ # install(FILES ${RMARKDOWN_PACKAGE} |
101 |
+@@ -502,24 +476,6 @@ if (NOT RSTUDIO_SESSION_WIN64) |
102 |
+ install(DIRECTORY "resources/profiler" |
103 |
+ DESTINATION ${RSTUDIO_INSTALL_SUPPORTING}/resources) |
104 |
+ |
105 |
+- # install libclang |
106 |
+- if(WIN32) |
107 |
+- file(GLOB LIBCLANG_32_FILES "${LIBCLANG_DIR}/x86/libclang.*") |
108 |
+- install(PROGRAMS ${LIBCLANG_32_FILES} |
109 |
+- DESTINATION ${RSTUDIO_INSTALL_BIN}/rsclang/x86) |
110 |
+- file(GLOB LIBCLANG_64_FILES "${LIBCLANG_DIR}/x86_64/libclang.*") |
111 |
+- install(PROGRAMS ${LIBCLANG_64_FILES} |
112 |
+- DESTINATION ${RSTUDIO_INSTALL_BIN}/rsclang/x86_64) |
113 |
+- else() |
114 |
+- file(GLOB_RECURSE LIBCLANG_FILES "${LIBCLANG_DIR}/libclang.*") |
115 |
+- install(PROGRAMS ${LIBCLANG_FILES} |
116 |
+- DESTINATION ${RSTUDIO_INSTALL_BIN}/rsclang) |
117 |
+- endif() |
118 |
+- |
119 |
+- # install libclang builtin-headers |
120 |
+- install(DIRECTORY "${RSTUDIO_DEPENDENCIES_DIR}/common/libclang/builtin-headers" |
121 |
+- DESTINATION "${RSTUDIO_INSTALL_SUPPORTING}/resources/libclang") |
122 |
+- |
123 |
+ # install winpty on windows |
124 |
+ if(WIN32) |
125 |
+ install(PROGRAMS "${WINPTY_BINDIR_32}/winpty.dll" |
126 |
|
127 |
diff --git a/sci-mathematics/rstudio/rstudio-1.1.368.ebuild b/sci-mathematics/rstudio/rstudio-1.1.368.ebuild |
128 |
new file mode 100644 |
129 |
index 00000000000..38ac6d8ddf2 |
130 |
--- /dev/null |
131 |
+++ b/sci-mathematics/rstudio/rstudio-1.1.368.ebuild |
132 |
@@ -0,0 +1,248 @@ |
133 |
+# Copyright 1999-2017 Gentoo Foundation |
134 |
+# Distributed under the terms of the GNU General Public License v2 |
135 |
+ |
136 |
+EAPI=6 |
137 |
+ |
138 |
+inherit eutils user cmake-utils gnome2-utils pam versionator xdg-utils java-pkg-2 pax-utils qmake-utils |
139 |
+ |
140 |
+# TODO |
141 |
+# * package gin and gwt |
142 |
+# * use dict from tree, linguas |
143 |
+# * do src_test (use junit from tree?) |
144 |
+ |
145 |
+# update from scripts in dependencies/common |
146 |
+# egrep '(GWT_SDK_VER=|GIN_VER=|SELENIUM_VER=|CHROMEDRIVER_VER=)' dependencies/common/install-gwt |
147 |
+GWT_VER=2.7.0 |
148 |
+GIN_VER=1.5 |
149 |
+SELENIUM_VER=2.37.0 |
150 |
+CHROMEDRIVER_VER=2.7 |
151 |
+# grep 'PANDOC_VERSION=' dependencies/common/update-pandoc |
152 |
+PANDOC_VER=1.13.1 |
153 |
+# ls dependencies/common/*.tar.gz |
154 |
+PACKRAT_VER=0.98.1000 |
155 |
+RMARKDOWN_VER=0.98.1000 |
156 |
+SHINYAPPS_VER=0.98.1000 |
157 |
+RSCONNECT_VER=0.4.1.4_fcac892a69817febd7b655b189bf57193260cda0 |
158 |
+ |
159 |
+DESCRIPTION="IDE for the R language" |
160 |
+HOMEPAGE=" |
161 |
+ http://www.rstudio.org |
162 |
+ https://github.com/rstudio/rstudio/" |
163 |
+SRC_URI=" |
164 |
+ https://github.com/rstudio/rstudio/archive/v${PV}.tar.gz -> ${P}.tar.gz |
165 |
+ https://s3.amazonaws.com/rstudio-buildtools/gin-${GIN_VER}.zip |
166 |
+ https://s3.amazonaws.com/rstudio-buildtools/gwt-${GWT_VER}.zip |
167 |
+ https://s3.amazonaws.com/rstudio-buildtools/selenium-java-${SELENIUM_VER}.zip |
168 |
+ https://s3.amazonaws.com/rstudio-buildtools/selenium-server-standalone-${SELENIUM_VER}.jar |
169 |
+ https://s3.amazonaws.com/rstudio-buildtools/chromedriver-linux |
170 |
+ https://s3.amazonaws.com/rstudio-dictionaries/core-dictionaries.zip |
171 |
+ https://dev.gentoo.org/~gienah/distfiles/packrat-${PACKRAT_VER}.tar.gz |
172 |
+ https://dev.gentoo.org/~gienah/distfiles/rmarkdown-${RMARKDOWN_VER}.tar.gz |
173 |
+ https://dev.gentoo.org/~gienah/distfiles/shinyapps-${SHINYAPPS_VER}.tar.gz |
174 |
+ https://dev.gentoo.org/~gienah/distfiles/rsconnect_${RSCONNECT_VER}.tar.gz |
175 |
+" |
176 |
+ |
177 |
+LICENSE="AGPL-3" |
178 |
+SLOT="0" |
179 |
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux" |
180 |
+IUSE="dedicated server" |
181 |
+ |
182 |
+QT_VER=5.4 |
183 |
+QT_SLOT=5 |
184 |
+RDEPEND=" |
185 |
+ app-text/pandoc |
186 |
+ dev-haskell/pandoc-citeproc |
187 |
+ >=dev-lang/R-2.11.1 |
188 |
+ >=dev-libs/boost-1.63:= |
189 |
+ >=dev-libs/mathjax-2.7.0 |
190 |
+ dev-libs/openssl:0 |
191 |
+ sys-apps/util-linux |
192 |
+ >=sys-devel/clang-3.5.0:* |
193 |
+ sys-libs/zlib |
194 |
+ >=virtual/jre-1.8:= |
195 |
+ x11-libs/pango |
196 |
+ !dedicated? ( |
197 |
+ >=dev-qt/qtcore-${QT_VER}:${QT_SLOT} |
198 |
+ >=dev-qt/qtdeclarative-${QT_VER}:${QT_SLOT} |
199 |
+ >=dev-qt/qtdbus-${QT_VER}:${QT_SLOT} |
200 |
+ >=dev-qt/qtgui-${QT_VER}:${QT_SLOT} |
201 |
+ >=dev-qt/qtnetwork-${QT_VER}:${QT_SLOT} |
202 |
+ >=dev-qt/qtopengl-${QT_VER}:${QT_SLOT} |
203 |
+ >=dev-qt/qtpositioning-${QT_VER}:${QT_SLOT} |
204 |
+ >=dev-qt/qtprintsupport-${QT_VER}:${QT_SLOT} |
205 |
+ >=dev-qt/qtsingleapplication-2.6.1_p20150629[X,qt5] |
206 |
+ >=dev-qt/qtsensors-${QT_VER}:${QT_SLOT} |
207 |
+ >=dev-qt/qtsql-${QT_VER}:${QT_SLOT} |
208 |
+ >=dev-qt/qtsvg-${QT_VER}:${QT_SLOT} |
209 |
+ >=dev-qt/qtwebchannel-${QT_VER}:${QT_SLOT} |
210 |
+ >=dev-qt/qtwebkit-${QT_VER}:${QT_SLOT} |
211 |
+ >=dev-qt/qtwidgets-${QT_VER}:${QT_SLOT} |
212 |
+ >=dev-qt/qtxml-${QT_VER}:${QT_SLOT} |
213 |
+ >=dev-qt/qtxmlpatterns-${QT_VER}:${QT_SLOT} |
214 |
+ server? ( virtual/pam ) |
215 |
+ ) |
216 |
+ dedicated? ( virtual/pam )" |
217 |
+DEPEND="${RDEPEND} |
218 |
+ app-arch/unzip |
219 |
+ dev-java/ant-core |
220 |
+ >=virtual/jdk-1.8:= |
221 |
+ virtual/pkgconfig" |
222 |
+# test? ( dev-java/junit:4 ) |
223 |
+ |
224 |
+PATCHES=( |
225 |
+ "${FILESDIR}/${PN}-0.99.879-prefs.patch" |
226 |
+ "${FILESDIR}/${PN}-1.0.44-paths.patch" |
227 |
+ "${FILESDIR}/${PN}-1.1.357-clang-pandoc.patch" |
228 |
+ "${FILESDIR}/${PN}-0.98.490-linker_flags.patch" |
229 |
+ "${FILESDIR}/${PN}-0.98.1091-boost-1.57.patch" |
230 |
+ "${FILESDIR}/${PN}-0.99.473-qtsingleapplication.patch" |
231 |
+ "${FILESDIR}/${PN}-1.0.44-systemd.patch" |
232 |
+) |
233 |
+ |
234 |
+src_unpack() { |
235 |
+ unpack ${P}.tar.gz gwt-${GWT_VER}.zip |
236 |
+ cd "${S}" || die |
237 |
+ mkdir -p src/gwt/lib/{gin,gwt} \ |
238 |
+ dependencies/common/dictionaries \ |
239 |
+ src/gwt/lib/selenium/${SELENIUM_VER} \ |
240 |
+ src/gwt/lib/selenium/chromedriver/${CHROMEDRIVER_VER} || die |
241 |
+ mv ../gwt-${GWT_VER} src/gwt/lib/gwt/${GWT_VER} || die |
242 |
+ unzip -qd src/gwt/lib/gin/${GIN_VER} \ |
243 |
+ "${DISTDIR}"/gin-${GIN_VER}.zip || die |
244 |
+ unzip -qd dependencies/common/dictionaries \ |
245 |
+ "${DISTDIR}"/core-dictionaries.zip || die |
246 |
+ unzip -qd src/gwt/lib/selenium/${SELENIUM_VER} \ |
247 |
+ "${DISTDIR}"/selenium-java-${SELENIUM_VER}.zip || die |
248 |
+ cp "${DISTDIR}"/selenium-server-standalone-${SELENIUM_VER}.jar \ |
249 |
+ src/gwt/lib/selenium/${SELENIUM_VER}/ || die |
250 |
+ cp "${DISTDIR}"/chromedriver-linux \ |
251 |
+ src/gwt/lib/selenium/chromedriver/${CHROMEDRIVER_VER}/ || die |
252 |
+ cd dependencies/common || die |
253 |
+ unpack packrat-${PACKRAT_VER}.tar.gz |
254 |
+ unpack rmarkdown-${RMARKDOWN_VER}.tar.gz |
255 |
+ unpack shinyapps-${SHINYAPPS_VER}.tar.gz |
256 |
+ unpack rsconnect_${RSCONNECT_VER}.tar.gz |
257 |
+ cp "${DISTDIR}"/rmarkdown-${RMARKDOWN_VER}.tar.gz \ |
258 |
+ . || die |
259 |
+ cp "${DISTDIR}"/packrat-${PACKRAT_VER}.tar.gz \ |
260 |
+ . || die |
261 |
+ cp "${DISTDIR}"/shinyapps-${SHINYAPPS_VER}.tar.gz \ |
262 |
+ . || die |
263 |
+ cp "${DISTDIR}"/rsconnect_${RSCONNECT_VER}.tar.gz \ |
264 |
+ . || die |
265 |
+} |
266 |
+ |
267 |
+src_prepare() { |
268 |
+ default |
269 |
+ java-pkg-2_src_prepare |
270 |
+ egit_clean |
271 |
+ |
272 |
+ # Enable CMake to install our .service file for systemd usage |
273 |
+ mkdir -vp "${S}/src/cpp/server/lib/systemd/system" || die |
274 |
+ cp -v "${FILESDIR}/rstudio-server.service.in" "${S}/src/cpp/server/lib/systemd/system/" || die |
275 |
+ |
276 |
+ # Adding -DDISTRO_SHARE=... to append-flags breaks cmake so using |
277 |
+ # this sed hack for now. ~RMH |
278 |
+ sed -i \ |
279 |
+ -e "s|DISTRO_SHARE|\"share/${PN}\"|g" \ |
280 |
+ src/cpp/server/ServerOptions.cpp \ |
281 |
+ src/cpp/session/SessionOptions.cpp || die |
282 |
+ |
283 |
+ # use mathjax from system |
284 |
+ ln -sf "${EPREFIX}"/usr/share/mathjax dependencies/common/mathjax-26 || die |
285 |
+ |
286 |
+ # make sure icons and mime stuff are with prefix |
287 |
+ sed -i \ |
288 |
+ -e "s:/usr:${EPREFIX}/usr:g" \ |
289 |
+ CMakeGlobals.txt src/cpp/desktop/CMakeLists.txt || die |
290 |
+ |
291 |
+ # On Gentoo the rstudio-server configuration file is /etc/conf.d/rstudio-server.conf |
292 |
+ sed -e "s@/etc/rstudio/rserver.conf@${EROOT}etc/conf.d/rstudio-server.conf@" \ |
293 |
+ -i src/cpp/server/ServerOptions.cpp \ |
294 |
+ || die |
295 |
+ |
296 |
+ # Set the rsession.conf file location for Gentoo prefix |
297 |
+ sed -e "s@/etc/rstudio/rsession.conf@${EROOT}etc/rstudio/rsession.conf@" \ |
298 |
+ -i src/cpp/session/SessionOptions.cpp \ |
299 |
+ || die |
300 |
+ |
301 |
+ # dev-qt/qtsingleapplication-2.6.1_p20150629 does not provide a cmake module. |
302 |
+ # It provides a library that has its version number appended to the end, |
303 |
+ # which is difficult to handle in cmake, as find_library does not support |
304 |
+ # searching for wildcard library names. So I find the library name from the |
305 |
+ # qmake spec, and then sed this into the patched src/cpp/desktop/CMakeLists.txt. |
306 |
+ rm -rf "${S}"/src/cpp/desktop/3rdparty || die |
307 |
+ local s=$(grep '\-lQt$${QT_MAJOR_VERSION}Solutions_SingleApplication' \ |
308 |
+ $(qt5_get_mkspecsdir)/features/qtsingleapplication.prf \ |
309 |
+ | sed -e 's@\$\${QT_MAJOR_VERSION}@5@' \ |
310 |
+ -e 's@LIBS \*= -l@@') |
311 |
+ sed -e "s@Qt5Solutions_SingleApplication-2.6@${s}@g" \ |
312 |
+ -i "${S}"/src/cpp/desktop/CMakeLists.txt \ |
313 |
+ || die |
314 |
+ |
315 |
+ # The git commit for tag: git rev-list -n 1 v0.99.903 |
316 |
+ sed -e 's@git ARGS rev-parse HEAD@echo ARGS 0eb2d8ea28ebc1ac6ac327e023becb6133b679c4@'\ |
317 |
+ -i "${S}"/CMakeLists.txt \ |
318 |
+ "${S}"/CMakeGlobals.txt \ |
319 |
+ || die |
320 |
+} |
321 |
+ |
322 |
+src_configure() { |
323 |
+ export RSTUDIO_VERSION_MAJOR=$(get_version_component_range 1) |
324 |
+ export RSTUDIO_VERSION_MINOR=$(get_version_component_range 2) |
325 |
+ export RSTUDIO_VERSION_PATCH=$(get_version_component_range 3) |
326 |
+ |
327 |
+ local mycmakeargs=( |
328 |
+ -DDISTRO_SHARE=share/${PN} |
329 |
+ -DRSTUDIO_INSTALL_FREEDESKTOP="$(usex !dedicated "ON" "OFF")" |
330 |
+ -DRSTUDIO_TARGET=$(usex dedicated "Server" "$(usex server "Development" "Desktop")") |
331 |
+ -DQT_QMAKE_EXECUTABLE=$(qt5_get_bindir)/qmake |
332 |
+ -DRSTUDIO_VERIFY_R_VERSION=FALSE |
333 |
+ ) |
334 |
+ |
335 |
+ cmake-utils_src_configure |
336 |
+} |
337 |
+ |
338 |
+src_compile() { |
339 |
+ # Avoid the rest of the oracle-jdk-bin-1.8.0.60 sandbox violations F: mkdir S: deny |
340 |
+ # P: /root/.oracle_jre_usage. |
341 |
+ export ANT_OPTS="-Duser.home=${T}" |
342 |
+ cmake-utils_src_compile |
343 |
+} |
344 |
+ |
345 |
+src_install() { |
346 |
+ export ANT_OPTS="-Duser.home=${T}" |
347 |
+ cmake-utils_src_install |
348 |
+ pax-mark m "${ED}usr/bin/rstudio" |
349 |
+ doconfd "${FILESDIR}"/rstudio-server.conf |
350 |
+ dodir /etc/rstudio |
351 |
+ insinto /etc/rstudio |
352 |
+ doins "${FILESDIR}"/rsession.conf |
353 |
+ dosym "${ROOT}etc/conf.d/rstudio-server.conf" "${ROOT}etc/rstudio/rserver.conf" |
354 |
+ if use dedicated || use server; then |
355 |
+ dopamd src/cpp/server/extras/pam/rstudio |
356 |
+ newinitd "${FILESDIR}"/rstudio-server.initd rstudio-server |
357 |
+ fi |
358 |
+} |
359 |
+ |
360 |
+pkg_preinst() { |
361 |
+ use dedicated || gnome2_icon_savelist |
362 |
+ java-pkg-2_pkg_preinst |
363 |
+} |
364 |
+ |
365 |
+pkg_postinst() { |
366 |
+ use dedicated || { xdg_desktop_database_update |
367 |
+ xdg_mimeinfo_database_update |
368 |
+ gnome2_icon_cache_update ;} |
369 |
+ |
370 |
+ if use dedicated || use server; then |
371 |
+ enewgroup rstudio-server |
372 |
+ enewuser rstudio-server -1 -1 -1 rstudio-server |
373 |
+ fi |
374 |
+} |
375 |
+ |
376 |
+pkg_postrm() { |
377 |
+ use dedicated || { xdg_desktop_database_update |
378 |
+ xdg_mimeinfo_database_update |
379 |
+ gnome2_icon_cache_update ;} |
380 |
+} |