diff options
-rwxr-xr-x | libreoffice/build/libreoffice36.SlackBuild | 48 |
1 files changed, 29 insertions, 19 deletions
diff --git a/libreoffice/build/libreoffice36.SlackBuild b/libreoffice/build/libreoffice36.SlackBuild index 58715afb..2019354d 100755 --- a/libreoffice/build/libreoffice36.SlackBuild +++ b/libreoffice/build/libreoffice36.SlackBuild @@ -579,6 +579,7 @@ else mkdir -p $TMP/tmp-$PRGNAM # location to build the source mkdir -p $PKG # place for the package to be built rm -rf $PKG/* # always erase old package's contents + rm -rf $PKG2/* # always erase old package's contents rm -rf $TMP/tmp-$PRGNAM/* # remove the remnants of previous build rm -rf $OUTPUT/{configure,make,install,error,makepkg}-$PRGNAM.log # remove old log files @@ -813,6 +814,7 @@ fi # copy them into the package: mkdir -p $PKG/usr/lib${LIBDIRSUFFIX}/${PRGNAM}/share/extensions/install cp -a $SRCDIR/sources/dict-*.oxt $PKG/usr/lib${LIBDIRSUFFIX}/${PRGNAM}/share/extensions/install/ +chown -R root:root $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM/share/extensions/install # Create aliases for locales that have matching languages in LibreOffice. # This enables people with these locales to use the autocorrect function: @@ -1094,27 +1096,35 @@ fi find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true -# Split off the browser plugin, not everyone will want it: -echo -e "**\n** splitting off the mozilla plugin ...\n**" -# Move the mozilla plugin: -mkdir -p $PKG2/usr/lib${LIBDIRSUFFIX}/mozilla/ -mv -i $PKG/usr/lib${LIBDIRSUFFIX}/mozilla/plugins \ - $PKG2/usr/lib${LIBDIRSUFFIX}/mozilla/ -rmdir $PKG/usr/lib${LIBDIRSUFFIX}/mozilla 2>/dev/null || true +# Split off the browser plugin if we built it, not everyone will want it: +if [ -f $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM/program/libnpsoplugin.so ]; then -mkdir -p $PKG2/install -cat $SRCDIR/slack-desc.$PRGNAM2 > $PKG2/install/slack-desc -cat $SRCDIR/slack-required.$PRGNAM2 > $PKG2/install/slack-required + echo -e "**\n** splitting off the mozilla plugin ...\n**" + # Move the mozilla plugin: + mkdir -p $PKG2/usr/lib${LIBDIRSUFFIX}/$PRGNAM/program + mv $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM/program/libnpsoplugin.so \ + $PKG2/usr/lib${LIBDIRSUFFIX}/$PRGNAM/program/ + mkdir -p $PKG2/usr/lib${LIBDIRSUFFIX}/mozilla/ + mv $PKG/usr/lib${LIBDIRSUFFIX}/mozilla/plugins \ + $PKG2/usr/lib${LIBDIRSUFFIX}/mozilla/ + rmdir $PKG/usr/lib${LIBDIRSUFFIX}/mozilla 2>/dev/null || true + + # Add some package information: + mkdir -p $PKG2/install + cat $SRCDIR/slack-desc.$PRGNAM2 > $PKG2/install/slack-desc + cat $SRCDIR/slack-required.$PRGNAM2 > $PKG2/install/slack-required + + # Create the package: + ( cd $PKG2 + makepkg --linkadd y --chown n $OUTPUT/${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE:-txz} 2>&1 | tee $OUTPUT/makepkg-${PRGNAM}_${PRGNAM2}.log + ) + ( cd $OUTPUT + md5sum ${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE:-txz} > ${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE:-txz}.md5 + ) + cat $PKG2/install/slack-desc | grep "^${PRGNAM}-${PRGNAM2}" > $OUTPUT/${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.txt + cat $PKG2/install/slack-required > $OUTPUT/${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.dep -( cd $PKG2 - makepkg --linkadd y --chown n $OUTPUT/${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE} 2>&1 | tee $OUTPUT/makepkg-${PRGNAM}_${PRGNAM2}.log -) -( cd $OUTPUT - md5sum ${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE} > ${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.${PKGTYPE}.md5 -) -cat $PKG2/install/slack-desc | grep "^${PRGNAM}-${PRGNAM2}" > $OUTPUT/${PRGNAM}- -${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.txt -cat $PKG2/install/slack-required > $OUTPUT/${PRGNAM}-${PRGNAM2}-${VERSION}-${ARCH}-${BUILD}${TAG}.dep +fi # End splitting off the mozplugin # Continuing with the main package: |