diff options
43 files changed, 946 insertions, 232 deletions
diff --git a/classes/insane.bbclass b/classes/insane.bbclass index e6f4f1440d..d983af3f9f 100644 --- a/classes/insane.bbclass +++ b/classes/insane.bbclass @@ -58,7 +58,8 @@ def package_qa_get_machine_dict(): "armeb": ( 40, 97, 0, False, True), "powerpc": ( 20, 0, 0, False, True), "mipsel": ( 8, 0, 0, True, True), - "avr32": (6317, 0, 0, False, True), + "avr32": (6317, 0, 0, False, True), + "bfin": ( 0, 0, 0, True, True), }, "linux-gnueabi" : { "arm" : (40, 0, 0, True, True), diff --git a/classes/kernel-arch.bbclass b/classes/kernel-arch.bbclass index 3804cd71b8..9208c3507a 100644 --- a/classes/kernel-arch.bbclass +++ b/classes/kernel-arch.bbclass @@ -12,7 +12,7 @@ valid_archs = "alpha cris ia64 \ m32r mips \ sh sh64 um h8300 \ parisc s390 v850 \ - avr32" + avr32 blackfin" def map_kernel_arch(a, d): import bb, re @@ -24,7 +24,8 @@ def map_kernel_arch(a, d): elif re.match('armeb$', a): return 'arm' elif re.match('mipsel$', a): return 'mips' elif re.match('sh(3|4)$', a): return 'sh' - elif a in valid_archs: return a + elif re.match('bfin', a): return 'blackfin' + elif a in valid_archs: return a else: bb.error("cannot map '%s' to a linux kernel architecture" % a) diff --git a/classes/qmake-base.bbclass b/classes/qmake-base.bbclass index 5ca3ee2904..09694e97b8 100644 --- a/classes/qmake-base.bbclass +++ b/classes/qmake-base.bbclass @@ -23,7 +23,7 @@ export OE_QMAKE_RPATH="-Wl,-rpath-link," # default to qte2 via bb.conf, inherit qt3x11 to configure for qt3x11 export OE_QMAKE_INCDIR_QT="${QTDIR}/include" export OE_QMAKE_LIBDIR_QT="${QTDIR}/lib" -export OE_QMAKE_LIBS_QT="${QT_LIBRARY}" +export OE_QMAKE_LIBS_QT="qte" export OE_QMAKE_LIBS_X11="" oe_qmake_mkspecs () { diff --git a/classes/siteinfo.bbclass b/classes/siteinfo.bbclass index 43a9b55b28..db1dbf19b4 100644 --- a/classes/siteinfo.bbclass +++ b/classes/siteinfo.bbclass @@ -29,8 +29,9 @@ def get_siteinfo_list(d): "arm-linux-gnueabi": "endian-little bit-32 common-glibc arm-common arm-linux",\ "arm-linux-uclibc": "endian-little bit-32 common-uclibc arm-common",\ "arm-linux-uclibcgnueabi": "endian-little bit-32 common-uclibc arm-common arm-linux-uclibc",\ - "avr32-linux": "endian-big bit-32 common-glibc",\ - "avr32-linux-uclibc": "endian-big bit-32 common-uclibc",\ + "avr32-linux": "endian-big bit-32 common-glibc avr32-common",\ + "avr32-linux-uclibc": "endian-big bit-32 common-uclibc avr32-common",\ + "bfin-linux-uclibc": "endian-little bit-32 common-uclibc bfin-common",\ "i386-linux": "endian-little bit-32 common-glibc ix86-common",\ "i486-linux": "endian-little bit-32 common-glibc ix86-common",\ "i586-linux": "endian-little bit-32 common-glibc ix86-common",\ diff --git a/conf/distro/angstrom-2007.1.conf b/conf/distro/angstrom-2007.1.conf index a9e9e0dbd8..059a1ad4bf 100644 --- a/conf/distro/angstrom-2007.1.conf +++ b/conf/distro/angstrom-2007.1.conf @@ -8,7 +8,7 @@ #DISTRO_VERSION = "2007.4" DISTRO_VERSION = "test-${DATE}" -DISTRO_REVISION = "45" +DISTRO_REVISION = "46" require conf/distro/include/angstrom.inc require conf/distro/include/sane-srcdates.inc @@ -143,7 +143,7 @@ PREFERRED_VERSION_file_native = "4.18" PREFERRED_VERSION_fontconfig = "2.4.1" PREFERRED_VERSION_freetype = "2.3.3" PREFERRED_VERSION_freetype-native = "2.2.1" -PREFERRED_VERSION_cairo = "1.4.4" +PREFERRED_VERSION_cairo = "1.4.8" PREFERRED_VERSION_glib-2.0 = "2.12.12" PREFERRED_VERSION_pango = "1.16.4" PREFERRED_VERSION_atk = "1.10.3" @@ -330,4 +330,5 @@ DISTRO_EXTRA_RDEPENDS += "\ DISTRO_EXTRA_RRECOMMENDS += " \ kernel-module-vfat \ kernel-module-ext2 \ + kernel-module-af-packet \ " diff --git a/conf/machine/adsp-bf537-stamp.conf b/conf/machine/adsp-bf537-stamp.conf new file mode 100644 index 0000000000..2a8fd640e7 --- /dev/null +++ b/conf/machine/adsp-bf537-stamp.conf @@ -0,0 +1,18 @@ +#@TYPE: Machine +#@Name: Analog Devices blackfin platfrom +#@DESCRIPTION: ADSP-BF537 STAMP Board + + +TARGET_ARCH = "bfin" + +PREFERRED_PROVIDER_virtual/kernel = "linux" +PREFERRED_PROVIDER_xserver = "xserver-kdrive" + +#don't try to access tty1 +USE_VT = "0" + +MACHINE_FEATURES = "kernel26 alsa ext2 usbhost usbgadget screen" + +# used by sysvinit_2 +SERIAL_CONSOLE = "115200" + diff --git a/conf/sanity.conf b/conf/sanity.conf index 58313f27ca..3a1dec9059 100644 --- a/conf/sanity.conf +++ b/conf/sanity.conf @@ -3,6 +3,6 @@ # See sanity.bbclass # # Expert users can confirm their sanity with "touch conf/sanity.conf" -BB_MIN_VERSION = "1.6.2" +BB_MIN_VERSION = "1.6.8" INHERIT += "sanity" diff --git a/packages/base-files/base-files_3.0.14.bb b/packages/base-files/base-files_3.0.14.bb index 37068780fd..74c4c33711 100644 --- a/packages/base-files/base-files_3.0.14.bb +++ b/packages/base-files/base-files_3.0.14.bb @@ -1,7 +1,7 @@ DESCRIPTION = "Miscellaneous files for the base system." SECTION = "base" PRIORITY = "required" -PR = "r66" +PR = "r68" LICENSE = "GPL" SRC_URI = " \ @@ -80,9 +80,11 @@ do_install () { echo ${hostname} > ${D}${sysconfdir}/hostname fi + install -m 644 ${WORKDIR}/issue* ${D}${sysconfdir} + if [ -n "${DISTRO_NAME}" ]; then - echo -n "${DISTRO_NAME} " > ${D}${sysconfdir}/issue - echo -n "${DISTRO_NAME} " > ${D}${sysconfdir}/issue.net + echo -n "${DISTRO_NAME} " >> ${D}${sysconfdir}/issue + echo -n "${DISTRO_NAME} " >> ${D}${sysconfdir}/issue.net if [ -n "${DISTRO_VERSION}" ]; then echo -n "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue echo -n "${DISTRO_VERSION} " >> ${D}${sysconfdir}/issue.net diff --git a/packages/cairo/cairo_1.4.8.bb b/packages/cairo/cairo_1.4.8.bb new file mode 100644 index 0000000000..845e14fc29 --- /dev/null +++ b/packages/cairo/cairo_1.4.8.bb @@ -0,0 +1,6 @@ +require cairo.inc + +SRC_URI = "http://cairographics.org/releases/cairo-${PV}.tar.gz" + +PR = "r0" + diff --git a/packages/ftpd-topfield/ftpd-topfield_0.7.3.bb b/packages/ftpd-topfield/ftpd-topfield_0.7.4.bb index f86524b8cf..75d963f6da 100755 --- a/packages/ftpd-topfield/ftpd-topfield_0.7.3.bb +++ b/packages/ftpd-topfield/ftpd-topfield_0.7.4.bb @@ -4,8 +4,8 @@ HOMEPAGE = "http://sourceforge.net/projects/puppy" SECTION = "net" LICENSE = "MIT" -SRC_URI = "cvs://anonymous@puppy.cvs.sourceforge.net/cvsroot/puppy;method=pserver;module=ftpd-topfield;tag=FTPD_TOPFIELD_0_7_3 \ - cvs://anonymous@puppy.cvs.sourceforge.net/cvsroot/puppy;method=pserver;module=libtopfield;tag=FTPD_TOPFIELD_0_7_3 \ +SRC_URI = "cvs://anonymous@puppy.cvs.sourceforge.net/cvsroot/puppy;method=pserver;module=ftpd-topfield;tag=FTPD_TOPFIELD_0_7_4 \ + cvs://anonymous@puppy.cvs.sourceforge.net/cvsroot/puppy;method=pserver;module=libtopfield;tag=FTPD_TOPFIELD_0_7_4 \ file://init" # The source will end up in the subdirectory 'ftpd-topfield' - no release name diff --git a/packages/gpsd/files/gpsd b/packages/gpsd/files/gpsd index 289896fb47..2cf26c5f3a 100755 --- a/packages/gpsd/files/gpsd +++ b/packages/gpsd/files/gpsd @@ -16,6 +16,8 @@ GPS_DEV="/dev/ttyS3" RETVAL=0 prog="gpsd" +test -f /etc/default/$prog && . /etc/default/$prog + start() { # Start daemons. echo -n "Starting $prog: " diff --git a/packages/gpsd/gpsd.inc b/packages/gpsd/gpsd.inc index f7c1de2362..7fa05d4716 100644 --- a/packages/gpsd/gpsd.inc +++ b/packages/gpsd/gpsd.inc @@ -10,6 +10,7 @@ EXTRA_OECONF = "--x-includes=${STAGING_INCDIR}/X11 \ --disable-python " SRC_URI = "http://download.berlios.de/gpsd/gpsd-${PV}.tar.gz \ + file://gpsd-default \ file://gpsd" inherit autotools update-rc.d @@ -40,6 +41,8 @@ do_install_append() { install -d ${D}/${sysconfdir}/init.d install -d ${D}/dev install -m 0755 ${WORKDIR}/gpsd ${D}/${sysconfdir}/init.d/ + install -d ${D}/${sysconfdir}/default + install -m 0644 ${WORKDIR}/gpsd-default ${D}/${sysconfdir}/default/gpsd } PACKAGES =+ "libgps" diff --git a/packages/gpsd/gpsd_2.28.bb b/packages/gpsd/gpsd_2.28.bb index 1a5e608aa8..12ef7f47a3 100644 --- a/packages/gpsd/gpsd_2.28.bb +++ b/packages/gpsd/gpsd_2.28.bb @@ -1,2 +1,2 @@ require gpsd.inc -PR = "r1" +PR = "r2" diff --git a/packages/gpsd/gpsd_2.32.bb b/packages/gpsd/gpsd_2.32.bb index 4d07974d6e..1a5e608aa8 100644 --- a/packages/gpsd/gpsd_2.32.bb +++ b/packages/gpsd/gpsd_2.32.bb @@ -1,2 +1,2 @@ require gpsd.inc -PR = "r0" +PR = "r1" diff --git a/packages/gpsd/gpsd_2.33.bb b/packages/gpsd/gpsd_2.33.bb index f61c613eb8..02aef515da 100644 --- a/packages/gpsd/gpsd_2.33.bb +++ b/packages/gpsd/gpsd_2.33.bb @@ -2,4 +2,4 @@ require gpsd.inc DEPENDS = "ncurses" -PR = "r0" +PR = "r1" diff --git a/packages/gpsd/gpsd_2.34.bb b/packages/gpsd/gpsd_2.34.bb index 58e9ebeee2..885a41dbda 100644 --- a/packages/gpsd/gpsd_2.34.bb +++ b/packages/gpsd/gpsd_2.34.bb @@ -1,3 +1,3 @@ require gpsd.inc -PR = "r0" +PR = "r1" diff --git a/packages/gspcav1/gspcav1_20070110.bb b/packages/gspcav1/gspcav1_20070110.bb index 86cb1010df..e1fc443d36 100644 --- a/packages/gspcav1/gspcav1_20070110.bb +++ b/packages/gspcav1/gspcav1_20070110.bb @@ -4,7 +4,9 @@ PRIORITY = "optional" SECTION = "kernel/modules" LICENSE = "GPL" -SRC_URI = "http://mxhaard.free.fr/spca50x/Download/${PN}-${PV}.tar.gz \ +PR = "r1" + +SRC_URI = "http://mxhaard.free.fr/spca50x/Download/oldrelease/${PN}-${PV}.tar.gz \ file://Makefile.patch;patch=1 \ file://MS.patch;patch=1" diff --git a/packages/gspcav1/gspcav1_20070508.bb b/packages/gspcav1/gspcav1_20070508.bb new file mode 100644 index 0000000000..e1fc443d36 --- /dev/null +++ b/packages/gspcav1/gspcav1_20070508.bb @@ -0,0 +1,27 @@ +DESCRIPTION = "USB Webcam driver for spca5xx chipset family supporting \ +over 100 models of camera" +PRIORITY = "optional" +SECTION = "kernel/modules" +LICENSE = "GPL" + +PR = "r1" + +SRC_URI = "http://mxhaard.free.fr/spca50x/Download/oldrelease/${PN}-${PV}.tar.gz \ + file://Makefile.patch;patch=1 \ + file://MS.patch;patch=1" + +S = "${WORKDIR}/${PN}-${PV}" + +inherit module + +do_compile () { + unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS + oe_runmake 'KERNELDIR=${STAGING_KERNEL_DIR}' \ + 'CC=${KERNEL_CC}' \ + 'LD=${KERNEL_LD}' +} + +do_install() { + install -d ${D}${base_libdir}/modules/${KERNEL_VERSION}/kernel/drivers/usb/media + install -m 0644 *${KERNEL_OBJECT_SUFFIX} ${D}${base_libdir}/modules/${KERNEL_VERSION}/kernel/drivers/usb/media +} diff --git a/packages/images/angstrom-minimal-image.bb b/packages/images/angstrom-minimal-image.bb index 90f46a1e01..c79bff25e2 100644 --- a/packages/images/angstrom-minimal-image.bb +++ b/packages/images/angstrom-minimal-image.bb @@ -1,15 +1,11 @@ #Angstrom minimalist image #gives you a small images with ssh access LICENSE = "MIT" -PR = "r0" +PR = "r1" ANGSTROM_EXTRA_INSTALL ?= "" DISTRO_SSH_DAEMON ?= "dropbear" -DEPENDS = "task-base \ - ${DISTRO_SSH_DAEMON} \ - " - RDEPENDS = "task-boot \ ${DISTRO_SSH_DAEMON} \ " diff --git a/packages/iperf/iperf_2.0.2.bb b/packages/iperf/iperf_2.0.2.bb index 357ac19dd0..c54bafe70d 100644 --- a/packages/iperf/iperf_2.0.2.bb +++ b/packages/iperf/iperf_2.0.2.bb @@ -13,6 +13,7 @@ S="${WORKDIR}/iperf-${PV}" # --disable-threads is needed on epia/x86 with uclibc do_configure() { + gnu-configize oe_runconf --exec-prefix=${STAGING_DIR} --disable-threads } diff --git a/packages/linux-libc-headers/linux-libc-headers_2.6.20.bb b/packages/linux-libc-headers/linux-libc-headers_2.6.20.bb index 5bad9fedae..8145a80f8d 100644 --- a/packages/linux-libc-headers/linux-libc-headers_2.6.20.bb +++ b/packages/linux-libc-headers/linux-libc-headers_2.6.20.bb @@ -26,6 +26,7 @@ set_arch() { sparc*) ARCH=sparc ;; x86_64*) ARCH=x86_64 ;; avr32*) ARCH=avr32 ;; + bfin*) ARCH=blackfin ;; esac } diff --git a/packages/linux/linux-magicbox_2.6.19.2.bb b/packages/linux/linux-magicbox_2.6.19.2.bb index 4e07abdfb2..438eaac478 100644 --- a/packages/linux/linux-magicbox_2.6.19.2.bb +++ b/packages/linux/linux-magicbox_2.6.19.2.bb @@ -1,7 +1,9 @@ +# Copyright (C) 2007, Stelios Koroneos - Digital OPSiS, All Rights Reserved +# Released under the MIT license (see packages/COPYING) SECTION = "kernel" DESCRIPTION = "Linux kernel for Magicbox ver 1.1 and 2.0 router boards" LICENSE = "GPL" -PR = "r2" +PR = "r3" DEPENDS = "u-boot" COMPATIBLE_MACHINE = "magicbox" @@ -86,16 +88,17 @@ do_stage_append () { do_install_append () { - install -d ${DEPLOY_DIR}/images - install -m 0755 arch/ppc/boot/images/zImage.elf ${DEPLOY_DIR}/images/${KERNEL_IMAGETYPE}-${PV}-${MACHINE}-${DATETIME}.elf - install -m 0755 vmlinux ${DEPLOY_DIR}/images/ - powerpc${TARGET_VENDOR}-${TARGET_OS}-objcopy -O binary -R .note -R .comment -S ${DEPLOY_DIR}/images/vmlinux ${DEPLOY_DIR}/images/linux.bin - gzip -f -9 ${DEPLOY_DIR}/images/linux.bin - cp -a ${DEPLOY_DIR}/images/linux.bin.gz ${DEPLOY_DIR}/images/linux-${PV}-${MACHINE}-${DATETIME}.bin.gz + install -d ${DEPLOY_DIR_IMAGE} + install -m 0755 arch/ppc/boot/images/zImage.elf ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${PV}-${MACHINE}-${DATETIME}.elf + install -m 0755 vmlinux ${DEPLOY_DIR_IMAGE}/ + powerpc${TARGET_VENDOR}-${TARGET_OS}-objcopy -O binary -R .note -R .comment -S ${DEPLOY_DIR_IMAGE}/vmlinux \ + ${DEPLOY_DIR_IMAGE}/linux.bin + gzip -f -9 ${DEPLOY_DIR_IMAGE}/linux.bin + cp -a ${DEPLOY_DIR_IMAGE}/linux.bin.gz ${DEPLOY_DIR_IMAGE}/linux-${PV}-${MACHINE}-${DATETIME}.bin.gz mkimage -A ppc -O linux -T kernel -C gzip -a 00000000 -e 00000000 -n "magicbox"-${PV} \ - -d ${DEPLOY_DIR}/images/linux.bin.gz ${DEPLOY_DIR}/images/uImage-${PV}-${MACHINE}-${DATETIME}.bin - rm ${DEPLOY_DIR}/images/vmlinux - rm ${DEPLOY_DIR}/images/linux.bin.gz + -d ${DEPLOY_DIR_IMAGE}/linux.bin.gz ${DEPLOY_DIR_IMAGE}/uImage-${PV}-${MACHINE}-${DATETIME}.bin + rm ${DEPLOY_DIR_IMAGE}/vmlinux + rm ${DEPLOY_DIR_IMAGE}/linux.bin.gz } diff --git a/packages/lua/lua.inc b/packages/lua/lua.inc index a03bf8ff22..b713825f00 100644 --- a/packages/lua/lua.inc +++ b/packages/lua/lua.inc @@ -3,10 +3,16 @@ for extending applications." LICENSE = "MIT" HOMEPAGE = "http://www.lua.org/" -PACKAGES = "${PN} liblua ${PN}-doc liblua-dev \ - liblualib liblualib-dev" -FILES_${PN} = "${bindir}/lua ${bindir}/luac" -FILES_${PN}-doc = "${mandir}/man1/lua.1 ${mandir}/man1/luac.1" +PACKAGES = "liblua-dbg liblualib-dbg ${PN}-dbg \ +liblua-dev liblua liblualib-dev liblualib ${PN}-doc ${PN}" + +FILES_${PN}-dbg = "${bindir}/.debug" +FILES_liblua-dbg = "${libdir}/.debug/liblua.so.*" +FILES_liblualib-dbg = "${libdir}/.debug/liblualib.so.*" + +FILES_${PN} = "${bindir}" +FILES_${PN}-doc = "${mandir}" + FILES_liblua = "${libdir}/liblua.so.*" FILES_liblua-dev = "${libdir}/liblua.so ${libdir}/liblua.a \ ${includedir}/lua.h" diff --git a/packages/lua/lua_5.0.2.bb b/packages/lua/lua_5.0.2.bb index 6dbb656166..bb989c04d9 100644 --- a/packages/lua/lua_5.0.2.bb +++ b/packages/lua/lua_5.0.2.bb @@ -1,7 +1,7 @@ require lua.inc DEPENDS += "readline" -PR = "r3" +PR = "r4" SRC_URI = "http://www.lua.org/ftp/lua-${PV}.tar.gz \ file://debian.patch;patch=1 \ file://make.patch;patch=1 \ diff --git a/packages/meta/meta-toolchain.bb b/packages/meta/meta-toolchain.bb index 35dbe9f4cb..1fa80f7d6d 100644 --- a/packages/meta/meta-toolchain.bb +++ b/packages/meta/meta-toolchain.bb @@ -22,25 +22,31 @@ TARGET_INSTALL = "\ RDEPENDS = "${TARGET_INSTALL} ${HOST_INSTALL}" -do_populate_sdk() { - touch ${DEPLOY_DIR_IPK}/Packages - ipkg-make-index -r ${DEPLOY_DIR_IPK}/Packages -p ${DEPLOY_DIR_IPK}/Packages -l ${DEPLOY_DIR_IPK}/Packages.filelist -m ${DEPLOY_DIR_IPK} +sdk_ipk_do_indexes () { + set -ex + rootfs_ipk_do_indexes + set +ex +} +do_populate_sdk() { + sdk_ipk_do_indexes rm -rf ${SDK_OUTPUT} mkdir -p ${SDK_OUTPUT} + echo "Creating host.conf..." + cat <<EOF >${SDK_DIR}/ipkg-host.conf -src oe file:${DEPLOY_DIR_IPK} +src oe file:${DEPLOY_DIR_IPK}/${BUILD_ARCH} arch ${BUILD_ARCH} 1 EOF - cat <<EOF >${SDK_DIR}/ipkg-target.conf -src oe file:${DEPLOY_DIR_IPK} -EOF - ipkgarchs="${PACKAGE_ARCHS}" + echo "done." priority=1 for arch in $ipkgarchs; do echo "arch $arch $priority" >> ${SDK_DIR}/ipkg-target.conf - priority=$(expr $priority + 5) + priority=$(expr $priority + 5) + if [ -e ${DEPLOY_DIR_IPK}/$arch/Packages ] ; then + echo "src oe-$arch file:${DEPLOY_DIR_IPK}/$arch" >> ${SDK_DIR}/ipkg-target.conf + fi done rm -r ${SDK_OUTPUT} diff --git a/packages/netbase/netbase/interfaces b/packages/netbase/netbase/interfaces index e6a4574aa9..c9b2faf3f8 100644 --- a/packages/netbase/netbase/interfaces +++ b/packages/netbase/netbase/interfaces @@ -28,7 +28,7 @@ iface wlan0 inet dhcp # wireless-key s:My-PlainText-Password # wireless-mode managed # -# A WPA encrypted connection locked to a specific access point. +# A WPA1 or WPA2 encrypted connection locked to a specific access point. # The WLAN cards firmware is updated temporarily to allow WPA # connections. Your card may or may not need the update. # diff --git a/packages/netbase/netbase_4.21.bb b/packages/netbase/netbase_4.21.bb index ba5d95b287..6851ae8d9a 100644 --- a/packages/netbase/netbase_4.21.bb +++ b/packages/netbase/netbase_4.21.bb @@ -2,7 +2,7 @@ DESCRIPTION = "This package provides the necessary \ infrastructure for basic TCP/IP based networking." SECTION = "base" LICENSE = "GPL" -PR = "r17" +PR = "r18" inherit update-rc.d diff --git a/packages/opie-reader/files/qt4.patch b/packages/opie-reader/files/qt4.patch index 82f3b9fdd1..f19000f12f 100644 --- a/packages/opie-reader/files/qt4.patch +++ b/packages/opie-reader/files/qt4.patch @@ -27,20 +27,36 @@ index 45aa045..c67db9e 100644 Bkmk::Bkmk(const tchar* _nm, const tchar* _anno, unsigned int _p) : m_position(_p) diff --git a/BuffDoc.cpp b/BuffDoc.cpp -index 355d14d..8c1eadc 100644 +index 355d14d..170ed43 100644 --- a/BuffDoc.cpp +++ b/BuffDoc.cpp -@@ -682,7 +682,8 @@ int BuffDoc::openfile(QWidget* _parent, const char *src) +@@ -23,6 +23,8 @@ + #include "Reb.h" #endif - codecpath += "/plugins/reader/codecs"; + ++#include "uqtcommon.h" ++ + + linkType BuffDoc::hyperlink(unsigned int n, unsigned int noff, QString& wrd, QString& nm) + { +@@ -674,35 +676,19 @@ int BuffDoc::openfile(QWidget* _parent, const char *src) + } + // //qDebug("Doing final open:%x:%x",exp,filt); #else +-#ifdef USEQPE +-#ifdef OPIE +- QString codecpath(getenv("OPIEDIR")); +-#else +- QString codecpath(getenv("QTDIR")); +-#endif +- codecpath += "/plugins/reader/codecs"; +-#else - QString codecpath(getenv("READERDIR")); -+ const char *rd = getenv("READERDIR"); -+ QString codecpath(rd?rd:"/usr/lib/uqtreader"); - codecpath += "/codecs"; - #endif - QDir d(codecpath, "*.so"); -@@ -690,19 +691,14 @@ int BuffDoc::openfile(QWidget* _parent, const char *src) +- codecpath += "/codecs"; +-#endif +- QDir d(codecpath, "*.so"); ++ QDir d(uqt_codecspath(), "*.so"); + if (d.exists()) { @@ -217,19 +233,37 @@ index 78d3eeb..c74c560 100644 QComboBox* colorbox; public: diff --git a/CFilter.cpp b/CFilter.cpp -index a4ea60a..4baa890 100644 +index a4ea60a..84fa451 100644 --- a/CFilter.cpp +++ b/CFilter.cpp -@@ -673,7 +673,8 @@ ExternFilter::ExternFilter(const QString& nm, const QString& optional) : filt(NU - #endif - filterpath += "/plugins/reader/filters/lib"; - #else +@@ -9,6 +9,7 @@ + #include "CDrawBuffer.h" + #include "CFilter.h" + #include "hrule.h" ++#include "uqtcommon.h" + + #include <qregexp.h> + #include <qimage.h> +@@ -665,17 +666,8 @@ class ErrorFilter : public CFilter + #ifndef __STATIC + ExternFilter::ExternFilter(const QString& nm, const QString& optional) : filt(NULL), handle(NULL) + { +-#ifdef USEQPE +-#ifdef OPIE +- QString filterpath(getenv("OPIEDIR")); +-#else +- QString filterpath(getenv("QTDIR")); +-#endif +- filterpath += "/plugins/reader/filters/lib"; +-#else - QString filterpath(getenv("READERDIR")); -+ const char *rd = getenv("READERDIR"); -+ QString filterpath(rd?rd:"/usr/lib/uqtreader"); - filterpath += "/filters/lib"; - #endif +- filterpath += "/filters/lib"; +-#endif ++ QString filterpath = uqt_filterspath(); ++ filterpath += "lib"; filterpath += nm; + filterpath += ".so"; + if (QFile::exists(filterpath)) diff --git a/CHM.cpp b/CHM.cpp index ace5abc..3c325bb 100644 --- a/CHM.cpp @@ -281,7 +315,7 @@ index 54aaf1c..84609f5 100644 class QVBoxLayout; class QHBoxLayout; diff --git a/FontControl.cpp b/FontControl.cpp -index 08b8c52..b80dd6e 100644 +index 08b8c52..0be54ba 100644 --- a/FontControl.cpp +++ b/FontControl.cpp @@ -1,4 +1,5 @@ @@ -302,6 +336,63 @@ index 08b8c52..b80dd6e 100644 if (sizes.count() == 0) { return false; +@@ -65,3 +66,25 @@ bool FontControl::ChangeFont(QString& n, int tgt) + } + return true; + } ++ ++void FontControl::setCourier() { ++ setCourier(m_fontname); ++} ++void FontControl::setCourier(const QString fn) { ++ QFontDatabase fdb; ++ QStringList fl = fdb.families(); ++ setCourier(fn,fl); ++} ++void FontControl::setCourier(const QString fn,const QStringList fl) { ++ QString fp; ++ int sp = fn.indexOf(' '); ++ if(sp>=0) fp = fn.left(sp); ++ for(QStringList::const_iterator i=fl.begin();i!=fl.end();++i) { ++ if( ++ ( i->startsWith(fn,Qt::CaseInsensitive) ++ || ( (!fp.isEmpty()) && i->startsWith(fp,Qt::CaseInsensitive) ) ) ++ && ( i->endsWith("mono",Qt::CaseInsensitive) ++ || i->endsWith("Fixed") ) ) ++ hasCourier(true,*i); ++ } ++} +diff --git a/FontControl.h b/FontControl.h +index 563e1a8..c7a54ab 100644 +--- a/FontControl.h ++++ b/FontControl.h +@@ -2,6 +2,7 @@ + #define __FONTCONTROL_H + + #include <qfontmetrics.h> ++#include <QFontDatabase> + #include "StyleConsts.h" + + class FontControl +@@ -32,6 +33,7 @@ class FontControl + m_fontsizes(NULL), m_hasCourier(false), m_leading(0), |
