diff options
-rw-r--r-- | dev-libs/gobject-introspection/Manifest | 2 | ||||
-rw-r--r-- | dev-libs/gobject-introspection/gobject-introspection-1.40.0-r1.ebuild | 180 |
2 files changed, 182 insertions, 0 deletions
diff --git a/dev-libs/gobject-introspection/Manifest b/dev-libs/gobject-introspection/Manifest index a7b1ec5..8a069c1 100644 --- a/dev-libs/gobject-introspection/Manifest +++ b/dev-libs/gobject-introspection/Manifest @@ -1,4 +1,6 @@ DIST gobject-introspection-1.38.0.tar.xz 1226324 SHA256 3575e5d353c17a567fdf7ffaaa7aebe9347b5b0eee8e69d612ba56a9def67d73 SHA512 2eeafbb09484988c8489757232233aa9bf5cefecf7f80ed940867cf721e271644f7e94d8ae3b18717340ba3af1c208701c4766b1113af03972311517fda10e8f WHIRLPOOL 7dbab4e983095a12d6711236cd198473a326b100c67958693edf4a236cab6a922234b0e809d171fac1a2c860e29f7775f74a70589c1e1a124c137769ddd540e0 +DIST gobject-introspection-1.40.0.tar.xz 1286424 SHA256 96ea75e9679083e7fe39a105e810e2ead2d708abf189a5ba420bfccfffa24e98 SHA512 d6cc91be018d812f1b04281bc322b8809c2cc12e5e16adf8b826a82505315ec140ce2b823c107ed98c6dced8f62afb6071eed2702a9e76b0e8e73ad193824c04 WHIRLPOOL b5ab2bb221816802cd3d1d3aedcb6b9b5ea9f516b51b4a3a892de1098d834c78cf94aa3e552dc58f0d2530c032e9ba08b41c24b31992afc4493ac3f0bfdc2f78 EBUILD gobject-introspection-1.38.0-r1.ebuild 5082 SHA256 15bcf66b1c888f6b44d1730ee9b7b7db205c562b3fdb6a14d0c21d1037df7166 SHA512 3b7fc58b6fb3ffdb83a5f5b6264ca8b248681e49aa57f24b1e8443ad98d66fa6e1145c74de9eb3eef8daddad5ba786c5ff801d7635ee038b048c0e16c023eb35 WHIRLPOOL 5620c171a9fb0f3dbf0e4364f555146becd9a7346d5166811d412603c1914ee871a6080985a28b77ba02e77f0ff18dfc3ee809cc63b77a35bb91d6741c4ee8b4 +EBUILD gobject-introspection-1.40.0-r1.ebuild 5082 SHA256 5ed298b6f09bf1755fa1bd2cfe547e31aa341af34688df17a5d8fd36ba87b2dc SHA512 4ff39810b880f28df954271478b61a10b770305bab54d6deb8304f713d2e32a6ed73ec9eba803eee6f4a069aaaa3aae3bb24c4fa2308724ea1ac14491c0d4e35 WHIRLPOOL da5bb0aea79cdf7c1294ddfb26c27251907ed6be59d898629f6123a6f3b84ce5b41c8eecf1d8558ac97d896f0c6519457e52e1a413c26015c37542e9ede86591 MISC ChangeLog 20690 SHA256 76c540459cf1dbc9ff23ddb45a97ddb6128cda6d0c28522157c205a4db732f56 SHA512 c4050d5f767ec3b6d15144d96c8bb5bbbc9125814857c366056289b6562a56fed57496cfd1e9d1e6c6d2107eb5d82bc97bbc2b6ff5c567b4a869c7c715c83ca6 WHIRLPOOL d70109c86b5c4c4a7bf12b773a197671d1c32f39a6448740ba6ad2dda5c90ccb4dafcf8f017b52f497f85271ffd43b657d5dc8b7fa0a8d248e614271759b6d7e MISC metadata.xml 276 SHA256 64896ff5d165a9a750f5e13dfb6ae8ab203c9c5ecf1fe95f5828dca418652cb3 SHA512 69c30c46828ec7f02fde73973d64e48042242a42f7c354fe37297df0653552eed04fac21cabbe385efa9e0d348f70e718afdf328ebdcd203a109761b4b89f99e WHIRLPOOL c527df37fc6657961892dd27b52b8597a54f11f9da01e3acbe7cad6ebaaa6d41364e49bb1635ab5c5e354a8a56e11eae49eff1f394be934cda9322204de4e282 diff --git a/dev-libs/gobject-introspection/gobject-introspection-1.40.0-r1.ebuild b/dev-libs/gobject-introspection/gobject-introspection-1.40.0-r1.ebuild new file mode 100644 index 0000000..bdcf3ca --- /dev/null +++ b/dev-libs/gobject-introspection/gobject-introspection-1.40.0-r1.ebuild @@ -0,0 +1,180 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI="5" +GCONF_DEBUG="no" +PYTHON_COMPAT=( python2_7 ) +PYTHON_REQ_USE="xml" + +inherit python-single-r1 gtk-doc toolchain-funcs gnome2-multilib + +DESCRIPTION="Introspection infrastructure for generating gobject library bindings for various languages" +HOMEPAGE="http://live.gnome.org/GObjectIntrospection/" + +LICENSE="LGPL-2+ GPL-2+" +SLOT="0" +IUSE="cairo doctool test" +REQUIRED_USE=" + ${PYTHON_REQUIRED_USE} + test? ( cairo ) +" +KEYWORDS="~amd64" + +RDEPEND=" + >=dev-libs/gobject-introspection-common-${PV} + >=dev-libs/glib-2.36:2[${MULTILIB_USEDEP}] + doctool? ( dev-python/mako ) + virtual/libffi:=[${MULTILIB_USEDEP}] + !<dev-lang/vala-0.20.0 + ${PYTHON_DEPS} +" +# Wants real bison, not virtual/yacc +DEPEND="${RDEPEND} + >=dev-util/gtk-doc-am-1.19 + sys-devel/bison + sys-devel/flex + virtual/pkgconfig +" +# PDEPEND to avoid circular dependencies, bug #391213 +PDEPEND="cairo? ( x11-libs/cairo[glib,${MULTILIB_USEDEP}] )" + +pkg_setup() { + python-single-r1_pkg_setup +} + +src_configure() { + if ! has_version "x11-libs/cairo[glib,${MULTILIB_USEDEP}]"; then + # Bug #391213: enable cairo-gobject support even if it's not installed + # We only PDEPEND on cairo to avoid circular dependencies + export CAIRO_LIBS="-lcairo -lcairo-gobject" + export CAIRO_CFLAGS="-I${EPREFIX}/usr/include/cairo" + fi + + # To prevent crosscompiling problems, bug #414105 + gnome2-multilib_src_configure \ + --disable-static \ + YACC=$(type -p yacc) \ + $(use_with cairo) \ + $(use_enable doctool) +} + +ehook gnome2-multilib-per-abi-pre_src_configure abi_src_configure +abi_src_configure() { + G2CONF+=( "CC=${CC:-$(tc-getCC)}" ) +} + +############################################################### +# DANGER WILL ROBINSON!!! OBSCENELY INELEGANT HACK AHEAD +# +# this is tricky. the scanner needs to build for the native +# abi, only, or else all hell breaks loose (python trouble). +# So, we very gingerly pre-build those executables, and +# unceremoneously wedge them into the non-native-abi build-trees, +# right where they would have gone, had we allowed the makefile +# to generate them (if it was able to, which it isn't). +# + +_goi_giscanner_build_native() { + pushd "${BUILD_DIR}" >/dev/null || die + emake g-ir-scanner + [[ -x g-ir-scanner ]] || die "Dude, where's my scanner?" + local stuff + # FIXME: use platform independent suffix for library here + find . \( -name '*.so' -o -name '*.la' -o -name '*.o' -o -name 'g-ir-scanner' -o -name '*.lo' -o -name '*.lai' \) \ + -print | sed "s:^:$(pwd) :" > "${T}"/its_for_scanning_things_ldo + popd > /dev/null || die +} + +_goi_giscanner_inject() { + pushd "${BUILD_DIR}" > /dev/null || die + einfo "injecting scanner (darkly) from \"${DEFAULT_ABI}\" build-tree into that of \"${ABI}\"" + [[ -f "${T}"/its_for_scanning_things_ldo ]] || die + local d f dn + cat "${T}"/its_for_scanning_things_ldo | while read d f ; do + [[ -d "${d}" ]] || die "bad source \"${d}\"" + [[ -f "${d}/${f}" ]] || die "bad file \"${d}/${f}\"" + dn=$(dirname "${f}") + [[ ${dn} == . ]] || mkdir -p "${dn}" + # hard link + ln -P ${d}/${f} ./${f} || die + done + popd > /dev/null || die +} + +# +# n.b.: I'm aware that the above was pretty damn evil. +# By all means, let's find some better way to do it! +# It is likely that some vastly better way exists. In +# the meanwhile, the above seems to work. +# -gmt +############################################################### + +_if_is_native_abi() { + if multilib_is_native_abi; then + "$@" + else + return 0 + fi +} + +_if_aint_native_abi() { + if multilib_is_native_abi; then + return 0 + else + "$@" + fi +} + +_for_native_abi_only() { + multilib_parallel_foreach_abi _if_is_native_abi "$@" +} + +_for_nonnative_abis() { + multilib_parallel_foreach_abi _if_aint_native_abi "$@" +} + +src_compile() { + _for_native_abi_only _goi_giscanner_build_native + _for_nonnative_abis _goi_giscanner_inject + + gnome2-multilib_src_compile +} + +src_test() { + multilib_foreach_abi run_in_build_dir abi_src_test +} + +abi_src_test() { + # there seems to be an oot-build bug for tests/warn: + local mysrcdir="${S}"/tests/warn + local mydestdir="${BUILD_DIR}"/tests/warn + ebegin "OOT bug workaround for abi ${ABI}: copying *.h from \"${mysrcdir}\" into \"${mydestdir}\"..." + for f in "${mysrcdir}"/*.h ; do + [[ -f "${f}" ]] && { cp -f "${f}" "${mydestdir}" || die ; } + done + eend + + emake check \ + && einfo "ABI \"${ABI}\" ran the test suite without incident" \ + || { eerror "at least one test for ABI \"${ABI}\" failed" ; die ; } +} + +src_install() { + gnome2-multilib_src_install + + dodoc AUTHORS CONTRIBUTORS ChangeLog NEWS README TODO + # Prevent collision with gobject-introspection-common + rm -v "${ED}"usr/share/aclocal/introspection.m4 \ + "${ED}"usr/share/gobject-introspection-1.0/Makefile.introspection || die + rmdir "${ED}"usr/share/aclocal || die + + + # prevent installation of 64-bit giscanner hacks + _for_nonnative_abis _zap_scanner_files +} + +_zap_scanner_files() { + einfo "zapping scanner files for abi ${ABI}" + rm -rf "${ED}"usr/lib32/gobject-introspection/giscanner || die "failed to zap scanner files" +} |