1 |
flameeyes 09/12/26 17:06:02 |
2 |
|
3 |
Modified: ruby-fakegem.eclass |
4 |
Log: |
5 |
Add a variable to explicit further required paths, useful for gems like RedCloth. |
6 |
|
7 |
Revision Changes Path |
8 |
1.8 eclass/ruby-fakegem.eclass |
9 |
|
10 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/ruby-fakegem.eclass?rev=1.8&view=markup |
11 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/ruby-fakegem.eclass?rev=1.8&content-type=text/plain |
12 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/eclass/ruby-fakegem.eclass?r1=1.7&r2=1.8 |
13 |
|
14 |
Index: ruby-fakegem.eclass |
15 |
=================================================================== |
16 |
RCS file: /var/cvsroot/gentoo-x86/eclass/ruby-fakegem.eclass,v |
17 |
retrieving revision 1.7 |
18 |
retrieving revision 1.8 |
19 |
diff -u -r1.7 -r1.8 |
20 |
--- ruby-fakegem.eclass 21 Dec 2009 19:07:38 -0000 1.7 |
21 |
+++ ruby-fakegem.eclass 26 Dec 2009 17:06:02 -0000 1.8 |
22 |
@@ -1,6 +1,6 @@ |
23 |
# Copyright 1999-2009 Gentoo Foundation |
24 |
# Distributed under the terms of the GNU General Public License v2 |
25 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/ruby-fakegem.eclass,v 1.7 2009/12/21 19:07:38 flameeyes Exp $ |
26 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/ruby-fakegem.eclass,v 1.8 2009/12/26 17:06:02 flameeyes Exp $ |
27 |
# |
28 |
# @ECLASS: ruby-fakegem.eclass |
29 |
# @MAINTAINER: |
30 |
@@ -54,6 +54,11 @@ |
31 |
# Binaries to wrap around (relative to the bin/ directory) |
32 |
# RUBY_FAKEGEM_BINWRAP="*" |
33 |
|
34 |
+# @ECLASS-VARIABLE: RUBY_FAKEGEM_REQUIRE_PATHS |
35 |
+# @DESCRIPTION: |
36 |
+# Extra require paths (beside lib) to add to the specification |
37 |
+# RUBY_FAKEGEM_BINWRAP="" |
38 |
+ |
39 |
RUBY_FAKEGEM_NAME="${RUBY_FAKEGEM_NAME:-${PN}}" |
40 |
RUBY_FAKEGEM_VERSION="${RUBY_FAKEGEM_VERSION:-${PV}}" |
41 |
|
42 |
@@ -128,8 +133,14 @@ |
43 |
# In the gemspec, the following values are set: name, version, summary, |
44 |
# homepage, and require_paths=["lib"]. |
45 |
# See RUBY_FAKEGEM_NAME and RUBY_FAKEGEM_VERSION for setting name and version. |
46 |
+# See RUBY_FAKEGEM_REQUIRE_PATHS for setting extra require paths. |
47 |
ruby_fakegem_genspec() { |
48 |
( |
49 |
+ local required_paths="'lib'" |
50 |
+ for path in ${RUBY_FAKEGEM_REQUIRE_PATHS}; do |
51 |
+ required_paths="${required_paths}, '${path}'" |
52 |
+ done |
53 |
+ |
54 |
# We use the _ruby_implementation variable to avoid having stray |
55 |
# copies with different implementations; while for now we're using |
56 |
# the same exact content, we might have differences in the future, |
57 |
@@ -140,7 +151,7 @@ |
58 |
s.version = "${RUBY_FAKEGEM_VERSION}" |
59 |
s.summary = "${DESCRIPTION}" |
60 |
s.homepage = "${HOMEPAGE}" |
61 |
- s.require_paths = ["lib"] |
62 |
+ s.require_paths = [${required_paths}] |
63 |
end |
64 |
EOF |