summaryrefslogtreecommitdiffstats
path: root/arch/extras
diff options
context:
space:
mode:
Diffstat (limited to 'arch/extras')
-rw-r--r--arch/extras/README12
-rw-r--r--arch/extras/autotools_PKGBUILD59
-rwxr-xr-xarch/extras/batchbuild324
-rw-r--r--arch/extras/cmake_PKGBUILD66
4 files changed, 461 insertions, 0 deletions
diff --git a/arch/extras/README b/arch/extras/README
new file mode 100644
index 000000000..d508b327f
--- /dev/null
+++ b/arch/extras/README
@@ -0,0 +1,12 @@
+contents of this directory
+
+ autotools_PKGBUILD: example of PKGBUILD for building
+ trinity components with autotools. Should be used
+ as template for new PKGBUILDS.
+
+ cmake_PKGBUILD: example of PKGBUILD for building
+ trinity components with CMake. Should be used as
+ a template for new PKGBUILDS.
+
+ batchbuild: simple scirpt for batch building trinity
+ components.
diff --git a/arch/extras/autotools_PKGBUILD b/arch/extras/autotools_PKGBUILD
new file mode 100644
index 000000000..da6756f37
--- /dev/null
+++ b/arch/extras/autotools_PKGBUILD
@@ -0,0 +1,59 @@
+# Maintainer: Calvin Morrison <mutantturkey@gmail.com>
+
+pkgname=trinity-pkname
+pkgver=3513
+pkgrel=1
+
+arch=('i686' 'x86_64')
+
+url='http://www.trinitydesktop.org'
+license=('GPL')
+groups=('trinity')
+pkgdesc="Trinity - pkgdesc"
+
+depends=('trinity-kdelibs')
+makedepends=('pkgconfig' 'autoconf' 'automake')
+optdepends=()
+
+provides=($pkgname)
+conflicts=()
+replaces=()
+
+options=('libtool' '!strip')
+
+source=(http://mirror.its.uidaho.edu/pub/trinity/releases/3.5.13/applications/pkname-3.5.13.tar.gz)
+md5sums=('pkgmd5')
+
+_builddir=applications/pkname
+_prefix=/opt/trinity
+
+build() {
+
+ msg "Setting Trinity Environment variables"
+ export LD_LIBRARY_PATH=${_prefix}/lib:${_prefix}/lib/trinity:$LD_LIBRARY_PATH
+ export PKG_CONFIG_PATH=${_prefix}/lib/pkgconfig:${QTDIR}/lib/pkgconfig
+
+ #msg "Patching..."
+ #patch -N -d ${srcdir} -p0 < pkname.patch
+
+ msg "Starting autoconf..."
+ cd "$srcdir/${_builddir}"
+ cp -f "/usr/share/aclocal/libtool.m4" "admin/libtool.m4.in"
+ cp -f "/usr/share/libtool/config/ltmain.sh" "admin/ltmain.sh"
+ make -f admin/Makefile.common
+
+ msg "Starting configure..."
+ ./configure --with-qt-dir=${QTDIR} \
+ --prefix=${_prefix} \
+ --with-extra-includes=${_prefix}/include:/usr/include/dbus-1.0:${_prefix}/include/libkrandr \
+ --with-extra-libs=${_prefix}/lib:${_prefix}/lib/trinity:${_prefix}/pkgconfig
+
+ msg "Building ${pkgname}..."
+ make
+}
+
+package() {
+ msg "Packaging - $pkgname-$pkgver"
+ cd ${srcdir}/${_builddir}
+ make DESTDIR="${pkgdir}" install
+}
diff --git a/arch/extras/batchbuild b/arch/extras/batchbuild
new file mode 100755
index 000000000..01b9a3e05
--- /dev/null
+++ b/arch/extras/batchbuild
@@ -0,0 +1,324 @@
+#!/bin/bash
+
+# some of base things
+version="3.5.13"
+arch=`arch`
+startdir=`pwd`
+binariesdir="${startdir}/binaries-${arch}"
+scriptname=`basename $0`
+
+#usage function
+function usage(){
+ printf "Usage: %s [ OPTIONS ]\n\n" ${scriptname}
+ printf "Options:\n"
+ printf " -a, --all\t\tBuild all binaries.\n"
+ printf " -b, --base\t\tBuild base components.\n"
+ printf " -x, --extras\t\tBuild extras.\n"
+ printf " -d, --deps\t\tBuild external dependencies.\n"
+ printf " -h, --help\t\tDisplay this mesage.\n"
+ printf " -p, --patch [dir]\tPatch PKGBUILDs using patches found in patch folder.\n"
+ printf "\t\t\tThis files should be created manually.\n"
+ printf "\t\t\tPatches should be named after PKGBUILD they correct.\n"
+ printf "\t\t\tExample: kdebase.patch\n"
+ printf "\t\t\tOptionally you can specify patches location (default\n"
+ printf "\t\t\tpatch folder).\n"
+ printf " -c, --dont-clean\tDont remove anything.\n"
+ printf "Note: This script should be run on clean and out-of-box arch\n"
+ printf "installation for the best outcome. There is no need to \n"
+ printf "pull anything needed for building manually.\n"
+ printf "Binaries will be automatically installed as build process\n"
+ printf "progress and gethered in %s dir.\n" ${binariesdir}
+ printf "\e[0;31m THIS SCRIPT SHOULD BE RUN AS ROOT\e[0m\n\n\n"
+ exit 1
+}
+
+function build_pkg(){
+ cd $1
+ makepkg -i $cleanflag -s --noconfirm --asroot
+ cd ..
+}
+
+function patch_pkgbuild(){
+if [ -e ${startdir}/patch/${1}.patch ]; then
+ patch ${1}/PKGBUILD < ${patchdir}/${1}.patch
+fi
+}
+
+# Parse args
+if [ $# -lt 1 ]; then
+ usage
+fi
+
+args=`getopt -o abxdrhp::c \
+ -l all,base,extras,asroot,deps,"help",patch::,dont-clean \
+ -n $scriptname -- "$@"`
+eval set -- "$args"
+while true ; do
+ case "$1" in
+ -a|--all)
+ buildbase=1
+ fetch=1
+ builddeps=1
+ buildextras=1
+ shift 1
+ ;;
+ -b|--base)
+ buildbase=1
+ fetch=1
+ shift 1
+ ;;
+ -x|--extras)
+ buildextras=1
+ fetch=1
+ shift 1
+ ;;
+ -d|--deps)
+ builddeps=1
+ shift 1
+ ;;
+ -h|--help)
+ usage
+ shift 1
+ ;;
+ -p|--patch)
+ patch=1
+ case $2 in
+ "")
+ patchdir=${curdir}/patch/
+ shift 2
+ ;;
+ *)
+ patchdir=${2}
+ shift 2
+ ;;
+ esac
+ ;;
+ -c|--dont-clean)
+ dontclean=1
+ shift 1
+ ;;
+ --) shift ; break ;;
+ esac
+done
+
+if [ ! $dontclean ]; then
+ cleanflag="-c"
+fi
+
+if [ $builddeps ]; then
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "\n\e[0;34mBuilding dependencies form aur\e[0m\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+
+ mkdir deps
+ cd deps
+
+ printf "\n\e[0;34mhal-info\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+
+ wget http://aur.archlinux.org/packages/ha/hal-info/hal-info.tar.gz
+ tar zxvf hal-info.tar.gz
+ build_pkg hal-info
+
+ printf "\n\e[0;34mhal-git\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+
+ wget http://aur.archlinux.org/packages/ha/hal-git/hal-git.tar.gz
+ tar zxvf hal-git.tar.gz
+ build_pkg hal-git
+
+ printf "\n\e[0;34mlibnjb\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+
+ wget http://aur.archlinux.org/packages/li/libnjb/libnjb.tar.gz
+ tar zxvf libnjb.tar.gz
+ build_pkg libnjb
+
+ # gather binaries
+ cd $curdir
+ mkdir -p ${binariesdir}/deps/
+ mv aur/*/*.tar.xz ${binariesdir}/deps/
+ if [ ! $dontclean ]; then
+ rm -r deps
+ fi
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "\e[0;34mFinished building external dependencies\e[0m\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+fi
+
+if [ $fetch ]; then
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "\n\e[0;34mFetching trinity PKGBUILDs\e[0m\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+
+ # fetch PKGBUILD and remove useless things
+ git clone http://scm.trinitydesktop.org/scm/git/tde-packaging
+ cd tde-packaging
+ git submodule init
+ git submodule update
+ rm -r ark debian ubuntu fedora mandriva opensuse redhat slackware README.GIT
+ cd $startdir
+ mv tde-packaging/arch/${version}/* .
+ rm -r tde-packaging
+ if [ ! $buildbase ]; then
+ rm -r trinity-base
+ fi
+ if [ ! $buildextras ]; then
+ rm -r trinity-extras
+ fi
+
+fi
+
+if [ $buildbase ]; then
+ cd trinity-base
+
+ # build
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "Building base trinity components\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+
+ printf "\n\e[0;34mtrinity-qt3\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild qt3
+ fi
+ build_pkg trinity-qt3
+
+ printf "\n\e[0;34mtrinity-pyqt3\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild pyqt3
+ fi
+ build_pkg trinity-pyqt3
+
+ printf "\n\e[0;34mtrinity-tqtinterface\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild tqtinterface
+ fi
+ build_pkg trinity-tqtinterface
+
+ printf "\n\e[0;34mtrinity-arts\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild arts
+ fi
+ build_pkg trinity-arts
+
+ printf "\n\e[0;34mtrinity-dbus-1-qt3\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild dbus-1-qt3
+ fi
+ build_pkg trinity-dbus-1-qt3
+
+ printf "\n\e[0;34mtrinity-dbus-tqt\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild dbus-tqt
+ fi
+ build_pkg trinity-dbus-tqt
+
+ printf "\n\e[0;34mtrinity-dbus-tqt-1\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild dbus-tqt-1
+ fi
+ build_pkg trinity-dbus-tqt-1
+
+ printf "\n\e[0;34mtrinity-kdelibs\e[0m\n\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild kdelibs
+ fi
+ build_pkg trinity-kdelibs
+
+ printf "\n\e[0;34mtrinity-kdebase\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild kdebase
+ fi
+ build_pkg trinity-kdebase
+
+ # gather binaries and clean
+ cd $curdir
+ mkdir -p ${binariesdir}/trinity-base/
+ mv aur/*/*.tar.xz ${binariesdir}/trinity-base/
+ if [ ! $dontclean ]; then
+ rm -r trinity-base
+ fi
+
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "\e[0;34mFinished building base components\e[0m\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+fi
+
+if [ $buildextras ]; then
+
+ cd trinity-extras
+
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "\n\e[0;34mBuilding trinity-extras\e[0m\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+
+ printf "\n\e[0;34mtrinity-amarok\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild amarok
+ fi
+ build_pkg trinity-amarok
+
+ printf "\n\e[0;34mtrinity-gtk-qt-engine\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild gtk-qt-engine
+ fi
+ build_pkg trinity-gtk-qt-engine
+
+ printf "\n\e[0;34mtrinity-kdegraphics\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild kdegraphics
+ fi
+ build_pkg trinity-kdegraphics
+
+ printf "\n\e[0;34mtrinity-kdevelop\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild kdevelop
+ fi
+ build_pkg trinity-kdevelop
+
+ printf "\n\e[0;34mtrinity-konversation\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild konversation
+ fi
+ build_pkg trinity-konversation
+
+ printf "\n\e[0;34mtrinity-kpowersave\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild kpowersave
+ fi
+ build_pkg trinity-kpowersave
+
+ printf "\n\e[0;34mtrinity-amarok\e[0m\n"
+ printf "\e[0;34m%b----------------------------------------\e[0m\n"
+ if [ $patch ]; then
+ patch_pkgbuild qtcurve
+ fi
+ build_pkg trinity-qtcurve
+
+ # gather binaries and clean
+ cd $curdir
+ mkdir -p ${binariesdir}/trinity-extras/
+ mv aur/*/*.tar.xz ${binariesdir}/trinity-extras/
+ if [ ! $dontclean ]; then
+ rm -r trinity-extras
+ fi
+ printf "\e[0;34m=========================================\e[0m\n"
+ printf "\e[0;34mFinished building external dependencies\e[0m\n"
+ printf "\e[0;34m=========================================\e[0m\n"
+fi
+
diff --git a/arch/extras/cmake_PKGBUILD b/arch/extras/cmake_PKGBUILD
new file mode 100644
index 000000000..5ba8e651b
--- /dev/null
+++ b/arch/extras/cmake_PKGBUILD
@@ -0,0 +1,66 @@
+# Maintainer: Calvin Morrison <mutantturkey@gmail.com>
+
+pkgname=trinity-pkname
+pkgver=3513
+pkgrel=1
+
+arch=('i686' 'x86_64')
+
+url='http://www.trinitydesktop.org'
+license=('GPL')
+groups=('trinity-extras')
+pkgdesc="Trinity - pkgdesc"
+
+depends=('trinity-kdelibs')
+makedepends=('pkgconfig' 'cmake' 'imake')
+optdepends=()
+
+provides=($pkgname)
+confilcts=()
+replaces=()
+
+options=('libtool' '!strip')
+
+source=(http://mirror.its.uidaho.edu/pub/trinity/releases/3.5.13/applications/pkname-3.5.13.tar.gz)
+md5sums=('')
+
+_svnmod=applications/kpowersave
+_builddir=build
+_prefix="/opt/trinity"
+
+build() {
+ msg "Setting PATH, CMAKE and Trinity Environment variables"
+ export CMAKE_PREFIX_PATH=${QTDIR}:${_prefix}
+ export CMAKE_INCLUDE_PATH=${QTDIR}/include:${QTDIR}/include/tqt:/usr/include/dbus-1.0:${_prefix}/include:${_prefix}/include/libkrandr
+ export LD_LIBRARY_PATH=${_prefix}/lib:${_prefix}/lib/trinity:$LD_LIBRARY_PATH
+ export PKG_CONFIG_PATH=${_prefix}/lib/pkgconfig:${QTDIR}/lib/pkgconfig
+
+# patch
+# msg "Patching..."
+# patch -N -d ${srcdir} -p0 < ${srcdir}/pkname.patch
+
+ cd $srcdir
+ msg "Creating out-of-source build directory: ${srcdir}/${_builddir}"
+ mkdir -p ${_builddir}
+ cd ${_builddir}
+
+ msg "Starting cmake..."
+ cmake ${srcdir}/${_svnmod} \
+ -DCMAKE_INSTALL_PREFIX=${_prefix} \
+ -DCMAKE_VERBOSE_MAKEFILE=ON \
+ -DQT_VERSION=3 \
+ -DWITH_QT3=ON \
+ -DQTDIR=${QTDIR} \
+ -DQT_DOCDIR=${QTDIR}/man \
+ -DQT_LIBRARY_DIRS=${QTDIR}/lib \
+ -DBUILD_ALL=ON
+
+ msg "Building - $pkgname..."
+ make
+}
+
+package() {
+ msg "Packaging - $pkgname-$pkgver"
+ cd ${srcdir}/${_builddir}
+ make DESTDIR="${pkgdir}" install
+}