blob: 9f5dfd3c71d2b73674fef7796cbd721938074a53 (
plain)
1 # Description: RStudio - an Interface for GNU R
2 # URL: https://www.rstudio.com/
3 # Maintainer: Tim Biermann, tbier at posteo dot de
4 # Depends on: ant boost hyphen libevent mathjax openjdk8 pandoc-bin qtwebengine r
5
6 name=rstudio
7 version=1.3.1093
8 release=1
9
10 source=(https://github.com/rstudio/rstudio/archive/v$version/$name-$version.tar.gz
11 # https://gitweb.gentoo.org/repo/gentoo.git/tree/sci-mathematics/rstudio/files
12 rstudio-1.2.5042-boost-1.73.0.patch rstudio-1.3.1056-boost-1.74.0.patch)
13 git=(https://github.com/rstudio/rstudio.git)
14
15 build() {
16 ## if you want your git snapshot to be a particular version
17 ## uncomment below and change every occurance of $name-$version to $name
18 #git checkout v$version $name
19
20 patch -Np1 -d $name-$version -i $SRC/rstudio-1.2.5042-boost-1.73.0.patch
21 patch -Np1 -d $name-$version -i $SRC/rstudio-1.3.1056-boost-1.74.0.patch
22 pushd $name-$version/dependencies/common
23 install -d pandoc
24 ln -sfT /usr/share/myspell/dicts dictionaries
25 ln -sfT /usr/share/mathjax mathjax-27
26 ln -sfT /usr/bin/pandoc pandoc/pandoc
27 ln -sfT /usr/bin/pandoc-citeproc pandoc/pandoc-citeproc
28 export R_LIBS_USER="$PKG/usr/lib/R/library/"
29 bash install-packages
30 popd
31
32 export PATH="/usr/lib/java/openjdk8/jre/bin/:${PATH}"
33 cmake -S$name-$version -Bbuild -GNinja\
34 -DCMAKE_INSTALL_PREFIX=/usr/lib/rstudio \
35 -DRSTUDIO_TARGET=Desktop \
36 -DCMAKE_BUILD_TYPE=Release \
37 -DRSTUDIO_USE_SYSTEM_BOOST=ON \
38 -DQT_QMAKE_EXECUTABLE=/usr/lib/qt5/bin/qmake \
39 -DBoost_NO_BOOST_CMAKE=ON \
40 -DRSTUDIO_BUNDLE_QT=FALSE \
41 -Wno-dev
42
43 cmake --build build
44 DESTDIR=$PKG cmake --install build
45
46 install -dm755 $PKG/usr/bin/
47 ln -s /usr/lib/$name/bin/$name $PKG/usr/bin/$name
48 sed -i 's|/usr/lib/rstudio/bin/rstudio|/usr/bin/rstudio|g' $PKG/usr/share/applications/rstudio.desktop
49 find $PKG \(\
50 -iname '*README*' -o \
51 -iname '*COPYING*' -o \
52 -iname 'INSTALL' \
53 \) -delete || true
54 }
|