This is based on the tde-slackbuilds build scripts which can be used for a native RPi3 build.
Builds have been done for the RPi3 running systems based on Slackware-arm-current [hard float], and Slarm64 [which can be downloaded from a mirror site, for example slackware.uk], with both systems using a 64-bit kernel built here.
The packages listed on this page have been built on an x86_64 machine and installed and tested OK on an RPi3.
[Edit: builds for R14.1.3 have been verified for 64-bit arm only].
For any problems, questions, etc please open an issue at tde-slackbuilds.
Why cross-compile?
Of the methods available for compiling TDE for the RPi3, I've tried three:
1] natively on the Pi itself
2] in an arm chroot on a x86_64 machine
3] cross compiling on a x86_64 machine using qemu/binfmt to run most of the TDE binaries required for the build
All methods work, but usually speed of compilation is the determining factor for which to choose.
Compared to a native x86_64 build, the build times are typically:
1] x3+
2] x10 - all binaries used here have to run through qemu
3] +25% typically - using a mix of x86_64 and arm binaries, the use of qemu can be minimized.
For example, tqmoc is used extensively and as it builds arch independent output, the x86_64 version can be used.
The build order is:
1] the cross compiler
2] a 64-bit kernel
3] qemu
4] set up the build environment with tqmoc and meinproc x86 binaries
5] the required TDE packages and install them to / and sysroot
6] other packages
Options include packaging, 64-bit kernel and its components, imlib, …
To aid trouble shooting, this page has been set up so that each build can be run by selecting the contents in part or whole and pasting into a console.
TDE build environment
This will be the build setup for the cross-compiler and sysroot.
The intention is that as much as possible that is required for the TDE cross compilation is contained within one directory and can be installed/mounted only when required.
♦♦ sysroot libs and headers can be permanently installed within the cross-compiler tree or bind mounted from another media or directory.
♦ only TDE packages required for building other TDE apps will be installed.
/opt ├── cross-pi-gcc │ ├── $TARGET │ │ ├── bin │ │ │ └── ldd … │ │ └── lib │ │ └── ld-linux-*.so.* … │ ├── bin cross compiler │ │ └── $TARGET-gcc … │ └── sysroot │ ├── lib$LIBDIRSUFFIX ♦♦ target libraries │ ├── usr ♦♦ │ │ ├── include target headers │ │ │ └── linux kernel headers │ │ └── lib$LIBDIRSUFFIX target libraries │ ├── src source archives │ ├── x86 x86 binaries - qemu-$ARM, meinproc, tqmoc │ └── opt │ └── tde ♦ for TDE headers and libraries for pkg-config └── tde ♦ for TDE executables used during TDE builds
Source archives
The source archives need to be downloaded and placed in the src directory -
For the official release, R series, download from https://mirror.ppa.trinitydesktop.org/trinity/releases/
Build in a chroot?
Yes if:
▸ the TDE installation directory exists on the build system,
▸ any of the packages being built exist on the build system, because they will be overwritten with arm versions.
Set HOST for a 32-bit [armv7] or 64-bit [aarch64] build for the host system - RPi3 - for the TDE builds which use the autotools differentiation between build, host and target.
## 32-bit - only tested for a hard float build
export HOST="arm-linux-gnueabihf"
## OR:
## 64-bit
export HOST="aarch64-linux-gnu"
export ARM=$(echo $HOST|cut -d- -f1)
## Set installation directories
## for cross compiler
export XGCC_DIR=/opt/cross-pi-gcc
## for sysroot
export SYSROOT=$XGCC_DIR/sysroot
… build gcc cross-compiler Based on - Building GCC as a cross compiler for Raspberry Pi - and the mentioned article - How to Build a GCC Cross-Compiler.
/tmp
└── xgcc
├── gcc-9 sources for a gcc-9.1.0/glibc-2.29 build
│ ├── binutils-2.32.tar.xz
│ ├── gcc-9.1.0.tar.xz
│ ├── glibc-2.29.tar.xz
│ ├── gmp-6.1.2.tar.xz
│ ├── isl-0.18.tar.bz2
│ ├── mpc-1.1.0.tar.gz
│ └── mpfr-4.0.2.tar.xz
├── build_all build area
│ ├── linux for kernel headers
│ ├── binutils-2.32
│ ├── build-binutils
│ ├── gcc-9.1.0
│ ├── build-gcc
│ ├── glibc-2.29
│ └── build-glibc
└── pkg DESTDIR for creating package
Set variables for a 32-bit [armv7] or 64-bit [aarch64] build:
## 32-bit - only tested for a hard float build
## for kernel headers
export K_ARCH=arm
## Set options for RPi3
export PiARCH="armv8-a+crc"
export FPU="neon-fp-armv8"
export TUNE="cortex-a53"
export FLOAT="hard"
export MACH_OPTS="--with-arch=$PiARCH --with-tune=$TUNE --with-fpu=$FPU --with-float=$FLOAT"
export glibcMACH_OPTS=$MACH_OPTS
## Set target - building cross compiler to run on x86 to build for target arm
export TARGET=$HOST
## OR:
## 64-bit
## for kernel headers
export K_ARCH=arm64
## Set options for RPi3 - the build for aarch64 takes a limited number of options
export PiARCH="armv8-a+crc"
export TUNE="cortex-a53"
export MACH_OPTS="--with-arch=$PiARCH --with-cpu=$TUNE"
export glibcMACH_OPTS="--with-arch=$PiARCH --with-tune=$TUNE"
## Set target - building cross compiler to run on x86 to build for target aarch64
export TARGET=$HOST
## Create build directories
mkdir -p /tmp/xgcc/{gcc-9,build_all}
cd /tmp/xgcc/gcc-9
## Get required sources
wget https://ftpmirror.gnu.org/binutils/binutils-2.32.tar.xz
wget https://ftpmirror.gnu.org/gcc/gcc-9.1.0/gcc-9.1.0.tar.xz
wget https://ftpmirror.gnu.org/glibc/glibc-2.29.tar.xz
wget https://gmplib.org/download/gmp/gmp-6.1.2.tar.xz
wget https://gcc.gnu.org/pub/gcc/infrastructure/isl-0.18.tar.bz2
wget https://ftpmirror.gnu.org/gnu/mpc/mpc-1.1.0.tar.gz
wget https://ftpmirror.gnu.org/gnu/mpfr/mpfr-4.0.2.tar.xz
## Install the kernel headers
## Download the kernel source and create a headers package.
## This is a 180MB download
cd ../build_all
git clone --depth=1 --no-checkout https://github.com/raspberrypi/linux
## Backup
tar Jcf /tmp/RPi-kernel-git-$(date +%Y%m%d).tar.xz linux/
## Check out the default branch
cd linux
git checkout
## Make headers - these are different for 32 and 64-bit - not to be confused with the kernel build
make headers_install ARCH=$K_ARCH INSTALL_HDR_PATH=/tmp/headers/usr
export K_VER=$(make kernelversion)
(cd /tmp/headers
makepkg -l y -c n /tmp/kernel-headers-$K_VER-RPi-$K_ARCH.txz)
rm -rf /tmp/headers
cd ..
## If building kernel, modules, and dtbs …
mv /tmp/xgcc/build_all/linux /tmp
ROOT=$SYSROOT installpkg /tmp/kernel-headers-$K_VER-RPi-$K_ARCH.txz
## Extract the archives
tar xf ../gcc-9/binutils-2.32.tar.xz
tar xf ../gcc-9/glibc-2.29.tar.xz
tar xf ../gcc-9/gcc-9.1.0.tar.xz
cd gcc-9.1.0
ln -s ../../gcc-9/gmp-6.1.2.tar.xz .
ln -s ../../gcc-9/mpc-1.1.0.tar.gz .
ln -s ../../gcc-9/mpfr-4.0.2.tar.xz .
ln -s ../../gcc-9/isl-0.18.tar.bz2 .
## Update the prerequisites versions
sed -i 's|6.1.0.tar.bz2|6.1.2.tar.xz|;s|3.1.4.tar.bz2|4.0.2.tar.xz|;s|1.0.3|1.1.0|' contrib/download_prerequisites
## Set up the gcc build environment
contrib/download_prerequisites --no-verify
## Fix build error:
##../../../../gcc-9.1.0/libsanitizer/asan/asan_linux.cc:216:21: error: ‘PATH_MAX’ was not declared in this scope
## '#include <limits.h>' in asan_linux.cc isn't picking up the linux headers version which defines PATH_MAX, so add the latter:
echo $'--- libsanitizer/asan/asan_linux.cc
+++ libsanitizer/asan/asan_linux.cc
@@ -33,0 +34 @@
+#include <linux/limits.h>' | patch -p0
## Build Binutils
## The cross compiler toolchain is going to be built with defaults for the RPi3 using machine [arch/tune/fpu/float] options
mkdir ../build-binutils
cd ../build-binutils
../binutils-2.32/configure --prefix=$XGCC_DIR --with-sysroot=$SYSROOT --target=$TARGET $MACH_OPTS --disable-multilib
make -j4
## install to '--prefix' for this build
make install-strip
## install for packaging
DESTDIR=/tmp/xgcc/pkg make install-strip
## Start building gcc
mkdir ../build-gcc
cd ../build-gcc
../gcc-9.1.0/configure --prefix=$XGCC_DIR --with-sysroot=$SYSROOT --target=$TARGET --enable-languages=c,c++ $MACH_OPTS --disable-multilib
make -j4 all-gcc
make install-gcc
## Add the cross compiler binaries to PATH for building glibc
## Prevents "__INT64_C" redefined and "__ARM_ARCH" is not defined errors.
## And includes $TARGET-strip which is used to strip the glibc executables and libs.
export PATH=$XGCC_DIR/bin:$PATH
## Start building glibc
mkdir ../build-glibc
cd ../build-glibc
../glibc-2.29/configure --prefix=$XGCC_DIR/$TARGET --with-sysroot=$SYSROOT --build=$MACHTYPE --host=$TARGET --target=$TARGET $glibcMACH_OPTS --disable-multilib libc_cv_forced_unwind=yes
make install-bootstrap-headers=yes install-headers
make -j4 csu/subdir_lib
install csu/crt1.o csu/crti.o csu/crtn.o $XGCC_DIR/$TARGET/lib
$TARGET-gcc -nostdlib -nostartfiles -shared -x c /dev/null -o $XGCC_DIR/$TARGET/lib/libc.so
touch $XGCC_DIR/$TARGET/include/gnu/stubs.h
## Back to gcc
cd ../build-gcc
make -j4 all-target-libgcc
make install-target-libgcc
## Finish building glibc
cd ../build-glibc
make -j4
## no strip option to 'make install'
make install
## install to different DESTDIR for stripping
DESTDIR=/tmp/xgcc/pkg-2 make install
find /tmp/xgcc/pkg-2 | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs $TARGET-strip --strip-debug
find /tmp/xgcc/pkg-2 | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs $TARGET-strip --strip-debug
## Finish building gcc
cd ../build-gcc
make -j4
make install-strip
DESTDIR=/tmp/xgcc/pkg make install-strip
## Create cross compiler package
## Copy stripped glibc to the cross gcc packaging directory
cp -a /tmp/xgcc/pkg-2/* /tmp/xgcc/pkg/
## Create a sysroot directory
mkdir /tmp/xgcc/pkg$SYSROOT
## Remove unwanted locales
rm -rf /tmp/xgcc/pkg$XGCC_DIR/share/locale
mv /tmp/xgcc/pkg$XGCC_DIR/$TARGET/share/i18n/locales/en_{GB,US} /tmp
rm -rf /tmp/xgcc/pkg$XGCC_DIR/$TARGET/share/i18n/locales/*
mv /tmp/en_{GB,US} /tmp/xgcc/pkg$XGCC_DIR/$TARGET/share/i18n/locales/
mv /tmp/xgcc/pkg$XGCC_DIR/$TARGET/share/locale/{en_GB,locale.alias} /tmp
rm -rf /tmp/xgcc/pkg$XGCC_DIR/$TARGET/share/locale/*
mv /tmp/{en_GB,locale.alias} /tmp/xgcc/pkg$XGCC_DIR/$TARGET/share/locale/
## Create the package
cd /tmp/xgcc/pkg
makepkg -l y -c n /tmp/xgcc910-glibc2.29-${K_VER}_RPi_headers-en_GB-$ARM.txz
## Remove the build area
cd /
rm -rf /tmp/xgcc
close
… build 64-bit kernel and modules, and device tree blobs - based on Exaga's article.
## To keep track of where stuff is installed use the package management system - delete the cross-compiler build installation directory and re-install from the package created
rm -rf $XGCC_DIR
installpkg /tmp/xgcc910-glibc2.29-*_RPi_headers-en_GB-aarch64.txz
## Set PATH to include cross-compiler if not continuing from previous section
[[ ! $PATH == *$XGCC_DIR/bin* ]] && export PATH=$XGCC_DIR/bin:$PATH
cd /tmp/linux
## Create .config
make -j4 ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- bcmrpi3_defconfig
## Build the kernel
make -j4 Image ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu-
## Tail end of screen output shows where the kernel is:
# SYSMAP System.map
# OBJCOPY arch/arm64/boot/Image
## Build the device tree blobs
make -j4 dtbs ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu-
## find . -name "*rpi-3-b.dtb"
#./arch/arm64/boot/dts/broadcom/bcm2710-rpi-3-b.dtb
#./arch/arm64/boot/dts/broadcom/bcm2837-rpi-3-b.dtb
## Build the arm64 modules
make -j4 modules ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu-
make -j4 modules_install ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- INSTALL_MOD_PATH=/tmp/modules
(cd /tmp/modules
makepkg -l y -c n /tmp/kernel-modules-$K_VER-RPi-arm64.txz)
rm -rf /tmp/modules
Installation
As detailed in Exaga's article, install the dtbs and the kernel [Image ⇒ kernel8.img] to the microSD card boot partition; and the modules to the OS partition.
close
… build qemu Required to run arm binaries used during the build - for example tquic and tde-config.
cd /tmp
wget https://download.qemu.org/qemu-2.12.1.tar.xz
tar xf qemu-2.12.1.tar.xz
cd qemu-2.12.1/
mkdir build
cd build
## Only the one target is needed for the LSB binaries required for the RPi3,
## and most other options are not required for this particular use.
## There is no need to build qemu-static because qemu will be built and run within this environment.
export PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
../configure \
--target-list=$ARM-linux-user \
--audio-drv-list= \
--disable-blobs \
--disable-bluez \
--disable-brlapi \
--disable-bsd-user \
--disable-bzip2 \
--disable-cap-ng \
--disable-capstone \
--disable-crypto-afalg \
--disable-curl \
--disable-curses \
--disable-debug-info \
--disable-debug-tcg \
--disable-docs \
--disable-fdt \
--disable-gcrypt \
--disable-glusterfs \
--disable-gnutls \
--disable-gtk \
--disable-guest-agent \
--disable-hax \
--disable-hvf \
--disable-jemalloc \
--disable-kvm \
--disable-libiscsi \
--disable-libnfs \
--disable-libssh2 \
--disable-libusb \
--disable-libxml2 \
--disable-linux-aio \
--disable-lzo \
--disable-malloc-trim \
--disable-modules \
--disable-netmap \
--disable-nettle \
--disable-numa \
--disable-opengl \
--disable-qom-cast-debug \
--disable-rbd \
--disable-rdma \
--disable-replication \
--disable-sanitizers \
--disable-seccomp \
--disable-sdl \
--disable-slirp \
--disable-smartcard \
--disable-snappy \
--disable-sparse \
--disable-spice \
--disable-system \
--disable-tcg-interpreter \
--disable-tcmalloc \
--disable-tools \
--disable-tpm \
--disable-usb-redir \
--disable-vde \
--disable-vhost-crypto \
--disable-vhost-net \
--disable-vhost-scsi \
--disable-vhost-user \
--disable-vhost-vsock \
--disable-virglrenderer \
--disable-virtfs \
--disable-vte \
--disable-vnc \
--disable-vxhs \
--disable-xen \
--disable-xfsctl
make -j6
make install DESTDIR=/tmp/qemu-temp
qemu-$ARM will be copied to sysroot in the next section …
close
… the build environment Set the shell variables and install the required arm headers and libraries in SYSROOT.
Install the cross-compiler
To keep track of where stuff is installed use the package management system - delete the cross-compiler build installation directory and re-install from the package created:
rm -rf $XGCC_DIR
installpkg /tmp/xgcc910-glibc2.29-${K_VER}_RPi_headers-en_GB-$ARM.txz
## Set the variables for the TDE packages builds
export TDE_VERSION=14.1.3
export INSTALL_TDE=/opt/tde
export SYS_CNF_DIR=/etc/tde
[[ $ARM == aarch64 ]] && export LIBDIRSUFFIX=64
export TQTDIR=$INSTALL_TDE
export INST_RPATH=$TQTDIR/lib$LIBDIRSUFFIX
export COMPILER="$HOST-gcc -w"
export COMPILER_CXX="$HOST-g++ -w"
export CC=$COMPILER
export CXX=$COMPILER_CXX
export PLUGIN_INSTALL_DIR=tde
export NUMJOBS=-j6
export BUILD=1
export SLKLDFLAGS=""
export SLKCFLAGS="-O2 -w -Wl,-rpath,'$INST_RPATH'"
export I18N=en_GB
## Set variables for local paths:
## where the source archives are:
export TDE_SRC=/path_to_${TDE_VERSION}_source_archives
export MISC_SRC=/path_to_misc_source_archives
## Set Slack_base where the Slackware/Slarm64 packages a-y directories are:
export Slack_base=/path_to_[Slackware_arm_current/Slarm64]_a-y_directories
## for SYSROOT location - option [2] in setting up the build environment
export SYSROOT_REPO=/path_to_[Slackware_arm_current/Slarm64]_libs_headers_installation_directory
## ldconfig is not going to be used during arm packages installaion because it's an x86 binary, nor is /etc/ld.so.conf going to be updated, so use LD_LIBRARY_PATH to find libtqt-mt.so.3 during the build.
## And add the location of the libstdc++, libssp etc. libs from the cross compiler.
export LD_LIBRARY_PATH=$SYSROOT$TQTDIR/lib$LIBDIRSUFFIX:$XGCC_DIR/$HOST/lib$LIBDIRSUFFIX
## The arm libs and headers needed for cross compiling need to be installed in SYSROOT.
## They can be [1] directly installed to $SYSROOT if the cross compiler is to be a permanent addition to the system, otherwise [2] installed to a directory [$SYSROOT_REPO] which is bind-mounted to $SYSROOT:
## [2]:
mkdir -p $SYSROOT_REPO
mount -B $SYSROOT_REPO $SYSROOT
## Create a source directory and place or sym-link all the source archives there
mkdir -p $SYSROOT/src
ln -sf $MISC_SRC/* $SYSROOT/src/
ln -sf $TDE_SRC/* $SYSROOT/src/
## only need qemu-$ARM from the qemu build/installation - just place it somewhere the kernel can find it …
mkdir -p $SYSROOT/x86
## Remove any previously installed files if they are for an older version build
rm $SYSROOT/x86/*
cp /tmp/qemu-temp/usr/local/bin/qemu-$ARM $SYSROOT/x86
rm -rf /tmp/qemu*
## … and load the arm interpreter
modprobe binfmt_misc
mount binfmt_misc -t binfmt_misc /proc/sys/fs/binfmt_misc
[[ $ARM == aarch64 ]] && \
echo ":arm:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\xb7\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff:$SYSROOT/x86/qemu-$ARM:" > /proc/sys/fs/binfmt_misc/register \
|| \
echo ":arm:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x28\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff:$SYSROOT/x86/qemu-$ARM:" > /proc/sys/fs/binfmt_misc/register
## let qemu know where the target libraries are
export QEMU_LD_PREFIX=$SYSROOT
## Install all packages needed to build the required TDE packages.
## SYSROOT is not a functioning system, it's just a repository for arm libs and headers required for cross compiling.
## move ldconfig out of the way - links will be set up by doinst.sh
mv /sbin/ldconfig /sbin/ldconfig-bak
export ROOT=$SYSROOT
installpkg /tmp/kernel-headers-*-RPi-*.txz
cd $Slack_base
## glibc must be the same version as for the cross-compiler to prevent 'undefined reference to …' errors
installpkg l/glibc-2.29-*.txz
installpkg */dbus-*.txz
installpkg a/eudev-*.txz
installpkg x/fontconfig-*.txz
installpkg l/freetype-*.txz
installpkg x/libICE-*.txz
installpkg x/libSM-*.txz
installpkg x/libX11-*.txz
installpkg x/libXcomposite-*.txz
installpkg x/libXcursor-*.txz
installpkg x/libXext-*.txz
installpkg x/libXft-*.txz
installpkg x/libXi-*.txz
installpkg x/libXinerama-*.txz
installpkg x/libXmu-*.txz
installpkg x/libXrandr-*.txz
installpkg x/libXrender-*.txz
installpkg l/libjpeg-turbo-*.txz
installpkg l/libmng-*.txz
installpkg l/libpng-*.txz
installpkg x/mesa-*.txz
installpkg a/util-linux-*.txz
installpkg l/zlib-*.txz
installpkg l/harfbuzz-*.txz
installpkg l/graphite2-*.txz
installpkg l/lcms2-*.txz
installpkg x/libXau-*.txz
installpkg x/libXdamage-*.txz
installpkg x/libXdmcp-*.txz
installpkg x/libXfixes-*.txz
installpkg x/libXt-*.txz
installpkg x/libXxf86vm-*.txz
installpkg x/libdrm-*.txz
installpkg x/libxcb-*.txz
installpkg x/libxshmfence-*.txz
installpkg x/glu-*.txz
installpkg x/libXi-*.txz
installpkg l/libidn2-*.txz
installpkg ap/cups-*.txz
installpkg l/libxml2-*.txz
installpkg l/libxslt-*.txz
installpkg a/file-*.txz
installpkg l/taglib-1*.txz
installpkg ap/cdparanoia-*.txz
installpkg l/audiofile-*.txz
installpkg l/alsa-lib-*.txz
installpkg l/glib2-*.txz
installpkg l/pcre-*.txz
installpkg ap/flac-*.txz
installpkg l/libogg-*.txz
installpkg l/libvorbis-*.txz
installpkg l/libmad-*.txz
installpkg n/openssl-*.txz
installpkg a/bzip2-*.txz
installpkg a/xz-*.txz
installpkg l/openexr-*.txz
installpkg l/ilmbase-*.txz
installpkg l/expat-*.txz
installpkg n/gnutls-*.txz
installpkg n/p11-kit-*.txz
installpkg l/libunistring-*.txz
installpkg n/nettle-*.txz
installpkg l/libffi-*.txz
installpkg n/NetworkManager-*.txz
installpkg a/acl-*.txz
installpkg a/attr-*.txz
installpkg x/libpthread-stubs-*.txz
installpkg n/libtirpc-*.txz
installpkg x/libfontenc-*.txz
installpkg x/libXtst-*.txz
installpkg n/htdig-*.txz
installpkg x/libxkbfile-*.txz
installpkg x/xorgproto-*.txz
## + for tdeutils
installpkg l/gmp-*.txz
installpkg d/python-*.txz
installpkg d/python3-*.txz
## + for imlib
installpkg l/libtiff-*.txz
installpkg l/giflib-*.txz
## + for tdegraphics
installpkg l/poppler-*.txz
## + for imlib - Slarm64 deps
installpkg l/libwebp-*.txz
installpkg l/zstd-*.txz
## + for 14.0.9+ builds
installpkg d/intltool-*.txz
## + for 14.0.10+ builds
installpkg ap/lm_sensors-*.txz
## + for 14.1.2+ builds for tdebase
x/xkeyboard-config-*-noarch-*.txz
## + for 14.1.3+ builds for tdelibs
installpkg l/pcre2-*.txz
## remove .la files and any links to them - they can cause a problem because the paths are hard-coded to /usr/... and so pick up the build machine libs rather than the libs in SYSROOT
find $SYSROOT/usr/lib$LIBDIRSUFFIX -type l -name \*.la -exec rename .la .la-bak {} \;
find $SYSROOT/usr/lib$LIBDIRSUFFIX -type f -name \*.la -exec rename .la .la-bak {} \;
## restore ldconfig
mv /sbin/ldconfig-bak /sbin/ldconfig
unset ROOT
cd /
## This link is in the wrong place
[[ $ARM == aarch64 ]] && mv $SYSROOT/ld-linux-aarch64.so.1 $SYSROOT/lib/ld-linux-aarch64.so.1
## Set the PATH for this shell
## Add $XGCC_DIR/bin for $HOST-gcc etc; $XGCC_DIR/$HOST/bin for strip etc.
export PATH=$XGCC_DIR/bin:$XGCC_DIR/$HOST/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin
## Set up pkg-config to prefix -I and -L paths in *.pc files with $SYSROOT.
## This works where the host libs and headers are in $SYSROOT …
## But TDE doesn't install to SYSROOT, its .pc files might be in, say, /opt/tde/lib64/pkgconfig, with the result that TDE includes and libs can't be found.
## If INSTALL_TDE=/usr, TDE would also have to be *installed* to SYSROOT - linking wouldn't work because that would pull the build system libs and headers into SYSROOT, as would bind mounting it.
## So my work-around for this is to install TDE to both / and $SYSROOT so that the TDE binaries will be found in $INSTALL_TDE and pkg-config will locate the headers and libs in $SYSROOT$INSTALL_TDE.
export PKG_CONFIG_PATH=
export PKG_CONFIG_SYSROOT_DIR=$SYSROOT
export PKG_CONFIG_LIBDIR=$SYSROOT/usr/lib$LIBDIRSUFFIX/pkgconfig:$SYSROOT/usr/share/pkgconfig:$SYSROOT$INSTALL_TDE/lib$LIBDIRSUFFIX/pkgconfig
## Functions - common to each build
untar_fn ()
{
cd $TMP/tmp-$PRGNAM
tar xf $SYSROOT/src/$PRGNAM-*$VERSION.tar.*
[[ $VERSION == $TDE_VERSION ]] && (cd $PRGNAM*
mkdir cmake
tar xf $SYSROOT/src/cmake-*$VERSION.tar.* --strip-components=1 -C cmake)
cd $PRGNAM-*$VERSION
}
chown_fn ()
{
chown -R root:root .
chmod -R u+w,go+r-w,a+rX-st .
}
cd_builddir_fn()
{
mkdir -p build-${PRGNAM}
cd build-${PRGNAM}
}
mangzip_fn ()
{
find $PKG$INSTALL_TDE/man -type f -name "*.?" -exec gzip -9f {} \;
}
strip_fn ()
{
find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
}
mkdir_install_fn ()
{
mkdir -p $PKG/install
}
makepkg_fn ()
{
cd $PKG
makepkg --linkadd y --chown n $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
}
ltoolupdate_fn ()
{
{
## look in SYSROOT for headers and libs, and
## edit hard coded tqt directory for tqt3/tqtinterface installed to TQTDIR [!= /usr]
sed -i "s|/usr/include/tqt\"|$SYSROOT$TQTDIR/include/tqt\"|" admin/acinclude.m4.in
sed -i "s|/usr/include/tqt3|$SYSROOT$TQTDIR/include/tqt|" admin/acinclude.m4.in
sed -i "s|/usr/lib/tqt3|$SYSROOT$TQTDIR|" admin/acinclude.m4.in
## $LIBDIRSUFFIX isn't required as it's built-in as ${tdelibsuff} in acinclude.m4.in
sed -i "s|/usr/lib|$SYSROOT&|g" admin/acinclude.m4.in
## correct the variable name in error message
sed -i "s|variable UIC to|variable UIC_PATH to|" admin/acinclude.m4.in
## edit hard coded plugins installation directories - could be 'tde'
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|g" admin/acinclude.m4.in
## include updating config.{guess,sub} for libart-lgpl and misc builds
[[ -d admin ]] && ADMIN=admin/ || ADMIN=""
cp /$(grep -h config.guess /var/log/packages/libtool*) ./$ADMIN
cp /$(grep -h config.sub /var/log/packages/libtool*) ./$ADMIN
cp /$(grep -h ltmain.sh /var/log/packages/libtool*) admin/
cp /$(grep -h libtool.m4 /var/log/packages/libtool*) admin/libtool.m4.in
cp /$(grep -h missing /var/log/packages/libtool*) admin/
make -f admin/Makefile.common
} 2>/dev/null
}
cmake-toolchain_fn ()
{
echo " set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR arm)
set(CMAKE_SYSROOT $SYSROOT)
## maybe try this later
## set(CMAKE_CROSSCOMPILING_EMULATOR $XGCC_DIR/bin/$HOST-gcc)
## these don't seem to have any affect:
set(PKG_CONFIG_USE_CMAKE_PREFIX_PATH $SYSROOT)
set(CMAKE_FIND_ROOT_PATH $SYSROOT)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
" > cmake-toolchain.cmake
}
## paths in doinst.sh should be relative to allow for installation to ROOT != "/"
doinst_sh_fn ()
{
echo "
# Update the desktop database:
/usr/bin/update-desktop-database .$INSTALL_TDE/share/applications
# Update hicolor theme cache:
/usr/bin/gtk-update-icon-cache -f -t .$INSTALL_TDE/share/icons/hicolor
# Update the mime database:
/usr/bin/update-mime-database -Vn usr/share/mime
" >> $PKG/install/doinst.sh
}
close
… tqmoc and meinproc x86 binaries The cross compiling build time can be reduced by using x86 versions of tqmoc and meinproc which produce ARCH independent ouput. The figures for the tdebase build demonstrate how much quicker a build can be.
Variables for pre-built x86 packages - these were built to install to /opt/tde on a 64-bit system
INSTALL_TDE_x86="/opt/tde"
LIBDIRSUFFIX_x86="64"
## Install x86 packages to temporary location on BUILD system
cd /location_of_pre-built_TDE_x86_packages
ROOT=/tmp/x86/ installpkg tqt3-$TDE_VERSION-x86_64-*.txz tqtinterface-$TDE_VERSION-x86_64-*.txz dbus-1-tqt-$TDE_VERSION-x86_64-*.txz tdelibs-$TDE_VERSION-x86_64-*.txz libart*lgpl-$TDE_VERSION-x86_64-*.txz
## Copy tqmoc, and meinproc and its dependent libraries, to a convenient location, $SYSROOT/x86
cd $SYSROOT/x86
cp -a /tmp/x86$INSTALL_TDE_x86/bin/tqmoc .
cp -a /tmp/x86$INSTALL_TDE_x86/bin/meinproc .
cp -a /tmp/x86$INSTALL_TDE_x86/lib$LIBDIRSUFFIX_x86/lib{DCOP,dbus-1-tqt,tde{core,fx,io,su,ui,walletclient}}.so* .
cp -a /tmp/x86$INSTALL_TDE_x86/lib$LIBDIRSUFFIX_x86/lib{tqt,tqt-mt}.so* .
cp -a /tmp/x86/usr/lib$LIBDIRSUFFIX_x86/libart_lgpl_2.so* .
rm -rf /tmp/x86*
## Add an RPATH so meinproc will use these libraries
patchelf --force-rpath --set-rpath $SYSROOT/x86 $SYSROOT/x86/meinproc
patchelf --force-rpath --set-rpath $SYSROOT/x86 $SYSROOT/x86/libtdecore.so.14.1.0
## Copy the x86 meinproc to the TDE installation directory - it's fussy about its location, producing parsing errors otherwise.
mkdir -p $INSTALL_TDE/bin
cp $SYSROOT/x86/meinproc $INSTALL_TDE/bin/meinproc-x86
close
cd /
PRGNAM=tqt3
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## Build 'everything = arm' for RPi3 installation
## Remove some stuff that's not needed for TDE build and run-time support
## html docs occupy ~21M
sed -i '/htmldocs/d' src/qt_install.pri
sed -i '/translations/d' src/qt_install.pri
sed -i '/assistanttranslations/d' tools/assistant/assistant.pro
sed -i '/phrasebooks/d' tools/linguist/linguist/linguist.pro
sed -i '/templates/d' tools/designer/designer/designer.pro
## only need linux-g++
(cd mkspecs
GLOBIGNORE=linux-g++
rm -rf *)
## RPATH is to be set as $ORIGIN/../lib, so don't need absolute libs directory built in -
## Allow setting CC/CXX for linux-g++/qmake.conf -
## Set correct paths for includes and libs -
echo $'--- mkspecs/linux-g++/qmake.conf
+++ mkspecs/linux-g++/qmake.conf
@@ -11 +11 @@
-QMAKE_CC\t\t= gcc
+QMAKE_CC\t\t= $(COMPILER)
@@ -29 +29 @@
-QMAKE_CXX\t\t= g++
+QMAKE_CXX\t\t= $(COMPILER_CXX)
@@ -40 +40 @@
-QMAKE_INCDIR\t\t=
+QMAKE_INCDIR\t\t= $(TQTDIR)/include/tqt
@@ -42,2 +42,2 @@
-QMAKE_INCDIR_X11\t= /usr/X11R6/include
-QMAKE_LIBDIR_X11\t= /usr/X11R6/lib
+QMAKE_INCDIR_X11\t= /usr/include/X11
+QMAKE_LIBDIR_X11\t= /usr/lib'"$LIBDIRSUFFIX"$'
@@ -45,3 +45,3 @@
-QMAKE_LIBDIR_TQT\t\t= $(TQTDIR)/lib
-QMAKE_INCDIR_OPENGL\t= /usr/X11R6/include
-QMAKE_LIBDIR_OPENGL\t= /usr/X11R6/lib
+QMAKE_LIBDIR_TQT\t\t= $(TQTDIR)/lib'"$LIBDIRSUFFIX"$'
+QMAKE_INCDIR_OPENGL\t= /usr/include/GL
+QMAKE_LIBDIR_OPENGL\t= /usr/lib'"$LIBDIRSUFFIX"$'
@@ -49,2 +49,2 @@
-QMAKE_LINK\t\t= g++
-QMAKE_LINK_SHLIB\t= g++
+QMAKE_LINK\t\t= $(COMPILER_CXX)
+QMAKE_LINK_SHLIB\t= $(COMPILER_CXX)
@@ -58 +58 @@
-QMAKE_RPATH\t\t= -Wl,-rpath,
+QMAKE_RPATH =' | patch -p0
chown_fn
## only look in sysroot for includes and libs
sed -i "s|/usr/include|$SYSROOT&|" config.tests/{unix,x11}/*.test
sed -i "s| /include| $SYSROOT/include|" config.tests/{unix,x11}/*.test
sed -i "s| /lib| $SYSROOT/lib$LIBDIRSUFFIX|" config.tests/{unix,x11}/*.test
sed -i "s| /usr/lib| $SYSROOT/usr/lib$LIBDIRSUFFIX|" config.tests/{unix,x11}/*.test
sed -i "s|\"/lib|\"$SYSROOT/lib$LIBDIRSUFFIX|" config.tests/unix/checkavail
sed -i "s|/usr|$SYSROOT&|" config.tests/unix/checkavail
## Set up an arm mkspecs to use for this build where the system includes and libs paths are set to SYSROOT
cp -a mkspecs/linux-g++ mkspecs/linux-arm-g++
echo $'--- mkspecs/linux-arm-g++/qmake.conf
+++ mkspecs/linux-arm-g++/qmake.conf
@@ -8 +8 @@
-CONFIG\t\t\t+= qt warn_on release incremental link_prl
+CONFIG\t\t\t+= qt warn_off release incremental link_prl
@@ -42,2 +42,2 @@
-QMAKE_INCDIR_X11\t= /usr/include/X11
-QMAKE_LIBDIR_X11\t= /usr/lib'"$LIBDIRSUFFIX"$'
+QMAKE_INCDIR_X11\t= $(SYSROOT)/usr/include/X11
+QMAKE_LIBDIR_X11\t= $(SYSROOT)/usr/lib'"$LIBDIRSUFFIX"$'
@@ -46,2 +46,2 @@
-QMAKE_INCDIR_OPENGL\t= /usr/include/GL
-QMAKE_LIBDIR_OPENGL\t= /usr/lib'"$LIBDIRSUFFIX"$'
+QMAKE_INCDIR_OPENGL\t= $(SYSROOT)/usr/include/GL
+QMAKE_LIBDIR_OPENGL\t= $(SYSROOT)/usr/lib'"$LIBDIRSUFFIX" | patch -p0
## Set -platform to arm so that tqmoc is built as an arm binary for installation on RPi3.
## Set -rpath so that libtqt-mt.so.3 can be found during the build
echo "yes" | \
./configure \
-platform linux-arm-g++ \
-xplatform linux-arm-g++ \
-no-exceptions \
-prefix $TQTDIR \
-libdir $TQTDIR/lib$LIBDIRSUFFIX \
-bindir $TQTDIR/bin \
-headerdir $TQTDIR/include/tqt \
-plugindir $TQTDIR/lib$LIBDIRSUFFIX/tqt/plugins \
-datadir $TQTDIR/lib$LIBDIRSUFFIX/tqt \
-translationdir $TQTDIR/share/tqt/translations \
-release \
-verbose \
-I$SYSROOT/usr/include \
-L$SYSROOT/usr/lib$LIBDIRSUFFIX \
-system-zlib \
-qt-imgfmt-png \
-qt-imgfmt-mng \
-qt-gif \
-thread \
-stl \
-nis \
-cups \
-pch \
-xft \
-xrender \
-xrandr \
-xcursor \
-tablet \
-xinerama \
-plugin-style-cde \
-plugin-style-compact \
-plugin-style-motif \
-plugin-style-motifplus \
-plugin-style-platinum \
-plugin-style-sgi \
-plugin-style-windows \
-fast \
-R-Wl,-rpath,\'\\\$\$ORIGIN/../lib:$INST_RPATH\'
## Don't build tutorial and examples which won't be installed because the release version is being built
make $NUMJOBS symlinks src-qmake src-moc sub-src sub-tools
make install INSTALL_ROOT=$PKG
## Remove some more stuff that's not needed for TDE build and run-time support
## which I haven't yet figured out how to avoid building in the first place
## binaries
(cd $PKG$INSTALL_TDE/bin/
rm tqtmergetr
rm tqm2ts
rm tqlupdate
rm tqembed
rm msg2tqm
rm maketqpf
rm tqtcreatecw
rm tqlrelease
rm tqdesigner)
## libraries
(cd $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/
rm libtqteditor*
rm libtqassistantclient*)
## remove sysroot references from RPi3 package
sed -i "s|-L\$(S.*X)||g;s|$SYSROOT||g" $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/libtqt-mt.la
sed -i "s|-L\$(S.*X)||g;s|$SYSROOT||g" $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/pkgconfig/tqt-mt.pc
(cd $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/tqt/mkspecs/
rm -rf linux-arm-g++
ln -sf linux-g++ default)
mkdir -p $PKG/etc/profile.d
echo '#!'"/bin/sh
# Environment path variable for the tQt package.
export TQTDIR=$TQTDIR
" > $PKG/etc/profile.d/tqt3.sh
chmod 755 $PKG/etc/profile.d/tqt3.sh
strip_fn
mkdir_install_fn
# Add this to the doinst.sh:
cat <<EOINS >> $PKG/install/doinst.sh
# Add TDE library directory:
[[ \$(cat etc/ld.so.conf|head -n1) != $INSTALL_TDE/lib$LIBDIRSUFFIX ]] && \
sed -i "1i $INSTALL_TDE/lib$LIBDIRSUFFIX" etc/ld.so.conf
# Add TQt library directory:
[[ \$(cat etc/ld.so.conf|head -n1) != $TQTDIR/lib$LIBDIRSUFFIX ]] &&\
sed -i "1i $TQTDIR/lib$LIBDIRSUFFIX" etc/ld.so.conf
[[ -x /sbin/ldconfig ]] && /sbin/ldconfig
EOINS
cat <<EOINS >> $PKG/install/doinst.sh
## This could be a rebuild or upgradepkg running installpkg twice,
## so delete any previous routine
sed -i '/Update PKG_CONFIG_PATH for TDE/,+11d' etc/profile.d/pkgconfig.sh
echo '# Update PKG_CONFIG_PATH for TDE:
## remove duplicated paths:
PKG_CONFIG_PATH=\$(echo \$PKG_CONFIG_PATH| tr : \\\\n | awk '"'!seen[\\\$0]++'"' | tr \\\\n :|sed '"'s|:\$||'"')
#
## add path for INSTALL_TDE ..
[[ ! \$PKG_CONFIG_PATH == *$INSTALL_TDE/lib$LIBDIRSUFFIX/pkgconfig* ]] && \\
PKG_CONFIG_PATH=\$PKG_CONFIG_PATH:$INSTALL_TDE/lib$LIBDIRSUFFIX/pkgconfig
## .. and for TQTDIR if different
[[ ! \$PKG_CONFIG_PATH == *$TQTDIR/lib$LIBDIRSUFFIX/pkgconfig* ]] && \\
PKG_CONFIG_PATH=\$PKG_CONFIG_PATH:$TQTDIR/lib$LIBDIRSUFFIX/pkgconfig
#
export PKG_CONFIG_PATH' >> etc/profile.d/pkgconfig.sh
EOINS
doinst_sh_fn
makepkg_fn
## move ldconfig out of the way - links will be set up by doinst.sh
mv /sbin/ldconfig /sbin/ldconfig-bak
## install to '/' for TDE binaries
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## and install to SYSROOT for TDE headers and libs
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tqtinterface
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$TQTDIR \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DQT_PREFIX_DIR=$TQTDIR \
-DTQT_INCLUDE_DIR=$TQTDIR/include/tqt \
-DMOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-DQT_VERSION=3 \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
## edit tqmoc path from package so that when installed on RPi3, the tqmoc path is correct
sed -i "s|$SYSROOT/x86/tqmoc|$INSTALL_TDE/bin/tqmoc|" $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/pkgconfig/tqt.pc
sed -i "s|$SYSROOT/x86/tqmoc|$INSTALL_TDE/bin/tqmoc|" $PKG$INSTALL_TDE/bin/tmoc
strip_fn
mkdir_install_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## revert tqmoc path in tmoc for cross compiling on the BUILD system
sed -i "s|$INSTALL_TDE/bin/tqmoc|$SYSROOT/x86/tqmoc|" {,$SYSROOT}$INSTALL_TDE/bin/tmoc
close
cd /
PRGNAM=arts
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D TQT_REPLACE_SCRIPT=$INSTALL_TDE/bin/tqt-replace \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_ALSA="ON" \
-DWITH_AUDIOFILE="ON" \
-DWITH_ESOUND="OFF" \
-DWITH_GCC_VISIBILITY="ON" \
-DWITH_JACK="OFF" \
-DWITH_MAD="ON" \
-DWITH_SNDIO="OFF" \
-DWITH_VORBIS="ON" \
-DBUILD_DOC="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
## remove sysroot path from package
sed -i "s|$SYSROOT||g" $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/pkgconfig/artsc.pc
mangzip_fn
strip_fn
mkdir_install_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=dbus-tqt
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=dbus-1-tqt
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DWITH_GCC_VISIBILITY="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=libart-lgpl
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DMAN_INSTALL_DIR=/usr/man \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
## in shell so that INSTALL_TDE for TDE isn't overridden
(INSTALL_TDE=/usr
mangzip_fn)
strip_fn
mkdir_install_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tqca
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DLIB_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX \
-DBUILD_TQCA="ON" \
-DBUILD_TQCA_TLS="ON" \
-DWITH_GCC_VISIBILITY="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tdelibs
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## Patch for TDE bug 2821 to make error message more user friendly
patch -N -p0 << EOF || true
--- tdecmshell/main.cpp
+++ tdecmshell/main.cpp
@@ -98,0 +99,6 @@
+
+ if (path.left(4) == "tde-")
+ path.replace(0,4,"tde/");
+ else
+ path.prepend("tde/");
+
@@ -101 +107 @@
- kdWarning(780) << "Could not find module '" << module << "'." << endl;
+ kdError(780) << "Could not find '" << path << "'." << endl;
EOF
## Configuration files are in /etc/tde, and plugins in $INSTALL_TDE/lib$LIBDIRSUFFIX/tde
for file in \
tdecore/kstandarddirs.cpp \
tdecore/kcrash.cpp \
tdeinit/lnusertemp.c \
tdeinit/tdeinit.cpp \
tdeinit/wrapper.c \
tdelfeditor/tdelfeditor.cpp \
tdeio/tests/kurifiltertest.cpp \
tdeio/tests/kmimetypetest.sh.cmake \
tdeio/tests/jobtest.cpp \
tdeio/kssl/kopenssl.cpp \
tdeinit/tdestartupconfig.cpp \
tdecore/tdeconfig_compiler/tests/test9main.cpp
do
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|g" $file || true
done
sed -i "s|\"trinity\"|\"$PLUGIN_INSTALL_DIR\"|" tdecore/tdeapplication.cpp || true
## Patching for preferred formatting of help files
patch -N -p0 << EOF || true
--- doc/common/tde-docs.css
+++ doc/common/tde-docs.css
#
## tone down menu items highlighting
@@ -176,6 +176,6 @@
.guilabel, .interface, .guibutton {
- background-color: rgb(220, 220, 220);
+ background-color: #f0f0f0;
color: black;
border: 1px solid rgb(190, 190, 190);
-
+ padding:0px 1px;
-khtml-border-radius: 3px;
#
## for the <keycap> tags
@@ -199 +199 @@
- background-color: #DFDFFF;
+ background-color: #efefef;
@@ -201 +201,6 @@
-
+ padding-left: 1px;
+ padding-right: 1px;
+ border-style: solid;
+ border-width: 0px 1px;
+ border-color: lightgray;
+ color:gray;
@@ -209 +214 @@
- border 2px solid gray;
+ border: 2px solid gray;
#
## left justify text in the <para> tags in index.docbook
--- doc/common/tde-default.css
+++ doc/common/tde-default.css
@@ -211 +211 @@
- text-align: justify;
+ text-align: left;
@@ -319 +319 @@
- text-align: justify;
+ text-align: left;
EOF
## Restore diff.xml +/- colours and match markdown.xml diff display
echo $'--- kate/data/diff.xml
+++ kate/data/diff.xml
@@ -111,2 +111,2 @@
- <itemData name="Removed line" defStyleNum="dsString" backgroundColor="#ffeef0"/>
- <itemData name="Added line" defStyleNum="dsOthers" backgroundColor="#e6ffed"/>
+ <itemData name="Removed line" defStyleNum="dsString" color="#FF0000"/>
+ <itemData name="Added line" defStyleNum="dsOthers" color="#0000FF"/>
--- kate/data/markdown.xml
+++ kate/data/markdown.xml
@@ -149,2 +149,2 @@
-\t\t\t<itemData name="difflineremove" defStyleNum="dsString" backgroundColor="#ffeef0" />
-\t\t\t<itemData name="difflineadd" defStyleNum="dsOthers" backgroundColor="#e6ffed" />
+\t\t\t<itemData name="difflineremove" defStyleNum="dsNormal" backgroundColor="#eeeeee" color="#FF0000" />
+\t\t\t<itemData name="difflineadd" defStyleNum="dsNormal" backgroundColor="#eeeeee" color="#0000FF" />
' | patch -p0
## Build without spell checker installed
## Otherwise, install Aspell, or Hspell, or Ispell …
sed -i 's|^.*Spell checker selected as default.*$|message( STATUS " ## no spell checker selected ##" )|' CMakeLists.txt
chown_fn
cd_builddir_fn
## Set some paths to required binaries
## /bin/sh: dcopidl2cpp: command not found
## /bin/sh: tdeconfig_compiler: command not found
## /bin/sh: meinproc: command not found
sed -i "s|dcopidl2cpp|$PWD/dcop/dcopidl2cpp/dcopidl2cpp|" ../CMakeLists.txt
sed -i "s|tdeconfig_compiler|$PWD/tdecore/tdeconfig_compiler/tdeconfig_compiler|" ../CMakeLists.txt
## Take this opportunity to use the native meinproc
sed -i "s|meinproc|$INSTALL_TDE/bin/meinproc-x86|" ../CMakeLists.txt
## Add exitcodes for try_run tests which produce a cmake error when x-compiling, unless CMAKE_CROSSCOMPILING_EMULATOR is set
## Set exitcodes to values that a native build would give
## Additionally, command line '-D HAVE_xxxxx_EXITCODE:STRING=x' option fails with cmake 3.12, so these builds use cmake 3.10
## Use native binary intltool-merge for ARCH independent desktop files
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-D HAVE_GOOD_GETADDRINFO_EXITCODE:STRING=0 \
-D HAVE_OPENPTY_EXITCODE:STRING=0 \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DCMAKE_SKIP_RPATH="OFF" \
-DCMAKE_INSTALL_RPATH=$INSTALL_TDE/lib$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DTDE_MALLOC="OFF" \
-DTDE_MALLOC_DEBUG="OFF" \
-DTDE_MALLOC_FULL="OFF" \
-DWITH_ALSA="ON" \
-DWITH_ARTS="ON" \
-DWITH_ASPELL="OFF" \
-DWITH_AVAHI=${AVAHI:-"OFF"} \
-DWITH_CONSOLEKIT="OFF" \
-DWITH_CUPS="ON" \
-DWITH_DEVKITPOWER="ON" \
-DWITH_ELFICON="OFF" \
-DWITH_GAMIN="OFF" \
-DWITH_GCC_VISIBILITY="ON" \
-DWITH_HSPELL="OFF" \
-DWITH_IMAGETOPS_BINARY="OFF" \
-DWITH_INOTIFY="ON" \
-DWITH_ISPELL="OFF" \
-DWITH_JASPER="OFF" \
-DWITH_KDE4_MENU_SUFFIX="ON" \
-DWITH_LIBART="ON" \
-DWITH_LIBBFD="OFF" \
-DWITH_LIBIDN="OFF" \
-DWITH_LOGINDPOWER="ON" \
-DWITH_LUA="OFF" \
-DWITH_LZMA="ON" \
-DWITH_MITSHM="OFF" \
-DWITH_NETWORK_MANAGER_BACKEND="ON" \
-DWITH_OLD_XDG_STD="OFF" \
-DWITH_OPENEXR="ON" \
-DWITH_PCRE2="ON" \
-DWITH_SSL="ON" \
-DWITH_SUDO_TDESU_BACKEND="OFF" \
-DWITH_TDEHWLIB="ON" \
-DWITH_TDEHWLIB_DAEMONS="ON" \
-DWITH_TDEICONLOADER_DEBUG="OFF" \
-DWITH_TIFF="ON" \
-DWITH_UDISKS2="ON" \
-DWITH_UDISKS="ON" \
-DWITH_UPOWER="OFF" \
-DWITH_UTEMPTER="OFF" \
-DWITH_XCOMPOSITE="ON" \
-DWITH_XRANDR="ON" \
-Wno-dev \
..
## Modify paths so that SYSROOT headers and libs are used, to avoid this error:
## error: /usr/include/gnu/stubs.h:7:11: fatal error: gnu/stubs-32.h: No such file or directory
## The alternative is to modify FindPkgConfig.cmake to prefix the INCLUDEDIR and LIBDIR results with ${CMAKE_SYSROOT}, but as this issue only surfaces here and that's a system file, let's keep the change local:
sed -i "s|=/usr/include|=$SYSROOT/usr/include|" CMakeCache.txt
sed -i "s|=/usr/lib$LIBDIRSUFFIX|=$SYSROOT/usr/lib$LIBDIRSUFFIX|" CMakeCache.txt
make $NUMJOBS
make DESTDIR=$PKG install
## remove sysroot paths to libz.so, libjpeg.so, and libasound.so from package
sed -i "s|$SYSROOT||g" $PKG$INSTALL_TDE/share/cmake/tdelibs.cmake
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## prefix paths with SYSROOT for build.make => link.txt dependencies for cmake builds for consistency with pkg-config paths
sed -i "s|\"$INSTALL_TDE|\"$SYSROOT$INSTALL_TDE|" {,$SYSROOT}$INSTALL_TDE/share/cmake/tdelibs.cmake
## reinstate the sysroot paths for the installed libz, libjpeg, libasound files required for the build
sed -i "s|;/usr|;$SYSROOT/usr|" {,$SYSROOT}$INSTALL_TDE/share/cmake/tdelibs.cmake
close
cd /
PRGNAM=tdebase
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## picking up the wrong limits.h - MAX_PATH not defined
sed -i 's|<limits.h>|&\n#include <linux/limits.h>|' kcontrol/krdb/krdb.cpp
sed -i '20s|^|#include <linux/limits.h>|' kdesktop/lock/lockprocess.cpp
## make default tdm screen text clearer against dark background and align login button with clickable area
## edit color="#ffff74" and/or color="#ff0000" for your own choice
echo $'
--- tdm/kfrontend/themes/o2_enterprise/enterprise.xml
+++ tdm/kfrontend/themes/o2_enterprise/enterprise.xml
@@ -12 +12 @@
-\t\t\t<normal color="#000000" font="Sans 10" />
+\t\t\t<normal color="#ffff74" font="Sans 10" />
@@ -39 +39 @@
-\t\t\t<pos width="box" x="540" y="188" anchor="c" height="box" />
+\t\t\t<pos width="38" x="540" y="188" anchor="c" height="box" />
@@ -42 +42 @@
-\t\t\t\t\t<pos x="90%" y="50%" anchor="c" />
+\t\t\t\t\t<pos x="40%" y="50%" anchor="c" />
@@ -59 +59 @@
-\t\t\t\t\t\t\t\t<normal color="#000000" font="Sans Condensed 10" />
+\t\t\t\t\t\t\t\t<normal color="#ffff74" font="Sans Condensed 10" />
@@ -64 +64 @@
-\t\t\t\t\t\t\t\t<normal color="#000000" font="Sans Condensed 10" />
+\t\t\t\t\t\t\t\t<normal color="#ffff74" font="Sans Condensed 10" />
@@ -86,2 +86,2 @@
-\t\t\t\t<pos x="435" y="293" anchor="s" />
-\t\t\t\t<normal color="#CD0000" font="Sans 10" />
+\t\t\t\t<pos x="435" y="240" anchor="s" />
+\t\t\t\t<normal color="#ff0000" font="Sans 11" />
@@ -93,2 +93,2 @@
-\t\t\t\t<normal color="#CD0000" font="Sans 10" />
-\t\t\t\t<pos x="435" y="323" anchor="s" />
+\t\t\t\t<normal color="#ff0000" font="Sans 11" />
+\t\t\t\t<pos x="435" y="260" anchor="s" />
' | patch -p0
## enable konqueror filemanagement ViewMode to be set - TDE bug 1963
echo $'
--- konqueror/listview/konq_detailedlistview.desktop
+++ konqueror/listview/konq_detailedlistview.desktop
@@ -86,0 +87 @@
+X-TDE-BrowserView-Built-Into=konqueror
--- konqueror/iconview/konq_iconview.desktop
+++ konqueror/iconview/konq_iconview.desktop
@@ -87,0 +88 @@
+X-TDE-BrowserView-Built-Into=konqueror
--- konqueror/iconview/konq_multicolumnview.desktop
+++ konqueror/iconview/konq_multicolumnview.desktop
@@ -87,0 +88 @@
+X-TDE-BrowserView-Built-Into=konqueror
--- konqueror/listview/konq_infolistview.desktop
+++ konqueror/listview/konq_infolistview.desktop
@@ -84,0 +85 @@
+X-TDE-BrowserView-Built-Into=konqueror
--- konqueror/listview/konq_textview.desktop
+++ konqueror/listview/konq_textview.desktop
@@ -87,0 +88 @@
+X-TDE-BrowserView-Built-Into=konqueror
--- konqueror/listview/konq_treeview.desktop
+++ konqueror/listview/konq_treeview.desktop
@@ -87,0 +88 @@
+X-TDE-BrowserView-Built-Into=konqueror
' | patch -p0
## Configuration files are in /etc/tde, and plugins in $INSTALL_TDE/lib$LIBDIRSUFFIX/tde
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|g" tdm/config.def || true
sed -i "s|/etc/trinity|$INSTALL_TDE/share/config|" tdm/kfrontend/gentdmconf.c || true
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|" tdm/kfrontend/gentdmconf.c || true
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|" kcontrol/hwmanager/devicepropsdlg.cpp || true
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|" tdeioslave/trash/testtrash.cpp || true
patch -N -p0 << EOF || true
--- translations/desktop_files/kcontrol-desktops/en_GB.po
+++ translations/desktop_files/kcontrol-desktops/en_GB.po
@@ -1355,3 +1355,3 @@
msgid "Configure display ICC color profile"
-msgstr ""
+msgstr "Configure display ICC colour profile"
@@ -1360,3 +1360,3 @@
msgid "ICC;display;color;profile;"
-msgstr ""
+msgstr "ICC;display;colour;profile;"
@@ -1365,3 +1365,3 @@
msgid "Color Profile"
-msgstr ""
+msgstr "Colour Profile"
EOF
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D HAVE_OPENPTY_EXITCODE:STRING=0 \
-D HAVE_NOGROUP_EXITCODE:STRING=0 \
-D HAVE_SETLOGIN_EXITCODE:STRING=1 \
-D HONORS_SOCKET_PERMS_EXITCODE:STRING=0 \
-D COVARIANT_RETURN_EXITCODE:STRING=0 \
-D HTDIG_SEARCH_BINARY=$SYSROOT/var/www/cgi-bin/htsearch \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_ARTS="ON" \
-DWITH_ELFICON="OFF" \
-DWITH_GCC_VISIBILITY="ON" \
-DWITH_I8K="OFF" \
-DWITH_LDAP="OFF" \
-DWITH_LIBART="ON" \
-DWITH_LIBCONFIG="OFF" \
-DWITH_LIBRAW1394="OFF" \
-DWITH_LIBUSB="OFF" \
-DWITH_OPENEXR="ON" \
-DWITH_OPENGL="ON" \
-DWITH_PAM="OFF" \
-DWITH_PCRE2="ON" \
-DWITH_SAMBA="OFF" \
-DWITH_SASL="OFF" \
-DWITH_SENSORS="ON" \
-DWITH_SHADOW="ON" \
-DWITH_SUDO_KONSOLE_SUPER_USER_COMMAND="OFF" \
-DWITH_SUDO_TDESU_BACKEND="OFF" \
-DWITH_TDEHWLIB="ON" \
-DWITH_UPOWER="ON" \
-DWITH_XCOMPOSITE="ON" \
-DWITH_XCURSOR="ON" \
-DWITH_XDMCP="ON" \
-DWITH_XFIXES="ON" \
-DWITH_XINERAMA="ON" \
-DWITH_XRANDR="ON" \
-DWITH_XRENDER="ON" \
-DWITH_XSCREENSAVER="OFF" \
-DWITH_XTEST="ON" \
-DBUILD_APPLNK="ON" \
-DBUILD_CRASHTEST="ON" \
-DBUILD_DOC="ON" \
-DBUILD_DRKONQI="ON" \
-DBUILD_KAPPFINDER="ON" \
-DBUILD_KATE="ON" \
-DBUILD_KCHECKPASS="ON" \
-DBUILD_KCMINIT="ON" \
-DBUILD_KCONTROL="ON" \
-DBUILD_KDCOP="ON" \
-DBUILD_KDESKTOP="ON" \
-DBUILD_KDIALOG="ON" \
-DBUILD_KFIND="ON" \
-DBUILD_KHELPCENTER="ON" \
-DBUILD_KHOTKEYS="ON" \
-DBUILD_KICKER="ON" \
-DBUILD_KLIPPER="ON" \
-DBUILD_KMENUEDIT="ON" \
-DBUILD_KNETATTACH="ON" \
-DBUILD_KONQUEROR="ON" \
-DBUILD_KONSOLE="ON" \
-DBUILD_KPAGER="ON" \
-DBUILD_KPERSONALIZER="ON" \
-DBUILD_KREADCONFIG="ON" \
-DBUILD_KROOTBACKING="ON" \
-DBUILD_KSMSERVER="ON" \
-DBUILD_KSPLASHML="ON" \
-DBUILD_KSTART="ON" \
-DBUILD_KSYSGUARD="ON" \
-DBUILD_KSYSTRAYCMD="ON" \
-DBUILD_KTIP="ON" \
-DBUILD_KXKB="ON" \
-DBUILD_L10N="ON" \
-DBUILD_LIBKONQ="ON" \
-DBUILD_NSPLUGINS="ON" \
-DBUILD_PICS="ON" \
-DBUILD_PROFILE_SHUTDOWN="OFF" \
-DBUILD_STARTTDE="ON" \
-DBUILD_TDEDEBUGDIALOG="ON" \
-DBUILD_TDEEJECT="ON" \
-DBUILD_TDEINIT="ON" \
-DBUILD_TDEIOSLAVES="ON" \
-DBUILD_TDEKBDLEDSYNC="ON" \
-DBUILD_TDEPASSWD="ON" \
-DBUILD_TDEPRINT="ON" \
-DBUILD_TDESCREENSAVER="ON" \
-DBUILD_TDESU="ON" \
-DBUILD_TDM="ON" \
-DBUILD_TDM_SYSTEMD_UNIT_FILE="OFF" \
-DBUILD_TQT3INTEGRATION="ON" \
-DBUILD_TSAK="ON" \
-DBUILD_TWIN="ON" \
-Wno-dev \
..
## If the linker can't find some libs to build kicker even though they've been built,
## edit kicker.dir/link.txt and rerun 'make':
make $NUMJOBS || \
[[ ! -e ./kicker/kicker/kicker ]] && {
sed -i 's|^.*$|& ../../libkonq/libkonq.so.4 ./interfaces/libkickoffsearch_interfaces.so.0|' ./kicker/kicker/CMakeFiles/kicker.dir/link.txt && \
make $NUMJOBS
}
make DESTDIR=$PKG install
## remove sysroot path from package
sed -i "s|$SYSROOT||" $PKG$INSTALL_TDE/bin/khc_htsearch.pl
mangzip_fn
strip_fn
## Add xinitrc:
mkdir -p $PKG/etc/X11/xinit
echo $"#!""/bin/sh
userresources=\$HOME/.Xresources
usermodmap=\$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap
if [ -f \$sysresources ]; then
/usr/bin/xrdb -merge \$sysresources
fi
if [ -f \$sysmodmap ]; then
/usr/bin/xmodmap \$sysmodmap
fi
if [ -f \$userresources ]; then
/usr/bin/xrdb -merge \$userresources
fi
if [ -f \$usermodmap ]; then
/usr/bin/xmodmap \$usermodmap
fi
if [ -z \"\$DESKTOP_SESSION\" -a -x /usr/bin/ck-launch-session ]; then
exec ck-launch-session dbus-launch --exit-with-session $INSTALL_TDE/bin/starttde
else
exec dbus-launch --exit-with-session $INSTALL_TDE/bin/starttde
fi
" > $PKG/etc/X11/xinit/xinitrc.tde
chmod 755 $PKG/etc/X11/xinit/xinitrc.tde
(cd $PKG/etc/X11/xinit/
ln -sf xinitrc.tde xinitrc)
mkdir -p $PKG/etc/profile.d
echo '#!'"/bin/sh
# TDE additions:
export TDEDIR=$INSTALL_TDE
# upgradepkg runs installpkg twice, so test for the second run:
[[ \"\$XDG_CONFIG_DIRS\" != *$SYS_CNF_DIR/xdg* ]] && {
if [ ! \"\$XDG_CONFIG_DIRS\" = \"\" ]; then
export XDG_CONFIG_DIRS=\$XDG_CONFIG_DIRS:$SYS_CNF_DIR/xdg
else
export XDG_CONFIG_DIRS=/etc/xdg:$SYS_CNF_DIR/xdg
fi
}
## Re: https://specifications.freedesktop.org/basedir-spec/basedir-spec-0.6.html
## If XDG_DATA_DIRS is null or unset, the default is /usr/local/share:/usr/share
[[ \$XDG_DATA_DIRS == \"\" ]] && \\
export XDG_DATA_DIRS=/usr/local/share:/usr/share:$INSTALL_TDE/share || {
[[ \$XDG_DATA_DIRS != *$INSTALL_TDE/share* ]] && \\
export XDG_DATA_DIRS=\$XDG_DATA_DIRS:$INSTALL_TDE/share
}
" > $PKG/etc/profile.d/tde.sh
chmod 755 $PKG/etc/profile.d/tde.sh
# Add some configuration files / scripts needed by TDE.
mkdir -p $PKG$SYS_CNF_DIR
mv $PKG$INSTALL_TDE/share/config/tdm $PKG$SYS_CNF_DIR/tdm
( cd $PKG$INSTALL_TDE/share/config ; ln -sf $SYS_CNF_DIR/tdm tdm )
# Add rc.4.local to give TDM priority over rc.4 X11 session manager options
# Assumes that rc.4.new from sysvinit-scripts still has the rc.4.local option
mkdir $PKG/etc/rc.d
echo $"#!""/bin/sh
# Start TDM:
if [ -x $INSTALL_TDE/bin/tdm ]; then
echo \"Using TDM (Trinity Login Manager).\"
echo
# log_cleanup \"/var/log/tdm.log\"
exec $INSTALL_TDE/bin/tdm -nodaemon -error /var/log/tdm.log
fi
" > $PKG/etc/rc.d/rc.4.local
chmod 755 $PKG/etc/rc.d/rc.4.local
# Set sane permissions for the include files.
if [ -d $PKG$INSTALL_TDE/include ]; then
find $PKG$INSTALL_TDE/include -type f -exec chmod 0644 {} \;
fi
# Set up config files for TDM:
$PKG$INSTALL_TDE/bin/gentdmconf --no-old --no-old-scripts --no-backup --in $PKG$SYS_CNF_DIR/tdm
## set correct paths for config files
sed -i "s|$INSTALL_TDE/share/config/tdm/|$SYS_CNF_DIR/tdm/|" $PKG$SYS_CNF_DIR/tdm/tdmrc
# Allow root to login
sed 's|AllowRootLogin=false|AllowRootLogin=true|' $PKG$SYS_CNF_DIR/tdm/tdmrc > $PKG$SYS_CNF_DIR/tdm/tdmrc.new
## Remove tdmrc which has AllowRootLogin=false set and would be used for a new installation
## The installed tdmrc will be created by doinst.sh from tdmrc.new if it doesn't exist
rm $PKG$SYS_CNF_DIR/tdm/tdmrc
mv $PKG$SYS_CNF_DIR/tdm/Xsession $PKG$SYS_CNF_DIR/tdm/Xsession.orig
echo $"#!""/bin/sh
# Xsession - run as user
# Merged in parts of the old Xsession to load defaults from
# Xresources and Xmodmap files, 2006-02-09 volkerdi
session=\$1
# This section is borrowed from the old X11 Xsession file:
userresources=\$HOME/.Xresources
usermodmap=\$HOME/.Xmodmap
sysresources=/usr/lib/X11/xinit/.Xresources
sysmodmap=/usr/lib/X11/xinit/.Xmodmap
# merge in defaults and keymaps
if [ -r \$sysresources ]; then
/usr/bin/xrdb -merge \$sysresources
fi
if [ -r \$sysmodmap ]; then
/usr/bin/xmodmap \$sysmodmap
fi
if [ -r \$userresources ]; then
/usr/bin/xrdb -merge \$userresources
fi
if [ -r \$usermodmap ]; then
/usr/bin/xmodmap \$usermodmap
fi
# Note that the respective logout scripts are not sourced.
case \$SHELL in
*/bash)
[ -z \"\$BASH\" ] && exec \$SHELL \$0 \"\$@\"
set +o posix
[ -f /etc/profile ] && . /etc/profile
if [ -f \$HOME/.bash_profile ]; then
. \$HOME/.bash_profile
elif [ -f \$HOME/.bash_login ]; then
. \$HOME/.bash_login
elif [ -f \$HOME/.profile ]; then
. \$HOME/.profile
fi
;;
*/zsh)
[ -z \"\$ZSH_NAME\" ] && exec \$SHELL \$0 \"\$@\"
emulate -R zsh
[ -d /etc/zsh ] && zdir=/etc/zsh || zdir=/etc
zhome=\${ZDOTDIR:-\$HOME}
# zshenv is always sourced automatically.
[ -f \$zdir/zprofile ] && . \$zdir/zprofile
[ -f \$zhome/.zprofile ] && . \$zhome/.zprofile
[ -f \$zdir/zlogin ] && . \$zdir/zlogin
[ -f \$zhome/.zlogin ] && . \$zhome/.zlogin
;;
*/csh|*/tcsh)
# [t]cshrc is always sourced automatically.
# Note that sourcing csh.login after .cshrc is non-standard.
xsess_tmp=`mktemp`
\$SHELL -c \"if (-f /etc/csh.login) source /etc/csh.login; if (-f ~/.login) source ~/.login; /bin/sh -c export >! \$xsess_tmp\"
. \$xsess_tmp
rm -f \$xsess_tmp
;;
*) # Plain sh, ksh, and anything we don't know.
[ -f /etc/profile ] && . /etc/profile
[ -f \$HOME/.profile ] && . \$HOME/.profile
;;
esac
[ -f /etc/xprofile ] && . /etc/xprofile
[ -f \$HOME/.xprofile ] && . \$HOME/.xprofile
case \$session in
\"\")
exec xmessage -center -buttons OK:0 -default OK \"Sorry, \$DESKTOP_SESSION is no valid session.\"
;;
failsafe)
exec xterm -geometry 80x24-0-0
;;
custom)
exec \$HOME/.xsession
;;
default)
exec $INSTALL_TDE/bin/starttde
;;
*)
eval exec \"\$session\"
;;
esac
exec xmessage -center -buttons OK:0 -default OK \"Sorry, cannot execute \$session. Check \$DESKTOP_SESSION.desktop.\"
" > $PKG$SYS_CNF_DIR/tdm/Xsession
mv $PKG$SYS_CNF_DIR/tdm/backgroundrc $PKG$SYS_CNF_DIR/tdm/backgroundrc.new
[[ -r $PKG$SYS_CNF_DIR/tdm/README ]] && \
sed -i "s|$TMP_BUILD/package-tdebase$SYS_CNF_DIR/tdm|$SYS_CNF_DIR/tdm|" $PKG$SYS_CNF_DIR/tdm/README
mkdir_install_fn
## set up doinst.sh
echo $"# Save old config files:
if [ ! -L etc/X11/tdm ]; then
if [ -d etc/X11/tdm ]; then
mkdir -p .$SYS_CNF_DIR/tdm
cp -a etc/X11/tdm/* .$SYS_CNF_DIR/tdm
rm -rf etc/X11/tdm
( cd etc/X11 ; ln -sf ../..$SYS_CNF_DIR/tdm tdm )
elif [ ! -e etc/X11/tdm ]; then
mkdir -p etc/X11
( cd etc/X11 ; ln -sf ../..$SYS_CNF_DIR/tdm tdm )
fi
fi
config() {
NEW=\"\$1\"
OLD=\"\$(dirname \$NEW)/\$(basename \$NEW .new)\"
# If there's no config file by that name, mv it over:
if [ ! -r \$OLD ]; then
mv \$NEW \$OLD
elif [ \"\$(cat \$OLD | md5sum)\" = \"\$(cat \$NEW | md5sum)\" ]; then # toss the redundant copy
rm \$NEW
fi
# Otherwise, we leave the .new copy for the admin to consider...
}
config .$SYS_CNF_DIR/tdm/tdmrc.new
config .$SYS_CNF_DIR/tdm/backgroundrc.new
# Update the desktop database:
\$(which update-desktop-database) $INSTALL_TDE/share/applications
# Update the mime database:
\$(which update-mime-database) /usr/share/mime
# Update hicolor theme cache:
\$(which gtk-update-icon-cache) -f -t $INSTALL_TDE/share/icons/hicolor
# update PATH
# upgradepkg runs this twice, so even though $TQTDIR/bin will be
# a new PATH, it needs to be tested for the second run
if ! grep $INSTALL_TDE/bin /etc/profile
then
echo \"PATH=\\\$PATH:$INSTALL_TDE/bin:$TQTDIR/bin\" >> /etc/profile
else
if ! grep $TQTDIR/bin /etc/profile
then
echo \"PATH=\\\$PATH:$TQTDIR/bin\" >> /etc/profile
fi
fi
# update MANPATH
if ! grep $INSTALL_TDE/man /etc/profile
then
echo \"export MANPATH=\\\$MANPATH:$INSTALL_TDE/man\" >> /etc/profile
fi
## you may not want to do this ##
# start a 'konsole' with system-wide profile
[[ ! \$(grep -x \"source /etc/profile\" \$HOME/.bashrc ) ]] && echo \"source /etc/profile\" >> \$HOME/.bashrc || true
# don't want this
sed -i 's|source /etc/profile.d/mc.sh|#source /etc/profile.d/mc.sh|' \$HOME/.bashrc || true
## set default runlevel to 4 for tdm
sed -i 's|id:[1-5]|id:4|' etc/inittab
" > $PKG/install/doinst.sh
## set TDEHOME and TDEROOTHOME variables - defaults ~/.trinity and /root/.trinity
echo "# upgradepkg runs installpkg twice, so firstly remove any previous TDE*HOME entries
sed -i '/TDE.*HOME/d' /etc/profile
echo 'export TDEHOME=~/.tde' >> /etc/profile
echo 'export TDEROOTHOME=/root/.tde' >> /etc/profile
" >> $PKG/install/doinst.sh
makepkg_fn
installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## prefix paths with SYSROOT for build.make => link.txt dependencies for cmake builds for consistency with pkg-config paths
sed -i "s|\"$INSTALL_TDE|\"$SYSROOT$INSTALL_TDE|g" {,$SYSROOT}$INSTALL_TDE/share/cmake/*.cmake
Build times
= 19:59 on x86_64 for x86_64
= 24:02 on x86_64 for RPi3 using tqmoc and meinproc x86_64 binaries
= 33:01 on x86_64 for RPi3 with tqmoc x86_64 & meinproc arm
= 49:01 on RPi3 for RPi3
close
cd /
PRGNAM=tdeaddons
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## enable 'ar' compression in Compress As menu
patch -N -p0 << EOF || true
--- konq-plugins/arkplugin/arkplugin.cpp
+++ konq-plugins/arkplugin/arkplugin.cpp
@@ -347 +347 @@
- if ( !TDEStandardDirs::findExe( "ar" ).isNull() && m_conf->readBoolEntry( "UseAr", false ) )
+ if ( !TDEStandardDirs::findExe( "ar" ).isNull() && m_conf->readBoolEntry( "UseAr", true ) )
EOF
chown_fn
## check for libatlantic [tdegames]
[[ $(ls $SYSROOT$INSTALL_TDE/lib$LIBDIRSUFFIX/libatlantic.so.*) ]] && ATLANTIKDESIGNER="ON"
## check for kaddressbook in tdepim
[[ $(ls $SYSROOT$INSTALL_TDE/lib$LIBDIRSUFFIX/libkaddressbook.so*) ]] && KADDRESSBOOK_PLUGINS="ON"
## check for tdemultimedia
[[ $(ls $SYSROOT$INSTALL_TDE/lib$LIBDIRSUFFIX/libnoatun.so*) ]] && NOATUN_PLUGINS="ON"
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_ARTS="ON" \
-DWITH_SDL="ON" \
-DWITH_BERKELEY_DB="ON" \
-DWITH_XMMS="OFF" \
-DWITH_TEST="OFF" \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-DBUILD_ATLANTIKDESIGNER=${ATLANTIKDESIGNER:-"OFF"} \
-DBUILD_KADDRESSBOOK_PLUGINS=${KADDRESSBOOK_PLUGINS:-"OFF"} \
-DBUILD_NOATUN_PLUGINS=${NOATUN_PLUGINS:-"OFF"} \
-DBUILD_KATE_PLUGINS="ON" \
-DBUILD_KICKER_APPLETS="ON" \
-DBUILD_KNEWSTICKER_SCRIPTS="ON" \
-DBUILD_KONQ_PLUGINS="ON" \
-DBUILD_KSIG="ON" \
-DBUILD_RENAMEDLG_PLUGINS="ON" \
-DBUILD_TDEFILE_PLUGINS="ON" \
-DBUILD_TUTORIALS="OFF" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
mangzip_fn
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tdeutils
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## Set some paths to required binaries
## /bin/sh: makecrc: command not found
sed -i "s|COMMAND makecrc|COMMAND ./makecrc|" klaptopdaemon/CMakeLists.txt
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_DPMS="ON" \
-DWITH_XSCREENSAVER="OFF" \
-DWITH_SENSORS="ON" \
-DWITH_SNMP="OFF" \
-DWITH_ASUS="OFF" \
-DWITH_POWERBOOK="OFF" \
-DWITH_POWERBOOK2="OFF" \
-DWITH_VAIO="OFF" \
-DWITH_THINKPAD="OFF" \
-DWITH_I8K="OFF" \
-DWITH_XMMS="OFF" \
-DWITH_TDENEWSTUFF="OFF" \
-DBUILD_DOC="ON" \
-DBUILD_ARK="ON" \
-DBUILD_CHARSELECTAPPLET="ON" \
-DBUILD_KCALC="ON" \
-DBUILD_KCHARSELECT="ON" \
-DBUILD_TDELIRC="ON" \
-DBUILD_TDESSH="ON" \
-DBUILD_KDF="ON" \
-DBUILD_KEDIT="ON" \
-DBUILD_KFLOPPY="ON" \
-DBUILD_KGPG="ON" \
-DBUILD_KHEXEDIT="ON" \
-DBUILD_KJOTS="ON" \
-DBUILD_KLAPTOPDAEMON="ON" \
-DBUILD_KMILO="ON" \
-DBUILD_KREGEXPEDITOR="ON" \
-DBUILD_KSIM="ON" \
-DBUILD_KTIMER="ON" \
-DBUILD_TDEWALLET="ON" \
-DBUILD_SUPERKARAMBA="ON" \
-DBUILD_TDEFILEREPLACE="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
mangzip_fn
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tdeartwork
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_GCC_VISIBILITY="ON" \
-DWITH_ALL_INCLUDED_XSCREENSAVERS="OFF" \
-DWITH_ARTS="ON" \
-DWITH_XSCREENSAVER="OFF" \
-DWITH_LIBART="ON" \
-DWITH_OPENGL="ON" \
-DBUILD_DOC="ON" \
-DBUILD_EMOTICONS="ON" \
-DBUILD_ICEWM_THEMES="ON" \
-DBUILD_ICON_THEMES="ON" \
-DBUILD_TDESCREENSAVER="ON" \
-DBUILD_TWIN_STYLES="ON" \
-DBUILD_KWORLDCLOCK="ON" \
-DBUILD_SOUNDS="ON" \
-DBUILD_STYLES="ON" \
-DBUILD_TDEASCIIQUARIUM="ON" \
-DBUILD_WALLPAPERS="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
mangzip_fn
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
… imlib Required for kuickshow - part of tdegraphics.
cd /
PRGNAM=imlib
VERSION=1.9.15
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
Patches thanks to fedora
echo $'--- Imlib/load.c
+++ Imlib/load.c
@@ -6,0 +7,2 @@
+#define G_MAXINT ((int) 0x7fffffff)
+
@@ -43,0 +46,2 @@
+ * we check G_MAXINT/4 because rend.c malloc\'s w * h * bpp
+ * + 3 is safety margin
@@ -48,3 +52,5 @@
- if( w > 32767 || h > 32767)
- return NULL;
- return malloc(w * h * 3);
+ if (w <= 0 || w > 32767 ||
+ h <= 0 || h > 32767 ||
+ h >= (G_MAXINT/4 - 1) / w)
+ return NULL;
+ return malloc(w * h * 3 + 3);
@@ -194 +200 @@
- if (setjmp(png_ptr->jmpbuf))
+ if (setjmp(png_jmpbuf(png_ptr)))
@@ -199 +205 @@
- if (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)
+ if (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_RGB_ALPHA)
@@ -257 +263,2 @@
- if (color_type == PNG_COLOR_TYPE_GRAY_ALPHA)
+ if (color_type == PNG_COLOR_TYPE_GRAY
+ || color_type == PNG_COLOR_TYPE_GRAY_ALPHA)
@@ -281,0 +289 @@
+#if 0
@@ -296,0 +305 @@
+#endif
@@ -363 +372,3 @@
- if(ww > 32767 || hh > 32767)
+ if (ww <= 0 || ww > 32767 ||
+ hh <= 0 || hh > 32767 ||
+ hh >= (G_MAXINT/sizeof(uint32)) / ww)
@@ -445,0 +457,3 @@
+#ifdef GIFLIB_MAJOR
+ gif = DGifOpenFileHandle(fd, NULL);
+#else
@@ -446,0 +461 @@
+#endif
@@ -453,0 +469,3 @@
+#ifdef GIFLIB_MAJOR
+\t fprintf(stderr, "giflib error: %s\\n", GifErrorString(gif->Error));
+#else
@@ -454,0 +473 @@
+#endif
@@ -460,0 +480,3 @@
+#ifdef GIFLIB_MAJOR
+\t fprintf(stderr, "giflib error: %s\\n", GifErrorString(gif->Error));
+#else
@@ -461,0 +484 @@
+#endif
@@ -466 +489 @@
-\t if (*h > 32767 || *w > 32767)
+\t if (*h <= 0 || *h > 32767 || *w <= 0 || *w > 32767)
@@ -472,0 +496,3 @@
+#ifdef GIFLIB_MAJOR
+\t DGifCloseFile(gif, NULL);
+#else
@@ -473,0 +500 @@
+#endif
@@ -478,0 +506,3 @@
+#ifdef GIFLIB_MAJOR
+\t DGifCloseFile(gif, NULL);
+#else
@@ -479,0 +510 @@
+#endif
@@ -489,0 +521,3 @@
+#ifdef GIFLIB_MAJOR
+\t\t DGifCloseFile(gif, NULL);
+#else
@@ -490,0 +525 @@
+#endif
@@ -578,0 +614,3 @@
+#ifdef GIFLIB_MAJOR
+ DGifCloseFile(gif, NULL);
+#else
@@ -579,0 +618 @@
+#endif
@@ -648 +687 @@
- if (bpp != 1 && bpp != 4 && bpp != 8 && bpp && 16 && bpp != 24 && bpp != 32)
+ if (bpp != 1 && bpp != 4 && bpp != 8 && bpp != 16 && bpp != 24 && bpp != 32)
@@ -1002,0 +1042,2 @@
+ memset(lookup, 0, sizeof(lookup));
+
@@ -1003,0 +1045,3 @@
+ if (!line)
+ return NULL;
+
@@ -1032 +1076 @@
- if (ncolors > 32766)
+ if (ncolors <= 0 || ncolors > 32766)
@@ -1038 +1082 @@
-\t\t if (cpp > 5)
+\t\t if (cpp <= 0 || cpp > 5)
@@ -1044 +1088 @@
-\t\t if (*w > 32767)
+\t\t if (*w <= 0 || *w > 32767)
@@ -1050 +1094 @@
-\t\t if (*h > 32767)
+\t\t if (*h <= 0 || *h > 32767)
@@ -1082,0 +1127 @@
+\t\t int space;
@@ -1087,0 +1133 @@
+\t\t space = sizeof(col) - 1;
@@ -1110,4 +1156,4 @@
-\t\t\t\t if (col[0])
-\t\t\t\t\tstrcat(col, " ");
- if (strlen(col) + strlen(s) < sizeof(col))
-\t\t\t\t\tstrcat(col, s);
+\t\t\t\t if (col[0] && space > 0)
+\t\t\t\t\tstrcat(col, " "), space -= 1;
+ if (slen <= space)
+\t\t\t\t\tstrcat(col, s), space -= slen;
@@ -1143 +1189,2 @@
-\t\t\t\t strcpy(tok, s);
+\t\t\t\t if (slen < sizeof(tok));
+\t\t\t\t strcpy(tok, s);
@@ -1144,0 +1192 @@
+\t\t\t\t space = sizeof(col) - 1;
@@ -1148,3 +1196,4 @@
-\t\t\t\t if (col[0])
-\t\t\t\t strcat(col, " ");
-\t\t\t\t strcat(col, s);
+\t\t\t\t if (col[0] && space > 0)
+\t\t\t\t strcat(col, " "), space -=1;
+\t\t\t\t if (slen <= space)
+\t\t\t\t strcat(col, s), space -= slen;
@@ -1379 +1428 @@
-\t if (a > 32767)
+\t if (a <= 0 || a > 32767)
@@ -1384 +1433 @@
-\t if (b > 32767)
+\t if (b <= 0 || b > 32767)
--- Imlib/misc.c
+++ Imlib/misc.c
@@ -677,0 +678,4 @@
+
+ id->x.shm = 0;
+ id->x.shmp = 0;
+ id->max_shm = 0;
@@ -693 +697,2 @@
-\t if (XShmPixmapFormat(id->x.disp) == ZPixmap)
+\t if ((XShmPixmapFormat(id->x.disp) == ZPixmap &&
+\t\t (pm == True)))
@@ -698 +702,0 @@
- else
@@ -700,4 +704 @@
- {
- id->x.shm = 0;
- id->x.shmp = 0;
- }
+
@@ -955,2 +956,2 @@
-\t if (id->x.shm)
-\t id->x.shmp = p->sharedpixmaps;
+\t if (!p->sharedpixmaps)
+\t id->x.shmp = 0;
--- Imlib/save.c
+++ Imlib/save.c
@@ -345 +345 @@
-\t if (setjmp(png_ptr->jmpbuf))
+\t if (setjmp(png_jmpbuf(png_ptr)))
--- Imlib/utils.c
+++ Imlib/utils.c
@@ -1498,0 +1499 @@
+ memset(lookup, 0, sizeof(lookup));
@@ -1502,0 +1504,15 @@
+ if (!line)
+\tbreak;
+ line = strdup(line);
+ if (!line)
+\tbreak;
+ len = strlen(line);
+ for (i = 0; i < len; ++i)
+\t{
+\t c = line[i];
+\t if (c < 32)
+\t line[i] = 32;
+\t else if (c > 127)
+\t line[i] = 127;
+\t}
+
@@ -1507 +1523 @@
-\t if (ncolors > 32766)
+\t if (ncolors <= 0 || ncolors > 32766)
@@ -1510,0 +1527 @@
+\t free(line);
@@ -1513 +1530 @@
-\t if (cpp > 5)
+\t if (cpp <= 0 || cpp > 5)
@@ -1516,0 +1534 @@
+\t free(line);
@@ -1519 +1537 @@
-\t if (w > 32767)
+\t if (w <= 0 || w > 32767)
@@ -1522,0 +1541 @@
+\t free(line);
@@ -1525 +1544 @@
-\t if (h > 32767)
+\t if (h <= 0 || h > 32767)
@@ -1528,0 +1548 @@
+\t free(line);
@@ -1535,0 +1556 @@
+\t free(line);
@@ -1544,0 +1566 @@
+\t free(line);
@@ -1819,0 +1842 @@
+ free(line);
@@ -1961,2 +1984 @@
-
- if (setjmp(png_ptr->jmpbuf))
+ if (setjmp(png_jmpbuf(png_ptr)))
@@ -1968 +1990 @@
- if (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)
+ if (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_RGB_ALPHA)
--- configure
+++ configure
@@ -22914,2 +22913,0 @@
-CPPFLAGS="$CPPFLAGS -I$includedir -I$prefix/include"
-
--- configure.in
+++ configure.in
@@ -144,2 +143,0 @@
-CPPFLAGS="$CPPFLAGS -I$includedir -I$prefix/include"
-
--- gdk_imlib/io-gif.c
+++ gdk_imlib/io-gif.c
@@ -32,0 +33,3 @@
+#ifdef GIFLIB_MAJOR
+ gif = DGifOpenFileHandle(fd, NULL);
+#else
@@ -33,0 +37 @@
+#endif
@@ -45,0 +50,3 @@
+#ifdef GIFLIB_MAJOR
+\t fprintf(stderr, "giflib error: %s\\n", GifErrorString(gif->Error));
+#else
@@ -46,0 +54 @@
+#endif
@@ -52,0 +61,3 @@
+#ifdef GIFLIB_MAJOR
+\t fprintf(stderr, "giflib error: %s\\n", GifErrorString(gif->Error));
+#else
@@ -53,0 +65 @@
+#endif
@@ -58 +70 @@
-\t if(*h > 32767 || *w > 32767)
+\t if(*h <= 0 || *h > 32767 || *w <= 0 || *w > 32767)
@@ -64,0 +77,3 @@
+#ifdef GIFLIB_MAJOR
+\t DGifCloseFile(gif, NULL);
+#else
@@ -65,0 +81 @@
+#endif
@@ -70,0 +87,3 @@
+#ifdef GIFLIB_MAJOR
+\t DGifCloseFile(gif, NULL);
+#else
@@ -71,0 +91 @@
+#endif
@@ -81,0 +102,3 @@
+#ifdef GIFLIB_MAJOR
+\t\t DGifCloseFile(gif, NULL);
+#else
@@ -82,0 +106 @@
+#endif
@@ -170,0 +195,3 @@
+#ifdef GIFLIB_MAJOR
+ DGifCloseFile(gif, NULL);
+#else
@@ -171,0 +199 @@
+#endif
--- gdk_imlib/io-png.c
+++ gdk_imlib/io-png.c
@@ -43 +43 @@
- if (setjmp(png_ptr->jmpbuf))
+ if (setjmp(png_jmpbuf(png_ptr)))
@@ -49 +49 @@
- if (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)
+ if (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_RGB_ALPHA)
@@ -278 +278 @@
- if (setjmp(png_ptr->jmpbuf))
+ if (setjmp(png_jmpbuf(png_ptr)))
@@ -284 +284 @@
- if (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)
+ if (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_RGB_ALPHA)
@@ -303,0 +304,3 @@
+ if (color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8)
+ png_set_expand(png_ptr);
+
@@ -443 +446 @@
-\tif (setjmp(png_ptr->jmpbuf))
+\tif (setjmp(png_jmpbuf(png_ptr)))
@@ -449 +452 @@
-\tif (info_ptr->color_type == PNG_COLOR_TYPE_RGB_ALPHA)
+\tif (png_get_color_type(png_ptr, info_ptr) == PNG_COLOR_TYPE_RGB_ALPHA)
@@ -638 +641 @@
-\t if (setjmp(png_ptr->jmpbuf))
+\t if (setjmp(png_jmpbuf(png_ptr)))
--- gdk_imlib/io-ppm.c
+++ gdk_imlib/io-ppm.c
@@ -56 +56 @@
-\t if (a > 32767)
+\t if (a <= 0 || a > 32767)
@@ -61 +61 @@
-\t if (b > 32767)
+\t if (b <= 0 || b > 32767)
--- gdk_imlib/io-tiff.c
+++ gdk_imlib/io-tiff.c
@@ -39 +39,3 @@
- if(ww > 32767 || hh > 32767)
+ if (ww <= 0 || ww > 32767 ||
+ hh <= 0 || hh > 32767 ||
+ hh >= (G_MAXINT/sizeof(uint32)) / ww)
--- gdk_imlib/io-xpm.c
+++ gdk_imlib/io-xpm.c
@@ -42,0 +43 @@
+ memset(lookup, 0, sizeof(lookup));
@@ -44,0 +46,3 @@
+ if (!line)
+ return NULL;
+
@@ -73 +77 @@
-\t\t if (ncolors > 32766)
+\t\t if (ncolors <= 0 || ncolors > 32766)
@@ -79 +83 @@
-\t\t if (cpp > 5)
+\t\t if (cpp <= 0 || cpp > 5)
@@ -85 +89 @@
-\t\t if (*w > 32767)
+\t\t if (*w <= 0 || *w > 32767)
@@ -91 +95 @@
-\t\t if (*h > 32767)
+\t\t if (*h <= 0 || *h > 32767)
@@ -122,0 +127 @@
+\t\t int space;
@@ -127,0 +133 @@
+\t\t space = sizeof(col) - 1;
@@ -150,4 +156,4 @@
-\t\t\t\t if (col[0])
-\t\t\t\t\tstrcat(col, " ");
-\t\t\t\t if (strlen(col) + strlen(s) < sizeof(col))
-\t\t\t\t\tstrcat(col, s);
+\t\t\t\t if (col[0] && space > 0)
+\t\t\t\t\tstrncat(col, " ", space), space -= 1;
+\t\t\t\t if (slen <= space)
+\t\t\t\t\tstrcat(col, s), space -= slen;
@@ -183 +189,2 @@
-\t\t\t\t strcpy(tok, s);
+\t\t\t\t if (slen < sizeof(tok))
+\t\t\t\t strcpy(tok, s);
@@ -184,0 +192 @@
+\t\t\t\t space = sizeof(col) - 1;
@@ -188,3 +196,4 @@
-\t\t\t\t if (col[0])
-\t\t\t\t strcat(col, " ");
-\t\t\t\t strcat(col, s);
+\t\t\t\t if (col[0] && space > 0)
+\t\t\t\t strcat(col, " "), space -= 1;
+\t\t\t\t if (slen <= space)
+\t\t\t\t strcat(col, s), space -= slen;
--- gdk_imlib/misc.c
+++ gdk_imlib/misc.c
@@ -676,0 +677,4 @@
+
+ id->x.shm = 0;
+ id->x.shmp = 0;
+ id->max_shm = 0;
@@ -692 +696,2 @@
-\t if (XShmPixmapFormat(id->x.disp) == ZPixmap)
+\t if ((XShmPixmapFormat(id->x.disp) == ZPixmap) &&
+\t\t (pm == True))
@@ -697 +701,0 @@
- else
@@ -699,4 +703 @@
- {
- id->x.shm = 0;
- id->x.shmp = 0;
- }
+
@@ -938,2 +939,2 @@
-\t if (id->x.shm)
-\t id->x.shmp = p->sharedpixmaps;
+\t if (!p->sharedpixmaps)
+\t id->x.shmp = 0;
@@ -1357,0 +1359,2 @@
+ *\twe check G_MAX_INT/4 because rend.c malloc\'s w * h * bpp
+ *\t+ 3 is safety margin
@@ -1362 +1365,3 @@
-\tif( w > 32767 || h > 32767)
+\tif (w <= 0 || w > 32767 ||
+\t h <= 0 || h > 32767 ||
+\t h >= (G_MAXINT/4 - 1) / w)
@@ -1364 +1369 @@
-\treturn malloc(w * h * 3);
+\treturn malloc(w * h * 3 + 3);
@@ -1365,0 +1371 @@
+
--- gdk_imlib/utils.c
+++ gdk_imlib/utils.c
@@ -1238,0 +1239 @@
+ memset(lookup, 0, sizeof(lookup));
@@ -1242,0 +1244,15 @@
+ if (!line)
+\tbreak;
+ line = strdup(line);
+ if (!line)
+\tbreak;
+ len = strlen(line);
+ for (i = 0; i < len; ++i)
+ {
+\t c = line[i];
+\t if (c < 32)
+\t line[i] = 32;
+\t else if (c > 127)
+\t line[i] = 127;
+\t}
+
@@ -1247 +1263 @@
-\t if (ncolors > 32766)
+\t if (ncolors <= 0 || ncolors > 32766)
@@ -1250,0 +1267 @@
+\t free(line);
@@ -1253 +1270 @@
-\t if (cpp > 5)
+\t if (cpp <= 0 || cpp > 5)
@@ -1256,0 +1274 @@
+\t free(line);
@@ -1259 +1277 @@
-\t if (w > 32767)
+\t if (w <= 0 || w > 32767)
@@ -1262,0 +1281 @@
+\t free(line);
@@ -1265 +1284 @@
-\t if (h > 32767)
+\t if (h <= 0 || h > 32767)
@@ -1268,0 +1288 @@
+\t free(line);
@@ -1275,0 +1296 @@
+\t free(line);
@@ -1284,0 +1306 @@
+\t free(line);
@@ -1358 +1380 @@
-\t\t\t if (colptr + ls <= sizeof(col))
+\t\t\t if (colptr + ls < sizeof(col))
@@ -1560,0 +1583 @@
+ free(line);
' | patch -p0
ltoolupdate_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
CFLAGS="$SLKCFLAGS" \
../configure \
--prefix=/usr \
--libdir=/usr/lib$LIBDIRSUFFIX \
--disable-static \
--host=$HOST
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
makepkg_fn
## only need to install to $SYSROOT for the tdegraphics build
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tdegraphics
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## error: /bin/sh: squeeze: command not found
sed -i 's|COMMAND squeeze|COMMAND ./squeeze|' kdvi/CMakeLists.txt
chown_fn
## option to build without the dedicated KolourPaint button in ksnapshot
echo $'--- ksnapshot/ksnapshot.cpp
+++ ksnapshot/ksnapshot.cpp
@@ -84 +83,0 @@
- connect(mainWidget, TQ_SIGNAL(openWithKPClicked()), TQ_SLOT(slotOpenWithKP()));
@@ -135,6 +133,0 @@
- // Check for KolourPaint availability
- KService::Ptr kpaint = KService::serviceByDesktopName("kolourpaint");
- if (!kpaint) {
- mainWidget->btnOpenWithKP->hide();
- }
-
@@ -395,7 +388,0 @@
-void KSnapshot::slotOpenWithKP() {
- KService::Ptr kpaint = KService::serviceByDesktopName("kolourpaint");
- if (kpaint) {
- openWithExternalApp(*kpaint);
- }
-}
-
--- ksnapshot/ksnapshot.h
+++ ksnapshot/ksnapshot.h
@@ -114 +113,0 @@
- void slotOpenWithKP();
--- ksnapshot/ksnapshotwidget.ui
+++ ksnapshot/ksnapshotwidget.ui
@@ -245,14 +244,0 @@
- <widget class="KPushButton">
- <property name="name">
- <cstring>btnOpenWithKP</cstring>
- </property>
- <property name="text">
- <string>Open in &KolourPaint</string>
- </property>
- <property name="whatsThis" stdset="0">
- <string>Click this button to edit the snapshot in KolourPaint.</string>
- </property>
- <property name="iconSet">
- <iconset>"kolourpaint"</iconset>
- </property>
- </widget>
@@ -320,6 +305,0 @@
- <connection>
- <sender>btnOpenWithKP</sender>
- <signal>clicked()</signal>
- <receiver>KSnapshotWidget</receiver>
- <slot>slotOpenWithKPClicked()</slot>
- </connection>
@@ -365 +344,0 @@
- <signal>openWithKPClicked()</signal>
@@ -375 +353,0 @@
- <slot access="protected" specifier="non virtual">slotOpenWithKPClicked()</slot>
--- ksnapshot/ksnapshotwidget.ui.h
+++ ksnapshot/ksnapshotwidget.ui.h
@@ -140,4 +139,0 @@
-void KSnapshotWidget::slotOpenWithKPClicked()
-{
- emit openWithKPClicked();
-}' |patch -p0
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
## If imlib is installed, include kuickshow:
[[ $(ls $SYSROOT/usr/lib$LIBDIRSUFFIX/libImlib.so.*) ]] && KUICKSHOW=ON
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_PAPER="OFF" \
-DWITH_TIFF="OFF" \
-DWITH_OPENEXR="OFF" \
-DWITH_PDF="ON" \
-DBUILD_DOC="ON" \
-DBUILD_TDEFILE_PLUGINS="ON" \
-DBUILD_KUICKSHOW=${KUICKSHOW:-OFF} \
-DBUILD_KPDF="ON" \
-DBUILD_KAMERA="OFF" \
-DBUILD_KSVG="OFF" \
-DBUILD_LIBKSCAN="OFF" \
-DBUILD_KOOKA="OFF" \
-DBUILD_KCOLOREDIT="ON" \
-DBUILD_KDVI="ON" \
-DBUILD_KFAX="ON" \
-DBUILD_KFAXVIEW="ON" \
-DBUILD_KGAMMA="ON" \
-DBUILD_KGHOSTVIEW="ON" \
-DBUILD_TDEICONEDIT="ON" \
-DBUILD_KMRML="OFF" \
-DBUILD_KOLOURPAINT="ON" \
-DBUILD_KPOVMODELER="ON" \
-DBUILD_KRULER="ON" \
-DBUILD_KSNAPSHOT="ON" \
-DBUILD_KVIEW="ON" \
-DBUILD_KVIEWSHELL="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
mangzip_fn
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tdeadmin
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-DBUILD_KCRON="ON" \
-DBUILD_KDAT="ON" \
-DBUILD_KNETWORKCONF="ON" \
-DBUILD_KSYSV="ON" \
-DBUILD_KUSER="ON" \
-DBUILD_LILO_CONFIG="ON" \
-DBUILD_KPACKAGE="ON" \
-DBUILD_TDEFILE_PLUGINS="ON" \
-DBUILD_SECPOLICY="OFF" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=tdmtheme
VERSION=$TDE_VERSION
BUILD=$BUILD
I18N=$I18N
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## set support for additional language(s) as per I18N variable
## but only for languages available with this package
## [need to export LINGUAS to set it as an environment variable for cmake]
[[ $I18N ]] && TRANS=ON && export LINGUAS=$I18N
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-DBUILD_TRANSLATIONS=${TRANS:-"OFF"} \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=knemo
VERSION=$TDE_VERSION
BUILD=$BUILD
I18N=$I18N
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## rename knemo icons to avoid conflict with those in tdeartwork
rename network_ knemo_network_ src/knemod/pics/*png
sed -i -e 's|network_|knemo_network_|g' src/{knemod/interfaceicon,kcm/configdialog}.cpp
## widen text area in Tooltips box to avoid text wrapping
sed -i 's|<tr><td>|<tr><td width=70%>|g' src/knemod/interfacetooltip.cpp
## patch
sed -i 's|Default Gateway" ), LINK_QUALITY|Default Gateway" ), GATEWAY|' src/knemod/interfacetooltip.cpp
## set support for additional language(s) as per I18N variable
## but only for languages available with this package
## [need to export LINGUAS to set it as an environment variable for cmake]
[[ $I18N ]] && TRANS=ON && export LINGUAS=$I18N
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DWITH_GCC_VISIBILITY="ON" \
-DWITH_LIBIW="OFF" \
-DBUILD_DOC="ON" \
-DBUILD_TRANSLATIONS=${TRANS:-"OFF"} \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=krusader
VERSION=$TDE_VERSION
BUILD=$BUILD
I18N=$I18N
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## set support for additional language(s) as per I18N variable
## but only for languages available with this package
langs="";for Lang in $I18N;do [[ -e po/$Lang".po" ]] && langs="$langs $Lang"".po";done
sed -i "s|POFILES =.*$|POFILES =$langs|" po/Makefile.am
langs=$(echo $langs | sed 's|.po||g')
[[ $I18N != *ru* ]] && \
sed -i 's| ru||' doc/Makefile.am
ltoolupdate_fn
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \
MOC=$SYSROOT/x86/tqmoc \
MEINPROC=$INSTALL_TDE/bin/meinproc-x86 \
../configure \
--prefix=$INSTALL_TDE \
--mandir=$INSTALL_TDE/man \
--enable-gcc-hidden-visibility \
--disable-rpath \
--host=$HOST
make $NUMJOBS
make DESTDIR=$PKG install
## remove xgcc paths in package
sed -i "s|$XGCC_DIR/$HOST|/usr|g" $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/t*/*.la
sed -i "s|$SYSROOT||g" $PKG$INSTALL_TDE/lib$LIBDIRSUFFIX/t*/*.la
mangzip_fn
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=kvkbd
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
These patches provide Kvkbd build options
• Use Win keys as modifier keys or for characters set with xmodmap.
• Use alternative text on the num pad keys.
• Show small icons on the buttons.
• Show blank keys where AltGr doesn't produce a character.
## change num-pad keys text
echo $'--- src/MainWidget.cpp
+++ src/MainWidget.cpp
@@ -408 +408 @@
-\tTQString txt[9] = { "Ho\\nme", TQString::fromUtf8("▲"), "Pg\\nUp",
+\tTQString txt[9] = { TQString::fromUtf8("H\u2190"), TQString::fromUtf8("▲"), TQString::fromUtf8("P\u2191"),
@@ -410 +410 @@
-\t\t"End", TQString::fromUtf8("▼"), "Pg\\nDn" };
+\t\tTQString::fromUtf8("E\u2192"), TQString::fromUtf8("▼"), TQString::fromUtf8("P\u2193") };
@@ -453 +453 @@
-\tnuml->setText("Num\\nLock");
+\tnuml->setText(TQString::fromUtf8("\u2116"));
@@ -479 +479 @@
-\tent->setText("En\\nter");
+\tent->setText("Ent");'|patch -p0
## set small icons to better fit on buttons for keyboard used at default size
echo $'--- src/MainWidget.cpp
+++ src/MainWidget.cpp
@@ -380 +380 @@
-\tquit->setPixmap(TQIconSet(SmallIcon("application-exit", TDEIcon::SizeMedium)).pixmap());
+\tquit->setPixmap(TQIconSet(SmallIcon("application-exit")).pixmap());
@@ -391 +391 @@
-\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-backward", TDEIcon::SizeMedium)).pixmap());
+\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-backward")).pixmap());
@@ -396 +396 @@
-\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-forward", TDEIcon::SizeMedium)).pixmap());
+\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-forward")).pixmap());
@@ -561 +561 @@
-\t\tpopup_menu->setPixmap(TQIconSet(SmallIcon("configure", TDEIcon::SizeMedium)).pixmap());
+\t\tpopup_menu->setPixmap(TQIconSet(SmallIcon("configure")).pixmap());
@@ -748 +748 @@
-\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-forward", TDEIcon::SizeMedium)).pixmap());
+\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-forward")).pixmap());
@@ -754 +754 @@
-\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-backward", TDEIcon::SizeMedium)).pixmap());
+\t\textent->setPixmap(TQIconSet(SmallIcon("media-seek-backward")).pixmap());'|patch -p0
## configuration menu
echo $'--- src/MainWidget.cpp
+++ src/MainWidget.cpp
@@ -515 +515 @@
-\t\tm->insertItem ( i18n("Font ..."), this, TQ_SLOT ( chooseFont() ) );
+\t\tm->insertItem ( i18n("Font"), this, TQ_SLOT ( chooseFont() ) );
@@ -520,0 +521 @@
+\t\tm->insertSeparator();
@@ -522 +523 @@
-\t\tm->insertItem ( i18n ("Keys color"), this, TQ_SLOT ( chooseKeysColor() ) );
+\t\tm->insertItem ( i18n ("Key color"), this, TQ_SLOT ( chooseKeysColor() ) );'|patch -p0
## key spacing & sizing
echo $'--- src/MainWidget.cpp
+++ src/MainWidget.cpp
@@ -323 +323 @@
-\tlalt->move ( lwin->x() +lwin->width() +6, sty+ ( 5*35 ) );
+\tlalt->move ( lwin->x() +lwin->width() +5, sty+ ( 5*35 ) );
@@ -340 +340 @@
-\tralt->resize ( 48,30 );
+\tralt->resize ( 50,30 );
@@ -350 +350 @@
-\trwin->resize ( 48,30 );
+\trwin->resize ( 50,30 );
@@ -359 +359 @@
-\tmnu->resize ( 49,30 );
+\tmnu->resize ( 50,30 );
@@ -369 +369 @@
-\trctrl->resize ( 49,30 );
+\trctrl->resize ( 45,30 );
@@ -379 +379 @@
-\tquit->move ( 524,15 );
+\tquit->move ( 526,15 );
@@ -388 +388 @@
-\textent->move (524, 85 );
+\textent->move (526, 85 );
@@ -558 +558 @@
-\t\tpopup_menu->move ( 524,15+35 );
+\t\tpopup_menu->move ( 526,15+35 );
@@ -959 +959 @@
-\tresize ( 96,47 );
+\tresize ( 64,31 );'|patch -p0
## blank character display where AltGr does not provide extra characters
echo $'--- src/VButton.cpp
+++ src/VButton.cpp
@@ -56,6 +56,6 @@
-\tif (c == " ")
-\t{
-\t\t// use normal text in case altGr does not provide extra characters.
-\t\t// This is required at least on US keyboards, where altGr works as Alt.
-\t\tc = nc;
-\t}
+//\tif (c == " ")
+//\t{
+//\t\t// use normal text in case altGr does not provide extra characters.
+//\t\t// This is required at least on US keyboards, where altGr works as Alt.
+//\t\tc = nc;
+//\t}
@@ -74,6 +74,6 @@
-\tif (c == " ")
-\t{
-\t\t// use shift text in case altGr does not provide extra characters.
-\t\t// This is required at least on US keyboards, where altGr works as Alt.
-\t\tc = sc;
-\t}
+//\tif (c == " ")
+//\t{
+//\t\t// use shift text in case altGr does not provide extra characters.
+//\t\t// This is required at least on US keyboards, where altGr works as Alt.
+//\t\tc = sc;
+//\t}'|patch -p0
## generate keycode for Win keys with single click so that they can be used for xmodmap
echo $'--- src/MainWidget.cpp
+++ src/MainWidget.cpp
#
## donʹt lock the LWin button
@@ -317 +317 @@
-\tlwin->setToggleButton ( true );
+\tlwin->setToggleButton ( false );
## generate keycode on click rather than wait for next key-click
@@ -318 +318,2 @@
-\tmod_keys.append ( lwin );
+\tconnect ( lwin, TQ_SIGNAL ( keyClick ( unsigned int ) ), this, TQ_SLOT ( keyPress ( unsigned int ) ) );
+\tother_keys.append( lwin );
#
## donʹt lock the RWin button
@@ -354 +355 @@
-\trwin->setToggleButton ( true );
+\trwin->setToggleButton ( false );
## generate keycode on click rather than wait for next key-click
@@ -355 +356,2 @@
-\tmod_keys.append ( rwin );
+\tconnect ( rwin, TQ_SIGNAL ( keyClick ( unsigned int ) ), this, TQ_SLOT ( keyPress ( unsigned int ) ) );
+\tother_keys.append( rwin );'|patch -p0
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-DBUILD_TRANSLATIONS="OFF" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
There is a help page included with the tde-slackbuilds source which is not practical to add to this build.
It can be added to this package from that source with, if needed, the index.cache.bz2 file built with meinproc.
Translations are also available with the x86_64 build.
close
cd /
PRGNAM=tdebluez
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
## set support for additional language(s) as per I18N variable
## but only for languages available with this package
## [need to export LINGUAS to set it as an environment variable for cmake]
[[ $I18N ]] && TRANS=ON && export LINGUAS=$I18N
## path to configuration file
sed -i "s|trinity|$PLUGIN_INSTALL_DIR|" {README.md,doc/en/tdebluez.docbook}
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DLIB_SUFFIX=$LIBDIRSUFFIX \
-DPLUGIN_INSTALL_DIR=$INSTALL_TDE/lib$LIBDIRSUFFIX/$PLUGIN_INSTALL_DIR \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-DBUILD_TRANSLATIONS=${TRANS:-"OFF"} \
-DBUILD_LIBTDEBLUEZ="ON" \
-DBUILD_TDEIOSLAVE="ON" \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
cd /
PRGNAM=krename
VERSION=$TDE_VERSION
BUILD=$BUILD
TMP=/tmp/build
rm -rf $TMP
PKG=$TMP/package-$PRGNAM
OUTPUT=/tmp
mkdir -p $PKG
mkdir $TMP/tmp-$PRGNAM
untar_fn
sed -i 's| "TQt: 3.3.5"||' doc/man/krename.1
sed -i 's|^TQt.*$|krename \- a batch file renamer|' doc/man/krename.1
sed -i 's|TQt:|krename|' doc/man/krename.1
sed -i '/KDE: 3.4.2/d' doc/man/krename.1
sed -i '/KRename: 3.0.8/d' doc/man/krename.1
sed -i 's|info TQt|info krename|' doc/man/krename.1
## set support for additional language(s) as per I18N variable
## but only for languages available with this package
## [need to export LINGUAS to set it as an environment variable for cmake]
[[ $I18N ]] && TRANS=ON && export LINGUAS=$I18N
chown_fn
cd_builddir_fn
## rm -rf $TMP/tmp-$PRGNAM/$PRGNAM*/build-$PRGNAM/*
cmake-toolchain_fn
cmake \
-D CMAKE_TOOLCHAIN_FILE=./cmake-toolchain.cmake \
-D MOC_EXECUTABLE=$SYSROOT/x86/tqmoc \
-D INTLTOOL_MERGE_EXECUTABLE=$(which intltool-merge) \
-D KDE3_MEINPROC_EXECUTABLE:INTERNAL=$INSTALL_TDE/bin/meinproc-x86 \
-DCMAKE_C_FLAGS="$SLKCFLAGS" \
-DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
-DCMAKE_C_COMPILER=$COMPILER \
-DCMAKE_CXX_COMPILER=$COMPILER_CXX \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=$INSTALL_TDE \
-DCMAKE_MODULE_PATH=$PWD/../cmake/modules \
-DMAN_INSTALL_DIR=$INSTALL_TDE/man \
-DWITH_GCC_VISIBILITY="ON" \
-DBUILD_DOC="ON" \
-DBUILD_TRANSLATIONS=${TRANS:-"OFF"} \
-Wno-dev \
..
make $NUMJOBS
make DESTDIR=$PKG install
mangzip_fn
strip_fn
mkdir_install_fn
doinst_sh_fn
makepkg_fn
## don't need to install this
## installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
## ROOT=$SYSROOT installpkg $OUTPUT/$PRGNAM-$VERSION-$ARM-$BUILD.txz
close
git clone https://github.com/Ray-V/tde-slackbuilds.git
cd tde-slackbuilds
git checkout gh-pages