| 1 | # Copyright 1999-2009 Gentoo Foundation |
1 | # Copyright 1999-2009 Gentoo Foundation |
| 2 | # Distributed under the terms of the GNU General Public License v2 |
2 | # Distributed under the terms of the GNU General Public License v2 |
| 3 | # $Header: /var/cvsroot/gentoo-x86/eclass/ruby-ng.eclass,v 1.21 2010/07/08 04:00:57 flameeyes Exp $ |
3 | # $Header: /var/cvsroot/gentoo-x86/eclass/ruby-ng.eclass,v 1.22 2010/07/14 13:11:51 flameeyes Exp $ |
| 4 | # |
4 | # |
| 5 | # @ECLASS: ruby-ng.eclass |
5 | # @ECLASS: ruby-ng.eclass |
| 6 | # @MAINTAINER: |
6 | # @MAINTAINER: |
| 7 | # Ruby herd <ruby@gentoo.org> |
7 | # Ruby herd <ruby@gentoo.org> |
| 8 | # |
8 | # |
| … | |
… | |
| 395 | local libruby_soname=$(scanelf -qS "/usr/$(get_libdir)/${libruby_basename}" | awk '{ print $1 }') |
395 | local libruby_soname=$(scanelf -qS "/usr/$(get_libdir)/${libruby_basename}" | awk '{ print $1 }') |
| 396 | local sitedir=$(${RUBY} -rrbconfig -e 'puts Config::CONFIG["sitedir"]') |
396 | local sitedir=$(${RUBY} -rrbconfig -e 'puts Config::CONFIG["sitedir"]') |
| 397 | local sitelibdir=$(${RUBY} -rrbconfig -e 'puts Config::CONFIG["sitelibdir"]') |
397 | local sitelibdir=$(${RUBY} -rrbconfig -e 'puts Config::CONFIG["sitelibdir"]') |
| 398 | |
398 | |
| 399 | # Look for wrong files in sitedir |
399 | # Look for wrong files in sitedir |
| 400 | if [[ -d "${D}${sitedir}" ]]; then |
400 | # if [[ -d "${D}${sitedir}" ]]; then |
| 401 | local f=$(find "${D}${sitedir}" -mindepth 1 -maxdepth 1 -not -wholename "${D}${sitelibdir}") |
401 | # local f=$(find "${D}${sitedir}" -mindepth 1 -maxdepth 1 -not -wholename "${D}${sitelibdir}") |
| 402 | if [[ -n ${f} ]]; then |
402 | # if [[ -n ${f} ]]; then |
| 403 | eerror "Found files in sitedir, outsite sitelibdir:" |
403 | # eerror "Found files in sitedir, outsite sitelibdir:" |
| 404 | eerror "${f}" |
404 | # eerror "${f}" |
| 405 | die "Misplaced files in sitedir" |
405 | # die "Misplaced files in sitedir" |
| 406 | fi |
406 | # fi |
| 407 | fi |
407 | # fi |
| 408 | |
408 | |
| 409 | # The current implementation lacks libruby (i.e.: jruby) |
409 | # The current implementation lacks libruby (i.e.: jruby) |
| 410 | [[ -z ${libruby_soname} ]] && return 0 |
410 | [[ -z ${libruby_soname} ]] && return 0 |
| 411 | |
411 | |
| 412 | scanelf -qnR "${D}${sitedir}" \ |
412 | scanelf -qnR "${D}${sitedir}" \ |