diff options
author | Koen Kooi <koen@dominion.thruhere.net> | 2011-11-12 12:27:30 +0100 |
---|---|---|
committer | Koen Kooi <koen@dominion.thruhere.net> | 2011-11-12 12:27:30 +0100 |
commit | 5260401eb0cfe37a7358296866b4b43a167817ff (patch) | |
tree | 2ba2c50862f37f0b92805c1c577e096909db244d | |
parent | fee1171c5c99b5d2df873b13da24d4ae0af7a57d (diff) | |
download | meta-openembedded-5260401eb0cfe37a7358296866b4b43a167817ff.tar.gz |
classes: remove duplicate classes
Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
-rw-r--r-- | meta-oe/classes/gnomebase.bbclass | 32 | ||||
-rw-r--r-- | meta-oe/classes/mime.bbclass | 58 | ||||
-rw-r--r-- | meta-oe/classes/qmake_base.bbclass | 105 |
3 files changed, 0 insertions, 195 deletions
diff --git a/meta-oe/classes/gnomebase.bbclass b/meta-oe/classes/gnomebase.bbclass deleted file mode 100644 index 5a332a059..000000000 --- a/meta-oe/classes/gnomebase.bbclass +++ /dev/null | |||
@@ -1,32 +0,0 @@ | |||
1 | def gnome_verdir(v): | ||
2 | import re | ||
3 | m = re.match("^([0-9]+)\.([0-9]+)", v) | ||
4 | return "%s.%s" % (m.group(1), m.group(2)) | ||
5 | |||
6 | SECTION ?= "x11/gnome" | ||
7 | SRC_URI = "${GNOME_MIRROR}/${BPN}/${@gnome_verdir("${PV}")}/${BPN}-${PV}.tar.bz2;name=archive" | ||
8 | |||
9 | DEPENDS += "gnome-common" | ||
10 | |||
11 | FILES_${PN} += "${datadir}/application-registry \ | ||
12 | ${datadir}/mime-info \ | ||
13 | ${datadir}/mime/packages \ | ||
14 | ${datadir}/mime/application \ | ||
15 | ${datadir}/gnome-2.0 \ | ||
16 | ${datadir}/polkit* \ | ||
17 | ${datadir}/GConf \ | ||
18 | ${datadir}/glib-2.0/schemas \ | ||
19 | " | ||
20 | |||
21 | FILES_${PN}-doc += "${datadir}/devhelp" | ||
22 | |||
23 | inherit autotools pkgconfig | ||
24 | |||
25 | AUTOTOOLS_STAGE_PKGCONFIG = "1" | ||
26 | |||
27 | do_install_append() { | ||
28 | rm -rf ${D}${localstatedir}/lib/scrollkeeper/* | ||
29 | rm -rf ${D}${localstatedir}/scrollkeeper/* | ||
30 | rm -f ${D}${datadir}/applications/*.cache | ||
31 | } | ||
32 | |||
diff --git a/meta-oe/classes/mime.bbclass b/meta-oe/classes/mime.bbclass deleted file mode 100644 index d73c2cb11..000000000 --- a/meta-oe/classes/mime.bbclass +++ /dev/null | |||
@@ -1,58 +0,0 @@ | |||
1 | DEPENDS += "shared-mime-info-native shared-mime-info" | ||
2 | |||
3 | EXTRA_OECONF += "--disable-update-mimedb" | ||
4 | |||
5 | mime_postinst() { | ||
6 | if [ "$1" = configure ]; then | ||
7 | if [ -x ${bindir}/update-mime-database ] ; then | ||
8 | echo "Updating MIME database... this may take a while." | ||
9 | update-mime-database $D${datadir}/mime | ||
10 | else | ||
11 | echo "Missing ${bindir}/update-mime-database, update of mime database failed!" | ||
12 | exit 1 | ||
13 | fi | ||
14 | fi | ||
15 | } | ||
16 | |||
17 | mime_postrm() { | ||
18 | if [ "$1" = remove ] || [ "$1" = upgrade ]; then | ||
19 | if [ -x ${bindir}/update-mime-database ] ; then | ||
20 | echo "Updating MIME database... this may take a while." | ||
21 | update-mime-database $D${datadir}/mime | ||
22 | else | ||
23 | echo "Missing ${bindir}/update-mime-database, update of mime database failed!" | ||
24 | exit 1 | ||
25 | fi | ||
26 | fi | ||
27 | } | ||
28 | |||
29 | python ppopulate_packages_append () { | ||
30 | import os.path, re | ||
31 | packages = bb.data.getVar('PACKAGES', d, 1).split() | ||
32 | pkgdest = bb.data.getVar('PKGDEST', d, 1) | ||
33 | |||
34 | for pkg in packages: | ||
35 | mime_dir = '%s/%s/usr/share/mime/packages' % (pkgdest, pkg) | ||
36 | mimes = [] | ||
37 | mime_re = re.compile(".*\.xml$") | ||
38 | if os.path.exists(mime_dir): | ||
39 | for f in os.listdir(mime_dir): | ||
40 | if mime_re.match(f): | ||
41 | mimes.append(f) | ||
42 | if mimes != []: | ||
43 | bb.note("adding mime postinst and postrm scripts to %s" % pkg) | ||
44 | postinst = bb.data.getVar('pkg_postinst_%s' % pkg, d, 1) or bb.data.getVar('pkg_postinst', d, 1) | ||
45 | if not postinst: | ||
46 | postinst = '#!/bin/sh\n' | ||
47 | postinst += bb.data.getVar('mime_postinst', d, 1) | ||
48 | bb.data.setVar('pkg_postinst_%s' % pkg, postinst, d) | ||
49 | postrm = bb.data.getVar('pkg_postrm_%s' % pkg, d, 1) or bb.data.getVar('pkg_postrm', d, 1) | ||
50 | if not postrm: | ||
51 | postrm = '#!/bin/sh\n' | ||
52 | postrm += bb.data.getVar('mime_postrm', d, 1) | ||
53 | bb.data.setVar('pkg_postrm_%s' % pkg, postrm, d) | ||
54 | bb.note("adding freedesktop-mime-info dependency to %s" % pkg) | ||
55 | rdepends = explode_deps(bb.data.getVar('RDEPENDS_' + pkg, d, 0) or bb.data.getVar('RDEPENDS', d, 0) or "") | ||
56 | rdepends.append("freedesktop-mime-info") | ||
57 | bb.data.setVar('RDEPENDS_' + pkg, " " + " ".join(rdepends), d) | ||
58 | } | ||
diff --git a/meta-oe/classes/qmake_base.bbclass b/meta-oe/classes/qmake_base.bbclass deleted file mode 100644 index aa8c05b9d..000000000 --- a/meta-oe/classes/qmake_base.bbclass +++ /dev/null | |||
@@ -1,105 +0,0 @@ | |||
1 | |||
2 | OE_QMAKE_PLATFORM = "${TARGET_OS}-oe-g++" | ||
3 | QMAKESPEC := "${QMAKE_MKSPEC_PATH}/${OE_QMAKE_PLATFORM}" | ||
4 | |||
5 | # We override this completely to eliminate the -e normally passed in | ||
6 | EXTRA_OEMAKE = ' MAKEFLAGS= ' | ||
7 | |||
8 | export OE_QMAKE_CC="${CC}" | ||
9 | export OE_QMAKE_CFLAGS="${CFLAGS}" | ||
10 | export OE_QMAKE_CXX="${CXX}" | ||
11 | export OE_QMAKE_LDFLAGS="${LDFLAGS}" | ||
12 | export OE_QMAKE_AR="${AR}" | ||
13 | export OE_QMAKE_STRIP="echo" | ||
14 | export OE_QMAKE_RPATH="-Wl,-rpath-link," | ||
15 | |||
16 | # do not export STRIP to the environment | ||
17 | STRIP[unexport] = "1" | ||
18 | |||
19 | # default to qte2 via bb.conf, inherit qt3x11 to configure for qt3x11 | ||
20 | |||
21 | oe_qmake_mkspecs () { | ||
22 | mkdir -p mkspecs/${OE_QMAKE_PLATFORM} | ||
23 | for f in ${QMAKE_MKSPEC_PATH}/${OE_QMAKE_PLATFORM}/*; do | ||
24 | if [ -L $f ]; then | ||
25 | lnk=`readlink $f` | ||
26 | if [ -f mkspecs/${OE_QMAKE_PLATFORM}/$lnk ]; then | ||
27 | ln -s $lnk mkspecs/${OE_QMAKE_PLATFORM}/`basename $f` | ||
28 | else | ||
29 | cp $f mkspecs/${OE_QMAKE_PLATFORM}/ | ||
30 | fi | ||
31 | else | ||
32 | cp $f mkspecs/${OE_QMAKE_PLATFORM}/ | ||
33 | fi | ||
34 | done | ||
35 | } | ||
36 | |||
37 | do_generate_qt_config_file() { | ||
38 | export QT_CONF_PATH=${WORKDIR}/qt.conf | ||
39 | cat > ${WORKDIR}/qt.conf <<EOF | ||
40 | [Paths] | ||
41 | Prefix = | ||
42 | Binaries = ${STAGING_BINDIR_NATIVE} | ||
43 | Headers = ${STAGING_INCDIR}/qt4 | ||
44 | Plugins = ${STAGING_LIBDIR}/qt4/plugins/ | ||
45 | Mkspecs = ${STAGING_DATADIR}/qt4/mkspecs/ | ||
46 | EOF | ||
47 | } | ||
48 | |||
49 | addtask generate_qt_config_file after do_patch before do_configure | ||
50 | |||
51 | qmake_base_do_configure() { | ||
52 | case ${QMAKESPEC} in | ||
53 | *linux-oe-g++|*linux-uclibc-oe-g++|*linux-gnueabi-oe-g++|*linux-uclibceabi-oe-g++) | ||
54 | ;; | ||
55 | *-oe-g++) | ||
56 | die Unsupported target ${TARGET_OS} for oe-g++ qmake spec | ||
57 | ;; | ||
58 | *) | ||
59 | bbnote Searching for qmake spec file | ||
60 | paths="${QMAKE_MKSPEC_PATH}/qws/${TARGET_OS}-${TARGET_ARCH}-g++" | ||
61 | paths="${QMAKE_MKSPEC_PATH}/${TARGET_OS}-g++ $paths" | ||
62 | |||
63 | if (echo "${TARGET_ARCH}"|grep -q 'i.86'); then | ||
64 | paths="${QMAKE_MKSPEC_PATH}/qws/${TARGET_OS}-x86-g++ $paths" | ||
65 | fi | ||
66 | for i in $paths; do | ||
67 | if test -e $i; then | ||
68 | export QMAKESPEC=$i | ||
69 | break | ||
70 | fi | ||
71 | done | ||
72 | ;; | ||
73 | esac | ||
74 | |||
75 | bbnote "using qmake spec in ${QMAKESPEC}, using profiles '${QMAKE_PROFILES}'" | ||
76 | |||
77 | if [ -z "${QMAKE_PROFILES}" ]; then | ||
78 | PROFILES="`ls *.pro`" | ||
79 | else | ||
80 | PROFILES="${QMAKE_PROFILES}" | ||
81 | fi | ||
82 | |||
83 | if [ -z "$PROFILES" ]; then | ||
84 | die "QMAKE_PROFILES not set and no profiles found in $PWD" | ||
85 | fi | ||
86 | |||
87 | if [ ! -z "${EXTRA_QMAKEVARS_POST}" ]; then | ||
88 | AFTER="-after" | ||
89 | QMAKE_VARSUBST_POST="${EXTRA_QMAKEVARS_POST}" | ||
90 | bbnote "qmake postvar substitution: ${EXTRA_QMAKEVARS_POST}" | ||
91 | fi | ||
92 | |||
93 | if [ ! -z "${EXTRA_QMAKEVARS_PRE}" ]; then | ||
94 | QMAKE_VARSUBST_PRE="${EXTRA_QMAKEVARS_PRE}" | ||
95 | bbnote "qmake prevar substitution: ${EXTRA_QMAKEVARS_PRE}" | ||
96 | fi | ||
97 | |||
98 | #bbnote "Calling '${OE_QMAKE_QMAKE} -makefile -spec ${QMAKESPEC} -o Makefile $QMAKE_VARSUBST_PRE $AFTER $PROFILES $QMAKE_VARSUBST_POST'" | ||
99 | unset QMAKESPEC || true | ||
100 | ${OE_QMAKE_QMAKE} -makefile -spec ${QMAKESPEC} -o Makefile $QMAKE_VARSUBST_PRE $AFTER $PROFILES $QMAKE_VARSUBST_POST || die "Error calling ${OE_QMAKE_QMAKE} on $PROFILES" | ||
101 | } | ||
102 | |||
103 | EXPORT_FUNCTIONS do_configure | ||
104 | |||
105 | addtask configure after do_unpack do_patch before do_compile | ||