1 |
dirtyepic 10/07/04 20:42:23 |
2 |
|
3 |
Modified: xorg-2.eclass x-modular.eclass |
4 |
Log: |
5 |
Drop cleanup_fonts from xorg eclasses as it's now handled by font.eclass. (bug #315369) |
6 |
|
7 |
Revision Changes Path |
8 |
1.5 eclass/xorg-2.eclass |
9 |
|
10 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/xorg-2.eclass?rev=1.5&view=markup |
11 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/xorg-2.eclass?rev=1.5&content-type=text/plain |
12 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/xorg-2.eclass?r1=1.4&r2=1.5 |
13 |
|
14 |
Index: xorg-2.eclass |
15 |
=================================================================== |
16 |
RCS file: /var/cvsroot/gentoo-x86/eclass/xorg-2.eclass,v |
17 |
retrieving revision 1.4 |
18 |
retrieving revision 1.5 |
19 |
diff -u -r1.4 -r1.5 |
20 |
--- xorg-2.eclass 8 Jun 2010 20:22:12 -0000 1.4 |
21 |
+++ xorg-2.eclass 4 Jul 2010 20:42:22 -0000 1.5 |
22 |
@@ -1,6 +1,6 @@ |
23 |
# Copyright 1999-2010 Gentoo Foundation |
24 |
# Distributed under the terms of the GNU General Public License v2 |
25 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/xorg-2.eclass,v 1.4 2010/06/08 20:22:12 remi Exp $ |
26 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/xorg-2.eclass,v 1.5 2010/07/04 20:42:22 dirtyepic Exp $ |
27 |
# |
28 |
# @ECLASS: xorg-2.eclass |
29 |
# @MAINTAINER: |
30 |
@@ -357,45 +357,10 @@ |
31 |
# task right now is some cleanup for font packages. |
32 |
xorg-2_pkg_postrm() { |
33 |
if [[ -n ${FONT} ]]; then |
34 |
- cleanup_fonts |
35 |
font_pkg_postrm |
36 |
fi |
37 |
} |
38 |
|
39 |
-# @FUNCTION: cleanup_fonts |
40 |
-# @USAGE: |
41 |
-# @DESCRIPTION: |
42 |
-# Get rid of font directories that only contain generated files |
43 |
-cleanup_fonts() { |
44 |
- local allowed_files="encodings.dir fonts.alias fonts.cache-1 fonts.dir fonts.scale" |
45 |
- local real_dir=${EROOT}usr/share/fonts/${FONT_DIR} |
46 |
- local fle allowed_file |
47 |
- |
48 |
- unset KEEP_FONTDIR |
49 |
- |
50 |
- einfo "Checking ${real_dir} for useless files" |
51 |
- pushd ${real_dir} &> /dev/null |
52 |
- for fle in *; do |
53 |
- unset MATCH |
54 |
- for allowed_file in ${allowed_files}; do |
55 |
- if [[ ${fle} = ${allowed_file} ]]; then |
56 |
- # If it's allowed, then move on to the next file |
57 |
- MATCH="yes" |
58 |
- break |
59 |
- fi |
60 |
- done |
61 |
- # If we found a match in allowed files, move on to the next file |
62 |
- [[ -n ${MATCH} ]] && continue |
63 |
- # If we get this far, there wasn't a match in the allowed files |
64 |
- KEEP_FONTDIR="yes" |
65 |
- # We don't need to check more files if we're already keeping it |
66 |
- break |
67 |
- done |
68 |
- popd &> /dev/null |
69 |
- # If there are no files worth keeping, then get rid of the dir |
70 |
- [[ -z "${KEEP_FONTDIR}" ]] && rm -rf ${real_dir} |
71 |
-} |
72 |
- |
73 |
# @FUNCTION: setup_fonts |
74 |
# @USAGE: |
75 |
# @DESCRIPTION: |
76 |
|
77 |
|
78 |
|
79 |
1.119 eclass/x-modular.eclass |
80 |
|
81 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/x-modular.eclass?rev=1.119&view=markup |
82 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/x-modular.eclass?rev=1.119&content-type=text/plain |
83 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/x-modular.eclass?r1=1.118&r2=1.119 |
84 |
|
85 |
Index: x-modular.eclass |
86 |
=================================================================== |
87 |
RCS file: /var/cvsroot/gentoo-x86/eclass/x-modular.eclass,v |
88 |
retrieving revision 1.118 |
89 |
retrieving revision 1.119 |
90 |
diff -u -r1.118 -r1.119 |
91 |
--- x-modular.eclass 9 Dec 2009 10:21:49 -0000 1.118 |
92 |
+++ x-modular.eclass 4 Jul 2010 20:42:22 -0000 1.119 |
93 |
@@ -1,6 +1,6 @@ |
94 |
# Copyright 1999-2005 Gentoo Foundation |
95 |
# Distributed under the terms of the GNU General Public License v2 |
96 |
-# $Header: /var/cvsroot/gentoo-x86/eclass/x-modular.eclass,v 1.118 2009/12/09 10:21:49 vapier Exp $ |
97 |
+# $Header: /var/cvsroot/gentoo-x86/eclass/x-modular.eclass,v 1.119 2010/07/04 20:42:22 dirtyepic Exp $ |
98 |
# |
99 |
# @ECLASS: x-modular.eclass |
100 |
# @MAINTAINER: |
101 |
@@ -498,50 +498,10 @@ |
102 |
# task right now is some cleanup for font packages. |
103 |
x-modular_pkg_postrm() { |
104 |
if [[ -n "${FONT}" ]]; then |
105 |
- cleanup_fonts |
106 |
font_pkg_postrm |
107 |
fi |
108 |
} |
109 |
|
110 |
-# @FUNCTION: cleanup_fonts |
111 |
-# @USAGE: |
112 |
-# @DESCRIPTION: |
113 |
-# Get rid of font directories that only contain generated files |
114 |
-cleanup_fonts() { |
115 |
- local ALLOWED_FILES="encodings.dir fonts.alias fonts.cache-1 fonts.dir fonts.scale" |
116 |
- for DIR in ${FONT_DIR}; do |
117 |
- unset KEEP_FONTDIR |
118 |
- REAL_DIR=${ROOT}usr/share/fonts/${DIR} |
119 |
- |
120 |
- ebegin "Checking ${REAL_DIR} for useless files" |
121 |
- pushd ${REAL_DIR} &> /dev/null |
122 |
- for FILE in *; do |
123 |
- unset MATCH |
124 |
- for ALLOWED_FILE in ${ALLOWED_FILES}; do |
125 |
- if [[ ${FILE} = ${ALLOWED_FILE} ]]; then |
126 |
- # If it's allowed, then move on to the next file |
127 |
- MATCH="yes" |
128 |
- break |
129 |
- fi |
130 |
- done |
131 |
- # If we found a match in allowed files, move on to the next file |
132 |
- if [[ -n ${MATCH} ]]; then |
133 |
- continue |
134 |
- fi |
135 |
- # If we get this far, there wasn't a match in the allowed files |
136 |
- KEEP_FONTDIR="yes" |
137 |
- # We don't need to check more files if we're already keeping it |
138 |
- break |
139 |
- done |
140 |
- popd &> /dev/null |
141 |
- # If there are no files worth keeping, then get rid of the dir |
142 |
- if [[ -z "${KEEP_FONTDIR}" ]]; then |
143 |
- rm -rf ${REAL_DIR} |
144 |
- fi |
145 |
- eend 0 |
146 |
- done |
147 |
-} |
148 |
- |
149 |
# @FUNCTION: setup_fonts |
150 |
# @USAGE: |
151 |
# @DESCRIPTION: |