Add a doruby function to install ruby files in the right place without reinventing...
authorDiego Elio Pettenò <flameeyes@gentoo.org>
Mon, 4 Dec 2006 22:05:53 +0000 (22:05 +0000)
committerDiego Elio Pettenò <flameeyes@gentoo.org>
Mon, 4 Dec 2006 22:05:53 +0000 (22:05 +0000)
eclass/ruby.eclass

index 40a279962d5ba02b4dfe33782db26eb510700cb9..9937a16e4d5a2ebe33151ba816e4053f50679ac0 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2004 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/ruby.eclass,v 1.54 2006/07/07 14:09:47 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/ruby.eclass,v 1.55 2006/12/04 22:05:53 flameeyes Exp $
 #
 # Author: Mamoru KOMACHI <usata@gentoo.org>
 #
@@ -114,6 +114,12 @@ ruby_src_compile() {
        ruby_emake "$@" || die
 }
 
+doruby() {
+       INSDESTTREE="$(${RUBY} -r rbconfig -e 'print Config::CONFIG["sitedir"]')" \
+       INSOPTIONS="-m 0644" \
+       doins "$@" || die "failed to install $@"
+}
+
 ruby_einstall() {
        local siteruby