1 |
scarabeus 13/03/29 10:02:23 |
2 |
|
3 |
Modified: ChangeLog office-ext-r1.eclass |
4 |
Log: |
5 |
Allow specification of directory where the extensions are. Also allow one package providing multiple oxts correctly. Wrt bug#463536. |
6 |
|
7 |
Revision Changes Path |
8 |
1.757 eclass/ChangeLog |
9 |
|
10 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.757&view=markup |
11 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?rev=1.757&content-type=text/plain |
12 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/ChangeLog?r1=1.756&r2=1.757 |
13 |
|
14 |
Index: ChangeLog |
15 |
=================================================================== |
16 |
RCS file: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v |
17 |
retrieving revision 1.756 |
18 |
retrieving revision 1.757 |
19 |
diff -u -r1.756 -r1.757 |
20 |
--- ChangeLog 28 Mar 2013 12:21:46 -0000 1.756 |
21 |
+++ ChangeLog 29 Mar 2013 10:02:23 -0000 1.757 |
22 |
@@ -1,6 +1,10 @@ |
23 |
# ChangeLog for eclass directory |
24 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
25 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.756 2013/03/28 12:21:46 mgorny Exp $ |
26 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/ChangeLog,v 1.757 2013/03/29 10:02:23 scarabeus Exp $ |
27 |
+ |
28 |
+ 29 Mar 2013; Tomáš Chvátal <scarabeus@g.o> office-ext-r1.eclass: |
29 |
+ Allow specification of directory where the extensions are. Also allow one |
30 |
+ package providing multiple oxts correctly. Wrt bug#463536. |
31 |
|
32 |
28 Mar 2013; Michał Górny <mgorny@g.o> python-utils-r1.eclass: |
33 |
Support obtaining CFLAGS and LIBS for the Python implementation (similarly to |
34 |
|
35 |
|
36 |
|
37 |
1.4 eclass/office-ext-r1.eclass |
38 |
|
39 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/office-ext-r1.eclass?rev=1.4&view=markup |
40 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/office-ext-r1.eclass?rev=1.4&content-type=text/plain |
41 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/office-ext-r1.eclass?r1=1.3&r2=1.4 |
42 |
|
43 |
Index: office-ext-r1.eclass |
44 |
=================================================================== |
45 |
RCS file: /var/cvsroot/gentoo-x86/eclass/office-ext-r1.eclass,v |
46 |
retrieving revision 1.3 |
47 |
retrieving revision 1.4 |
48 |
diff -u -r1.3 -r1.4 |
49 |
--- office-ext-r1.eclass 23 Mar 2013 10:24:42 -0000 1.3 |
50 |
+++ office-ext-r1.eclass 29 Mar 2013 10:02:23 -0000 1.4 |
51 |
@@ -1,6 +1,6 @@ |
52 |
# Copyright 1999-2013 Gentoo Foundation |
53 |
# Distributed under the terms of the GNU General Public License v2 |
54 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/office-ext-r1.eclass,v 1.3 2013/03/23 10:24:42 scarabeus Exp $ |
55 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/office-ext-r1.eclass,v 1.4 2013/03/29 10:02:23 scarabeus Exp $ |
56 |
|
57 |
# @ECLASS: office-ext-r1.eclass |
58 |
# @MAINTAINER: |
59 |
@@ -57,6 +57,16 @@ |
60 |
die "OFFICE_EXTENSIONS variable is not an array." |
61 |
fi |
62 |
|
63 |
+# @ECLASS-VARIABLE: OFFICE_EXTENSIONS_LOCATION |
64 |
+# @DESCRIPTION: |
65 |
+# Path to the extensions location. Defaults to ${DISTDIR}. |
66 |
+# |
67 |
+# Example: |
68 |
+# @CODE |
69 |
+# OFFICE_EXTENSIONS_LOCATION="${S}/unpacked/" |
70 |
+# @CODE |
71 |
+: ${OFFICE_EXTENSIONS_LOCATION:=${DISTDIR}} |
72 |
+ |
73 |
IUSE="" |
74 |
RDEPEND="" |
75 |
|
76 |
@@ -97,12 +107,15 @@ |
77 |
for i in ${OFFICE_EXTENSIONS[@]}; do |
78 |
# Unpack the extensions where required and add case for oxt |
79 |
# which should be most common case for the extensions. |
80 |
- if [[ -f "${DISTDIR}/${i}" ]] ; then |
81 |
+ if [[ -f "${OFFICE_EXTENSIONS_LOCATION}/${i}" ]] ; then |
82 |
case ${i} in |
83 |
*.oxt) |
84 |
- echo ">>> Unpacking "${DISTDIR}/${i}" to ${PWD}" |
85 |
- unzip -qo ${DISTDIR}/${i} |
86 |
- assert "failed unpacking ${DISTDIR}/${i}" |
87 |
+ mkdir -p "${WORKDIR}/${i}/" |
88 |
+ pushd "${WORKDIR}/${i}/" > /dev/null |
89 |
+ echo ">>> Unpacking "${OFFICE_EXTENSIONS_LOCATION}/${i}" to ${PWD}" |
90 |
+ unzip -qo ${OFFICE_EXTENSIONS_LOCATION}/${i} |
91 |
+ assert "failed unpacking ${OFFICE_EXTENSIONS_LOCATION}/${i}" |
92 |
+ popd > /dev/null |
93 |
;; |
94 |
*) unpack ${i} ;; |
95 |
esac |
96 |
@@ -127,11 +140,15 @@ |
97 |
# fixing it myself. |
98 |
insinto /usr/$(get_libdir)/${i}/share/extension/install |
99 |
for j in ${OFFICE_EXTENSIONS[@]}; do |
100 |
- doins ${DISTDIR}/${j} |
101 |
+ doins ${OFFICE_EXTENSIONS_LOCATION}/${j} |
102 |
done |
103 |
else |
104 |
- insinto /usr/$(get_libdir)/${i}/share/extensions/${PN} |
105 |
- doins -r * |
106 |
+ for j in ${OFFICE_EXTENSIONS[@]}; do |
107 |
+ pushd "${WORKDIR}/${j}/" > /dev/null |
108 |
+ insinto /usr/$(get_libdir)/${i}/share/extensions/${j/.oxt/} |
109 |
+ doins -r * |
110 |
+ popd > /dev/null |
111 |
+ done |
112 |
fi |
113 |
fi |
114 |
done |