glib: convert to new package format

Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
Stephan Raue 2013-12-14 17:17:53 +01:00
parent a9cbb0c7ae
commit a1d2a2f718
8 changed files with 107 additions and 243 deletions

View File

@ -26,7 +26,7 @@ PKG_LICENSE="GPL"
PKG_SITE="http://freedesktop.org/wiki/Software/dbus"
PKG_URL="http://dbus.freedesktop.org/releases/dbus-glib/$PKG_NAME-$PKG_VERSION.tar.gz"
PKG_DEPENDS="dbus glib expat"
PKG_BUILD_DEPENDS_HOST="toolchain glib-host dbus:host"
PKG_BUILD_DEPENDS_HOST="toolchain glib:host dbus:host"
PKG_BUILD_DEPENDS_TARGET="toolchain dbus glib expat dbus-glib:host"
PKG_PRIORITY="optional"
PKG_SECTION="devel"

View File

@ -1,59 +0,0 @@
#!/bin/sh
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
. config/options $1
$SCRIPTS/unpack glib
# hack: we need pkg.m4 for autoreconf, but pkgconfig depends on glib so install
# pkg.m4 first
$SCRIPTS/unpack pkg-config
cp $BUILD/pkg-config-*/pkg.m4 $TOOLCHAIN/share/aclocal
setup_toolchain host
export ZLIB_CFLAGS=""
export ZLIB_LIBS=""
export LIBFFI_CFLAGS="-I$ROOT/$TOOLCHAIN/include/libffi"
export LIBFFI_LIBS="-L$ROOT/$TOOLCHAIN/lib -lffi"
cd $BUILD/glib*
do_autoreconf
mkdir -p .build-host && cd .build-host
../configure --host=$HOST_NAME \
--build=$HOST_NAME \
--prefix=$ROOT/$TOOLCHAIN \
--enable-shared \
--disable-static \
--with-gnu-ld \
--with-libiconv=no \
--enable-debug=no \
--disable-man \
--disable-rebuilds \
--disable-gtk-doc \
make
make install
cp -f gobject/.libs/glib-genmarshal $ROOT/$TOOLCHAIN/bin
cp -f gobject/glib-mkenums $ROOT/$TOOLCHAIN/bin

View File

@ -1,36 +0,0 @@
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
PKG_NAME="glib-host"
PKG_VERSION=""
PKG_REV="1"
PKG_ARCH="any"
PKG_LICENSE="LGPL"
PKG_SITE="http://www.gtk.org/"
PKG_URL=""
PKG_DEPENDS=""
PKG_BUILD_DEPENDS="ccache libffi:host libxml2-host zlib:host Python-host"
PKG_PRIORITY="optional"
PKG_SECTION="devel"
PKG_SHORTDESC="glib-host: C support library"
PKG_LONGDESC="GLib is a library which includes support routines for C such as lists, trees, hashes, memory allocation, and many other things."
PKG_IS_ADDON="no"
PKG_AUTORECONF="no"

View File

@ -1,70 +0,0 @@
#!/bin/sh
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
. config/options $1
# glib segfaults with LTO optimization
strip_lto
cd $PKG_BUILD
mkdir -p .build-target && cd .build-target
ac_cv_func_mmap_fixed_mapped='yes' \
ac_cv_func_posix_getpwuid_r='yes' \
ac_cv_func_posix_getgrgid_r='yes' \
ac_cv_func_printf_unix98='yes' \
ac_cv_func_snprintf_c99='yes' \
ac_cv_func_vsnprintf_c99='yes' \
glib_cv_stack_grows='no' \
glib_cv_uscore='no' \
glib_cv_va_val_copy='no' \
../configure --host=$TARGET_NAME \
--build=$HOST_NAME \
--prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--disable-silent-rules \
--disable-debug \
--disable-static \
--enable-shared \
--disable-selinux \
--disable-fam \
--enable-xattr \
--disable-gtk-doc \
--disable-man \
--disable-dtrace \
--disable-systemtap \
--disable-gcov \
--enable-Bsymbolic \
--with-gnu-ld \
--with-threads=posix \
--with-pcre=system \
make
$MAKEINSTALL
mkdir -p $SYSROOT_PREFIX/usr/lib/pkgconfig
cp g*-2.0.pc $SYSROOT_PREFIX/usr/lib/pkgconfig
mkdir -p $SYSROOT_PREFIX/usr/share/aclocal
cp ../m4macros/glib-gettext.m4 $SYSROOT_PREFIX/usr/share/aclocal

View File

@ -1,40 +0,0 @@
#!/bin/sh
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
. config/options $1
mkdir -p $INSTALL/usr/lib
cp -P $PKG_BUILD/.build-target/glib/.libs/libglib*.so* $INSTALL/usr/lib
rm -rf $INSTALL/usr/lib/libglib*.so*T
cp -P $PKG_BUILD/.build-target/gmodule/.libs/libgmodule*.so* $INSTALL/usr/lib
rm -rf $INSTALL/usr/lib/libgmodule*.so*T
cp -P $PKG_BUILD/.build-target/gobject/.libs/libgobject*.so* $INSTALL/usr/lib
rm -rf $INSTALL/usr/lib/libgobject*.so*T
cp -P $PKG_BUILD/.build-target/gthread/.libs/libgthread*.so* $INSTALL/usr/lib
rm -rf $INSTALL/usr/lib/libgthread*.so*T
cp -P $PKG_BUILD/.build-target/gio/.libs/libgio*.so* $INSTALL/usr/lib
rm -rf $INSTALL/usr/lib/libgio*.so*T

View File

@ -1,36 +0,0 @@
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
PKG_NAME="glib"
PKG_VERSION="2.34.3"
PKG_REV="1"
PKG_ARCH="any"
PKG_LICENSE="LGPL"
PKG_SITE="http://www.gtk.org/"
PKG_URL="http://ftp.gnome.org/pub/gnome/sources/glib/2.34/$PKG_NAME-$PKG_VERSION.tar.xz"
PKG_DEPENDS="zlib libffi"
PKG_BUILD_DEPENDS="toolchain zlib libffi pcre glib-host Python-host"
PKG_PRIORITY="optional"
PKG_SECTION="devel"
PKG_SHORTDESC="glib: C support library"
PKG_LONGDESC="GLib is a library which includes support routines for C such as lists, trees, hashes, memory allocation, and many other things."
PKG_IS_ADDON="no"
PKG_AUTORECONF="yes"

View File

@ -0,0 +1,105 @@
################################################################################
# This file is part of OpenELEC - http://www.openelec.tv
# Copyright (C) 2009-2012 Stephan Raue (stephan@openelec.tv)
#
# This Program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This Program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with OpenELEC.tv; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110, USA.
# http://www.gnu.org/copyleft/gpl.html
################################################################################
PKG_NAME="glib"
PKG_VERSION="2.34.3"
PKG_REV="1"
PKG_ARCH="any"
PKG_LICENSE="LGPL"
PKG_SITE="http://www.gtk.org/"
PKG_URL="http://ftp.gnome.org/pub/gnome/sources/glib/2.34/$PKG_NAME-$PKG_VERSION.tar.xz"
PKG_DEPENDS="zlib libffi"
PKG_BUILD_DEPENDS_HOST="ccache libffi:host libxml2-host zlib:host Python-host"
PKG_BUILD_DEPENDS_TARGET="toolchain zlib libffi pcre glib:host Python-host"
PKG_PRIORITY="optional"
PKG_SECTION="devel"
PKG_SHORTDESC="glib: C support library"
PKG_LONGDESC="GLib is a library which includes support routines for C such as lists, trees, hashes, memory allocation, and many other things."
PKG_IS_ADDON="no"
PKG_AUTORECONF="yes"
PKG_CONFIGURE_OPTS_HOST="--with-gnu-ld \
--with-libiconv=no \
--enable-debug=no \
--disable-man \
--disable-rebuilds \
--disable-gtk-doc"
PKG_CONFIGURE_OPTS_TARGET="ac_cv_func_mmap_fixed_mapped=yes \
ac_cv_func_posix_getpwuid_r=yes \
ac_cv_func_posix_getgrgid_r=yes \
ac_cv_func_printf_unix98=yes \
ac_cv_func_snprintf_c99=yes \
ac_cv_func_vsnprintf_c99=yes \
glib_cv_stack_grows=no \
glib_cv_uscore=no \
glib_cv_va_val_copy=no \
--disable-selinux \
--disable-fam \
--enable-xattr \
--disable-gtk-doc \
--disable-man \
--disable-dtrace \
--disable-systemtap \
--disable-gcov \
--enable-Bsymbolic \
--with-gnu-ld \
--with-threads=posix \
--with-pcre=system"
pre_build_host() {
# hack: we need pkg.m4 for autoreconf, but pkgconfig depends on glib so install
# pkg.m4 first
$SCRIPTS/unpack pkg-config
cp $BUILD/pkg-config-*/pkg.m4 $TOOLCHAIN/share/aclocal
}
pre_configure_host() {
export ZLIB_CFLAGS=""
export ZLIB_LIBS=""
export LIBFFI_CFLAGS="-I$ROOT/$TOOLCHAIN/include/libffi"
export LIBFFI_LIBS="-L$ROOT/$TOOLCHAIN/lib -lffi"
}
pre_configure_target() {
# glib segfaults with LTO optimization
strip_lto
}
post_makeinstall_host() {
cp -f gobject/.libs/glib-genmarshal $ROOT/$TOOLCHAIN/bin
cp -f gobject/glib-mkenums $ROOT/$TOOLCHAIN/bin
}
post_makeinstall_target() {
mkdir -p $SYSROOT_PREFIX/usr/lib/pkgconfig
cp g*-2.0.pc $SYSROOT_PREFIX/usr/lib/pkgconfig
mkdir -p $SYSROOT_PREFIX/usr/share/aclocal
cp ../m4macros/glib-gettext.m4 $SYSROOT_PREFIX/usr/share/aclocal
}
post_makeinstall_target() {
rm -rf $INSTALL/usr/bin
rm -rf $INSTALL/usr/lib/gdbus-2.0
rm -rf $INSTALL/usr/lib/glib-2.0
rm -rf $INSTALL/usr/share
}

View File

@ -26,7 +26,7 @@ PKG_LICENSE="LGPL"
PKG_SITE="http://www.gnome.org"
PKG_URL=""
PKG_DEPENDS=""
PKG_BUILD_DEPENDS="toolchain glib-host"
PKG_BUILD_DEPENDS="toolchain glib:host"
PKG_PRIORITY="optional"
PKG_SECTION="other"
PKG_SHORTDESC="libidl: Library for creating trees of CORBA IDL files"