diff options
Diffstat (limited to 'academic')
-rw-r--r-- | academic/mendeleydesktop/README | 18 | ||||
-rw-r--r-- | academic/mendeleydesktop/mendeleydesktop.SlackBuild | 60 |
2 files changed, 52 insertions, 26 deletions
diff --git a/academic/mendeleydesktop/README b/academic/mendeleydesktop/README index 342deec2aa..8e9077e627 100644 --- a/academic/mendeleydesktop/README +++ b/academic/mendeleydesktop/README @@ -1,6 +1,14 @@ -Mendeley is a software to organize, share, and discover research papers. -Like iTunes(tm) for research papers, Mendeley is a free research management -tool for desktop and web. +Mendeley is software to organize, share, and discover research papers. +Like iTunes(tm) for research papers, Mendeley is a free research +management tool for desktop and web. -Before you use Mendeley, make sure that you are agree with the -terms and conditions at http://www.mendeley.com/terms/ +Before you use Mendeley, make sure that you agree with the terms and +conditions at http://www.mendeley.com/terms/ + +Optional Dependency + +qt5 -- this is highly recommended (replacing Mendeley's bundled qt5) to +be able to access all the functions if you use KDE5. You need to use +the option 'SYSTEM_QT5=yes', for example: + + SYSTEM_QT5=yes ./mendeleydesktop.SlackBuild diff --git a/academic/mendeleydesktop/mendeleydesktop.SlackBuild b/academic/mendeleydesktop/mendeleydesktop.SlackBuild index 83ca210f75..e36b27614f 100644 --- a/academic/mendeleydesktop/mendeleydesktop.SlackBuild +++ b/academic/mendeleydesktop/mendeleydesktop.SlackBuild @@ -27,7 +27,7 @@ PRGNAM=mendeleydesktop VERSION=${VERSION:-1.17.6} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -70,31 +70,49 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -# remove the bundled qt since it should be present in the system already -rm -rf lib/qt -# rm lib/mendeleydesktop/libexec/qt.conf -rm -rf lib/mendeleydesktop/plugins +# removing QT5 bundled libraries +if [ "${SYSTEM_QT5:-no}" != "no" ]; then + rm -rf lib/qt + rm bin/qt.conf + rm -rf lib/$PRGNAM/plugins + ( + cd lib/$PRGNAM/libexec/ + rm QtWeb* icudtl.dat qtwebengine* + ) +fi -[ $ARCH = 'x86_64' ] && mv lib lib$LIBDIRSUFFIX +# Using /opt for installation and prevent conflicts with QT5 applications +mkdir -p $PKG/opt/$PRGNAM +cp -r bin lib share $PKG/opt/$PRGNAM -rm bin/mendeleydesktop -ln -s ../lib${LIBDIRSUFFIX}/mendeleydesktop/libexec/mendeleydesktop.$ARCH \ - bin/mendeleydesktop +# make symlinks and moving some important files +mkdir -p $PKG/usr/{bin,share} +mv $PKG/opt/$PRGNAM/share/{applications,icons} $PKG/usr/share +if [ "${SYSTEM_QT5:-no}" != "no" ]; then +# configure all for use System QT installation + cat <<-EOF > $PKG/usr/bin/$PRGNAM +#!/bin/sh +MENDELEY_BASE=/opt/mendeleydesktop +MENDELEY_LIB=lib + +LD_LIBRARY_PATH=\${LD_LIBRARY_PATH}:\${MENDELEY_BASE}/\${MENDELEY_LIB} +export LD_LIBRARY_PATH +cd /opt/mendeleydesktop/lib/mendeleydesktop/libexec +./mendeleydesktop.$ARCH \$@ +EOF + chmod 755 $PKG/usr/bin/$PRGNAM +else + ( + cd $PKG/usr/bin + ln -s ../../opt/$PRGNAM/bin/$PRGNAM $PRGNAM + ) +fi -mkdir $PKG/usr -# some docs lay on the top folder, so install them first -mkdir -p $PKG/usr/doc -mv share/doc/mendeleydesktop $PKG/usr/doc/$PRGNAM-$VERSION -mv LICENSE README $PKG/usr/doc/$PRGNAM-$VERSION +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a share/doc/mendeleydesktop INSTALL LICENSE README \ + $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -rm INSTALL -rmdir share/doc - -mv * $PKG/usr - -find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ - | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true mkdir -p $PKG/install cat $CWD/doinst.sh > $PKG/install/doinst.sh |