diff options
Diffstat (limited to 'office/LibreOffice/LibreOffice.SlackBuild')
-rw-r--r-- | office/LibreOffice/LibreOffice.SlackBuild | 49 |
1 files changed, 36 insertions, 13 deletions
diff --git a/office/LibreOffice/LibreOffice.SlackBuild b/office/LibreOffice/LibreOffice.SlackBuild index 23153e0703..b50cf374e4 100644 --- a/office/LibreOffice/LibreOffice.SlackBuild +++ b/office/LibreOffice/LibreOffice.SlackBuild @@ -4,7 +4,7 @@ # Slackware build script for LibreOffice -# Copyright 2015-2022 Christoph Willing Brisbane, Australia +# Copyright 2015-2024 Christoph Willing Sydney, Australia # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -28,7 +28,7 @@ cd $(dirname $0) ; CWD=$(pwd) PRGNAM=LibreOffice SRCNAM=libreoffice -VERSION=${VERSION:-7.3.4.2} +VERSION=${VERSION:-24.2.1.2} SHORT_VERSION=${VERSION%.*.*} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -69,6 +69,18 @@ else LIBDIRSUFFIX="" fi +if [ -x /usr/bin/gcc-11.* ]; +then + echo Slackware-15.0 + export CC=/usr/bin/clang + export CXX=/usr/bin/clang++ + CXXCLANGFLAGS="-Wno-c++11-narrowing" +else + echo Slackware-15.0++ + export CC=/usr/bin/gcc + export CXX=/usr/bin/g++ +fi + set -e rm -rf $PKG @@ -163,6 +175,7 @@ if pkg-config --exists mdds-1.4 ; then mdds="--with-system-mdds" ; else mdds="" if pkg-config --exists mythes ; then mythes="--with-system-mythes" ; else mythes="" ; fi if test -x /usr/bin/odbc_config ; then odbc="--with-system-odbc" ; else odbc="" ; fi #if test -d /usr/lib${LIBDIRSUFFIX}/python3*/site-packages/lxml ; then lxml="--with-system-lxml" ; else lxml="" ; fi + if pkg-config --exists xmlsec1 ; then xmlsec="--with-system-xmlsec" else @@ -170,6 +183,7 @@ else # Also ensure correct nspr implementation is used if building libreoffice supplied xmlsec sed -i -e 's:openssl:openssl --with-mozilla-ver=/usr:' external/xmlsec/ExternalProject_xmlsec.mk fi + #if test -e /usr/share/ant/lib/rhino.jar ; then rhino="--with-system-rhino --with-rhino-jar=/usr/share/ant/lib/rhino.jar" ; else rhino="" ; fi if pkg-config --exists libvlc ; then vlc="--enable-vlc" ; else vlc="" ; fi # Building with vlc backend is marked as experimental so demand explicit indication via environment variable VLC to do it. @@ -189,9 +203,20 @@ extwikipub="--enable-ext-wiki-publisher"; [ "${EXTWIKIPUB:-no}" != "yes" ] & extnlpsolver="--enable-ext-nlpsolver"; [ "${EXTNLPSOLVER:-yes}" != "yes" ] && extnlpsolver="" -./autogen.sh \ +# Temporary fix for problems with boost > 1.80 +# Results in additional download of compatible boost to use internally +BOOST_MINOR_VERSION=$(basename $(ls -d /usr/lib${LIBDIRSUFFIX}/cmake/Boost-1.*) | cut -d'.' -f2) +if [ "$BOOST_MINOR_VERSION" -gt "80" ]; then + boost="--without-system-boost" +else + boost="--with-system-boost" +fi + + +./configure \ CFLAGS="$SLKCFLAGS" \ - CXXFLAGS="$SLKCFLAGS" \ + CXXFLAGS="$SLKCFLAGS $CXXCLANGFLAGS" \ + LDFLAGS="-lz" \ NSS_CFLAGS="$(pkg-config --cflags-only-I mozilla-nss)"\ --prefix=/usr \ --mandir=/usr/man \ @@ -220,10 +245,9 @@ extnlpsolver="--enable-ext-nlpsolver"; [ "${EXTNLPSOLVER:-yes}" != "yes" ] & --without-krb5 \ --without-gssapi \ --without-junit \ + --without-system-libxml \ --with-help \ - --with-system-apr \ --with-system-bluez \ - --with-system-boost \ --with-system-bzip2 \ --with-system-cairo \ --with-system-clucene \ @@ -232,29 +256,30 @@ extnlpsolver="--enable-ext-nlpsolver"; [ "${EXTNLPSOLVER:-yes}" != "yes" ] & --with-system-epoxy \ --with-system-expat \ --with-system-hunspell \ - --with-system-icu \ --with-system-jpeg \ --with-system-lcms2 \ --with-system-libodfgen \ --with-system-libpng \ --with-system-librevenge \ + --with-system-libtiff \ --with-system-libvisio \ + --with-system-libwebp \ --with-system-libwpd \ --with-system-libwpg \ - --with-system-libxml \ --with-system-mariadb \ - --with-system-neon \ --with-system-nss \ --with-system-openldap \ --with-system-openssl \ --with-system-poppler \ --with-system-sane \ --with-system-zlib \ + $boost \ $coinmp \ $cppunit \ $glm \ $libabw \ $libcdr \ + $liblangtag \ $libcmis \ $libebook \ $libeot \ @@ -293,16 +318,14 @@ if [ "$HAVE_SRCS_TARBALL" = "0" ]; then fi patch -p0 < $CWD/no-check-if-root.diff -#patch -p0 < $CWD/skia-freetype-2.11.diff -#patch -p0 < $CWD/bison_yyn-yyrule_rename.diff +patch -p0 < $CWD/narrowing_0f5dfae.diff # GCC10 requirements (Tx alienBOB) sed -i external/libebook/ExternalProject_libebook.mk \ -e '/configure /i \\t\t&& sed -i "s/TRUE/true/g" src/lib/EBOOKCharsetConverter.cpp \\' -export LDFLAGS="-lboost_system" -make build-nocheck +make build make distro-pack-install DESTDIR=$PKG find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ |