author | eilers <eilers> | 2003-11-03 16:52:18 (UTC) |
---|---|---|
committer | eilers <eilers> | 2003-11-03 16:52:18 (UTC) |
commit | d34dc773591a2d467c68875a68a671d6a809f861 (patch) (side-by-side diff) | |
tree | b57e5ae15c51e3d87ca95d57aedfd1ca3db57bfe | |
parent | ce84f2d8bdd65c438821f0457cdad6bbbfa73380 (diff) | |
download | opie-d34dc773591a2d467c68875a68a671d6a809f861.zip opie-d34dc773591a2d467c68875a68a671d6a809f861.tar.gz opie-d34dc773591a2d467c68875a68a671d6a809f861.tar.bz2 |
Porting Opie to MacOS-X.
The base system and all platform independent applications and platforms
should work.
Please see $OPIEDIR/development/macosx for details
85 files changed, 2262 insertions, 144 deletions
@@ -21,32 +21,35 @@ endif ifdef CONFIG_TARGET_SHARP PLATFORM=sharp-linux endif ifdef CONFIG_TARGET_IPAQ PLATFORM=ipaq-linux endif ifdef CONFIG_TARGET_RAMSES PLATFORM=ramses-linux endif ifdef CONFIG_TARGET_SIMPAD PLATFORM=simpad-linux endif ifdef CONFIG_TARGET_YOPY PLATFORM=yopy-linux endif +ifdef CONFIG_TARGET_MACOSX + PLATFORM=macx-darwin +endif export QMAKE:=$(OPIEDIR)/qmake/qmake export QMAKESPECSDIR=$(OPIEDIR)/mkspecs ifeq ($(QPE_VERSION),) VERSION_MAJ:=$(shell echo $$(sed -n -e 's/.*QPE_VERSION "\([0-9]*\)\..*\..*".*/\1/p' <$(OPIEDIR)/library/version.h)) VERSION_MIN:=$(shell echo $$(sed -n -e 's/.*QPE_VERSION ".*\.\([0-9]*\)\..*".*/\1/p' <$(OPIEDIR)/library/version.h)) VERSION_PAT:=$(shell echo $$(sed -n -e 's/.*QPE_VERSION ".*\..*\.\([0-9]*\).*/\1/p' <$(OPIEDIR)/library/version.h)) QPE_VERSION:=$(VERSION_MAJ).$(VERSION_MIN).$(VERSION_PAT) ifeq ($(QPE_VERSION),..) QPE_VERSION=0.9.3 endif endif export QPE_VERSION @@ -1,30 +1,33 @@ mainmenu "Opie Configuration" menu "Build Parameters" choice prompt "Target Machine" default TARGET_X86 help Please select the architecture of the machine you will be building the OpenZaurus buildroot for. config TARGET_X86 boolean "Intel X86" + config TARGET_MACOSX + boolean "Mac OS X (DARWIN)" + config TARGET_SHARP boolean "Sharp Zaurus" config TARGET_IPAQ boolean "iPAQ" config TARGET_RAMSES boolean "Ramses" config TARGET_SIMPAD boolean "SIMpad" config TARGET_YOPY boolean "Yopy 3500/3700" endchoice @@ -49,32 +52,33 @@ config OPIE_NO_OVERRIDE_QT boolean "Build Opie against an unpatched version of Qt" default n config SPECFILE string default "qws/linux-generic-g++" if TARGET_X86 && (! X11) default "linux-g++" if TARGET_X86 && X11 default "qws/linux-sharp-g++" if TARGET_SHARP && (! X11) default "linux-g++" if TARGET_SHARP && X11 default "qws/linux-ipaq-g++" if TARGET_IPAQ && (! X11) default "linux-g++" if TARGET_IPAQ && X11 default "qws/linux-ramses-g++" if TARGET_RAMSES && (! X11) default "linux-g++" if TARGET_RAMSES && X11 default "qws/linux-simpad-g++" if TARGET_SIMPAD && (! X11) default "linux-g++" if TARGET_SIMPAD && X11 default "qws/linux-yopy-g++" if TARGET_YOPY && (! X11) + default "qws/macx-generic-g++" if TARGET_MACOSX && (! X11) config CUSTOMFILE string default "custom-ipaq.h" if TARGET_IPAQ default "custom-sharp.h" if TARGET_SHARP default "custom-ramses.h" if TARGET_RAMSES default "custom-ipaq.h" if TARGET_SIMPAD default "custom-yopy.h" if TARGET_YOPY config OPTIMIZATIONS string "Optimization flags" depends OPTIMIZE default "-march=armv4 -mtune=strongarm1100 -mapcs-32 -fexpensive-optimizations -fomit-frame-pointer -O2" if TARGET_IPAQ default "-march=armv4 -mtune=strongarm1100 -mapcs-32 -fexpensive-optimizations -fomit-frame-pointer -O2" if TARGET_YOPY default "-march=armv4 -mtune=strongarm1100 -mapcs-32 -fexpensive-optimizations -fomit-frame-pointer -O2" if TARGET_SHARP default "-march=armv4 -mtune=strongarm1100 -mapcs-32 -fexpensive-optimizations -fomit-frame-pointer -O2" if TARGET_RAMSES diff --git a/core/applets/batteryapplet/batteryapplet.pro b/core/applets/batteryapplet/batteryapplet.pro index c68ceb7..1bc208b 100644 --- a/core/applets/batteryapplet/batteryapplet.pro +++ b/core/applets/batteryapplet/batteryapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = battery.h batterystatus.h batteryappletimpl.h SOURCES = battery.cpp batterystatus.cpp batteryappletimpl.cpp TARGET = batteryapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include .. LIBS += -lqpe -lopie VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libbatteryapplet.ts \ ../../../i18n/nl/libbatteryapplet.ts \ ../../../i18n/da/libbatteryapplet.ts \ ../../../i18n/xx/libbatteryapplet.ts \ ../../../i18n/en/libbatteryapplet.ts \ ../../../i18n/es/libbatteryapplet.ts \ ../../../i18n/fr/libbatteryapplet.ts \ diff --git a/core/applets/cardmon/cardmon.pro b/core/applets/cardmon/cardmon.pro index 3907aa4..75facde 100644 --- a/core/applets/cardmon/cardmon.pro +++ b/core/applets/cardmon/cardmon.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = cardmon.h cardmonimpl.h SOURCES = cardmon.cpp cardmonimpl.cpp TARGET = cardmonapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include ../launcher LIBS += -lqpe -lopie VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libcardmonapplet.ts \ ../../../i18n/nl/libcardmonapplet.ts \ ../../../i18n/da/libcardmonapplet.ts \ ../../../i18n/xx/libcardmonapplet.ts \ ../../../i18n/en/libcardmonapplet.ts \ ../../../i18n/es/libcardmonapplet.ts \ ../../../i18n/fr/libcardmonapplet.ts \ diff --git a/core/applets/clipboardapplet/clipboardapplet.pro b/core/applets/clipboardapplet/clipboardapplet.pro index 1e9cc4f..358d658 100644 --- a/core/applets/clipboardapplet/clipboardapplet.pro +++ b/core/applets/clipboardapplet/clipboardapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = clipboard.h clipboardappletimpl.h SOURCES = clipboard.cpp clipboardappletimpl.cpp TARGET = clipboardapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libclipboardapplet.ts \ ../../../i18n/nl/libclipboardapplet.ts \ ../../../i18n/da/libclipboardapplet.ts \ ../../../i18n/xx/libclipboardapplet.ts \ ../../../i18n/en/libclipboardapplet.ts \ ../../../i18n/es/libclipboardapplet.ts \ ../../../i18n/fr/libclipboardapplet.ts \ diff --git a/core/applets/clockapplet/clockapplet.pro b/core/applets/clockapplet/clockapplet.pro index 22c7b55..88092f5 100644 --- a/core/applets/clockapplet/clockapplet.pro +++ b/core/applets/clockapplet/clockapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = clock.h clockappletimpl.h SOURCES = clock.cpp clockappletimpl.cpp TARGET = clockapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include .. LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libclockapplet.ts \ ../../../i18n/nl/libclockapplet.ts \ ../../../i18n/da/libclockapplet.ts \ ../../../i18n/xx/libclockapplet.ts \ ../../../i18n/en/libclockapplet.ts \ ../../../i18n/es/libclockapplet.ts \ ../../../i18n/fr/libclockapplet.ts \ diff --git a/core/applets/homeapplet/homeapplet.pro b/core/applets/homeapplet/homeapplet.pro index ac7956b..854050f 100644 --- a/core/applets/homeapplet/homeapplet.pro +++ b/core/applets/homeapplet/homeapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = home.h SOURCES = home.cpp TARGET = homeapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libhomeapplet.ts \ ../../../i18n/nl/libhomeapplet.ts \ ../../../i18n/da/libhomeapplet.ts \ ../../../i18n/xx/libhomeapplet.ts \ ../../../i18n/en/libhomeapplet.ts \ ../../../i18n/es/libhomeapplet.ts \ ../../../i18n/fr/libhomeapplet.ts \ diff --git a/core/applets/irdaapplet/irdaapplet.pro b/core/applets/irdaapplet/irdaapplet.pro index 56632ed..be16bad 100644 --- a/core/applets/irdaapplet/irdaapplet.pro +++ b/core/applets/irdaapplet/irdaapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = irda.h irdaappletimpl.h SOURCES = irda.cpp irdaappletimpl.cpp TARGET = irdaapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libirdaapplet.ts \ ../../../i18n/nl/libirdaapplet.ts \ ../../../i18n/da/libirdaapplet.ts \ ../../../i18n/xx/libirdaapplet.ts \ ../../../i18n/en/libirdaapplet.ts \ ../../../i18n/es/libirdaapplet.ts \ ../../../i18n/fr/libirdaapplet.ts \ diff --git a/core/applets/logoutapplet/logoutapplet.pro b/core/applets/logoutapplet/logoutapplet.pro index a019303..7826bb3 100644 --- a/core/applets/logoutapplet/logoutapplet.pro +++ b/core/applets/logoutapplet/logoutapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = logout.h SOURCES = logout.cpp TARGET = logoutapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/liblogoutapplet.ts \ ../../../i18n/nl/liblogoutapplet.ts \ ../../../i18n/da/liblogoutapplet.ts \ ../../../i18n/xx/liblogoutapplet.ts \ ../../../i18n/en/liblogoutapplet.ts \ ../../../i18n/es/liblogoutapplet.ts \ ../../../i18n/fr/liblogoutapplet.ts \ diff --git a/core/applets/restartapplet/restartapplet.pro b/core/applets/restartapplet/restartapplet.pro index bd27b0a..368a0ea 100644 --- a/core/applets/restartapplet/restartapplet.pro +++ b/core/applets/restartapplet/restartapplet.pro @@ -1,17 +1,17 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = restart.h restartappletimpl.h SOURCES = restart.cpp restartappletimpl.cpp TARGET = restartapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 MOC_DIR=opieobj OBJECTS_DIR=opieobj include ( $(OPIEDIR)/include.pro ) target.path = $$prefix/plugins/applets diff --git a/core/applets/restartapplet2/restartapplet.pro b/core/applets/restartapplet2/restartapplet.pro index 85a3b66..12a7922 100644 --- a/core/applets/restartapplet2/restartapplet.pro +++ b/core/applets/restartapplet2/restartapplet.pro @@ -1,17 +1,17 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = restart.h SOURCES = restart.cpp TARGET = restartapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 MOC_DIR=opieobj OBJECTS_DIR=opieobj include ( $(OPIEDIR)/include.pro ) target.path = $$prefix/plugins/applets diff --git a/core/applets/rotateapplet/rotateapplet.pro b/core/applets/rotateapplet/rotateapplet.pro index 9b39dba..2c8de8d 100644 --- a/core/applets/rotateapplet/rotateapplet.pro +++ b/core/applets/rotateapplet/rotateapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugn warn_on release HEADERS = rotate.h SOURCES = rotate.cpp TARGET = rotateapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/librotateapplet.ts \ ../../../i18n/nl/librotateapplet.ts \ ../../../i18n/da/librotateapplet.ts \ ../../../i18n/xx/librotateapplet.ts \ ../../../i18n/en/librotateapplet.ts \ ../../../i18n/es/librotateapplet.ts \ ../../../i18n/fr/librotateapplet.ts \ diff --git a/core/applets/screenshotapplet/screenshotapplet.pro b/core/applets/screenshotapplet/screenshotapplet.pro index fe7b299..a86eff2 100644 --- a/core/applets/screenshotapplet/screenshotapplet.pro +++ b/core/applets/screenshotapplet/screenshotapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = screenshot.h inputDialog.h screenshotappletimpl.h SOURCES = screenshot.cpp inputDialog.cpp screenshotappletimpl.cpp TARGET = screenshotapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 MOC_DIR=opieobj OBJECTS_DIR=opieobj TRANSLATIONS = ../../../i18n/de/libscreenshotapplet.ts \ ../../../i18n/nl/libscreenshotapplet.ts \ ../../../i18n/da/libscreenshotapplet.ts \ ../../../i18n/xx/libscreenshotapplet.ts \ ../../../i18n/en/libscreenshotapplet.ts \ diff --git a/core/applets/suspendapplet/suspendapplet.pro b/core/applets/suspendapplet/suspendapplet.pro index 7635d32..f58de63 100644 --- a/core/applets/suspendapplet/suspendapplet.pro +++ b/core/applets/suspendapplet/suspendapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = suspend.h SOURCES = suspend.cpp TARGET = suspendapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libsuspendapplet.ts \ ../../../i18n/nl/libsuspendapplet.ts \ ../../../i18n/da/libsuspendapplet.ts \ ../../../i18n/xx/libsuspendapplet.ts \ ../../../i18n/en/libsuspendapplet.ts \ ../../../i18n/es/libsuspendapplet.ts \ ../../../i18n/fr/libsuspendapplet.ts \ diff --git a/core/applets/vmemo/vmemo.pro b/core/applets/vmemo/vmemo.pro index 8cf1f07..43cb767 100644 --- a/core/applets/vmemo/vmemo.pro +++ b/core/applets/vmemo/vmemo.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = vmemo.h vmemoimpl.h adpcm.h SOURCES = vmemo.cpp vmemoimpl.cpp adpcm.c TARGET = vmemoapplet DESTDIR =$(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libvmemoapplet.ts \ ../../../i18n/nl/libvmemoapplet.ts \ ../../../i18n/da/libvmemoapplet.ts \ ../../../i18n/xx/libvmemoapplet.ts \ ../../../i18n/en/libvmemoapplet.ts \ ../../../i18n/es/libvmemoapplet.ts \ ../../../i18n/fr/libvmemoapplet.ts \ diff --git a/core/applets/volumeapplet/volumeapplet.pro b/core/applets/volumeapplet/volumeapplet.pro index d30567c..68d9eff 100644 --- a/core/applets/volumeapplet/volumeapplet.pro +++ b/core/applets/volumeapplet/volumeapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = volume.h volumeappletimpl.h oledbox.h SOURCES = volume.cpp volumeappletimpl.cpp oledbox.cpp TARGET = volumeapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libvolumeapplet.ts \ ../../../i18n/nl/libvolumeapplet.ts \ ../../../i18n/da/libvolumeapplet.ts \ ../../../i18n/xx/libvolumeapplet.ts \ ../../../i18n/en/libvolumeapplet.ts \ ../../../i18n/es/libvolumeapplet.ts \ ../../../i18n/fr/libvolumeapplet.ts \ diff --git a/core/launcher/applauncher.cpp b/core/launcher/applauncher.cpp index d6f93da..0ac043b 100644 --- a/core/launcher/applauncher.cpp +++ b/core/launcher/applauncher.cpp @@ -533,33 +533,37 @@ bool AppLauncher::execute(const QString &c, const QString &docParam, bool noRais #ifdef QT_NO_QWS_MULTIPROCESS QMessageBox::warning( 0, tr("Error"), tr("<qt>Could not find the application %1</qt>").arg(c), tr("OK"), 0, 0, 0, 1 ); #else QStrList slist; unsigned j; for ( j = 0; j < list.count(); j++ ) slist.append( list[j].utf8() ); const char **args = new const char *[slist.count() + 1]; for ( j = 0; j < slist.count(); j++ ) args[j] = slist.at(j); args[j] = NULL; #ifndef Q_OS_WIN32 +#ifdef Q_OS_MACX + if ( qlPid && qlReady && QFile::exists( QPEApplication::qpeDir()+"plugins/application/lib"+args[0] + ".dylib" ) ) { +#else if ( qlPid && qlReady && QFile::exists( QPEApplication::qpeDir()+"plugins/application/lib"+args[0] + ".so" ) ) { +#endif /* Q_OS_MACX */ qDebug( "Quick launching: %s", args[0] ); if ( getuid() == 0 ) setpriority( PRIO_PROCESS, qlPid, 0 ); QCString qlch("QPE/QuickLauncher-"); qlch += QString::number(qlPid); QCopEnvelope env( qlch, "execute(QStrList)" ); env << slist; runningApps[qlPid] = QString(args[0]); emit launched(qlPid, QString(args[0])); QCopEnvelope e("QPE/System", "busy()"); qlPid = 0; qlReady = FALSE; QTimer::singleShot( getuid() == 0 ? 800 : 1500, this, SLOT(createQuickLauncher()) ); } else { int pid = ::vfork(); if ( !pid ) { diff --git a/core/launcher/inputmethods.cpp b/core/launcher/inputmethods.cpp index 8f3e812..62e316c 100644 --- a/core/launcher/inputmethods.cpp +++ b/core/launcher/inputmethods.cpp @@ -214,33 +214,37 @@ void InputMethods::unloadInputMethods() inputMethodList.clear(); inputModifierList.clear(); } void InputMethods::unloadMethod( QValueList<InputMethod>& list ) { QValueList<InputMethod>::Iterator it; for (it = list.begin(); it != list.end(); ++it ) (*it).releaseInterface(); } QStringList InputMethods::plugins()const { QString path = QPEApplication::qpeDir() + "/plugins/inputmethods"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif /* Q_OS_MACX */ return dir.entryList(); } void InputMethods::installTranslator( const QString& type ) { QStringList langs = Global::languageList(); QStringList::ConstIterator lit; for ( lit= langs.begin(); lit!=langs.end(); ++lit) { QString lang = *lit; QTranslator * trans = new QTranslator(qApp); QString tfn = QPEApplication::qpeDir()+"/i18n/"+lang+"/"+type+".qm"; if ( trans->load( tfn )) qApp->installTranslator( trans ); else delete trans; diff --git a/core/launcher/irserver.cpp b/core/launcher/irserver.cpp index 579c78c..63f8d05 100644 --- a/core/launcher/irserver.cpp +++ b/core/launcher/irserver.cpp @@ -23,33 +23,37 @@ #include <qtopia/qlibrary.h> #include <qtopia/qpeapplication.h> #include <qtranslator.h> #include "obexinterface.h" #include <qdir.h> IrServer::IrServer( QObject *parent, const char *name ) : QObject( parent, name ), obexIface(0) { lib = 0; obexIface = 0; QString path = QPEApplication::qpeDir() + "/plugins/obex/"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif /* Q_OS_MACX */ QStringList list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { QLibrary *trylib = new QLibrary( path + *it ); //qDebug("trying lib %s", (path + (*it)).latin1() ); if ( trylib->queryInterface( IID_ObexInterface, (QUnknownInterface**)&obexIface ) == QS_OK ) { lib = trylib; //qDebug("found obex lib" ); QString lang = getenv( "LANG" ); QTranslator * trans = new QTranslator(qApp); QString type = (*it).left( (*it).find(".") ); QString tfn = QPEApplication::qpeDir()+"/i18n/"+lang+"/"+type+".qm"; //qDebug("tr fpr obex: %s", tfn.latin1() ); if ( trans->load( tfn )) qApp->installTranslator( trans ); else diff --git a/core/launcher/main.cpp b/core/launcher/main.cpp index 74965df..5416d33 100644 --- a/core/launcher/main.cpp +++ b/core/launcher/main.cpp @@ -263,33 +263,35 @@ int initApplication( int argc, char ** argv ) s->show(); /* THE ARM rtc has problem holdings the time on reset */ if ( QDate::currentDate ( ). year ( ) < 2000 ) { if ( QMessageBox::information ( 0, ServerApplication::tr( "Information" ), ServerApplication::tr( "<p>The system date doesn't seem to be valid.\n(%1)</p><p>Do you want to correct the clock ?</p>" ). arg( TimeString::dateString ( QDate::currentDate ( ))), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::Yes ) { QCopEnvelope e ( "QPE/Application/systemtime", "setDocument(QString)" ); e << QString ( ); } } int rv = a.exec(); qDebug("exiting..."); delete s; +#ifndef Q_OS_MACX ODevice::inst()->setSoftSuspend( false ); +#endif return rv; } static const char *pidfile_path = "/var/run/opie.pid"; void create_pidfile ( ) { FILE *f; if (( f = ::fopen ( pidfile_path, "w" ))) { ::fprintf ( f, "%d", getpid ( )); ::fclose ( f ); } } diff --git a/core/launcher/packageslave.cpp b/core/launcher/packageslave.cpp index 4f149a5..bf34368 100644 --- a/core/launcher/packageslave.cpp +++ b/core/launcher/packageslave.cpp @@ -1,97 +1,341 @@ /********************************************************************** -** Copyright (C) 2000 Trolltech AS. All rights reserved. +** Copyright (C) 2000-2002 Trolltech AS. All rights reserved. ** -** This file is part of Qtopia Environment. +** This file is part of the Qtopia Environment. ** ** This file may be distributed and/or modified under the terms of the ** GNU General Public License version 2 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #include "packageslave.h" +#include <qtopia/qprocess.h> -#include <qpe/process.h> -#include <qpe/qcopenvelope_qws.h> +#ifdef Q_WS_QWS +#include <qtopia/qcopenvelope_qws.h> +#endif #include <qdatastream.h> +#ifdef Q_WS_QWS #include <qcopchannel_qws.h> +#endif +#include <qtextstream.h> +#include <qdir.h> + +#include <stdlib.h> +#include <sys/stat.h> // mkdir() + +#if defined(_OS_LINUX_) || defined(Q_OS_LINUX) #include <unistd.h> +#include <sys/vfs.h> +#include <mntent.h> +#elif defined(Q_OS_WIN32) +#include <windows.h> +#include <winbase.h> +#elif defined(Q_OS_MACX) +#include <unistd.h> +#endif + -PackageSlave::PackageSlave( QObject *parent, char* name ) - : QObject( parent, name ), packageChannel( 0 ) +PackageHandler::PackageHandler( QObject *parent, char* name ) + : QObject( parent, name ), packageChannel( 0 ), currentProcess( 0 ), mNoSpaceLeft( FALSE ) { // setup qcop channel +#ifndef QT_NO_COP packageChannel = new QCopChannel( "QPE/Package", this ); connect( packageChannel, SIGNAL( received(const QCString &, const QByteArray &) ), this, SLOT( qcopMessage( const QCString &, const QByteArray &) ) ); +#endif } -void PackageSlave::qcopMessage( const QCString &msg, const QByteArray &data ) +void PackageHandler::qcopMessage( const QCString &msg, const QByteArray &data ) { QDataStream stream( data, IO_ReadOnly ); if ( msg == "installPackage(QString)" ) { QString file; stream >> file; installPackage( file ); - } - else if ( msg == "removePackage(QString)" ) { + } else if ( msg == "removePackage(QString)" ) { QString file; stream >> file; removePackage( file ); + } else if ( msg == "addPackageFiles(QString,QString)" ) { + QString location, listfile; + stream >> location >> listfile; + addPackageFiles( location, listfile); + } else if ( msg == "addPackages(QString)" ) { + QString location; + stream >> location; + addPackages( location ); + } else if ( msg == "cleanupPackageFiles(QString)" ) { + QString listfile; + stream >> listfile; + cleanupPackageFiles( listfile ); + } else if ( msg == "cleanupPackages(QString)" ) { + QString location; + stream >> location; + cleanupPackages( location ); + } else if ( msg == "prepareInstall(QString,QString)" ) { + QString size, path; + stream >> size; + stream >> path; + prepareInstall( size, path ); } } -void PackageSlave::installPackage( const QString &package ) +void PackageHandler::installPackage( const QString &package ) { - Process proc( QStringList() << "ipkg" << "install" << package ); + if ( mNoSpaceLeft ) { + mNoSpaceLeft = FALSE; + // Don't emit that for now, I still couldn't test it (Wener) + //sendReply( "installFailed(QString)", package ); + //return; + } + + currentProcess = new QProcess( QStringList() << "ipkg" << "install" << package ); // No tr + connect( currentProcess, SIGNAL( processExited() ), SLOT( iProcessExited() ) ); + connect( currentProcess, SIGNAL( readyReadStdout() ), SLOT( readyReadStdout() ) ); + connect( currentProcess, SIGNAL( readyReadStderr() ), SLOT( readyReadStderr() ) ); + currentPackage = package; + currentProcessError=""; sendReply( "installStarted(QString)", package ); + currentProcess->start(); +} + +void PackageHandler::removePackage( const QString &package ) +{ + currentProcess = new QProcess( QStringList() << "ipkg" << "remove" << package ); // No tr + connect( currentProcess, SIGNAL( processExited() ), SLOT( rmProcessExited() ) ); + connect( currentProcess, SIGNAL( readyReadStdout() ), SLOT( readyReadStdout() ) ); + connect( currentProcess, SIGNAL( readyReadStderr() ), SLOT( readyReadStderr() ) ); + currentPackage = package; + + currentProcessError=""; + sendReply( "removeStarted(QString)", package ); + currentProcess->start(); +} + +void PackageHandler::sendReply( const QCString& msg, const QString& arg ) +{ +#ifndef QT_NO_COP + QCopEnvelope e( "QPE/Desktop", msg ); + e << arg; +#endif +} + +void PackageHandler::addPackageFiles( const QString &location, + const QString &listfile ) +{ + QFile f(listfile); +#ifndef Q_OS_WIN32 + //make a copy so we can remove the symlinks later + mkdir( ("/usr/lib/ipkg/info/"+location).ascii(), 0777 ); + system(("cp " + f.name() + " /usr/lib/ipkg/info/"+location).ascii()); +#else + QDir d; + //#### revise + qDebug("Copy file at %s: %s", __FILE__, __LINE__ ); + d.mkdir(("/usr/lib/ipkg/info/" + location).ascii()); + system(("copy " + f.name() + " /usr/lib/ipkg/info/"+location).ascii()); +#endif + + + if ( f.open(IO_ReadOnly) ) { + QTextStream ts(&f); + + QString s; + while ( !ts.eof() ) { // until end of file... + s = ts.readLine(); // line of text excluding '\n' + // for s, do link/mkdir. + if ( s.right(1) == "/" ) { + qDebug("do mkdir for %s", s.ascii()); +#ifndef Q_OS_WIN32 + mkdir( s.ascii(), 0777 ); + //possible optimization: symlink directories + //that don't exist already. -- Risky. +#else + d.mkdir( s.ascii()); +#endif + + } else { +#ifndef Q_OS_WIN32 + qDebug("do symlink for %s", s.ascii()); + symlink( (location + s).ascii(), s.ascii() ); +#else + qDebug("Copy file instead of a symlink for WIN32"); + if (!CopyFile((TCHAR*)qt_winTchar((location + s), TRUE), (TCHAR*)qt_winTchar(s, TRUE), FALSE)) + qWarning("Unable to create symlinkfor %s", + (location + s).ascii()); +#endif + } + } + f.close(); + } +} - QString output; - if ( proc.exec( "", output ) ) { - sendReply( "installDone(QString)", package ); +void PackageHandler::addPackages( const QString &location ) +{ + // get list of *.list in location/usr/lib/ipkg/info/*.list + QDir dir(location + "/usr/lib/ipkg/info", "*.list", // No tr + QDir::Name, QDir::Files); + if ( !dir.exists() ) + return; + + QStringList packages = dir.entryList(); + for ( QStringList::Iterator it = packages.begin(); + it != packages.end(); ++it ) { + addPackageFiles( location, *it ); } +} + + +void PackageHandler::cleanupPackageFiles( const QString &listfile ) +{ + QFile f(listfile); + + if ( f.open(IO_ReadOnly) ) { + QTextStream ts(&f); + + QString s; + while ( !ts.eof() ) { // until end of file... + s = ts.readLine(); // line of text excluding '\n' + // for s, do link/mkdir. + if ( s.right(1) == "/" ) { + //should rmdir if empty, after all files have been removed + } else { +#ifndef Q_OS_WIN32 + qDebug("remove symlink for %s", s.ascii()); + //check if it is a symlink first (don't remove /etc/passwd...) + char buf[10]; //we don't care about the contents + if ( ::readlink( s.ascii(),buf, 10 >= 0 ) ) + ::unlink( s.ascii() ); +#else + // ### revise + qWarning("Unable to remove symlink %s:%s", __FILE__, __LINE__); +#endif + } + } + f.close(); + + //remove the list file + ::unlink( listfile.ascii() ); + + } +} + +void PackageHandler::cleanupPackages( const QString &location ) +{ + // get list of *.list in location/usr/lib/ipkg/info/*.list + QDir dir( "/usr/lib/ipkg/info/"+location, "*.list", // No tr + QDir::Name, QDir::Files); + if ( !dir.exists() ) + return; + + QStringList packages = dir.entryList(); + for ( QStringList::Iterator it = packages.begin(); + it != packages.end(); ++it ) { + cleanupPackageFiles( *it ); + } + + //remove the backup directory + //### +} + +void PackageHandler::prepareInstall( const QString& size, const QString& path ) +{ + // Check whether there will be enough space to install the next package. + bool ok; + unsigned int s = size.toUInt( &ok ); + + if ( !ok ) + return; + + // Shamelessly stolen from the sysinfo application (Werner) +#if defined(_OS_LINUX_) || defined(Q_OS_LINUX) + struct statfs fs; + if ( statfs( path.latin1(), &fs ) == 0 ) + if ( s > fs.f_bsize * fs.f_bavail ) { + //qDebug("############### Not enough space left ###############"); + mNoSpaceLeft = TRUE; + } +#endif +} + +void PackageHandler::iProcessExited() +{ + if ( currentProcess->normalExit() && currentProcess->exitStatus() == 0 ) + sendReply( "installDone(QString)", currentPackage ); else { - sendReply( "installFailed(QString)", package ); +#ifndef QT_NO_COP + QCopEnvelope e( "QPE/Desktop", "installFailed(QString,int,QString)" ); + e << currentPackage << currentProcess->exitStatus() + << currentProcessError; +#endif } + + delete currentProcess; + currentProcess = 0; + +#ifndef QT_NO_COP QCopEnvelope e("QPE/System", "linkChanged(QString)"); QString lf = QString::null; e << lf; - unlink( package ); +#endif + unlink( currentPackage ); } -void PackageSlave::removePackage( const QString &package ) +void PackageHandler::rmProcessExited() { - Process proc( QStringList() << "ipkg" << "remove" << package ); + if ( currentProcess->normalExit() && currentProcess->exitStatus() == 0 ) + sendReply( "removeDone(QString)", currentPackage ); + else + sendReply( "removeFailed(QString)", currentPackage ); - sendReply( "removeStarted(QString)", package ); - - QString output; - if ( proc.exec( "", output ) ) { - sendReply( "removeDone(QString)", package ); - } - else { - sendReply( "removeFailed(QString)", package ); - } +#ifndef QT_NO_COP QCopEnvelope e("QPE/System", "linkChanged(QString)"); QString lf = QString::null; e << lf; +#endif } -void PackageSlave::sendReply( const QCString& msg, const QString& arg ) +void PackageHandler::readyReadStdout() { - QCopEnvelope e( "QPE/Desktop", msg ); - e << arg; + while ( currentProcess->canReadLineStdout() ) { + QString line = currentProcess->readLineStdout(); + currentProcessError.append("OUT:"+line); + if ( line.contains( "Unpacking" ) ) // No tr + sendReply( "installStep(QString)", "one" ); // No tr + else if ( line.contains( "Configuring" ) ) // No tr + sendReply( "installStep(QString)", "two" ); // No tr + } +} + +void PackageHandler::readyReadStderr() +{ + while ( currentProcess->canReadLineStderr() ) { + QString line = currentProcess->readLineStderr(); + currentProcessError.append("ERR:"+line); + } +} + +void PackageHandler::redoPackages() +{ + //get list of filesystems + + //call cleanupPackages for the ones that have disappeared + + //call addPackageFiles for the new ones } diff --git a/core/launcher/qprocess_unix.cpp b/core/launcher/qprocess_unix.cpp index a07bf64..19a8c93 100644 --- a/core/launcher/qprocess_unix.cpp +++ b/core/launcher/qprocess_unix.cpp @@ -37,32 +37,35 @@ #include "qregexp.h" #include "qcleanuphandler_p.h" #include <stdlib.h> // ### FOR Qt 2.3 compat #include <unistd.h> #include <signal.h> #include <sys/socket.h> #include <sys/ioctl.h> #include <sys/wait.h> #include <sys/fcntl.h> #include <errno.h> +#ifdef Q_OS_MACX +#include <sys/time.h> +#endif #include <sys/resource.h> #ifdef __MIPSEL__ # ifndef SOCK_DGRAM # define SOCK_DGRAM 1 # endif # ifndef SOCK_STREAM # define SOCK_STREAM 2 # endif #endif //#define QT_QPROCESS_DEBUG #ifdef Q_C_CALLBACKS extern "C" { diff --git a/core/launcher/server.pro b/core/launcher/server.pro index 93baeb4..0513536 100644 --- a/core/launcher/server.pro +++ b/core/launcher/server.pro @@ -102,19 +102,24 @@ SOURCES += server.cpp \ syncdialog.cpp \ serverapp.cpp \ launcherglobal.cpp \ qprocess.cpp \ qprocess_unix.cpp \ screensaver.cpp INCLUDEPATH += $(OPIEDIR)/core/apps/calibrate DEPENDPATH += $(OPIEDIR)/core/apps/calibrate INCLUDEPATH += $(OPIEDIR)/include $(OPIEDIR)/rsync DEPENDPATH += $(OPIEDIR)/rsync TARGET = qpe -LIBS += -lcrypt -lqpe -lopie +CONFTEST = $$system( echo $CONFIG_TARGET_MACOSX ) +contains( CONFTEST, y ){ + LIBS += -lqpe -lopie +}else{ + LIBS += -lcrypt -lqpe -lopie +} include ( $(OPIEDIR)/include.pro ) diff --git a/core/launcher/startmenu.cpp b/core/launcher/startmenu.cpp index 014418d..08ae885 100644 --- a/core/launcher/startmenu.cpp +++ b/core/launcher/startmenu.cpp @@ -243,33 +243,37 @@ void StartMenu::clearApplets() void StartMenu::loadApplets() { Config cfg( "StartMenu" ); cfg.setGroup( "Applets" ); // SafeMode causes too much problems, so we disable it for now -- // maybe we should reenable it for OPIE 1.0 - sandman 26.09.02 // removed in the remerge PluginManager could handle it // we don't currently use it -zecke QStringList exclude = cfg.readListEntry( "ExcludeApplets", ',' ); QString lang = getenv( "LANG" ); QString path = QPEApplication::qpeDir() + "/plugins/applets"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif /* Q_OS_MACX */ QStringList list = dir.entryList(); QStringList::Iterator it; int napplets=0; MenuApplet* *xapplets = new MenuApplet*[list.count()]; for ( it = list.begin(); it != list.end(); ++it ) { if ( exclude.find( *it ) != exclude.end() ) continue; MenuAppletInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if (( lib->queryInterface( IID_MenuApplet, (QUnknownInterface**)&iface ) == QS_OK ) && iface ) { MenuApplet *applet = new MenuApplet; xapplets[napplets++] = applet; applet->library = lib; applet->iface = iface; QTranslator *trans = new QTranslator(qApp); diff --git a/core/launcher/systray.cpp b/core/launcher/systray.cpp index 6122770..691f6b8 100644 --- a/core/launcher/systray.cpp +++ b/core/launcher/systray.cpp @@ -89,40 +89,45 @@ void SysTray::clearApplets() if ( layout ) delete layout; layout = new QHBoxLayout( this, 0, 1 ); layout->setAutoAdd(TRUE); } void SysTray::addApplets() { hide(); #ifndef QT_NO_COMPONENTS Config cfg( "Taskbar" ); cfg.setGroup( "Applets" ); QStringList exclude = cfg.readListEntry( "ExcludeApplets", ',' ); QString lang = getenv( "LANG" ); QString path = QPEApplication::qpeDir() + "/plugins/applets"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif /* Q_OS_MACX */ QStringList list = dir.entryList(); QStringList::Iterator it; int napplets=0; TaskbarApplet* *applets = new TaskbarApplet*[list.count()]; for ( it = list.begin(); it != list.end(); ++it ) { if ( exclude.find( *it ) != exclude.end() ) continue; + qWarning( "Found Applet: %s", (*it).latin1() ); TaskbarAppletInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if (( lib->queryInterface( IID_TaskbarApplet, (QUnknownInterface**)&iface ) == QS_OK ) && iface ) { TaskbarApplet *applet = new TaskbarApplet; applets[napplets++] = applet; applet->library = lib; applet->iface = iface; QTranslator *trans = new QTranslator(qApp); QString type = (*it).left( (*it).find(".") ); QString tfn = QPEApplication::qpeDir()+"/i18n/"+lang+"/"+type+".qm"; if ( trans->load( tfn )) qApp->installTranslator( trans ); else delete trans; } else { diff --git a/core/launcher/transferserver.cpp b/core/launcher/transferserver.cpp index c69df2d..439e110 100644 --- a/core/launcher/transferserver.cpp +++ b/core/launcher/transferserver.cpp @@ -15,34 +15,37 @@ ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ //#define _XOPEN_SOURCE #include <qtopia/global.h> #include <qtopia/qpeapplication.h> #ifndef Q_OS_WIN32 #include <pwd.h> #include <sys/types.h> #include <unistd.h> #include <stdlib.h> #include <time.h> + +#ifndef Q_OS_MACX #include <shadow.h> #include <crypt.h> +#endif /* Q_OS_MACX */ #else #include <stdlib.h> #include <time.h> #endif #if defined(_OS_LINUX_) #include <shadow.h> #endif #include <qdir.h> #include <qfile.h> #include <qtextstream.h> #include <qdatastream.h> #include <qmessagebox.h> diff --git a/core/multimedia/opieplayer/wavplugin/wavplugin.pro b/core/multimedia/opieplayer/wavplugin/wavplugin.pro index 0366542..db41ad4 100644 --- a/core/multimedia/opieplayer/wavplugin/wavplugin.pro +++ b/core/multimedia/opieplayer/wavplugin/wavplugin.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = wavplugin.h wavpluginimpl.h SOURCES = wavplugin.cpp wavpluginimpl.cpp TARGET = wavplugin DESTDIR = $(OPIEDIR)/plugins/codecs INCLUDEPATH += $(OPIEDIR)/include .. DEPENDPATH += ../$(OPIEDIR)/include .. LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../../../i18n/de/libwavplugin.ts \ ../../../../i18n/nl/libwavplugin.ts \ ../../../../i18n/da/libwavplugin.ts \ ../../../../i18n/xx/libwavplugin.ts \ ../../../../i18n/en/libwavplugin.ts \ ../../../../i18n/es/libwavplugin.ts \ ../../../../i18n/fr/libwavplugin.ts \ diff --git a/core/pim/today/plugins/addressbook/addressbook.pro b/core/pim/today/plugins/addressbook/addressbook.pro index 4ebbc9e..54aaff2 100644 --- a/core/pim/today/plugins/addressbook/addressbook.pro +++ b/core/pim/today/plugins/addressbook/addressbook.pro @@ -1,19 +1,19 @@ TEMPLATE = lib CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release # Input HEADERS = addressplugin.h addresspluginimpl.h addresspluginconfig.h \ addresspluginwidget.h SOURCES = addressplugin.cpp addresspluginimpl.cpp addresspluginconfig.cpp \ addresspluginwidget.cpp INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library DEPENDPATH += $(OPIEDIR)/include \ ../ ../library LIBS+= -lqpe -lopie DESTDIR = $(OPIEDIR)/plugins/today TARGET = todayaddressbookplugin diff --git a/core/pim/today/plugins/datebook/datebook.pro b/core/pim/today/plugins/datebook/datebook.pro index e0a1dcb..2139f63 100644 --- a/core/pim/today/plugins/datebook/datebook.pro +++ b/core/pim/today/plugins/datebook/datebook.pro @@ -1,19 +1,19 @@ TEMPLATE = lib CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release # Input HEADERS = datebookplugin.h datebookpluginimpl.h datebookpluginconfig.h \ datebookevent.h datebookpluginwidget.h SOURCES = datebookplugin.cpp datebookpluginimpl.cpp datebookpluginconfig.cpp \ datebookevent.cpp datebookpluginwidget.cpp INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library DEPENDPATH += $(OPIEDIR)/include \ ../ ../library LIBS+= -lqpe -lopie DESTDIR = $(OPIEDIR)/plugins/today TARGET = todaydatebookplugin diff --git a/core/pim/today/plugins/mail/mail.pro b/core/pim/today/plugins/mail/mail.pro index 70c484d..421b3a5 100644 --- a/core/pim/today/plugins/mail/mail.pro +++ b/core/pim/today/plugins/mail/mail.pro @@ -1,19 +1,19 @@ TEMPLATE = lib CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release # Input HEADERS = mailplugin.h mailpluginimpl.h mailpluginwidget.h SOURCES = mailplugin.cpp mailpluginimpl.cpp mailpluginwidget.cpp INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library DEPENDPATH += $(OPIEDIR)/include \ ../ ../library LIBS+= -lqpe -lopie DESTDIR = $(OPIEDIR)/plugins/today TARGET = todaymailplugin TRANSLATIONS = ../../../../../i18n/de/libtodaymailplugin.ts \ diff --git a/core/pim/today/plugins/todolist/todolist.pro b/core/pim/today/plugins/todolist/todolist.pro index 31a6a27..c8730bb 100644 --- a/core/pim/today/plugins/todolist/todolist.pro +++ b/core/pim/today/plugins/todolist/todolist.pro @@ -1,19 +1,19 @@ TEMPLATE = lib CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release # Input HEADERS = todoplugin.h todopluginimpl.h todopluginconfig.h \ todopluginwidget.h SOURCES = todoplugin.cpp todopluginimpl.cpp todopluginconfig.cpp \ todopluginwidget.cpp INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library DEPENDPATH += $(OPIEDIR)/include \ ../ ../library LIBS+= -lqpe -lopie DESTDIR = $(OPIEDIR)/plugins/today TARGET = todaytodolistplugin diff --git a/core/pim/today/today.cpp b/core/pim/today/today.cpp index f213943..cb18c1c 100644 --- a/core/pim/today/today.cpp +++ b/core/pim/today/today.cpp @@ -161,37 +161,44 @@ void Today::init() { void Today::loadPlugins() { init(); QValueList<TodayPlugin>::Iterator tit; if ( !pluginList.isEmpty() ) { for ( tit = pluginList.begin(); tit != pluginList.end(); ++tit ) { (*tit).guiBox->hide(); (*tit).guiBox->reparent( 0, QPoint( 0, 0 ) ); delete (*tit).guiBox; (*tit).library->unload(); delete (*tit).library; } pluginList.clear(); } QString path = QPEApplication::qpeDir() + "/plugins/today"; + qWarning("Searching for Plugins in: %s", path.latin1()); +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif QStringList list = dir.entryList(); QStringList::Iterator it; + qWarning("Found: %d entries !", list.count() ); + QMap<QString, TodayPlugin> tempList; for ( it = list.begin(); it != list.end(); ++it ) { QInterfacePtr<TodayPluginInterface> iface; QLibrary *lib = new QLibrary( path + "/" + *it ); qDebug( "querying: %s", QString( path + "/" + *it ).latin1() ); if ( lib->queryInterface( IID_TodayPluginInterface, (QUnknownInterface**)&iface ) == QS_OK ) { qDebug( "accepted: %s", QString( path + "/" + *it ).latin1() ); qDebug( QString(*it) ); TodayPlugin plugin; plugin.library = lib; plugin.iface = iface; plugin.name = QString(*it); diff --git a/core/qws/transferserver.cpp b/core/qws/transferserver.cpp index 0337a94..239c824 100644 --- a/core/qws/transferserver.cpp +++ b/core/qws/transferserver.cpp @@ -10,49 +10,61 @@ ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #define _XOPEN_SOURCE #include <pwd.h> #include <sys/types.h> #include <unistd.h> #include <stdlib.h> #include <time.h> + +#ifndef Q_OS_MACX #include <shadow.h> +#endif /* Q_OS_MACX */ /* we need the _OS_LINUX stuff first ! */ #include <qglobal.h> #ifndef _OS_LINUX_ +// Is anybody able to review this ? The include "uuid/uuid.h" couldn't be found +// anywhere ? Therfore I removed it completely.. +// I think it should be made permanentyl !? (eilers) +#warning "Where should uuid/uuid.h be found ? Removed this part .. (eilers)" +#if 0 extern "C" { #include <uuid/uuid.h> #define UUID_H_INCLUDED } +#endif + #endif // not defined linux #if defined(_OS_LINUX_) #include <shadow.h> +#elif defined(Q_OS_MACX) +#include <stdlib.h> #endif #include <qdir.h> #include <qfile.h> #include <qtextstream.h> #include <qdatastream.h> #include <qmessagebox.h> #include <qstringlist.h> #include <qfileinfo.h> #include <qregexp.h> //#include <qpe/qcopchannel_qws.h> #include <qpe/process.h> #include <qpe/global.h> #include <qpe/config.h> #include <qpe/contact.h> #include <qpe/quuid.h> @@ -78,55 +90,62 @@ TransferServer::~TransferServer() void TransferServer::newConnection( int socket ) { (void) new ServerPI( socket, this ); } /* * small class in anonymous namespace * to generate a QUUid for us */ namespace { struct UidGen { QString uuid(); }; -#if !defined(_OS_LINUX_) - +#if defined(Q_OS_MACX) QString UidGen::uuid() { - uuid_t uuid; - uuid_generate( uuid ); - return QUUid( uuid ).toString(); + srandom( random() ); + QString numStr = QString::number( random() ); + + return "{" + numStr + "}"; } -#else +#elif defined(_OS_LINUX_) /* * linux got a /proc/sys/kernel/random/uuid file * it'll generate the uuids for us */ QString UidGen::uuid() { QFile file( "/proc/sys/kernel/random/uuid" ); if (!file.open(IO_ReadOnly ) ) return QString::null; QTextStream stream(&file); return "{" + stream.read().stripWhiteSpace() + "}"; } +#else +QString UidGen::uuid() +{ + uuid_t uuid; + ::uuid_generate( uuid ); + return QUUid( uuid ).toString(); +} #endif } QString SyncAuthentication::serverId() { Config cfg("Security"); cfg.setGroup("Sync"); QString r = cfg.readEntry("serverid"); if ( r.isEmpty() ) { UidGen gen; r = gen.uuid(); cfg.writeEntry("serverid", r ); } return r; } diff --git a/core/settings/launcher/menusettings.cpp b/core/settings/launcher/menusettings.cpp index 5a9fada..6fca621 100644 --- a/core/settings/launcher/menusettings.cpp +++ b/core/settings/launcher/menusettings.cpp @@ -66,33 +66,37 @@ MenuSettings::MenuSettings ( QWidget *parent, const char *name ) QWhatsThis::add ( m_list, tr( "Check the applets that you want to have included in the O-Menu." )); QWhatsThis::add ( m_menutabs, tr( "Adds the contents of the Launcher Tabs as menus in the O-Menu." )); connect ( m_list, SIGNAL( clicked ( QListViewItem * )), this, SLOT( appletChanged ( ))); init ( ); } void MenuSettings::init ( ) { Config cfg ( "StartMenu" ); cfg. setGroup ( "Applets" ); QStringList exclude = cfg. readListEntry ( "ExcludeApplets", ',' ); QString path = QPEApplication::qpeDir ( ) + "/plugins/applets"; +#ifdef Q_OS_MACX + QStringList list = QDir ( path, "lib*.dylib" ). entryList ( ); +#else QStringList list = QDir ( path, "lib*.so" ). entryList ( ); +#endif /* Q_OS_MACX */ for ( QStringList::Iterator it = list. begin ( ); it != list. end ( ); ++it ) { QString name; QPixmap icon; MenuAppletInterface *iface = 0; QLibrary *lib = new QLibrary ( path + "/" + *it ); lib-> queryInterface ( IID_MenuApplet, (QUnknownInterface**) &iface ); if ( iface ) { QString lang = getenv( "LANG" ); QTranslator *trans = new QTranslator ( qApp ); QString type = (*it). left ((*it). find (".")); QString tfn = QPEApplication::qpeDir ( ) + "/i18n/" + lang + "/" + type + ".qm"; if ( trans-> load ( tfn )) qApp-> installTranslator ( trans ); else diff --git a/core/settings/launcher/taskbarsettings.cpp b/core/settings/launcher/taskbarsettings.cpp index b3e302a..d03ea49 100644 --- a/core/settings/launcher/taskbarsettings.cpp +++ b/core/settings/launcher/taskbarsettings.cpp @@ -62,71 +62,88 @@ TaskbarSettings::TaskbarSettings ( QWidget *parent, const char *name ) lay-> addWidget ( m_list ); QWhatsThis::add ( m_list, tr( "Check the applets that you want displayed in the Taskbar." )); connect ( m_list, SIGNAL( clicked ( QListViewItem * )), this, SLOT( appletChanged ( ))); init ( ); } void TaskbarSettings::init ( ) { Config cfg ( "Taskbar" ); cfg. setGroup ( "Applets" ); QStringList exclude = cfg. readListEntry ( "ExcludeApplets", ',' ); QString path = QPEApplication::qpeDir ( ) + "/plugins/applets"; +#ifdef Q_OS_MACX + QStringList list = QDir ( path, "lib*.dylib" ). entryList ( ); +#else QStringList list = QDir ( path, "lib*.so" ). entryList ( ); +#endif /* Q_OS_MACX */ for ( QStringList::Iterator it = list. begin ( ); it != list. end ( ); ++it ) { QString name; QPixmap icon; TaskbarNamedAppletInterface *iface = 0; + qWarning("Load applet: %s", (*it).latin1() ); QLibrary *lib = new QLibrary ( path + "/" + *it ); lib-> queryInterface ( IID_TaskbarNamedApplet, (QUnknownInterface**) &iface ); + qWarning("<1>"); if ( iface ) { + qWarning("<2>"); QString lang = getenv( "LANG" ); QTranslator *trans = new QTranslator ( qApp ); QString type = (*it). left ((*it). find (".")); QString tfn = QPEApplication::qpeDir ( ) + "/i18n/" + lang + "/" + type + ".qm"; if ( trans-> load ( tfn )) qApp-> installTranslator ( trans ); else delete trans; name = iface-> name ( ); icon = iface-> icon ( ); iface-> release ( ); } + qWarning("<3>"); if ( !iface ) { + qWarning("<4>"); lib-> queryInterface ( IID_TaskbarApplet, (QUnknownInterface**) &iface ); if ( iface ) { + qWarning("<5>"); name = (*it). mid ( 3 ); + qWarning("Found applet: %s", name.latin1() ); +#ifdef Q_OS_MACX + int sep = name. find( ".dylib" ); +#else int sep = name. find( ".so" ); +#endif /* Q_OS_MACX */ if ( sep > 0 ) name. truncate ( sep ); sep = name. find ( "applet" ); if ( sep == (int) name.length ( ) - 6 ) name. truncate ( sep ); name[0] = name[0]. upper ( ); iface-> release ( ); } } + qWarning("<6>"); if ( iface ) { + qWarning("<7>"); QCheckListItem *item; item = new QCheckListItem ( m_list, name, QCheckListItem::CheckBox ); if ( !icon. isNull ( )) item-> setPixmap ( 0, icon ); item-> setOn ( exclude. find ( *it ) == exclude. end ( )); m_applets [*it] = item; } lib-> unload ( ); delete lib; } } void TaskbarSettings::appletChanged() { m_applets_changed = true; } diff --git a/development/keyview/keyview.pro b/development/keyview/keyview.pro index 70cc171..ca657bd 100644 --- a/development/keyview/keyview.pro +++ b/development/keyview/keyview.pro @@ -1,19 +1,19 @@ TEMPLATE = lib -#CONFIG = qt warn_on debug -CONFIG = qt warn_on release +#CONFIG = qt plugin warn_on debug +CONFIG = qt plugin warn_on release HEADERS = keyview.h keyboardimpl.h SOURCES = keyview.cpp keyboardimpl.cpp INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include ../../launcher LIBS += -lqpe INTERFACES = TARGET = keyview DESTDIR = $(OPIEDIR)/plugins/inputmethods TRANSLATIONS = ../i18n/de/keyview.ts \ ../i18n/nl/keyview.ts \ ../i18n/da/keyview.ts \ ../i18n/xx/keyview.ts \ ../i18n/en/keyview.ts \ ../i18n/es/keyview.ts \ ../i18n/fr/keyview.ts \ diff --git a/development/macosx/README_MACOSX b/development/macosx/README_MACOSX new file mode 100644 index 0000000..e2ed15f --- a/dev/null +++ b/development/macosx/README_MACOSX @@ -0,0 +1,91 @@ +Information about porting Opie to MacOS-X (eilers) +================================================== + +Credits: +-------- + +Special thanks to xxxx for its patches for qt-X11 (2.3.2), QT/E (2.3.5) and qtopia (1.6.1). +Without them, I wouldn't be able to provide the port for OPIE to MacOS-X that fast.. + +Status: +------- +The basic system works quite well. But a lot of applications and plugins, +which are platform specific, need some work to be compileable. + +What is ready: + +libqpe +libopie1 +pim-applications (addressbook, todolist, datebook, today) +A lot of applications and plugins which are not platform specific. + +What will follow soon: + +libopie2 + +Remember: A lot of configuration-settings are not tested (as for instance +the quicklauncher) and might fail to compile. +If you want to avoid misconfigurations, you may want to start with +the config-file in this directory. Just copy "config_macosx" to $OPIEDIR/.config +to get a working configuration to start with. + +(The missing apps/plugins will be ported on demand.) + +How to compile Opie for MacOS-X: +------------------------------- + +Before compiling for MacOS-X, you need the following: + +1. X11-Server (Provided by Apple) +2. QT-2.3.2 for X11 +3. QT/E-2.3.7 +4. Patches for QT-2.3.2 for MacOSX +5. Patches for QT/E-2.3.7 for MacOSX + +Please follow the instructions by xxxx how to create a buildsystem +for your Mac. +What is different to the previous desciption: +You don't need Qtopia ! +It is recommended to use QT/E in version 2.3.7 instead of 2.3.5 as described. +The Patch for QT/E for Opie, including all other opie-patches is available in the +qt-directory ($OPIEDIR/qt) and is called "qte237-all-macosx.patch" + +If your buildsystem is working correctly, you should be able to build +opie. You have to enter "make menuconfig" and set +"Build Parameters"->"Target Machine"->"Mac OS X (DARWIN)" +activate the platform specific changes. + +You will see that a lot of applications and plugins/applets will not compile +successfully, due to the fact that they are not ported to this platform. +You may disable them to be able to compile the rest. + + +Information for Developers: +--------------------------- + +1. Platform specific code should be surrounded by +#ifdef Q_OS_MACX +MACOS-X CODE +#else +OTHER-CODE +#endif + +2. The Plugin-Handling by MacOS-X is different than it is by Linux. +On linux-systems, shared libraries are not different to dynamic loaded libraries +(aka plugins). They just are different whether they are loaded automatically +at startup or manually by any application. +On MacOS-X, the plugins are loaded by a special mechanism and must be in a special +binary format. Therefore you have to add the term "plugin" to the CONFIG-clause, as +for instance: + +TEMPLATE=lib +CONFIG += qt plugin release + +If you don't add "plugin" you will get a shared library which is not loadable +(Error-Code: NSObjectFileImageInappropriateFile (2))! + + + +For problems, help and flames, feel free to contact me at + +eilers.stefan@epost.de
\ No newline at end of file diff --git a/development/macosx/config_macosx b/development/macosx/config_macosx new file mode 100644 index 0000000..eb0792f --- a/dev/null +++ b/development/macosx/config_macosx @@ -0,0 +1,290 @@ +# +# Automatically generated make config: don't edit +# + +# +# Build Parameters +# +# CONFIG_TARGET_X86 is not set +CONFIG_TARGET_MACOSX=y +# CONFIG_TARGET_SHARP is not set +# CONFIG_TARGET_IPAQ is not set +# CONFIG_TARGET_RAMSES is not set +# CONFIG_TARGET_SIMPAD is not set +# CONFIG_TARGET_YOPY is not set +# CONFIG_OPTIMIZE is not set +CONFIG_DEBUG=y +CONFIG_QUICK_LAUNCH=y +# CONFIG_OPIE_NO_OVERRIDE_QT is not set +CONFIG_SPECFILE="qws/macx-generic-g++" +CONFIG_EXPERIMENTAL=y + +# +# Base +# +CONFIG_LIBQPE=y +# CONFIG_X11 is not set +CONFIG_LIBOPIE=y +# CONFIG_OPIE-LOGIN is not set +# CONFIG_OPIEALARM is not set +CONFIG_LAUNCHER=y +CONFIG_PRELOAD=y +CONFIG_LAUNCHER_CORE=y +CONFIG_QWS=y + +# +# +# + +# +# Applets +# +CONFIG_BATTERYAPPLET=y +# CONFIG_CARDMON is not set +CONFIG_CLIPBOARDAPPLET=y +CONFIG_CLOCKAPPLET=y +CONFIG_HOMEAPPLET=y +# CONFIG_IRDAAPPLET is not set +# CONFIG_LOGOUTAPPLET is not set +# CONFIG_OBEXAPPLET is not set +# CONFIG_OBEX is not set +# CONFIG_RESTARTAPPLET is not set +# CONFIG_ROTATEAPPLET is not set +# CONFIG_SCREENSHOTAPPLET is not set +# CONFIG_SUSPENDAPPLET is not set +# CONFIG_VMEMO is not set +# CONFIG_VOLUMEAPPLET is not set +# CONFIG_VTAPPLET is not set + +# +# Network applet needs a libqpe and libopie2 (core, ui, net) +# +CONFIG_NOTESAPPLET=y +# CONFIG_WIRELESSAPPLET is not set + +# +# Apps +# +# CONFIG_CALIBRATE is not set +# CONFIG_EMBEDDEDKONSOLE is not set +CONFIG_FILEBROWSER=y +CONFIG_HELPBROWSER=y +# CONFIG_OAPP is not set +CONFIG_OIPKG=y +CONFIG_QCOP=y +CONFIG_TEXTEDIT=y +# CONFIG_ADVANCEDFM is not set +# CONFIG_AQPKG is not set +CONFIG_CHECKBOOK=y +# CONFIG_ODICT is not set +# CONFIG_BARTENDER is not set +# CONFIG_OPIE-CONSOLE is not set +# CONFIG_OPIE-READER is not set +CONFIG_OPIE-SHEET=y +CONFIG_OPIE-WRITE=y +CONFIG_OXYGEN=y +CONFIG_SYSINFO=y +CONFIG_TABLEVIEWER=y +CONFIG_TINYKATE=y +CONFIG_LIBKATE=y +# CONFIG_ZSAFE is not set + +# +# Communications and Networking +# +# CONFIG_GSMTOOL is not set +# CONFIG_KEYPEBBLE is not set +# CONFIG_MOBILEMSG is not set +# CONFIG_MAIL is not set +# CONFIG_FTPLIB is not set +# CONFIG_MAILIT is not set +# CONFIG_OPIEIRC is not set +# CONFIG_OPIE-RDESKTOP is not set +# CONFIG_UBROWSER is not set + +# +# wellenreiter needs libqpe, libopie1 and libopie2 (core+net+ui) +# + +# +# Games +# +CONFIG_BACKGAMMON=y +CONFIG_BOUNCE=y +CONFIG_BUZZWORD=y +CONFIG_FIFTEEN=y +CONFIG_GO=y +CONFIG_KBILL=y +CONFIG_KCHECKERS=y +CONFIG_KPACMAN=y +CONFIG_MINDBREAKER=y +CONFIG_MINESWEEP=y +# CONFIG_WORDGAME is not set +CONFIG_PARASHOOT=y +CONFIG_QASTEROIDS=y +# CONFIG_SFCAVE is not set +# CONFIG_SFCAVE-SDL is not set +# CONFIG_SNAKE is not set +CONFIG_SOLITAIRE=y +# CONFIG_TETRIX is not set +# CONFIG_TICTAC is not set + +# +# Graphics and Multimedia +# +# CONFIG_FREETYPE is not set +CONFIG_DRAWPAD=y +# CONFIG_QPDF is not set +# CONFIG_OPIEPLAYER is not set + +# +# opie-camera needs a libqpe, libopie and libopie2core +# +# CONFIG_OPIEPLAYER2 is not set +# CONFIG_OPIEREC is not set +CONFIG_SHOWIMG=y + +# +# Input methods +# +# CONFIG_DASHER is not set +# CONFIG_DVORAK is not set +CONFIG_HANDWRITING=y + +# +# opie-handwriting-classicset automatically selected +# + +# +# opie-handwriting-graffitiset automatically selected +# +CONFIG_JUMPX=y +# CONFIG_KEYBOARD is not set +CONFIG_KJUMPX=y +# CONFIG_MULTIKEY is not set +CONFIG_PICKBOARD=y +CONFIG_UNIKEYBOARD=y + +# +# Pim +# +CONFIG_ADDRESSBOOK=y +CONFIG_DATEBOOK=y +CONFIG_OSEARCH=y +CONFIG_TODAY=y +CONFIG_TODO=y + +# +# Today Plugins +# +# CONFIG_TODAY_FORTUNE is not set +# CONFIG_TODAY_STOCKTICKER is not set +# CONFIG_TODAY_WEATHER is not set +CONFIG_TODAY_ADDRESSBOOK=y +CONFIG_TODAY_DATEBOOK=y +CONFIG_TODAY_MAIL=y +CONFIG_TODAY_TODOLIST=y + +# +# Settings +# +CONFIG_BUTTON-SETTINGS=y +CONFIG_CITYTIME=y +CONFIG_LAUNCHER-SETTINGS=y +CONFIG_LIGHT-AND-POWER=y +CONFIG_SECURITY=y +CONFIG_APPEARANCE2=y +CONFIG_BACKUP=y +CONFIG_LANGUAGE=y +CONFIG_MEDIUMMOUNT=y +CONFIG_NETSYSTEMTIME=y +# CONFIG_NETWORKSETUP is not set +# CONFIG_SOUND is not set +# CONFIG_SSHKEYS is not set +CONFIG_TABMANAGER=y +# CONFIG_USERMANAGER is not set + +# +# Theming +# + +# +# Decorations +# +CONFIG_DECO_FLAT=y +CONFIG_DECO_LIQUID=y +CONFIG_DECO_POLISHED=y + +# +# Styles +# +CONFIG_FLAT=y +CONFIG_FRESH=y +CONFIG_LIQUID=y +CONFIG_METAL=y +CONFIG_THEME=y + +# +# Tools +# +CONFIG_CALCULATOR=y +CONFIG_CLOCK=y +CONFIG_EUROCONV=y +# CONFIG_FORMATTER is not set +CONFIG_OPIE-SH=y +# CONFIG_REMOTE is not set + +# +# Development +# +# CONFIG_KEYVIEW is not set + +# +# Examples +# +# CONFIG_EXAMPLES is not set + +# +# +# + +# +# Experimental +# + +# +# libopie2 +# +# CONFIG_LIBOPIE2CORE is not set + +# +# libopie2db needs a libqpe and libopie2core +# + +# +# libopie2net needs a libqpe and libopie2core +# + +# +# libopie2pim needs a libqpe and libopie2core +# + +# +# libopie2ui needs a libqpe and libopie2core +# + +# +# libopie2mm needs a libqpe and libopie2core +# + +# +# +# + +# +# the examples need a libqpe, libopie2core, libopie2db, libopie2net, libopie2pim, libopie2ui and libopie2mm +# + +# +# SQL-Support needs libopie2db! +# diff --git a/include.pro b/include.pro index 70ed731..4bdcaa7 100644 --- a/include.pro +++ b/include.pro @@ -1,20 +1,21 @@ include ( $(OPIEDIR)/gen.pro ) # base opie install path -prefix = /opt/QtPalmtop +# prefix = /opt/QtPalmtop ??? Why here (eilers) ??? +prefix = $(OPIEDIR) contains( CONFIG, quick-app-lib ) { TEMPLATE = lib DESTDIR = $(OPIEDIR)/plugins/application DEFINES += OPIE_APP_INTERFACE !contains( TARGET, launcher ) { message( Linking $$TARGET to quicklauncher ) system( rm -f $$(OPIEDIR)/bin/$$TARGET ) system( ln -s quicklauncher $$(OPIEDIR)/bin/$$TARGET ) } } contains ( CONFIG, quick-app-bin ) { TEMPLATE = app DESTDIR = $(OPIEDIR)/bin DEFINES -= OPIE_APP_INTERFACE @@ -82,24 +83,33 @@ opie-lrelease.target = opie-lrelease opie-lrelease.commands = opie-lrelease $(PRO) lupdate.target = lupdate lupdate.commands = lupdate -noobsolete $(PRO) lrelease.target = lrelease lrelease.commands = lrelease $(PRO) # new message target to get all strings from the apps with and without tr messages.target = messages messages.commands = xgettext -C -n -ktr -kQT_TRANSLATE_NOOP $$HEADERS $$SOURCES -o '$(OPIEDIR)/messages-$(QMAKE_TARGET)-tr.po' && xgettext -C -n -a $$HEADERS $$SOURCES -o '$(OPIEDIR)/messages-$(QMAKE_TARGET)-allstrings.po' ipk.target = ipk ipk.commands = tmp=`mktemp -d /tmp/ipkg-opie.XXXXXXXXXX` && ( $(MAKE) INSTALL_ROOT="$$$$tmp" install && ipkg-build $$$$tmp; rm -rf $$$$tmp; ) QMAKE_EXTRA_UNIX_TARGETS += lupdate lrelease ipk opie-lupdate opie-lrelease messages +CONFTEST = $$system( echo $CONFIG_TARGET_MACOSX ) +contains( CONFTEST, y ){ +QMAKE_LFLAGS += -Wl +} +else { QMAKE_LFLAGS += -Wl,-rpath=$$prefix/lib +# I am not sure whether it is a good idea to change the way plugins is build +# on linux. Therefore I remove the "plugin" term, which is needed by MacOS-X +CONFIG -= plugin +} QMAKE_LIBDIR += $(OPIEDIR)/lib MOC_DIR=.moc/$(PLATFORM) OBJECTS_DIR=.obj/$(PLATFORM) #was here now at thetop #include ( $(OPIEDIR)/gen.pro ) diff --git a/inputmethods/dasher/dasher.pro b/inputmethods/dasher/dasher.pro index 7b6def9..b7669a4 100644 --- a/inputmethods/dasher/dasher.pro +++ b/inputmethods/dasher/dasher.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = Alphabet.h \ DasherModel.h \ FrameRate.h \ AlphabetMap.h \ DasherNode.h \ LanguageModel.h \ AlphIO.h \ DasherScreen.h \ PPMLanguageModel.h \ Context.h \ DasherSettingsInterface.h \ QtDasherImpl.h \ CustomAlphabet.h \ DasherTypes.h \ QtDasherPlugin.h \ diff --git a/inputmethods/dvorak/dvorak.pro b/inputmethods/dvorak/dvorak.pro index cd30aa2..67fe4e6 100644 --- a/inputmethods/dvorak/dvorak.pro +++ b/inputmethods/dvorak/dvorak.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = dvorak.h \ dvorakimpl.h SOURCES = dvorak.cpp \ dvorakimpl.cpp TARGET = qdvorak DESTDIR = ../../plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include ../../launcher LIBS += -lqpe -L$(OPIEDIR)/plugins/inputmethods -lqpickboard QMAKE_LFLAGS += -Wl,-rpath,/opt/QtPalmtop/plugins/inputmethods VERSION = 1.0.0 TRANSLATIONS = ../../i18n/de/libqdvorak.ts \ ../../i18n/nl/libqdvorak.ts \ ../../i18n/da/libqdvorak.ts \ ../../i18n/xx/libqdvorak.ts \ diff --git a/inputmethods/handwriting/handwriting.pro b/inputmethods/handwriting/handwriting.pro index 4ec5932..7a22208 100644 --- a/inputmethods/handwriting/handwriting.pro +++ b/inputmethods/handwriting/handwriting.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = qimpenchar.h \ qimpenprofile.h \ qimpencombining.h \ qimpenhelp.h \ qimpeninput.h \ qimpenmatch.h \ qimpensetup.h \ qimpenstroke.h \ qimpenwidget.h \ qimpenwordpick.h \ handwritingimpl.h SOURCES = qimpenchar.cpp \ qimpenprofile.cpp \ qimpencombining.cpp \ qimpenhelp.cpp \ qimpeninput.cpp \ diff --git a/inputmethods/jumpx/jumpx.pro b/inputmethods/jumpx/jumpx.pro index eff4563..a75ffd5 100644 --- a/inputmethods/jumpx/jumpx.pro +++ b/inputmethods/jumpx/jumpx.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = keyboard.h \ keyboardimpl.h SOURCES = keyboard.cpp \ keyboardimpl.cpp TARGET = qjumpx DESTDIR = ../../plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../i18n/de/libqjumpx.ts \ ../../i18n/nl/libqjumpx.ts \ ../../i18n/da/libqjumpx.ts \ ../../i18n/xx/libqjumpx.ts \ ../../i18n/en/libqjumpx.ts \ diff --git a/inputmethods/keyboard/keyboard.pro b/inputmethods/keyboard/keyboard.pro index 5ca97f1..56e35b9 100644 --- a/inputmethods/keyboard/keyboard.pro +++ b/inputmethods/keyboard/keyboard.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = keyboard.h \ keyboardimpl.h SOURCES = keyboard.cpp \ keyboardimpl.cpp TARGET = qkeyboard DESTDIR = ../../plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include ../../launcher LIBS += -lqpe -L$(OPIEDIR)/plugins/inputmethods -lqpickboard QMAKE_LFLAGS += -Wl,-rpath,/opt/QtPalmtop/plugins/inputmethods VERSION = 1.0.0 TRANSLATIONS = ../../i18n/de/libqkeyboard.ts \ ../../i18n/nl/libqkeyboard.ts \ ../../i18n/da/libqkeyboard.ts \ ../../i18n/xx/libqkeyboard.ts \ diff --git a/inputmethods/kjumpx/kjumpx.pro b/inputmethods/kjumpx/kjumpx.pro index 0624583..2dd6ddf 100644 --- a/inputmethods/kjumpx/kjumpx.pro +++ b/inputmethods/kjumpx/kjumpx.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = keyboard.h \ keyboardimpl.h SOURCES = keyboard.cpp \ keyboardimpl.cpp TARGET = qkjumpx DESTDIR = ../../plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../i18n/de/libqkjumpx.ts \ ../../i18n/nl/libqkjumpx.ts \ ../../i18n/da/libqkjumpx.ts \ ../../i18n/xx/libqkjumpx.ts \ ../../i18n/en/libqkjumpx.ts \ diff --git a/inputmethods/multikey/multikey.pro b/inputmethods/multikey/multikey.pro index 424c000..82dcb94 100644 --- a/inputmethods/multikey/multikey.pro +++ b/inputmethods/multikey/multikey.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = keyboard.h \ configdlg.h \ keyboardimpl.h SOURCES = keyboard.cpp \ configdlg.cpp \ keyboardimpl.cpp TARGET = qmultikey DESTDIR = $(OPIEDIR)/plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include ../../launcher LIBS += -lqpe -L$(OPIEDIR)/plugins/inputmethods -lqpickboard QMAKE_LFLAGS += -Wl,-rpath,/opt/QtPalmtop/plugins/inputmethods VERSION = 1.0.0 TRANSLATIONS = ../../i18n/pt_BR/libqmultikey.ts \ ../../i18n/nl/libqmultikey.ts \ diff --git a/inputmethods/pickboard/pickboard.pro b/inputmethods/pickboard/pickboard.pro index 53ff8f0..b86c069 100644 --- a/inputmethods/pickboard/pickboard.pro +++ b/inputmethods/pickboard/pickboard.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = pickboard.h pickboardcfg.h pickboardimpl.h pickboardpicks.h SOURCES = pickboard.cpp pickboardcfg.cpp pickboardimpl.cpp pickboardpicks.cpp TARGET = qpickboard DESTDIR = ../../plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include ../../launcher LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../i18n/de/libqpickboard.ts \ ../../i18n/nl/libqpickboard.ts \ ../../i18n/da/libqpickboard.ts \ ../../i18n/xx/libqpickboard.ts \ ../../i18n/en/libqpickboard.ts \ ../../i18n/es/libqpickboard.ts \ ../../i18n/fr/libqpickboard.ts \ diff --git a/inputmethods/unikeyboard/unikeyboard.pro b/inputmethods/unikeyboard/unikeyboard.pro index 0732dc8..678f575 100644 --- a/inputmethods/unikeyboard/unikeyboard.pro +++ b/inputmethods/unikeyboard/unikeyboard.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = unikeyboard.h unikeyboardimpl.h SOURCES = unikeyboard.cpp unikeyboardimpl.cpp TARGET = qunikeyboard DESTDIR = ../../plugins/inputmethods INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include ../../launcher LIBS += -lqpe VERSION = 1.0.0 TRANSLATIONS = ../../i18n/de/libqunikeyboard.ts \ ../../i18n/nl/libqunikeyboard.ts \ ../../i18n/da/libqunikeyboard.ts \ ../../i18n/xx/libqunikeyboard.ts \ ../../i18n/en/libqunikeyboard.ts \ ../../i18n/es/libqunikeyboard.ts \ ../../i18n/fr/libqunikeyboard.ts \ diff --git a/libopie/libopie.pro b/libopie/libopie.pro index 0398775..bf6b78f 100644 --- a/libopie/libopie.pro +++ b/libopie/libopie.pro @@ -80,36 +80,32 @@ SOURCES = ofontmenu.cc \ pim/opimnotify.cpp \ pim/opimnotifymanager.cpp \ pim/opimmainwindow.cpp \ pim/opimresolver.cpp \ pim/oevent.cpp \ pim/otimezone.cpp \ pim/odatebookaccess.cpp \ pim/odatebookaccessbackend.cpp \ pim/odatebookaccessbackend_xml.cpp \ orecurrancewidget.cpp \ oticker.cpp owait.cpp TARGET = opie INCLUDEPATH += $(OPIEDIR)/include DESTDIR = $(OPIEDIR)/lib$(PROJMAK) -# The following is just for my Notebook ! -# It should never be committed !! (eilers) -# QMAKE_CXXFLAGS += -DQT_NO_SOUND - LIBS += -lqpe # Add SQL-Support if selected by config (eilers) CONFTEST = $$system( echo $CONFIG_SQL_PIM_BACKEND ) contains( CONFTEST, y ){ DEFINES += __USE_SQL LIBS += -lopiedb2 -lsqlite HEADERS += pim/otodoaccesssql.h pim/ocontactaccessbackend_sql.h SOURCES += pim/otodoaccesssql.cpp pim/ocontactaccessbackend_sql.cpp } INTERFACES = otimepickerbase.ui orecurrancebase.ui TARGET = opie diff --git a/libopie/odevice.cpp b/libopie/odevice.cpp index 3edf8e7..fef623a 100644 --- a/libopie/odevice.cpp +++ b/libopie/odevice.cpp @@ -10,33 +10,35 @@ but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include <stdlib.h> #include <unistd.h> #include <fcntl.h> #include <sys/ioctl.h> #include <signal.h> #include <sys/time.h> +#ifndef QT_NO_SOUND #include <linux/soundcard.h> +#endif #include <math.h> #include <qapplication.h> #include <qfile.h> #include <qtextstream.h> #include <qpe/sound.h> #include <qpe/resource.h> #include <qpe/config.h> #include <qpe/qcopenvelope_qws.h> #include "odevice.h" #include <qwindowsystem_qws.h> #ifndef ARRAY_SIZE diff --git a/library/filemanager.cpp b/library/filemanager.cpp index cc657fa..91986a0 100644 --- a/library/filemanager.cpp +++ b/library/filemanager.cpp @@ -18,33 +18,42 @@ ** **********************************************************************/ #include "filemanager.h" #include "applnk.h" #include <qdir.h> #include <qfile.h> #include <qfileinfo.h> #include <qtextstream.h> #include <qtextcodec.h> #include <errno.h> #include <stdlib.h> #include <unistd.h> #include <sys/stat.h> #include <dirent.h> -#include <sys/sendfile.h> +#ifdef Q_OS_MACX +// MacOS X does not have sendfile.. :( +// But maybe in the future.. !? +# ifdef SENDFILE +# include <sys/types.h> +# include <sys/socket.h> +# endif +#else +# include <sys/sendfile.h> +#endif /* Q_OS_MACX */ #include <fcntl.h> /*! \class FileManager \brief The FileManager class assists with AppLnk input/output. */ /*! Constructs a FileManager. */ FileManager::FileManager() { } /*! Destroys a FileManager. @@ -203,65 +212,99 @@ bool FileManager::copyFile( const AppLnk &src, const AppLnk &dest ) if ( ok ) { // okay now rename the file... if ( !renameFile( fn.latin1(), dest.file().latin1() ) ) { qWarning( "problem renaming file %s to %s, errno: %d", fn.latin1(), dest.file().latin1(), errno ); // remove the tmp file, otherwise, it will just lay around... QFile::remove( fn.latin1() ); } } else { QFile::remove( fn.latin1() ); } return ok; } + + bool FileManager::copyFile( const QString & src, const QString & dest ) { bool success = true; struct stat status; int read_fd=0; int write_fd=0; struct stat stat_buf; off_t offset = 0; QFile srcFile(src); QFile destFile(dest); if(!srcFile.open( IO_ReadOnly|IO_Raw)) { return success = false; } read_fd = srcFile.handle(); if(read_fd != -1) { fstat (read_fd, &stat_buf); if( !destFile.open( IO_WriteOnly|IO_Raw ) ) return success = false; write_fd = destFile.handle(); if(write_fd != -1) { int err=0; QString msg; - err = sendfile(write_fd, read_fd, &offset, stat_buf.st_size); - if( err == -1) { - switch(err) { - case EBADF : msg = "The input file was not opened for reading or the output file was not opened for writing. "; - case EINVAL: msg = "Descriptor is not valid or locked. "; - case ENOMEM: msg = "Insufficient memory to read from in_fd."; - case EIO: msg = "Unspecified error while reading from in_fd."; - }; - success = false; - } - } else { +#ifdef Q_OS_MACX +#ifdef SENDMAIL + /* FreeBSD does support a different kind of + * sendfile. (eilers) + * I took this from Very Secure FTPd + * Licence: GPL + * Author: Chris Evans + * sysdeputil.c + */ + /* XXX - start_pos will truncate on 32-bit machines - can we + * say "start from current pos"? + */ + off_t written = 0; + int retval = 0; + retval = sendfile(read_fd, write_fd, offset, stat_buf.st_size, NULL, + &written, 0); + /* Translate to Linux-like retval */ + if (written > 0) + { + err = (int) written; + } +#else /* SENDMAIL */ + err == -1; + msg = "FAILURE: Using unsupported function \"sendfile()\" Need Workaround !!"; + success = false; +# warning "Need workaround for sendfile!!(eilers)" +#endif /* SENDMAIL */ + +#else + err = sendfile(write_fd, read_fd, &offset, stat_buf.st_size); + if( err == -1) { + switch(err) { + case EBADF : msg = "The input file was not opened for reading or the output file was not opened for writing. "; + case EINVAL: msg = "Descriptor is not valid or locked. "; + case ENOMEM: msg = "Insufficient memory to read from in_fd."; + case EIO: msg = "Unspecified error while reading from in_fd."; + }; + success = false; + } +#endif /* Q_OS_MACX */ + if( !success ) + qWarning( msg ); + } else { qWarning("open write failed %s, %s",src.latin1(), dest.latin1()); success = false; } } else { qWarning("open read failed %s, %s",src.latin1(), dest.latin1()); success = false; } srcFile.close(); destFile.close(); // Set file permissions if( stat( (const char *) src, &status ) == 0 ) { chmod( (const char *) dest, status.st_mode ); } return success; } diff --git a/library/fontdatabase.cpp b/library/fontdatabase.cpp index c7a5211..2ad8e95 100644 --- a/library/fontdatabase.cpp +++ b/library/fontdatabase.cpp @@ -157,33 +157,37 @@ void FontDatabase::loadRenderers() #ifndef QT_NO_COMPONENT if ( !factoryList ) factoryList = new QValueList<FontFactory>; QValueList<FontFactory>::Iterator mit; for ( mit = factoryList->begin(); mit != factoryList->end(); ++mit ) { qt_fontmanager->factories.setAutoDelete( false ); qt_fontmanager->factories.removeRef( (*mit).factory ); qt_fontmanager->factories.setAutoDelete( true ); (*mit).interface->release(); (*mit).library->unload(); delete (*mit).library; } factoryList->clear(); QString path = QPEApplication::qpeDir() + "/plugins/fontfactories"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif if ( !dir.exists()) return; QStringList list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { FontFactoryInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if ( lib->queryInterface( IID_FontFactory, (QUnknownInterface**)&iface ) == QS_OK ) { FontFactory factory; factory.library = lib; factory.interface = iface; factory.factory = factory.interface->fontFactory(); factoryList->append( factory ); qt_fontmanager->factories.append( factory.factory ); diff --git a/library/global.cpp b/library/global.cpp index 90954fe..05d23ac 100644 --- a/library/global.cpp +++ b/library/global.cpp @@ -591,33 +591,37 @@ void Global::invoke(const QString &c) unsigned int j; for ( j = 0; j < list.count(); j++ ) slist.append( list[j].utf8() ); const char **args = new (const char *)[slist.count() + 1]; for ( j = 0; j < slist.count(); j++ ) args[j] = slist.at(j); args[j] = NULL; #if !defined(QT_NO_COP) // an attempt to show a wait... // more logic should be used, but this will be fine for the moment... QCopEnvelope ( "QPE/System", "busy()" ); #endif #ifdef HAVE_QUICKEXEC +#ifdef Q_OS_MACX + QString libexe = qpeDir()+"/binlib/lib"+args[0] + ".dylib"; +#else QString libexe = qpeDir()+"/binlib/lib"+args[0] + ".so"; +#endif qDebug("libfile = %s", libexe.latin1() ); if ( QFile::exists( libexe ) ) { qDebug("calling quickexec %s", libexe.latin1() ); quickexecv( libexe.utf8().data(), (const char **)args ); } else #endif { bool success = false; int pfd [2]; if ( ::pipe ( pfd ) < 0 ) pfd [0] = pfd [1] = -1; pid_t pid = ::fork ( ); if ( pid == 0 ) { // child for ( int fd = 3; fd < 100; fd++ ) { diff --git a/library/library.pro b/library/library.pro index ab1f451..5acfc0c 100644 --- a/library/library.pro +++ b/library/library.pro @@ -111,33 +111,33 @@ SOURCES = calendar.cpp \ categoryselect.cpp \ categorywidget.cpp \ ir.cpp \ backend/vcc_yacc.cpp \ backend/vobject.cpp \ findwidget_p.cpp \ finddialog.cpp \ lnkproperties.cpp \ qt_override.cpp # Qt 3 compatibility HEADERS += quuid.h qcom.h qlibrary.h qlibrary_p.h SOURCES += quuid.cpp qlibrary.cpp qlibrary_unix.cpp INCLUDEPATH += $(OPIEDIR)/include backend -LIBS += -ldl -lcrypt -lm +# LIBS += -ldl -lcrypt -lm INTERFACES = passwordbase_p.ui categoryeditbase_p.ui findwidgetbase_p.ui lnkpropertiesbase_p.ui TARGET = qpe DESTDIR = $(OPIEDIR)/lib$(PROJMAK) VERSION = 1.5.0.1 TRANSLATIONS = ../i18n/de/libqpe.ts \ ../i18n/nl/libqpe.ts \ ../i18n/xx/libqpe.ts \ ../i18n/en/libqpe.ts \ ../i18n/es/libqpe.ts \ ../i18n/fr/libqpe.ts \ ../i18n/hu/libqpe.ts \ ../i18n/ja/libqpe.ts \ ../i18n/ko/libqpe.ts \ ../i18n/no/libqpe.ts \ ../i18n/pl/libqpe.ts \ diff --git a/library/network.cpp b/library/network.cpp index 3568809..991e11a 100644 --- a/library/network.cpp +++ b/library/network.cpp @@ -405,33 +405,37 @@ int Network::addStateWidgets(QWidget* parent) } } return n; } static QDict<NetworkInterface> *ifaces; /*! \internal */ NetworkInterface* Network::loadPlugin(const QString& type) { #ifndef QT_NO_COMPONENT if ( !ifaces ) ifaces = new QDict<NetworkInterface>; NetworkInterface *iface = ifaces->find(type); if ( !iface ) { +#ifdef Q_OS_MACX + QString libfile = QPEApplication::qpeDir() + "/plugins/network/lib" + type + ".dylib"; +#else QString libfile = QPEApplication::qpeDir() + "/plugins/network/lib" + type + ".so"; +#endif QLibrary lib(libfile); if ( !lib.queryInterface( IID_Network, (QUnknownInterface**)&iface ) == QS_OK ) return 0; ifaces->insert(type,iface); QStringList langs = Global::languageList(); for (QStringList::ConstIterator it = langs.begin(); it!=langs.end(); ++it) { QString lang = *it; QTranslator * trans = new QTranslator(qApp); QString tfn = QPEApplication::qpeDir()+"/i18n/"+lang+"/lib"+type+".qm"; if ( trans->load( tfn )) qApp->installTranslator( trans ); else delete trans; } } return iface; diff --git a/library/qlibrary_unix.cpp b/library/qlibrary_unix.cpp index 7740321..0229b7b 100644 --- a/library/qlibrary_unix.cpp +++ b/library/qlibrary_unix.cpp @@ -63,33 +63,144 @@ bool QLibraryPrivate::freeLibrary() void* QLibraryPrivate::resolveSymbol( const char* symbol ) { if ( !pHnd ) return 0; void* address = 0; if ( shl_findsym( (shl_t*)&pHnd, symbol, TYPE_UNDEFINED, address ) < 0 ) { #if defined(QT_DEBUG) || defined(QT_DEBUG_COMPONENT) qDebug( "Couldn't resolve symbol \"%s\"", symbol ); #endif return 0; } return address; } -#else // Q_OS_HPUX +#elif defined(_NULL_LIB_) + +bool QLibraryPrivate::loadLibrary() +{ + //qDebug("QLibraryPrivate::loadLibrary\n"); + return FALSE; +} +bool QLibraryPrivate::freeLibrary() +{ + //qDebug("QLibraryPrivate::freeLibrary\n"); + return FALSE; +} +void* QLibraryPrivate::resolveSymbol( const char* symbol ) +{ + //qDebug("QLibraryPrivate::resolveSymbol\n"); + return FALSE; +} + +#elif defined(Q_OS_MACX) + +#define ENUM_DYLD_BOOL +enum DYLD_BOOL { + DYLD_FALSE, + DYLD_TRUE +}; +#include <mach-o/dyld.h> +typedef struct { + NSObjectFileImage img; + NSModule mod; +} DyldLibDesc; + +bool QLibraryPrivate::loadLibrary() +{ + // qDebug("QLibraryPrivate::loadLibrary\n"); + // return FALSE; + if ( pHnd ) + return TRUE; + + QString filename = library->library(); + + NSObjectFileImage img = 0; + NSModule mod = 0; + NSObjectFileImageReturnCode ret = NSCreateObjectFileImageFromFile( filename.latin1() , &img ); + if ( ret != NSObjectFileImageSuccess ) { + qWarning( "Error in NSCreateObjectFileImageFromFile(): %d; Filename: %s", ret, filename.latin1() ); + if (ret == NSObjectFileImageAccess) { + qWarning ("(NSObjectFileImageAccess)" ); + } + } else { + mod = NSLinkModule(img, filename.latin1(), NSLINKMODULE_OPTION_BINDNOW | + NSLINKMODULE_OPTION_PRIVATE | + NSLINKMODULE_OPTION_RETURN_ON_ERROR); + if (mod == 0) { + qWarning( "Error in NSLinkModule()" ); + NSDestroyObjectFileImage(img); + } + } + DyldLibDesc* desc = 0; + if (img != 0 && mod != 0) { + desc = new DyldLibDesc; + desc->img = img; + desc->mod = mod; + } + pHnd = desc; + return pHnd != 0; +} + +bool QLibraryPrivate::freeLibrary() +{ + //qDebug("QLibraryPrivate::freeLibrary\n"); + //return FALSE; + if ( !pHnd ) + return TRUE; + + DyldLibDesc* desc = (DyldLibDesc*) pHnd; + NSModule mod = desc->mod; + NSObjectFileImage img = desc->img; + DYLD_BOOL success = NSUnLinkModule(mod, NSUNLINKMODULE_OPTION_NONE); + if ( success ) { + NSDestroyObjectFileImage(img); + delete desc; + pHnd = 0; + } +#if defined(QT_DEBUG) || defined(QT_DEBUG_COMPONENT) + else { + qWarning( "Error in NSUnLinkModule(): %d", ret ); + } +#endif + return pHnd == 0; +} + +void* QLibraryPrivate::resolveSymbol( const char* symbol ) +{ + //qDebug("QLibraryPrivate::resolveSymbol\n"); + //return FALSE; + if ( !pHnd ) + return 0; + + DyldLibDesc* desc = (DyldLibDesc*) pHnd; + NSSymbol sym = NSLookupSymbolInModule(desc->mod, symbol); + void* address = 0; + if (sym != 0) { + address = NSAddressOfSymbol(sym); + } +#if defined(QT_DEBUG) || defined(QT_DEBUG_COMPONENT) + if ( address == 0 ) + qWarning( "Cannot find symbol: %s", symbol ); +#endif + return address; +} + +#else // Something else, assuming POSIX #include <dlfcn.h> bool QLibraryPrivate::loadLibrary() { if ( pHnd ) return TRUE; QString filename = library->library(); pHnd = dlopen( filename.latin1() , RTLD_LAZY ); #if defined(QT_DEBUG) || defined(QT_DEBUG_COMPONENT) if ( !pHnd ) qWarning( "%s", dlerror() ); #endif return pHnd != 0; diff --git a/library/qpeapplication.cpp b/library/qpeapplication.cpp index d4734ae..a97efc0 100644 --- a/library/qpeapplication.cpp +++ b/library/qpeapplication.cpp @@ -7,33 +7,35 @@ ** GNU General Public License version 2 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** */ #define QTOPIA_INTERNAL_LANGLIST #include <stdlib.h> #include <unistd.h> +#ifndef Q_OS_MACX #include <linux/limits.h> // needed for some toolchains (PATH_MAX) +#endif #include <qfile.h> #include <qqueue.h> #ifdef Q_WS_QWS #ifndef QT_NO_COP #if QT_VERSION <= 231 #define private public #define sendLocally processEvent #include "qcopenvelope_qws.h" #undef private #else #include "qcopenvelope_qws.h" #endif #endif #include <qwindowsystem_qws.h> #endif #include <qtextstream.h> @@ -76,34 +78,35 @@ #endif #include "config.h" #include "network.h" #ifdef QWS #include "fontmanager.h" #endif #include "alarmserver.h" #include "applnk.h" #include "qpemenubar.h" #include "textcodecinterface.h" #include "imagecodecinterface.h" #include <unistd.h> #include <sys/file.h> #include <sys/ioctl.h> +#ifndef QT_NO_SOUND #include <sys/soundcard.h> - +#endif #include "qt_override_p.h" class QPEApplicationData { public: QPEApplicationData ( ) : presstimer( 0 ), presswidget( 0 ), rightpressed( false ), kbgrabbed( false ), notbusysent( false ), preloaded( false ), forceshow( false ), nomaximize( false ), keep_running( true ), qcopQok( false ), qpe_main_widget( 0 ) {} int presstimer; QWidget* presswidget; QPoint presspos; @@ -220,58 +223,66 @@ public: sendQCopQ(); #endif if ( preloaded ) { if (forceshow) show_mx(mw, nomax); } else if ( keep_running ) { show_mx(mw, nomax); } } void loadTextCodecs() { QString path = QPEApplication::qpeDir() + "/plugins/textcodecs"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif QStringList list; if ( dir. exists ( )) list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { TextCodecInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if ( lib->queryInterface( IID_QtopiaTextCodec, (QUnknownInterface**)&iface ) == QS_OK && iface ) { QValueList<int> mibs = iface->mibEnums(); for (QValueList<int>::ConstIterator i = mibs.begin(); i != mibs.end(); ++i) { (void)iface->createForMib(*i); // ### it exists now; need to remember if we can delete it } } else { lib->unload(); delete lib; } } } void loadImageCodecs() { QString path = QPEApplication::qpeDir() + "/plugins/imagecodecs"; +#ifdef Q_OS_MACX + QDir dir( path, "lib*.dylib" ); +#else QDir dir( path, "lib*.so" ); +#endif QStringList list; if ( dir. exists ( )) list = dir.entryList(); QStringList::Iterator it; for ( it = list.begin(); it != list.end(); ++it ) { ImageCodecInterface *iface = 0; QLibrary *lib = new QLibrary( path + "/" + *it ); if ( lib->queryInterface( IID_QtopiaImageCodec, (QUnknownInterface**)&iface ) == QS_OK && iface ) { QStringList formats = iface->keys(); for (QStringList::ConstIterator i = formats.begin(); i != formats.end(); ++i) { (void)iface->installIOHandler(*i); // ### it exists now; need to remember if we can delete it } } else { lib->unload(); @@ -327,102 +338,110 @@ static int& hack(int& i) (void)new QUtf16Codec; #endif return i; } static int muted = 0; static int micMuted = 0; static void setVolume( int t = 0, int percent = -1 ) { switch ( t ) { case 0: { Config cfg( "qpe" ); cfg.setGroup( "Volume" ); if ( percent < 0 ) percent = cfg.readNumEntry( "VolumePercent", 50 ); +#ifndef QT_NO_SOUND int fd = 0; if ( ( fd = open( "/dev/mixer", O_RDWR ) ) >= 0 ) { int vol = muted ? 0 : percent; // set both channels to same volume vol |= vol << 8; ioctl( fd, MIXER_WRITE( 0 ), &vol ); ::close( fd ); } +#endif } break; } } static void setMic( int t = 0, int percent = -1 ) { switch ( t ) { case 0: { Config cfg( "qpe" ); cfg.setGroup( "Volume" ); if ( percent < 0 ) percent = cfg.readNumEntry( "Mic", 50 ); +#ifndef QT_NO_SOUND int fd = 0; int mic = micMuted ? 0 : percent; if ( ( fd = open( "/dev/mixer", O_RDWR ) ) >= 0 ) { ioctl( fd, MIXER_WRITE( SOUND_MIXER_MIC ), &mic ); ::close( fd ); } +#endif } break; } } static void setBass( int t = 0, int percent = -1 ) { switch ( t ) { case 0: { Config cfg( "qpe" ); cfg.setGroup( "Volume" ); if ( percent < 0 ) percent = cfg.readNumEntry( "BassPercent", 50 ); +#ifndef QT_NO_SOUND int fd = 0; int bass = percent; if ( ( fd = open( "/dev/mixer", O_RDWR ) ) >= 0 ) { ioctl( fd, MIXER_WRITE( SOUND_MIXER_BASS ), &bass ); ::close( fd ); } +#endif } break; } } static void setTreble( int t = 0, int percent = -1 ) { switch ( t ) { case 0: { Config cfg( "qpe" ); cfg.setGroup( "Volume" ); if ( percent < 0 ) percent = cfg.readNumEntry( "TreblePercent", 50 ); +#ifndef QT_NO_SOUND int fd = 0; int treble = percent; if ( ( fd = open( "/dev/mixer", O_RDWR ) ) >= 0 ) { ioctl( fd, MIXER_WRITE( SOUND_MIXER_TREBLE ), &treble ); ::close( fd ); } +#endif } break; } } /*! \class QPEApplication qpeapplication.h \brief The QPEApplication class implements various system services that are available to all Qtopia applications. Simply by using QPEApplication instead of QApplication, a standard Qt application becomes a Qtopia application. It automatically follows style changes, quits and raises, and in the case of \link docwidget.html document-oriented\endlink applications, changes the currently displayed document in response to the environment. @@ -1636,37 +1655,43 @@ void QPEApplication::internalSetStyle( const QString &style ) #endif #ifndef QT_NO_STYLE_MOTIF else if ( style == "Motif" ) { setStyle( new QMotifStyle ); } #endif #ifndef QT_NO_STYLE_MOTIFPLUS else if ( style == "MotifPlus" ) { setStyle( new QMotifPlusStyle ); } #endif else { QStyle *sty = 0; QString path = QPEApplication::qpeDir ( ) + "/plugins/styles/"; +#ifdef Q_OS_MACX + if ( style. find ( ".dylib" ) > 0 ) + path += style; + else + path = path + "lib" + style. lower ( ) + ".dylib"; // compatibility +#else if ( style. find ( ".so" ) > 0 ) path += style; else path = path + "lib" + style. lower ( ) + ".so"; // compatibility - +#endif static QLibrary *lastlib = 0; static StyleInterface *lastiface = 0; QLibrary *lib = new QLibrary ( path ); StyleInterface *iface = 0; if (( lib-> queryInterface ( IID_Style, ( QUnknownInterface ** ) &iface ) == QS_OK ) && iface ) sty = iface-> style ( ); if ( sty ) { setStyle ( sty ); if ( lastiface ) lastiface-> release ( ); lastiface = iface; diff --git a/library/qpedecoration_qws.cpp b/library/qpedecoration_qws.cpp index 933542d..bac1a75 100644 --- a/library/qpedecoration_qws.cpp +++ b/library/qpedecoration_qws.cpp @@ -499,37 +499,45 @@ QPEDecoration::QPEDecoration( const QString &plugin ) void QPEDecoration::init ( const QString &plugin ) { libname = plugin; if ( wdlib ) { wdiface->release(); wdlib->unload(); delete wdlib; wdlib = 0; } else { delete wdiface; } WindowDecorationInterface *iface = 0; QString path = QPEApplication::qpeDir() + "/plugins/decorations/"; +#ifdef Q_OS_MACX + if ( plugin.find( ".dylib" ) > 0 ) { +#else if ( plugin.find( ".so" ) > 0 ) { +#endif // full library name supplied path += plugin; } else { +#ifdef Q_OS_MACX + path += "lib" + plugin.lower() + ".dylib"; // compatibility +#else path += "lib" + plugin.lower() + ".so"; // compatibility +#endif } QLibrary *lib = new QLibrary( path ); if ( lib->queryInterface( IID_WindowDecoration, (QUnknownInterface**)&iface ) == QS_OK && iface ) { wdiface = iface; wdlib = lib; } else { delete lib; wdiface = new DefaultWindowDecoration; } helpFile = QString(qApp->argv()[0]) + ".html"; QStringList helpPath = Global::helpPath(); helpExists = FALSE; for (QStringList::ConstIterator it=helpPath.begin(); it!=helpPath.end() && !helpExists; ++it) { helpExists = QFile::exists( *it + "/" + helpFile ); diff --git a/library/sound.cpp b/library/sound.cpp index c8704f9..5b67995 100644 --- a/library/sound.cpp +++ b/library/sound.cpp @@ -15,33 +15,36 @@ ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #include <qpe/resource.h> #include <qpe/sound.h> #include <qpe/qcopenvelope_qws.h> #include <qsound.h> #include <qfile.h> #include <unistd.h> #include <fcntl.h> #include <sys/ioctl.h> + +#ifndef QT_NO_SOUND #include <sys/soundcard.h> +#endif #include "config.h" #include <qmessagebox.h> #ifndef QT_NO_SOUND static int WAVsoundDuration(const QString& filename) { // bad solution // most of this is copied from qsoundqss.cpp QFile input(filename); if ( !input.open(IO_ReadOnly) ) return 0; struct QRiffChunk { char id[4]; diff --git a/library/storage.cpp b/library/storage.cpp index dc5cc22..f8b75d0 100644 --- a/library/storage.cpp +++ b/library/storage.cpp @@ -16,64 +16,76 @@ ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #include <qpe/storage.h> #include <qpe/custom.h> #include <qfile.h> #include <qtimer.h> #include <qcopchannel_qws.h> #include <stdio.h> -#if defined(_OS_LINUX_) || defined(Q_OS_LINUX) +#if defined(_OS_LINUX_) || defined(Q_OS_LINUX) #include <sys/vfs.h> #include <mntent.h> #endif +#ifdef Q_OS_MACX +# include <sys/param.h> +# include <sys/ucred.h> +# include <sys/mount.h> +# include <stdio.h> // For strerror() +# include <errno.h> +#endif /* Q_OS_MACX */ + #include <qstringlist.h> -#include <sys/vfs.h> -#include <mntent.h> +// Shouldn't be here ! (eilers) +// #include <sys/vfs.h> +// #include <mntent.h> static bool isCF(const QString& m) { + +#ifndef Q_OS_MACX FILE* f = fopen("/var/run/stab", "r"); if (!f) f = fopen("/var/state/pcmcia/stab", "r"); if (!f) f = fopen("/var/lib/pcmcia/stab", "r"); if ( f ) { char line[1024]; char devtype[80]; char devname[80]; while ( fgets( line, 1024, f ) ) { // 0 ide ide-cs 0 hda 3 0 if ( sscanf(line,"%*d %s %*s %*s %s", devtype, devname )==2 ) { if ( QString(devtype) == "ide" && m.find(devname)>0 ) { fclose(f); return TRUE; } } } fclose(f); } +#endif /* Q_OS_MACX */ return FALSE; } /*! \class StorageInfo storage.h \brief The StorageInfo class describes the disks mounted on the file system. This class provides access to the mount information for the Linux filesystem. Each mount point is represented by the FileSystem class. To ensure this class has the most up to date size information, call the update() method. Note that this will automatically be signaled by the operating system when a disk has been mounted or unmounted. \ingroup qtopiaemb */ /*! Constructor that determines the current mount points of the filesystem. @@ -191,46 +203,66 @@ void StorageInfo::update() humanname = tr("Internal Storage") + " " + disk; else if ( disk.left(5) == "tmpfs" ) //ipaqs /mnt/ramfs humanname = tr("Internal Memory"); FileSystem *fs = new FileSystem( disk, *fsit, humanname, removable, opts ); mFileSystems.append( fs ); } emit disksChanged(); } else { // just update them for (QListIterator<FileSystem> i(mFileSystems); i.current(); ++i) i.current()->update(); } #endif } bool deviceTab( const char *device) { - QString name = device; - bool hasDevice=false; + QString name = device; + bool hasDevice=false; + +#ifdef Q_OS_MACX + // Darwin (MacOS X) + struct statfs** mntbufp; + int count = 0; + if ( ( count = getmntinfo( mntbufp, MNT_WAIT ) ) == 0 ){ + qWarning("deviceTab: Error in getmntinfo(): %s",strerror( errno ) ); + hasDevice = false; + } + for( int i = 0; i < count; i++ ){ + QString deviceName = mntbufp[i]->f_mntfromname; + qDebug(deviceName); + if( deviceName.left( name.length() ) == name ) + hasDevice = true; + } +#else + // Linux struct mntent *me; FILE *mntfp = setmntent( "/etc/mtab", "r" ); if ( mntfp ) { while ( (me = getmntent( mntfp )) != 0 ) { QString deviceName = me->mnt_fsname; // qDebug(deviceName); if( deviceName.left(name.length()) == name) { hasDevice = true; } } } endmntent( mntfp ); +#endif /* Q_OS_MACX */ + + return hasDevice; } /*! * @fn static bool StorageInfo::hasCf() * @brief returns whether device has Cf mounted * */ bool StorageInfo::hasCf() { return deviceTab("/dev/hd"); } /*! * @fn static bool StorageInfo::hasSd() * @brief returns whether device has SD mounted diff --git a/mkspecs/qws/macx-generic-g++/qmake.conf b/mkspecs/qws/macx-generic-g++/qmake.conf index 3460a40..04f1c8b 100644 --- a/mkspecs/qws/macx-generic-g++/qmake.conf +++ b/mkspecs/qws/macx-generic-g++/qmake.conf @@ -11,33 +11,33 @@ QMAKE_EXTENSION_SHLIB = dylib QMAKE_CC = $(TB)cc QMAKE_LEX = flex QMAKE_LEXFLAGS = QMAKE_YACC = yacc QMAKE_YACCFLAGS = -d QMAKE_CFLAGS = -pipe $(CFLAGS_EXTRA) QMAKE_CFLAGS_WARN_ON = -Wall -W QMAKE_CFLAGS_WARN_OFF = QMAKE_CFLAGS_RELEASE = $(if $(CFLAGS_RELEASE),$(CFLAGS_RELEASE), -O2 -fno-default-inline) QMAKE_CFLAGS_DEBUG = -g QMAKE_CFLAGS_SHLIB = -fPIC QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses QMAKE_CFLAGS_THREAD = -D_REENTRANT QMAKE_CXX = $(TB)c++ -QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -DQT_NO_QWS_TRANSFORMED -DQWS -fno-exceptions -fno-rtti $(CXXFLAGS_EXTRA) +QMAKE_CXXFLAGS = $$QMAKE_CFLAGS -DQT_NO_QWS_TRANSFORMED -DQWS -fno-exceptions -fno-rtti $(CXXFLAGS_EXTRA) -DQ_OS_MACX -DQT_NO_SOUND -DOPIE_NO_OVERRIDE_QT QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG QMAKE_CXXFLAGS_SHLIB = $$QMAKE_CFLAGS_SHLIB QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD QMAKE_INCDIR = QMAKE_LIBDIR = QMAKE_INCDIR_X11 = QMAKE_LIBDIR_X11 = QMAKE_INCDIR_QT = $(QTDIR)/include QMAKE_LIBDIR_QT = $(QTDIR)/lib QMAKE_INCDIR_OPENGL = /usr/X11R6/include QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib @@ -45,32 +45,33 @@ QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib QMAKE_LINK = $$QMAKE_CXX QMAKE_LINK_SHLIB = $$QMAKE_CXX QMAKE_LFLAGS = $(LFLAGS_EXTRA) QMAKE_LFLAGS_RELEASE = QMAKE_LFLAGS_DEBUG = QMAKE_LFLAGS_SHLIB = -dynamiclib QMAKE_LFLAGS_INCREMENTAL = -undefined suppress -flat_namespace QMAKE_LFLAGS_PLUGIN = -bundle QMAKE_LFLAGS_SONAME = QMAKE_LFLAGS_THREAD = QMAKE_RPATH = QMAKE_LIBS = $(LIBS_EXTRA) QMAKE_LIBS_X11 = QMAKE_LIBS_X11SM = QMAKE_LIBS_QT = -lqte +#QMAKE_LIBS_QT = libqte.dylib QMAKE_LIBS_QT_THREAD = -lqte-mt QMAKE_LIBS_QT_OPENGL = -lqgl QMAKE_LIBS_THREAD = QMAKE_MOC = $(QTDIR)/bin/moc QMAKE_UIC = $(QTDIR)/bin/uic QMAKE_AR = ar cqs QMAKE_RANLIB = QMAKE_TAR = tar -cf QMAKE_GZIP = gzip -9f QMAKE_COPY = cp -f QMAKE_MOVE = mv -f QMAKE_DEL_FILE = rm -f diff --git a/noncore/applets/networkapplet/networkapplet.pro b/noncore/applets/networkapplet/networkapplet.pro index ec58455..368f80e 100644 --- a/noncore/applets/networkapplet/networkapplet.pro +++ b/noncore/applets/networkapplet/networkapplet.pro @@ -1,15 +1,15 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = networkapplet.h SOURCES = networkapplet.cpp TARGET = networkapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe -lopiecore2 -lopieui2 -lopienet2 VERSION = 0.1.0 MOC_DIR = moc OBJECTS_DIR = obj include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/applets/notesapplet/notesapplet.pro b/noncore/applets/notesapplet/notesapplet.pro index e4558f7..3075948 100644 --- a/noncore/applets/notesapplet/notesapplet.pro +++ b/noncore/applets/notesapplet/notesapplet.pro @@ -1,16 +1,16 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = notes.h notesappletimpl.h SOURCES = notes.cpp notesappletimpl.cpp TARGET = notesapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 MOC_DIR=opieobj OBJECTS_DIR=opieobj include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/applets/wirelessapplet/wirelessapplet.pro b/noncore/applets/wirelessapplet/wirelessapplet.pro index 501327d..aee89d7 100644 --- a/noncore/applets/wirelessapplet/wirelessapplet.pro +++ b/noncore/applets/wirelessapplet/wirelessapplet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = wireless.h wirelessappletimpl.h networkinfo.h mgraph.h advancedconfig.h SOURCES = wireless.cpp wirelessappletimpl.cpp networkinfo.cpp mgraph.cpp advancedconfig.cpp INTERFACES = advancedconfigbase.ui TARGET = wirelessapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += ../$(OPIEDIR)/include LIBS += -lqpe VERSION = 0.1.0 TRANSLATIONS = ../../../i18n/de/libwirelessapplet.ts \ ../../../i18n/nl/libwirelessapplet.ts \ ../../../i18n/da/libwirelessapplet.ts \ ../../../i18n/xx/libwirelessapplet.ts \ ../../../i18n/en/libwirelessapplet.ts \ ../../../i18n/es/libwirelessapplet.ts \ diff --git a/noncore/decorations/flat/flat.pro b/noncore/decorations/flat/flat.pro index e691339..f3d63ea 100644 --- a/noncore/decorations/flat/flat.pro +++ b/noncore/decorations/flat/flat.pro @@ -1,15 +1,15 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = flat.h SOURCES = flat.cpp TARGET = flat DESTDIR = $(OPIEDIR)/plugins/decorations INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/decorations/liquid/liquid.pro b/noncore/decorations/liquid/liquid.pro index 7c310a6..2afed26 100644 --- a/noncore/decorations/liquid/liquid.pro +++ b/noncore/decorations/liquid/liquid.pro @@ -1,14 +1,14 @@ TEMPLATE = lib -CONFIG = qt embedded release warn_on +CONFIG = qt plugin embedded release warn_on SOURCES = liquid.cpp HEADERS = liquid.h LIBS += -lqpe INCLUDEPATH += $(OPIEDIR)/include DESTDIR = $(OPIEDIR)/plugins/decorations TARGET = liquid VERSION = 1.0.0 include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/decorations/polished/polished.pro b/noncore/decorations/polished/polished.pro index 1ee940e..d3f3dcc 100644 --- a/noncore/decorations/polished/polished.pro +++ b/noncore/decorations/polished/polished.pro @@ -1,15 +1,15 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = polished.h SOURCES = polished.cpp TARGET = polished DESTDIR = $(OPIEDIR)/plugins/decorations INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/net/opietooth/applet/applet.pro b/noncore/net/opietooth/applet/applet.pro index 23c1d0a..4efcb42 100644 --- a/noncore/net/opietooth/applet/applet.pro +++ b/noncore/net/opietooth/applet/applet.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = bluezapplet.h bluezappletimpl.h SOURCES = bluezapplet.cpp bluezappletimpl.cpp TARGET = bluetoothapplet DESTDIR = $(OPIEDIR)/plugins/applets INCLUDEPATH += $(OPIEDIR)/include INCLUDEPATH += $(OPIEDIR)/noncore/net/opietooth/lib DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe -lopietooth VERSION = 0.0.3 TRANSLATIONS = ../../../../i18n/de/libbluetoothapplet.ts \ ../../../../i18n/nl/libbluetoothapplet.ts \ ../../../../i18n/da/libbluetoothapplet.ts \ ../../../../i18n/xx/libbluetoothapplet.ts \ ../../../../i18n/en/libbluetoothapplet.ts \ ../../../../i18n/es/libbluetoothapplet.ts \ diff --git a/noncore/settings/networksettings/ppp/ppp.pro b/noncore/settings/networksettings/ppp/ppp.pro index 84acd0e..dc78eb1 100644 --- a/noncore/settings/networksettings/ppp/ppp.pro +++ b/noncore/settings/networksettings/ppp/ppp.pro @@ -1,17 +1,17 @@ #TEMPLATE = app # TEMPLATE = lib -#CONFIG += qt warn_on release -CONFIG += qt warn_on debug +#CONFIG += qt plugin warn_on release +CONFIG += qt plugin warn_on debug DESTDIR = $(OPIEDIR)/plugins/networksettings HEADERS = pppmodule.h modem.h modeminfo.h pppdata.h kpppconfig.h pppdata.h runtests.h general.h modemcmds.h conwindow.h accounts.h connect.h edit.h scriptedit.h pppdargs.h iplined.h pwentry.h pppconfig.h interfaceinformationppp.h interfaceppp.h authwidget.h chooserwidget.h devices.h SOURCES = pppmodule.cpp modem.cpp modeminfo.cpp pppdata.cpp runtests.cpp general.cpp modemcmds.cpp conwindow.cpp accounts.cpp connect.cpp edit.cpp scriptedit.cpp pppdargs.cpp iplined.cpp pwentry.cpp pppconfig.cpp interfaceinformationppp.cpp interfaceppp.cpp authwidget.cpp chooserwidget.cpp devices.cpp INCLUDEPATH += $(OPIEDIR)/include ../ ../interfaces/ DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe -L../interfaces/ -linterfaces TARGET = kppp VERSION = 1.0.0 include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/settings/networksettings/wlan/wlan.pro b/noncore/settings/networksettings/wlan/wlan.pro index 82a5b2f..098ad1d 100644 --- a/noncore/settings/networksettings/wlan/wlan.pro +++ b/noncore/settings/networksettings/wlan/wlan.pro @@ -1,21 +1,21 @@ # TEMPLATE = lib #TEMPLATE = app -CONFIG += qt warn_on release -#CONFIG += qt warn_on debug +CONFIG += qt plugin warn_on release +#CONFIG += qt plugin warn_on debug DESTDIR = $(OPIEDIR)/plugins/networksettings HEADERS = infoimp.h wlanmodule.h wextensions.h keyedit.h SOURCES = infoimp.cpp wlanmodule.cpp wextensions.cpp keyedit.cpp INCLUDEPATH += $(OPIEDIR)/include ../ ../interfaces/ DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe -L../interfaces/ -linterfaces -lopienet2 INTERFACES = wlan.ui info.ui TARGET = wlan VERSION = 1.0.0 #CONFIG += wirelessopts wirelessopts { HEADERS += wlanimp.h SOURCES += wlanimp.cpp } diff --git a/noncore/styles/flat/flat.pro b/noncore/styles/flat/flat.pro index ed25d5c..2721e14 100644 --- a/noncore/styles/flat/flat.pro +++ b/noncore/styles/flat/flat.pro @@ -1,15 +1,15 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = flat.h SOURCES = flat.cpp TARGET = flatstyle DESTDIR = $(OPIEDIR)/plugins/styles INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/styles/fresh/fresh.pro b/noncore/styles/fresh/fresh.pro index 88a8de3..564c5cd 100644 --- a/noncore/styles/fresh/fresh.pro +++ b/noncore/styles/fresh/fresh.pro @@ -1,15 +1,15 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS = fresh.h SOURCES = fresh.cpp TARGET = freshstyle DESTDIR = $(OPIEDIR)/plugins/styles INCLUDEPATH += $(OPIEDIR)/include DEPENDPATH += $(OPIEDIR)/include LIBS += -lqpe VERSION = 1.0.0 include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/styles/liquid/liquid.pro b/noncore/styles/liquid/liquid.pro index 9241eba..4e1c575 100644 --- a/noncore/styles/liquid/liquid.pro +++ b/noncore/styles/liquid/liquid.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG = qt embedded release warn_on +CONFIG = qt plugin embedded release warn_on SOURCES = liquid.cpp \ effects.cpp \ liquidset.cpp \ plugin.cpp HEADERS = liquid.h \ effects.h \ liquidset.h \ plugin.h LIBS += -lqpe -lopie INCLUDEPATH += $(OPIEDIR)/include DESTDIR = $(OPIEDIR)/plugins/styles TARGET = liquid VERSION = 1.0.0 diff --git a/noncore/styles/metal/metal.pro b/noncore/styles/metal/metal.pro index 3bb376d..8633284 100644 --- a/noncore/styles/metal/metal.pro +++ b/noncore/styles/metal/metal.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG = qt embedded release warn_on +CONFIG = qt plugin embedded release warn_on SOURCES = metal.cpp plugin.cpp HEADERS = metal.h plugin.h LIBS += -lqpe INCLUDEPATH += $(OPIEDIR)/include DESTDIR = $(OPIEDIR)/plugins/styles TARGET = metal VERSION = 1.0.0 TRANSLATIONS = ../../../i18n/de/libmetal.ts \ ../../../i18n/nl/libmetal.ts \ ../../../i18n/da/libmetal.ts \ ../../../i18n/xx/libmetal.ts \ ../../../i18n/en/libmetal.ts \ ../../../i18n/es/libmetal.ts \ ../../../i18n/fr/libmetal.ts \ diff --git a/noncore/styles/theme/theme.pro b/noncore/styles/theme/theme.pro index f7ed324..4f84f3f 100644 --- a/noncore/styles/theme/theme.pro +++ b/noncore/styles/theme/theme.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG = qt embedded debug warn_on +CONFIG = qt plugin embedded debug warn_on SOURCES = ogfxeffect.cpp \ othemestyle.cpp \ othemebase.cpp \ themeset.cpp \ plugin.cpp HEADERS = ogfxeffect.h \ othemebase.h \ othemestyle.h \ themeset.h \ plugin.h LIBS += -lqpe INCLUDEPATH += $(OPIEDIR)/include DESTDIR = $(OPIEDIR)/plugins/styles diff --git a/noncore/todayplugins/fortune/fortune.pro b/noncore/todayplugins/fortune/fortune.pro index 0a0d5b9..ac503c3 100644 --- a/noncore/todayplugins/fortune/fortune.pro +++ b/noncore/todayplugins/fortune/fortune.pro @@ -1,19 +1,19 @@ TEMPLATE = lib #CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release # Input HEADERS = fortuneplugin.h fortunepluginimpl.h \ fortunepluginwidget.h SOURCES = fortuneplugin.cpp fortunepluginimpl.cpp \ fortunepluginwidget.cpp INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library DEPENDPATH += $(OPIEDIR)/include \ ../ ../library LIBS+= -lqpe -lopie DESTDIR = $(OPIEDIR)/plugins/today TARGET = todayfortuneplugin diff --git a/noncore/todayplugins/stockticker/stocktickerlib/stocktickerlib.pro b/noncore/todayplugins/stockticker/stocktickerlib/stocktickerlib.pro index c34be33..490a8f9 100644 --- a/noncore/todayplugins/stockticker/stocktickerlib/stocktickerlib.pro +++ b/noncore/todayplugins/stockticker/stocktickerlib/stocktickerlib.pro @@ -1,19 +1,19 @@ TEMPLATE = lib CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release HEADERS = stocktickerplugin.h stocktickerpluginimpl.h stocktickerpluginwidget.h stocktickerconfig.h \ ../libstocks/csv.h \ ../libstocks/http.h \ ../libstocks/lists.h \ ../libstocks/stocks.h SOURCES = stocktickerplugin.cpp stocktickerpluginimpl.cpp stocktickerpluginwidget.cpp stocktickerconfig.cpp \ ../libstocks/csv.c \ ../libstocks/currency.c \ ../libstocks/history.c \ ../libstocks/http.c \ ../libstocks/lists.c \ ../libstocks/stocks.c INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library diff --git a/noncore/todayplugins/weather/weather.pro b/noncore/todayplugins/weather/weather.pro index 2833e88..bd4b565 100644 --- a/noncore/todayplugins/weather/weather.pro +++ b/noncore/todayplugins/weather/weather.pro @@ -1,19 +1,19 @@ TEMPLATE = lib #CONFIG -= moc -CONFIG += qt release +CONFIG += qt plugin release HEADERS = weatherplugin.h \ weatherpluginimpl.h \ weatherpluginwidget.h \ weatherconfig.h SOURCES = weatherplugin.cpp \ weatherpluginimpl.cpp \ weatherpluginwidget.cpp \ weatherconfig.cpp INCLUDEPATH += $(OPIEDIR)/include \ ../ ../library DEPENDPATH += $(OPIEDIR)/include \ ../ ../library diff --git a/noncore/unsupported/mail2/bend/bend.pro b/noncore/unsupported/mail2/bend/bend.pro index b03f652..61eea5f 100644 --- a/noncore/unsupported/mail2/bend/bend.pro +++ b/noncore/unsupported/mail2/bend/bend.pro @@ -1,18 +1,18 @@ TEMPLATE = lib -CONFIG += qt warn_on release +CONFIG += qt plugin warn_on release HEADERS += bend.h \ bendimpl.h SOURCES += bend.cpp \ bendimpl.cpp INCLUDEPATH += $(OPIEDIR)/include ../libmail LIBS += -lmail -lqpe TARGET = bend DESTDIR += $(OPIEDIR)/plugins/applets/ TRANSLATIONS = ../../../i18n/de/libbend.ts \ ../../../i18n/nl/libbend.ts \ ../../../i18n/da/libbend.ts \ ../../../i18n/xx/libbend.ts \ ../../../i18n/en/libbend.ts \ ../../../i18n/es/libbend.ts \ ../../../i18n/fr/libbend.ts \ diff --git a/plugins/Makefile b/plugins/Makefile index 4863bd0..2515903 100644 --- a/plugins/Makefile +++ b/plugins/Makefile @@ -1,4 +1,8 @@ clean: - find -name "*.so*" -print0 | xargs -0 rm -f +ifeq ( CONFIG_TARGET_MACOSX, y ) + find ./ -name "*.dylib*" -print0 | xargs -0 rm -f +else + find ./ -name "*.so*" -print0 | xargs -0 rm -f +endif all install ipk lupdate lrelease opie-lupdate opie-lrelease: diff --git a/qmake/include/qglobal.h b/qmake/include/qglobal.h index d212bff..94e5607 100644 --- a/qmake/include/qglobal.h +++ b/qmake/include/qglobal.h @@ -141,33 +141,40 @@ # define Q_OS_QNX #elif defined(_SEQUENT_) # define Q_OS_DYNIX #elif defined(_SCO_DS) /* SCO OpenServer 5 + GCC */ # define Q_OS_SCO #elif defined(__USLC__) /* all SCO platforms + UDK or OUDK */ # define Q_OS_UNIXWARE # define Q_OS_UNIXWARE7 #elif defined(__svr4__) && defined(i386) /* Open UNIX 8 + GCC */ # define Q_OS_UNIXWARE # define Q_OS_UNIXWARE7 #else # error "Qt has not been ported to this OS - talk to qt-bugs@trolltech.com" #endif #if defined(Q_OS_MAC9) || defined(Q_OS_MACX) -# define Q_OS_MAC +/* This hack forces the generater to compile qmake not for maxosx native. It is + * compiled for Linux and generates usual makefiles.. + * Does anyone has a better solution for this ? (eilers) + */ +// # define Q_OS_MAC +#define Q_OS_LINUX +#warning "boeser Hack !! (se)" +#undef Q_OS_MACX #endif #if defined(Q_OS_MAC9) || defined(Q_OS_MSDOS) || defined(Q_OS_OS2) || defined(Q_OS_WIN32) || defined(Q_OS_WIN64) # undef Q_OS_UNIX #elif !defined(Q_OS_UNIX) # define Q_OS_UNIX #endif /* The compiler, must be one of: (Q_CC_x) SYM - Symantec C++ for both PC and Macintosh MPW - MPW C++ MWERKS - Metrowerks CodeWarrior MSVC - Microsoft Visual C/C++ diff --git a/qt/qt-2.3.7.patch/qte237-all-macosx.patch b/qt/qt-2.3.7.patch/qte237-all-macosx.patch new file mode 100644 index 0000000..82ed530 --- a/dev/null +++ b/qt/qt-2.3.7.patch/qte237-all-macosx.patch @@ -0,0 +1,1161 @@ +diff -ru qte-2.3.7_orig/include/qapplication.h qte-2.3.7/include/qapplication.h +--- qte-2.3.7_orig/include/qapplication.h Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/include/qapplication.h Mon Oct 27 14:21:28 2003 +@@ -61,6 +61,10 @@ + class QSemaphore; + #endif + ++#if !defined( QT_WEAK_SYMBOL ) ++#define QT_WEAK_SYMBOL ++#endif ++ + // REMOVE IN 3.0 (just here for moc source compatibility) + #define QNonBaseApplication QApplication + +@@ -85,7 +89,10 @@ + + #ifndef QT_NO_STYLE + static QStyle &style(); +- static void setStyle( QStyle* ); ++ static void setStyle( QStyle* ) QT_WEAK_SYMBOL; ++private: ++ static void setStyle_NonWeak( QStyle* ); ++public: + #endif + #if 1 /* OBSOLETE */ + enum ColorMode { NormalColors, CustomColors }; +@@ -106,11 +113,19 @@ + #ifndef QT_NO_PALETTE + static QPalette palette( const QWidget* = 0 ); + static void setPalette( const QPalette &, bool informWidgets=FALSE, ++ const char* className = 0 ) QT_WEAK_SYMBOL; ++private: ++ static void setPalette_NonWeak( const QPalette &, bool informWidgets=FALSE, + const char* className = 0 ); ++public: + #endif + static QFont font( const QWidget* = 0 ); + static void setFont( const QFont &, bool informWidgets=FALSE, ++ const char* className = 0 ) QT_WEAK_SYMBOL; ++private: ++ static void setFont_NonWeak( const QFont &, bool informWidgets=FALSE, + const char* className = 0 ); ++public: + static QFontMetrics fontMetrics(); + + QWidget *mainWidget() const; +@@ -207,7 +222,10 @@ + void qwsSetCustomColors( QRgb *colortable, int start, int numColors ); + #ifndef QT_NO_QWS_MANAGER + static QWSDecoration &qwsDecoration(); +- static void qwsSetDecoration( QWSDecoration *); ++ static void qwsSetDecoration( QWSDecoration *) QT_WEAK_SYMBOL; ++private: ++ static void qwsSetDecoration_NonWeak( QWSDecoration *); ++public: + #endif + #endif + +Only in qte-2.3.7/include: qconfig-qpe.h +diff -ru qte-2.3.7_orig/include/qconfig.h qte-2.3.7/include/qconfig.h +--- qte-2.3.7_orig/include/qconfig.h Fri Jan 26 14:43:06 2001 ++++ qte-2.3.7/include/qconfig.h Wed Oct 29 22:13:16 2003 +@@ -1,3 +1,26 @@ ++// Copied from qconfig-qpe.h ++/********************************************************************** ++** Copyright (C) 2000 Trolltech AS. All rights reserved. ++** ++** This file is part of Qtopia Environment. ++** ++** This file may be distributed and/or modified under the terms of the ++** GNU General Public License version 2 as published by the Free Software ++** Foundation and appearing in the file LICENSE.GPL included in the ++** packaging of this file. ++** ++** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ++** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ++** ++** See http://www.trolltech.com/gpl/ for GPL licensing information. ++** ++** Contact info@trolltech.com if any conditions of this licensing are ++** not clear to you. ++** ++**********************************************************************/ ++#ifndef QT_H ++#endif // QT_H ++ + // Empty leaves all features enabled. See doc/html/features.html for choices. + + // Note that disabling some features will produce a libqt that is not +@@ -8,3 +31,69 @@ + #ifndef QT_DLL + #define QT_DLL // Internal + #endif ++ ++#if defined(QT_QWS_IPAQ) || defined(QT_QWS_CASSIOPEIA) || defined(QT_QWS_SL5XXX) ++# define QT_NO_QWS_CURSOR ++# define QT_NO_QWS_MOUSE_AUTO ++#endif ++#ifndef QT_NO_CODECS ++#define QT_NO_CODECS ++#endif ++#define QT_NO_UNICODETABLES ++//#define QT_NO_IMAGEIO_BMP ++#define QT_NO_IMAGEIO_PPM ++//#define QT_NO_ASYNC_IO ++//#define QT_NO_ASYNC_IMAGE_IO ++#define QT_NO_FREETYPE ++#define QT_NO_BDF ++//#define QT_NO_FONTDATABASE ++#define QT_NO_DRAGANDDROP ++//#define QT_NO_CLIPBOARD ++#define QT_NO_PROPERTIES ++#define QT_NO_NETWORKPROTOCOL ++ ++#define QT_NO_IMAGE_TEXT ++ ++//#define QT_NO_TOOLTIP ++#define QT_NO_COLORNAMES ++#define QT_NO_TRANSFORMATIONS ++#define QT_NO_TRANSLATION_BUILDER ++#define QT_NO_COMPLEXTEXT ++#define QT_NO_PRINTER ++#define QT_NO_PICTURE ++//#define QT_NO_ICONVIEW ++#define QT_NO_DIAL ++#define QT_NO_SIZEGRIP ++#define QT_NO_WORKSPACE ++//#define QT_NO_TABLE ++//#define QT_NO_ACTION ++//#define QT_NO_SETTINGS ++#define QT_NO_STYLE_POCKETPC ++#ifndef QT_NO_STYLE_AQUA ++# define QT_NO_STYLE_AQUA ++#endif ++#define QT_NO_STYLE_MOTIF ++#define QT_NO_STYLE_PLATINUM ++#define QT_NO_FILEDIALOG ++#define QT_NO_FONTDIALOG ++#define QT_NO_PRINTDIALOG ++#define QT_NO_COLORDIALOG ++#define QT_NO_INPUTDIALOG ++//#define QT_NO_MESSAGEBOX ++#define QT_NO_PROGRESSDIALOG ++//#define QT_NO_TABDIALOG ++#define QT_NO_WIZARD ++#define QT_NO_EFFECTS ++//#define QT_NO_COMPONENT ++#define QT_NO_DOM ++#define QT_NO_SEMIMODAL ++//#define QT_NO_PROGRESSBAR ++#define QT_NO_SPLITTER ++ ++//#define QT_NO_QWS_SAVEFONTS ++//#define QT_NO_QWS_PROPERTIES ++ ++#define QT_NO_QWS_BEOS_WM_STYLE ++#define QT_NO_QWS_KDE2_WM_STYLE ++#define QT_NO_QWS_KDE_WM_STYLE ++#define QT_NO_QWS_WINDOWS_WM_STYLE +diff -ru qte-2.3.7_orig/include/qfontdatabase.h qte-2.3.7/include/qfontdatabase.h +--- qte-2.3.7_orig/include/qfontdatabase.h Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/include/qfontdatabase.h Mon Oct 27 14:21:28 2003 +@@ -59,6 +59,10 @@ + class QDiskFont; + #endif + ++#if !defined( QT_WEAK_SYMBOL ) ++#define QT_WEAK_SYMBOL ++#endif ++ + class QFontDatabasePrivate; + + class Q_EXPORT QFontDatabase +@@ -67,9 +71,16 @@ + QFontDatabase(); + + QStringList families( bool onlyForLocale = TRUE ) const; ++ ++ + QValueList<int> pointSizes( const QString &family, + const QString &style = QString::null, +- const QString &charSet = QString::null ); ++ const QString &charSet = QString::null ) QT_WEAK_SYMBOL; ++private: ++ QValueList<int> pointSizes_NonWeak( const QString &family, ++ const QString &style, ++ const QString &charSet ); ++public: + QStringList styles( const QString &family, + const QString &charSet = QString::null ) const; + QStringList charSets( const QString &familyName, +Only in qte-2.3.7_orig/include: qgifimageformat_p.h +diff -ru qte-2.3.7_orig/include/qmodules.h qte-2.3.7/include/qmodules.h +--- qte-2.3.7_orig/include/qmodules.h Fri Aug 31 17:00:56 2001 ++++ qte-2.3.7/include/qmodules.h Wed Oct 29 21:57:53 2003 +@@ -1,14 +1,12 @@ +-#ifndef QT_H +-#endif // QT_H +- ++// These modules are licensed to you + #define QT_MODULE_TOOLS + #define QT_MODULE_KERNEL + #define QT_MODULE_WIDGETS + #define QT_MODULE_DIALOGS +- + #define QT_MODULE_ICONVIEW + #define QT_MODULE_WORKSPACE +-#define QT_MODULE_TABLE ++#define QT_MODULE_NETWORK + #define QT_MODULE_CANVAS ++#define QT_MODULE_TABLE + #define QT_MODULE_XML +-#define QT_MODULE_NETWORK ++#define QT_MODULE_OPENGL +Only in qte-2.3.7_orig/include: qxt.h +Only in qte-2.3.7/lib: libqte.dylib +Only in qte-2.3.7/lib: libqte.dylib.2 +Only in qte-2.3.7/lib: libqte.dylib.2.3 +Only in qte-2.3.7/lib: libqte.dylib.2.3.7 +Only in qte-2.3.7/src/3rdparty/kernel: qgifimageformat.o +Only in qte-2.3.7/src/3rdparty/kernel: qpointarray.o +Only in qte-2.3.7/src/3rdparty/kernel: qpolygonscanner.o +Only in qte-2.3.7/src/3rdparty/kernel: qregion_qws.o +Only in qte-2.3.7/src/3rdparty/libpng: png.o +Only in qte-2.3.7/src/3rdparty/libpng: pngerror.o +Only in qte-2.3.7/src/3rdparty/libpng: pngget.o +Only in qte-2.3.7/src/3rdparty/libpng: pngmem.o +Only in qte-2.3.7/src/3rdparty/libpng: pngpread.o +Only in qte-2.3.7/src/3rdparty/libpng: pngread.o +Only in qte-2.3.7/src/3rdparty/libpng: pngrio.o +Only in qte-2.3.7/src/3rdparty/libpng: pngrtran.o +Only in qte-2.3.7/src/3rdparty/libpng: pngrutil.o +Only in qte-2.3.7/src/3rdparty/libpng: pngset.o +Only in qte-2.3.7/src/3rdparty/libpng: pngtrans.o +Only in qte-2.3.7/src/3rdparty/libpng: pngwio.o +Only in qte-2.3.7/src/3rdparty/libpng: pngwrite.o +Only in qte-2.3.7/src/3rdparty/libpng: pngwtran.o +Only in qte-2.3.7/src/3rdparty/libpng: pngwutil.o +Only in qte-2.3.7/src/3rdparty/tools: qbig5codec.o +Only in qte-2.3.7/src/3rdparty/tools: qeucjpcodec.o +Only in qte-2.3.7/src/3rdparty/tools: qeuckrcodec.o +Only in qte-2.3.7/src/3rdparty/tools: qgbkcodec.o +Only in qte-2.3.7/src/3rdparty/tools: qjiscodec.o +Only in qte-2.3.7/src/3rdparty/tools: qjpunicode.o +Only in qte-2.3.7/src/3rdparty/tools: qrtlcodec.o +Only in qte-2.3.7/src/3rdparty/tools: qsjiscodec.o +Only in qte-2.3.7/src/3rdparty/tools: qtsciicodec.o +Only in qte-2.3.7/src/3rdparty/zlib: Makefile +Only in qte-2.3.7/src/3rdparty/zlib: adler32.o +Only in qte-2.3.7/src/3rdparty/zlib: compress.o +Only in qte-2.3.7/src/3rdparty/zlib: crc32.o +Only in qte-2.3.7/src/3rdparty/zlib: deflate.o +Only in qte-2.3.7/src/3rdparty/zlib: gzio.o +Only in qte-2.3.7/src/3rdparty/zlib: infblock.o +Only in qte-2.3.7/src/3rdparty/zlib: infcodes.o +Only in qte-2.3.7/src/3rdparty/zlib: inffast.o +Only in qte-2.3.7/src/3rdparty/zlib: inflate.o +Only in qte-2.3.7/src/3rdparty/zlib: inftrees.o +Only in qte-2.3.7/src/3rdparty/zlib: infutil.o +Only in qte-2.3.7/src/3rdparty/zlib: trees.o +Only in qte-2.3.7/src/3rdparty/zlib: uncompr.o +Only in qte-2.3.7/src/3rdparty/zlib: zutil.o +Only in qte-2.3.7/src: Makefile +Only in qte-2.3.7/src: allmoc.cpp +Only in qte-2.3.7/src: allmoc.o +Only in qte-2.3.7/src/canvas: qcanvas.o +Only in qte-2.3.7/src/dialogs: qcolordialog.moc +Only in qte-2.3.7/src/dialogs: qcolordialog.o +Only in qte-2.3.7/src/dialogs: qfiledialog.moc +Only in qte-2.3.7/src/dialogs: qfiledialog.o +Only in qte-2.3.7/src/dialogs: qfontdialog.o +Only in qte-2.3.7/src/dialogs: qinputdialog.o +Only in qte-2.3.7/src/dialogs: qmessagebox.o +Only in qte-2.3.7/src/dialogs: qprintdialog.o +Only in qte-2.3.7/src/dialogs: qprogressdialog.o +Only in qte-2.3.7/src/dialogs: qtabdialog.o +Only in qte-2.3.7/src/dialogs: qwizard.o +Only in qte-2.3.7/src/iconview: qiconview.o +Only in qte-2.3.7/src/kernel: qabstractlayout.o +Only in qte-2.3.7/src/kernel: qaccel.o +diff -ru qte-2.3.7_orig/src/kernel/qapplication.cpp qte-2.3.7/src/kernel/qapplication.cpp +--- qte-2.3.7_orig/src/kernel/qapplication.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qapplication.cpp Mon Oct 27 14:21:28 2003 +@@ -35,6 +35,8 @@ + ** + **********************************************************************/ + ++#define QT_WEAK_SYMBOL __attribute__(( weak )) ++ + #include "qobjectlist.h" + #include "qobjectdict.h" + #include "qapplication.h" +@@ -933,11 +935,16 @@ + #ifndef QT_NO_STYLE + void QApplication::setStyle( QStyle *style ) + { ++ setStyle_NonWeak ( style ); ++} ++ ++void QApplication::setStyle_NonWeak( QStyle *style ) ++{ + QStyle* old = app_style; +- app_style = style; + + if ( startingUp() ) { + delete old; ++ app_style = style; + return; + } + +@@ -958,6 +965,8 @@ + old->unPolish( qApp ); + } + ++ app_style = style; ++ + // take care of possible palette requirements of certain gui + // styles. Do it before polishing the application since the style + // might call QApplication::setStyle() itself +@@ -1184,13 +1193,30 @@ + \sa QWidget::setPalette(), palette(), QStyle::polish() + */ + +-void QApplication::setPalette( const QPalette &palette, bool informWidgets, ++void QApplication::setPalette ( const QPalette &palette, bool informWidgets, ++ const char* className ) ++{ ++ setPalette_NonWeak ( palette, informWidgets, className ); ++} ++ ++void QApplication::setPalette_NonWeak ( const QPalette &palette, bool informWidgets, + const char* className ) + { + QPalette pal = palette; + #ifndef QT_NO_STYLE +- if ( !startingUp() ) ++ if ( !startingUp() ) { + qApp->style().polish( pal ); // NB: non-const reference ++ if ( className ) { ++ // if we just polished a class specific palette (this normally ++ // only called by qt_fix_tooltips - see below), we better re- ++ // polish the global palette. Some styles like liquid can get ++ // confused, because they can not detect if the polished palette ++ // is the global one or only a class specific one. ++ // (liquid uses this palette to calculate blending pixmaps) ++ QPalette p = qApp-> palette ( ); ++ qApp->style().polish ( p ); ++ } ++ } + #endif + bool all = FALSE; + if ( !className ) { +@@ -1273,6 +1299,12 @@ + */ + + void QApplication::setFont( const QFont &font, bool informWidgets, ++ const char* className ) ++{ ++ setFont_NonWeak ( font, informWidgets, className ); ++} ++ ++void QApplication::setFont_NonWeak( const QFont &font, bool informWidgets, + const char* className ) + { + bool all = FALSE; +diff -ru qte-2.3.7_orig/src/kernel/qapplication.h qte-2.3.7/src/kernel/qapplication.h +--- qte-2.3.7_orig/src/kernel/qapplication.h Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qapplication.h Mon Oct 27 14:21:28 2003 +@@ -61,6 +61,10 @@ + class QSemaphore; + #endif + ++#if !defined( QT_WEAK_SYMBOL ) ++#define QT_WEAK_SYMBOL ++#endif ++ + // REMOVE IN 3.0 (just here for moc source compatibility) + #define QNonBaseApplication QApplication + +@@ -85,7 +89,10 @@ + + #ifndef QT_NO_STYLE + static QStyle &style(); +- static void setStyle( QStyle* ); ++ static void setStyle( QStyle* ) QT_WEAK_SYMBOL; ++private: ++ static void setStyle_NonWeak( QStyle* ); ++public: + #endif + #if 1 /* OBSOLETE */ + enum ColorMode { NormalColors, CustomColors }; +@@ -106,11 +113,19 @@ + #ifndef QT_NO_PALETTE + static QPalette palette( const QWidget* = 0 ); + static void setPalette( const QPalette &, bool informWidgets=FALSE, ++ const char* className = 0 ) QT_WEAK_SYMBOL; ++private: ++ static void setPalette_NonWeak( const QPalette &, bool informWidgets=FALSE, + const char* className = 0 ); ++public: + #endif + static QFont font( const QWidget* = 0 ); + static void setFont( const QFont &, bool informWidgets=FALSE, ++ const char* className = 0 ) QT_WEAK_SYMBOL; ++private: ++ static void setFont_NonWeak( const QFont &, bool informWidgets=FALSE, + const char* className = 0 ); ++public: + static QFontMetrics fontMetrics(); + + QWidget *mainWidget() const; +@@ -207,7 +222,10 @@ + void qwsSetCustomColors( QRgb *colortable, int start, int numColors ); + #ifndef QT_NO_QWS_MANAGER + static QWSDecoration &qwsDecoration(); +- static void qwsSetDecoration( QWSDecoration *); ++ static void qwsSetDecoration( QWSDecoration *) QT_WEAK_SYMBOL; ++private: ++ static void qwsSetDecoration_NonWeak( QWSDecoration *); ++public: + #endif + #endif + +Only in qte-2.3.7/src/kernel: qapplication.o +diff -ru qte-2.3.7_orig/src/kernel/qapplication_qws.cpp qte-2.3.7/src/kernel/qapplication_qws.cpp +--- qte-2.3.7_orig/src/kernel/qapplication_qws.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qapplication_qws.cpp Mon Oct 27 14:21:28 2003 +@@ -2804,6 +2804,11 @@ + */ + void QApplication::qwsSetDecoration( QWSDecoration *d ) + { ++ qwsSetDecoration_NonWeak ( d ); ++} ++ ++void QApplication::qwsSetDecoration_NonWeak( QWSDecoration *d ) ++{ + if ( d ) { + delete qws_decoration; + qws_decoration = d; +Only in qte-2.3.7/src/kernel: qapplication_qws.cpp~ +Only in qte-2.3.7/src/kernel: qapplication_qws.o +Only in qte-2.3.7/src/kernel: qasyncimageio.o +Only in qte-2.3.7/src/kernel: qasyncio.o +Only in qte-2.3.7/src/kernel: qbitmap.o +Only in qte-2.3.7/src/kernel: qclipboard.o +Only in qte-2.3.7/src/kernel: qclipboard_qws.o +Only in qte-2.3.7/src/kernel: qcolor.o +Only in qte-2.3.7/src/kernel: qcolor_p.o +Only in qte-2.3.7/src/kernel: qcolor_qws.o +Only in qte-2.3.7/src/kernel: qconnection.o +Only in qte-2.3.7/src/kernel: qcopchannel_qws.moc +Only in qte-2.3.7/src/kernel: qcopchannel_qws.o +Only in qte-2.3.7/src/kernel: qcursor.o +Only in qte-2.3.7/src/kernel: qcursor_qws.o +Only in qte-2.3.7/src/kernel: qdialog.o +Only in qte-2.3.7/src/kernel: qdirectpainter_qws.o +Only in qte-2.3.7/src/kernel: qdnd_qws.o +Only in qte-2.3.7/src/kernel: qdragobject.o +Only in qte-2.3.7/src/kernel: qdrawutil.o +Only in qte-2.3.7/src/kernel: qdropsite.o +Only in qte-2.3.7/src/kernel: qevent.o +Only in qte-2.3.7/src/kernel: qfocusdata.o +Only in qte-2.3.7/src/kernel: qfont.o +Only in qte-2.3.7/src/kernel: qfont_qws.o +diff -ru qte-2.3.7_orig/src/kernel/qfontdatabase.cpp qte-2.3.7/src/kernel/qfontdatabase.cpp +--- qte-2.3.7_orig/src/kernel/qfontdatabase.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qfontdatabase.cpp Mon Oct 27 14:21:28 2003 +@@ -35,6 +35,8 @@ + ** + **********************************************************************/ + ++#define QT_WEAK_SYMBOL __attribute__(( weak )) ++ + #include "qfontdatabase.h" + + #ifndef QT_NO_FONTDATABASE +@@ -2421,6 +2423,13 @@ + */ + + QValueList<int> QFontDatabase::pointSizes( const QString &family, ++ const QString &style, ++ const QString &charSet ) ++{ ++ return pointSizes_NonWeak ( family, style, charSet ); ++} ++ ++QValueList<int> QFontDatabase::pointSizes_NonWeak ( const QString &family, + const QString &style, + const QString &charSet ) + { +diff -ru qte-2.3.7_orig/src/kernel/qfontdatabase.h qte-2.3.7/src/kernel/qfontdatabase.h +--- qte-2.3.7_orig/src/kernel/qfontdatabase.h Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qfontdatabase.h Mon Oct 27 14:21:28 2003 +@@ -59,6 +59,10 @@ + class QDiskFont; + #endif + ++#if !defined( QT_WEAK_SYMBOL ) ++#define QT_WEAK_SYMBOL ++#endif ++ + class QFontDatabasePrivate; + + class Q_EXPORT QFontDatabase +@@ -67,9 +71,16 @@ + QFontDatabase(); + + QStringList families( bool onlyForLocale = TRUE ) const; ++ ++ + QValueList<int> pointSizes( const QString &family, + const QString &style = QString::null, +- const QString &charSet = QString::null ); ++ const QString &charSet = QString::null ) QT_WEAK_SYMBOL; ++private: ++ QValueList<int> pointSizes_NonWeak( const QString &family, ++ const QString &style, ++ const QString &charSet ); ++public: + QStringList styles( const QString &family, + const QString &charSet = QString::null ) const; + QStringList charSets( const QString &familyName, +Only in qte-2.3.7/src/kernel: qfontdatabase.o +Only in qte-2.3.7/src/kernel: qfontfactorybdf_qws.o +Only in qte-2.3.7/src/kernel: qfontfactoryttf_qws.o +Only in qte-2.3.7/src/kernel: qfontmanager_qws.o +diff -ru qte-2.3.7_orig/src/kernel/qgfx_qws.cpp qte-2.3.7/src/kernel/qgfx_qws.cpp +--- qte-2.3.7_orig/src/kernel/qgfx_qws.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qgfx_qws.cpp Mon Oct 27 14:27:25 2003 +@@ -32,7 +32,7 @@ + #include "qgfx_qws.h" + + #include <stdio.h> +-#include <dlfcn.h> ++//#include <dlfcn.h> + #include <sys/types.h> + #include <dirent.h> + #include <stdlib.h> +Only in qte-2.3.7/src/kernel: qgfx_qws.o +diff -ru qte-2.3.7_orig/src/kernel/qgfxraster_qws.cpp qte-2.3.7/src/kernel/qgfxraster_qws.cpp +--- qte-2.3.7_orig/src/kernel/qgfxraster_qws.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qgfxraster_qws.cpp Mon Oct 27 14:27:25 2003 +@@ -75,7 +75,11 @@ + # if __BYTE_ORDER == __BIG_ENDIAN + # define QWS_BIG_ENDIAN + # endif ++#elif defined(__APPLE__) ++# define QWS_BIG_ENDIAN + #endif ++// AJ: the above (test for __APPLE__) is very hacky, but I can't ++// think of something better at the moment. + + // Pull this private function in from qglobal.cpp + extern unsigned int qt_int_sqrt( unsigned int n ); +@@ -3770,6 +3774,19 @@ + b = srcval & 0xff; + + unsigned char * tmp=(unsigned char *)&alphabuf[loopc]; ++# ifdef QWS_BIG_ENDIAN ++ if(av==255) { ++ // Do nothing - we already have source values in r,g,b ++ } else if(av==0) { ++ r = *(tmp+1); ++ g = *(tmp+2); ++ b = *(tmp+3); ++ } else { ++ r = ((r-*(tmp+1)) * av) / 256 + *(tmp+1); ++ g = ((g-*(tmp+2)) * av) / 256 + *(tmp+2); ++ b = ((b-*(tmp+3)) * av) / 256 + *(tmp+3); ++ } ++# else + if(av==255) { + // Do nothing - we already have source values in r,g,b + } else if(av==0) { +@@ -3781,6 +3798,7 @@ + g = ((g-*(tmp+1)) * av) / 256 + *(tmp+1); + b = ((b-*(tmp+0)) * av) / 256 + *(tmp+0); + } ++# endif + *(alphaptr++) = (r << 16) | (g << 8) | b; + } + +@@ -4204,7 +4222,7 @@ + + } else if ( depth == 1 ) { + if (srctype==SourceImage) { +- static int warn; ++ static int warn = 0; + if ( warn++ < 5 ) + qDebug( "bitmap alpha-image not implemented" ); + hImageLineUnclipped( x1, x2, l, srcdata, FALSE ); +@@ -4237,7 +4255,7 @@ + setAlphaType(IgnoreAlpha); + if ( w <= 0 || h <= 0 || !ncliprect ) return; + GFX_START(QRect(rx+xoffs, ry+yoffs, w+1, h+1)) +-#ifdef QWS_EXPERIMENTAL_FASTPATH ++#if 0 // def QWS_EXPERIMENTAL_FASTPATH !! this is crashing HancomWord on OZ !! + // ### fix for 8bpp + // This seems to be reliable now, at least for 16bpp + +Only in qte-2.3.7/src/kernel: qgfxraster_qws.cpp~ +Only in qte-2.3.7/src/kernel: qgfxraster_qws.o +Only in qte-2.3.7/src/kernel: qguardedptr.o +Only in qte-2.3.7/src/kernel: qiconset.o +Only in qte-2.3.7/src/kernel: qimage.o +Only in qte-2.3.7/src/kernel: qinputcontext_qws.o +Only in qte-2.3.7/src/kernel: qjpegio.o +diff -ru qte-2.3.7_orig/src/kernel/qkeyboard_qws.cpp qte-2.3.7/src/kernel/qkeyboard_qws.cpp +--- qte-2.3.7_orig/src/kernel/qkeyboard_qws.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qkeyboard_qws.cpp Mon Oct 27 14:42:11 2003 +@@ -69,7 +69,7 @@ + #if !defined(_OS_QNX6_) + + #include <termios.h> +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + #include <sys/kd.h> + #include <sys/vt.h> + #endif +@@ -468,10 +468,12 @@ + void QWSPC101KeyboardHandler::restoreLeds() + { + char leds; ++#if !defined(_OS_MACX_) + ioctl(0, KDGETLED, &leds); + leds = leds & ~LED_CAP; + if ( caps ) leds |= LED_CAP; + ioctl(0, KDSETLED, leds); ++#endif + } + + class QWSTtyKeyboardHandler : public QWSPC101KeyboardHandler +@@ -547,7 +549,7 @@ + + static void vtSwitchHandler(int /*sig*/) + { +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + if (vtActive) { + qwsServer->enablePainting(false); + qt_screen->save(); +@@ -880,7 +882,7 @@ + if (term && !release) { + ctrl = false; + alt = false; +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + ioctl(kbdFD, VT_ACTIVATE, term); + #endif + return; +@@ -1031,7 +1033,7 @@ + struct termios termdata; + tcgetattr( kbdFD, &termdata ); + +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + ioctl(kbdFD, KDSKBMODE, K_RAW); + #endif + +@@ -1047,7 +1049,7 @@ + + signal(VTSWITCHSIG, vtSwitchHandler); + +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + struct vt_mode vtMode; + ioctl(kbdFD, VT_GETMODE, &vtMode); + +@@ -1068,7 +1070,7 @@ + { + if (kbdFD >= 0) + { +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + ioctl(kbdFD, KDSKBMODE, K_XLATE); + #endif + tcsetattr(kbdFD, TCSANOW, &origTermData); +Only in qte-2.3.7/src/kernel: qkeyboard_qws.cpp.rej +Only in qte-2.3.7/src/kernel: qkeyboard_qws.cpp~ +Only in qte-2.3.7/src/kernel: qkeyboard_qws.moc +Only in qte-2.3.7/src/kernel: qkeyboard_qws.o +Only in qte-2.3.7/src/kernel: qlayout.o +Only in qte-2.3.7/src/kernel: qlayoutengine.o +Only in qte-2.3.7/src/kernel: qlocalfs.o +diff -ru qte-2.3.7_orig/src/kernel/qlock_qws.cpp qte-2.3.7/src/kernel/qlock_qws.cpp +--- qte-2.3.7_orig/src/kernel/qlock_qws.cpp Thu Jul 17 03:20:25 2003 ++++ qte-2.3.7/src/kernel/qlock_qws.cpp Mon Oct 27 14:27:25 2003 +@@ -38,7 +38,7 @@ + #include <errno.h> + + #if defined(__GNU_LIBRARY__) && !defined(_SEM_SEMUN_UNDEFINED) \ +- || defined _OS_FREEBSD_ ++ || defined(_OS_FREEBSD_) || defined(_OS_MACX_) + /* union semun is defined by including <sys/sem.h> */ + #else + /* according to X/OPEN we have to define it ourselves */ +Only in qte-2.3.7/src/kernel: qlock_qws.o +Only in qte-2.3.7/src/kernel: qmemorymanager_qws.o +Only in qte-2.3.7/src/kernel: qmetaobject.o +Only in qte-2.3.7/src/kernel: qmime.o +Only in qte-2.3.7/src/kernel: qmngio.o +Only in qte-2.3.7/src/kernel: qmovie.moc +Only in qte-2.3.7/src/kernel: qmovie.o +Only in qte-2.3.7/src/kernel: qnetworkprotocol.o +Only in qte-2.3.7/src/kernel: qobject.o +Only in qte-2.3.7/src/kernel: qpaintdevice_qws.o +Only in qte-2.3.7/src/kernel: qpaintdevicemetrics.o +Only in qte-2.3.7/src/kernel: qpainter.o +Only in qte-2.3.7/src/kernel: qpainter_qws.o +Only in qte-2.3.7/src/kernel: qpalette.o +Only in qte-2.3.7/src/kernel: qpicture.o +Only in qte-2.3.7/src/kernel: qpixmap.o +Only in qte-2.3.7/src/kernel: qpixmap_qws.o +Only in qte-2.3.7/src/kernel: qpixmapcache.o +Only in qte-2.3.7/src/kernel: qpngio.o +Only in qte-2.3.7/src/kernel: qpoint.o +Only in qte-2.3.7/src/kernel: qprinter.o +Only in qte-2.3.7/src/kernel: qprinter_qws.o +Only in qte-2.3.7/src/kernel: qpsprinter.o +Only in qte-2.3.7/src/kernel: qrect.o +Only in qte-2.3.7/src/kernel: qregion.o +Only in qte-2.3.7/src/kernel: qrichtext.o +Only in qte-2.3.7/src/kernel: qsemimodal.o +Only in qte-2.3.7/src/kernel: qsharedmemory.o +Only in qte-2.3.7/src/kernel: qsignal.o +Only in qte-2.3.7/src/kernel: qsignalmapper.o +Only in qte-2.3.7/src/kernel: qsimplerichtext.o +Only in qte-2.3.7/src/kernel: qsize.o +Only in qte-2.3.7/src/kernel: qsizegrip.o +Only in qte-2.3.7/src/kernel: qsocketnotifier.o +Only in qte-2.3.7/src/kernel: qsound.o +Only in qte-2.3.7/src/kernel: qsound_qws.o +Only in qte-2.3.7/src/kernel: qsoundqss_qws.moc +Only in qte-2.3.7/src/kernel: qsoundqss_qws.o +Only in qte-2.3.7/src/kernel: qstyle.o +Only in qte-2.3.7/src/kernel: qstylesheet.o +Only in qte-2.3.7/src/kernel: qthread_unix.moc +Only in qte-2.3.7/src/kernel: qthread_unix.o +Only in qte-2.3.7/src/kernel: qtimer.o +Only in qte-2.3.7/src/kernel: qtranslator.o +Only in qte-2.3.7/src/kernel: qurl.o +Only in qte-2.3.7/src/kernel: qurlinfo.o +Only in qte-2.3.7/src/kernel: qurloperator.o +Only in qte-2.3.7/src/kernel: qvariant.o +Only in qte-2.3.7/src/kernel: qwidget.o +Only in qte-2.3.7/src/kernel: qwidget_qws.o +diff -ru qte-2.3.7_orig/src/kernel/qwindowsystem_qws.cpp qte-2.3.7/src/kernel/qwindowsystem_qws.cpp +--- qte-2.3.7_orig/src/kernel/qwindowsystem_qws.cpp Thu Jul 17 03:20:26 2003 ++++ qte-2.3.7/src/kernel/qwindowsystem_qws.cpp Mon Oct 27 14:27:25 2003 +@@ -844,6 +844,18 @@ + { + } + ++static void catchSegvSignal( int ) ++{ ++#ifndef QT_NO_QWS_KEYBOARD ++ if ( qwsServer ) ++ qwsServer->closeKeyboard(); ++#endif ++ QWSServer::closedown(); ++ fprintf(stderr, "Segmentation fault.\n"); ++ exit(1); ++} ++ ++ + /*! + \class QWSServer qwindowsystem_qws.h + \brief Server-specific functionality in Qt/Embedded +@@ -936,6 +948,7 @@ + } + + signal(SIGPIPE, ignoreSignal); //we get it when we read ++ signal(SIGSEGV, catchSegvSignal); //recover the keyboard on crash + #endif + focusw = 0; + mouseGrabber = 0; +@@ -950,7 +963,7 @@ + + #ifndef QT_NO_QWS_MULTIPROCESS + if ( !geteuid() ) { +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + if( mount(0, "/var/shm", "shm", 0, 0) ) { + /* This just confuses people with 2.2 kernels + if ( errno != EBUSY ) +Only in qte-2.3.7/src/kernel: qwindowsystem_qws.cpp~ +Only in qte-2.3.7/src/kernel: qwindowsystem_qws.o +Only in qte-2.3.7/src/kernel: qwmatrix.o +Only in qte-2.3.7/src/kernel: qwsbeosdecoration_qws.o +Only in qte-2.3.7/src/kernel: qwscommand_qws.o +Only in qte-2.3.7/src/kernel: qwscursor_qws.o +Only in qte-2.3.7/src/kernel: qwsdecoration_qws.o +Only in qte-2.3.7/src/kernel: qwsdefaultdecoration_qws.o +Only in qte-2.3.7/src/kernel: qwsevent_qws.o +Only in qte-2.3.7/src/kernel: qwshydrodecoration_qws.o +Only in qte-2.3.7/src/kernel: qwskde2decoration_qws.o +Only in qte-2.3.7/src/kernel: qwskdedecoration_qws.o +Only in qte-2.3.7/src/kernel: qwsmanager_qws.o +diff -ru qte-2.3.7_orig/src/kernel/qwsmouse_qws.cpp qte-2.3.7/src/kernel/qwsmouse_qws.cpp +--- qte-2.3.7_orig/src/kernel/qwsmouse_qws.cpp Thu Jul 17 03:20:26 2003 ++++ qte-2.3.7/src/kernel/qwsmouse_qws.cpp Mon Oct 27 14:27:25 2003 +@@ -336,7 +336,7 @@ + tty.c_oflag = 0; + tty.c_lflag = 0; + tty.c_cflag = f | CREAD | CLOCAL | HUPCL; +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + tty.c_line = 0; + #endif + tty.c_cc[VTIME] = 0; +@@ -889,7 +889,7 @@ + tty.c_iflag = IGNBRK | IGNPAR; + tty.c_oflag = 0; + tty.c_lflag = 0; +-#if !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) ++#if !defined(_OS_MACX_) && !defined(_OS_FREEBSD_) && !defined(_OS_SOLARIS_) + tty.c_line = 0; + #endif // _OS_FREEBSD_ + tty.c_cc[VTIME] = 0; +Only in qte-2.3.7/src/kernel: qwsmouse_qws.moc +Only in qte-2.3.7/src/kernel: qwsmouse_qws.o +Only in qte-2.3.7/src/kernel: qwsproperty_qws.o +Only in qte-2.3.7/src/kernel: qwsregionmanager_qws.o +Only in qte-2.3.7/src/kernel: qwssocket_qws.o +Only in qte-2.3.7/src/kernel: qwswindowsdecoration_qws.o +Only in qte-2.3.7/src/moc: Makefile +Only in qte-2.3.7/src/moc: moc +Only in qte-2.3.7/src/moc: mocgen.o +Only in qte-2.3.7/src/moc: qbuffer.o +Only in qte-2.3.7/src/moc: qcollection.o +Only in qte-2.3.7/src/moc: qcstring.o +Only in qte-2.3.7/src/moc: qdatastream.o +Only in qte-2.3.7/src/moc: qdatetime.o +Only in qte-2.3.7/src/moc: qfile.o +Only in qte-2.3.7/src/moc: qfile_unix.o +Only in qte-2.3.7/src/moc: qgarray.o +Only in qte-2.3.7/src/moc: qgdict.o +Only in qte-2.3.7/src/moc: qglist.o +Only in qte-2.3.7/src/moc: qglobal.o +Only in qte-2.3.7/src/moc: qgvector.o +Only in qte-2.3.7/src/moc: qiodevice.o +Only in qte-2.3.7/src/moc: qregexp.o +Only in qte-2.3.7/src/moc: qstring.o +Only in qte-2.3.7/src/moc: qtextcodec.o +Only in qte-2.3.7/src/moc: qtextstream.o +Only in qte-2.3.7/src/moc: qutfcodec.o +Only in qte-2.3.7/src/network: qdns.o +Only in qte-2.3.7/src/network: qftp.o +Only in qte-2.3.7/src/network: qhostaddress.o +Only in qte-2.3.7/src/network: qnetwork.o +Only in qte-2.3.7/src/network: qserversocket.o +Only in qte-2.3.7/src/network: qsocket.o +Only in qte-2.3.7/src/network: qsocketdevice.o +Only in qte-2.3.7/src/network: qsocketdevice_unix.o +Only in qte-2.3.7/src/table: qtable.o +Only in qte-2.3.7/src/tools: qbitarray.o +Only in qte-2.3.7/src/tools: qbuffer.o +Only in qte-2.3.7/src/tools: qcollection.o +Only in qte-2.3.7/src/tools: qconfig-qpe.h +Only in qte-2.3.7/src/tools: qconfig-qpe.h~ +diff -ru qte-2.3.7_orig/src/tools/qconfig.h qte-2.3.7/src/tools/qconfig.h +--- qte-2.3.7_orig/src/tools/qconfig.h Fri Jan 26 14:43:06 2001 ++++ qte-2.3.7/src/tools/qconfig.h Wed Oct 29 22:13:16 2003 +@@ -1,3 +1,26 @@ ++// Copied from qconfig-qpe.h ++/********************************************************************** ++** Copyright (C) 2000 Trolltech AS. All rights reserved. ++** ++** This file is part of Qtopia Environment. ++** ++** This file may be distributed and/or modified under the terms of the ++** GNU General Public License version 2 as published by the Free Software ++** Foundation and appearing in the file LICENSE.GPL included in the ++** packaging of this file. ++** ++** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ++** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ++** ++** See http://www.trolltech.com/gpl/ for GPL licensing information. ++** ++** Contact info@trolltech.com if any conditions of this licensing are ++** not clear to you. ++** ++**********************************************************************/ ++#ifndef QT_H ++#endif // QT_H ++ + // Empty leaves all features enabled. See doc/html/features.html for choices. + + // Note that disabling some features will produce a libqt that is not +@@ -8,3 +31,69 @@ + #ifndef QT_DLL + #define QT_DLL // Internal + #endif ++ ++#if defined(QT_QWS_IPAQ) || defined(QT_QWS_CASSIOPEIA) || defined(QT_QWS_SL5XXX) ++# define QT_NO_QWS_CURSOR ++# define QT_NO_QWS_MOUSE_AUTO ++#endif ++#ifndef QT_NO_CODECS ++#define QT_NO_CODECS ++#endif ++#define QT_NO_UNICODETABLES ++//#define QT_NO_IMAGEIO_BMP ++#define QT_NO_IMAGEIO_PPM ++//#define QT_NO_ASYNC_IO ++//#define QT_NO_ASYNC_IMAGE_IO ++#define QT_NO_FREETYPE ++#define QT_NO_BDF ++//#define QT_NO_FONTDATABASE ++#define QT_NO_DRAGANDDROP ++//#define QT_NO_CLIPBOARD ++#define QT_NO_PROPERTIES ++#define QT_NO_NETWORKPROTOCOL ++ ++#define QT_NO_IMAGE_TEXT ++ ++//#define QT_NO_TOOLTIP ++#define QT_NO_COLORNAMES ++#define QT_NO_TRANSFORMATIONS ++#define QT_NO_TRANSLATION_BUILDER ++#define QT_NO_COMPLEXTEXT ++#define QT_NO_PRINTER ++#define QT_NO_PICTURE ++//#define QT_NO_ICONVIEW ++#define QT_NO_DIAL ++#define QT_NO_SIZEGRIP ++#define QT_NO_WORKSPACE ++//#define QT_NO_TABLE ++//#define QT_NO_ACTION ++//#define QT_NO_SETTINGS ++#define QT_NO_STYLE_POCKETPC ++#ifndef QT_NO_STYLE_AQUA ++# define QT_NO_STYLE_AQUA ++#endif ++#define QT_NO_STYLE_MOTIF ++#define QT_NO_STYLE_PLATINUM ++#define QT_NO_FILEDIALOG ++#define QT_NO_FONTDIALOG ++#define QT_NO_PRINTDIALOG ++#define QT_NO_COLORDIALOG ++#define QT_NO_INPUTDIALOG ++//#define QT_NO_MESSAGEBOX ++#define QT_NO_PROGRESSDIALOG ++//#define QT_NO_TABDIALOG ++#define QT_NO_WIZARD ++#define QT_NO_EFFECTS ++//#define QT_NO_COMPONENT ++#define QT_NO_DOM ++#define QT_NO_SEMIMODAL ++//#define QT_NO_PROGRESSBAR ++#define QT_NO_SPLITTER ++ ++//#define QT_NO_QWS_SAVEFONTS ++//#define QT_NO_QWS_PROPERTIES ++ ++#define QT_NO_QWS_BEOS_WM_STYLE ++#define QT_NO_QWS_KDE2_WM_STYLE ++#define QT_NO_QWS_KDE_WM_STYLE ++#define QT_NO_QWS_WINDOWS_WM_STYLE +Only in qte-2.3.7/src/tools: qconfig.h~ +Only in qte-2.3.7/src/tools: qcstring.o +Only in qte-2.3.7/src/tools: qdatastream.o +Only in qte-2.3.7/src/tools: qdatetime.o +Only in qte-2.3.7/src/tools: qdir.o +Only in qte-2.3.7/src/tools: qdir_unix.o +Only in qte-2.3.7/src/tools: qfile.o +Only in qte-2.3.7/src/tools: qfile_unix.o +Only in qte-2.3.7/src/tools: qfileinfo.o +Only in qte-2.3.7/src/tools: qfileinfo_unix.o +Only in qte-2.3.7/src/tools: qgarray.o +Only in qte-2.3.7/src/tools: qgcache.o +Only in qte-2.3.7/src/tools: qgdict.o +Only in qte-2.3.7/src/tools: qglist.o +Only in qte-2.3.7/src/tools: qglobal.o +Only in qte-2.3.7/src/tools: qgvector.o +Only in qte-2.3.7/src/tools: qiodevice.o +Only in qte-2.3.7/src/tools: qmap.o +diff -ru qte-2.3.7_orig/src/tools/qmodules.h qte-2.3.7/src/tools/qmodules.h +--- qte-2.3.7_orig/src/tools/qmodules.h Fri Aug 31 17:00:56 2001 ++++ qte-2.3.7/src/tools/qmodules.h Wed Oct 29 21:57:53 2003 +@@ -1,14 +1,12 @@ +-#ifndef QT_H +-#endif // QT_H +- ++// These modules are licensed to you + #define QT_MODULE_TOOLS + #define QT_MODULE_KERNEL + #define QT_MODULE_WIDGETS + #define QT_MODULE_DIALOGS +- + #define QT_MODULE_ICONVIEW + #define QT_MODULE_WORKSPACE +-#define QT_MODULE_TABLE ++#define QT_MODULE_NETWORK + #define QT_MODULE_CANVAS ++#define QT_MODULE_TABLE + #define QT_MODULE_XML +-#define QT_MODULE_NETWORK ++#define QT_MODULE_OPENGL +Only in qte-2.3.7/src/tools: qregexp.o +Only in qte-2.3.7/src/tools: qstring.o +Only in qte-2.3.7/src/tools: qstringlist.o +Only in qte-2.3.7/src/tools: qtextcodec.o +Only in qte-2.3.7/src/tools: qtextstream.o +Only in qte-2.3.7/src/tools: qutfcodec.o +Only in qte-2.3.7/src/widgets: qaction.o +Only in qte-2.3.7/src/widgets: qbutton.o +Only in qte-2.3.7/src/widgets: qbuttongroup.o +Only in qte-2.3.7/src/widgets: qcdestyle.o +Only in qte-2.3.7/src/widgets: qcheckbox.o +Only in qte-2.3.7/src/widgets: qcombobox.o +diff -ru qte-2.3.7_orig/src/widgets/qcommonstyle.cpp qte-2.3.7/src/widgets/qcommonstyle.cpp +--- qte-2.3.7_orig/src/widgets/qcommonstyle.cpp Thu Jul 17 03:20:26 2003 ++++ qte-2.3.7/src/widgets/qcommonstyle.cpp Mon Oct 27 14:21:28 2003 +@@ -566,7 +566,7 @@ + bool enabled, bool active ) + { + #ifndef QT_NO_MENUBAR +-#ifndef QT_NO_STYLE_SGI ++#if 1 // #ifndef QT_NO_STYLE_SGI + if (draw_menu_bar_impl != 0) { + QDrawMenuBarItemImpl impl = draw_menu_bar_impl; + (this->*impl)(p, x, y, w, h, mi, g, enabled, active); +Only in qte-2.3.7/src/widgets: qcommonstyle.o +Only in qte-2.3.7/src/widgets: qcompactstyle.o +Only in qte-2.3.7/src/widgets: qdial.o +Only in qte-2.3.7/src/widgets: qeffects.moc +Only in qte-2.3.7/src/widgets: qeffects.o +Only in qte-2.3.7/src/widgets: qframe.o +Only in qte-2.3.7/src/widgets: qgrid.o +Only in qte-2.3.7/src/widgets: qgroupbox.o +Only in qte-2.3.7/src/widgets: qhbox.o +Only in qte-2.3.7/src/widgets: qhbuttongroup.o +Only in qte-2.3.7/src/widgets: qheader.o +Only in qte-2.3.7/src/widgets: qhgroupbox.o +Only in qte-2.3.7/src/widgets: qinterlacestyle.o +Only in qte-2.3.7/src/widgets: qlabel.o +Only in qte-2.3.7/src/widgets: qlcdnumber.o +Only in qte-2.3.7/src/widgets: qlineedit.o +Only in qte-2.3.7/src/widgets: qlistbox.o +diff -ru qte-2.3.7_orig/src/widgets/qlistview.cpp qte-2.3.7/src/widgets/qlistview.cpp +--- qte-2.3.7_orig/src/widgets/qlistview.cpp Thu Jul 17 03:20:26 2003 ++++ qte-2.3.7/src/widgets/qlistview.cpp Mon Oct 27 14:21:28 2003 +@@ -4968,9 +4968,9 @@ + l = l->childItem ? l->childItem : l->siblingItem; + + if ( l && l->height() ) +- s.setHeight( s.height() + 10 * l->height() ); +- else +- s.setHeight( s.height() + 140 ); ++ s.setHeight( s.height() + 4 /*10*/ * l->height() ); ++ else // ^v much too big for handhelds ++ s.setHeight( s.height() + 30 /*140*/ ); + + if ( s.width() > s.height() * 3 ) + s.setHeight( s.width() / 3 ); +Only in qte-2.3.7/src/widgets: qlistview.o +Only in qte-2.3.7/src/widgets: qmainwindow.moc +Only in qte-2.3.7/src/widgets: qmainwindow.o +Only in qte-2.3.7/src/widgets: qmenubar.o +Only in qte-2.3.7/src/widgets: qmenudata.o +Only in qte-2.3.7/src/widgets: qmotifplusstyle.o +Only in qte-2.3.7/src/widgets: qmotifstyle.o +Only in qte-2.3.7/src/widgets: qmultilineedit.o +Only in qte-2.3.7/src/widgets: qplatinumstyle.o +Only in qte-2.3.7/src/widgets: qpopupmenu.o +Only in qte-2.3.7/src/widgets: qprogressbar.o +Only in qte-2.3.7/src/widgets: qpushbutton.o +Only in qte-2.3.7/src/widgets: qradiobutton.o +Only in qte-2.3.7/src/widgets: qrangecontrol.o +Only in qte-2.3.7/src/widgets: qscrollbar.o +Only in qte-2.3.7/src/widgets: qscrollview.o +Only in qte-2.3.7/src/widgets: qsgistyle.o +Only in qte-2.3.7/src/widgets: qslider.o +Only in qte-2.3.7/src/widgets: qspinbox.o +Only in qte-2.3.7/src/widgets: qsplitter.o +Only in qte-2.3.7/src/widgets: qstatusbar.o +Only in qte-2.3.7/src/widgets: qtabbar.o +Only in qte-2.3.7/src/widgets: qtableview.o +Only in qte-2.3.7/src/widgets: qtabwidget.o +Only in qte-2.3.7/src/widgets: qtextbrowser.o +Only in qte-2.3.7/src/widgets: qtextview.o +Only in qte-2.3.7/src/widgets: qtoolbar.moc +Only in qte-2.3.7/src/widgets: qtoolbar.o +diff -ru qte-2.3.7_orig/src/widgets/qtoolbutton.cpp qte-2.3.7/src/widgets/qtoolbutton.cpp +--- qte-2.3.7_orig/src/widgets/qtoolbutton.cpp Thu Jul 17 03:20:27 2003 ++++ qte-2.3.7/src/widgets/qtoolbutton.cpp Mon Oct 27 14:21:28 2003 +@@ -230,7 +230,7 @@ + else + QToolTip::add( this, textLabel ); + } +-#endif ++#endif + } + + +@@ -324,12 +324,12 @@ + QPixmap pm = iconSet(TRUE).pixmap(QIconSet::Large, QIconSet::Normal); + w = pm.width(); + h = pm.height(); +- if ( w < 32 ) +- w = 32; +- if ( h < 32 ) +- h = 32; ++ if ( w < 24 ) ++ w = 24; ++ if ( h < 24 ) ++ h = 24; + } else { +- w = h = 16; ++ w = h = 14; + QPixmap pm = iconSet(TRUE).pixmap(QIconSet::Small, QIconSet::Normal); + w = pm.width(); + h = pm.height(); +Only in qte-2.3.7/src/widgets: qtoolbutton.o +Only in qte-2.3.7/src/widgets: qtooltip.moc +Only in qte-2.3.7/src/widgets: qtooltip.o +Only in qte-2.3.7/src/widgets: qvalidator.o +Only in qte-2.3.7/src/widgets: qvbox.o +Only in qte-2.3.7/src/widgets: qvbuttongroup.o +Only in qte-2.3.7/src/widgets: qvgroupbox.o +Only in qte-2.3.7/src/widgets: qwhatsthis.moc +Only in qte-2.3.7/src/widgets: qwhatsthis.o +Only in qte-2.3.7/src/widgets: qwidgetstack.o +Only in qte-2.3.7/src/widgets: qwindowsstyle.o +Only in qte-2.3.7/src/workspace: qworkspace.moc +Only in qte-2.3.7/src/workspace: qworkspace.o +Only in qte-2.3.7/src/xml: qdom.o +Only in qte-2.3.7/src/xml: qxml.o +Only in qte-2.3.7: src-mt.mk +Only in qte-2.3.7: stamp-headers +Only in qte-2.3.7/tools: Makefile +Only in qte-2.3.7/tools/designer: Makefile +Only in qte-2.3.7/tools/designer/designer: Makefile +Only in qte-2.3.7/tools/designer/examples/walkthrough: Makefile +Only in qte-2.3.7/tools/designer/integration/rc2ui: Makefile +Only in qte-2.3.7/tools/designer/tools/createcw: Makefile +Only in qte-2.3.7/tools/designer/uic: Makefile +Only in qte-2.3.7/tools/designer/util: Makefile +Only in qte-2.3.7/tools/makeqpf: Makefile +Only in qte-2.3.7/tools/mergetr: Makefile +Only in qte-2.3.7/tools/msg2qm: Makefile +Only in qte-2.3.7/tools/qconfig: Makefile +Only in qte-2.3.7/tools/qembed: Makefile +Only in qte-2.3.7/tools/qvfb: Makefile +Only in qte-2.3.7/tutorial: Makefile +Only in qte-2.3.7/tutorial/t1: Makefile +Only in qte-2.3.7/tutorial/t10: Makefile +Only in qte-2.3.7/tutorial/t11: Makefile +Only in qte-2.3.7/tutorial/t12: Makefile +Only in qte-2.3.7/tutorial/t13: Makefile +Only in qte-2.3.7/tutorial/t14: Makefile +Only in qte-2.3.7/tutorial/t2: Makefile +Only in qte-2.3.7/tutorial/t3: Makefile +Only in qte-2.3.7/tutorial/t4: Makefile +Only in qte-2.3.7/tutorial/t5: Makefile +Only in qte-2.3.7/tutorial/t6: Makefile +Only in qte-2.3.7/tutorial/t7: Makefile +Only in qte-2.3.7/tutorial/t8: Makefile +Only in qte-2.3.7/tutorial/t9: Makefile diff --git a/rsync/config_linux.h b/rsync/config_linux.h index e5ff3e4..f488b78 100644 --- a/rsync/config_linux.h +++ b/rsync/config_linux.h @@ -10,33 +10,33 @@ /* Define to `unsigned' if <sys/types.h> doesn't define. */ /* #undef size_t */ /* Define if you have the ANSI C header files. */ #define STDC_HEADERS 1 /* Define this if your sockaddr structure contains sin_len */ /* #undef HAVE_SOCK_SIN_LEN */ /* How many bits would you like to have in an off_t? */ #define _FILE_OFFSET_BITS 64 /* Define to include GNU C library extensions. */ #define _GNU_SOURCE 1 /* GNU extension of saving argv[0] to program_invocation_short_name */ -#define HAVE_PROGRAM_INVOCATION_NAME 1 +/* #define HAVE_PROGRAM_INVOCATION_NAME 1 */ /* Define to a replacement type if intmax_t is not a builtin, or in sys/types.h or stdlib.h or stddef.h */ /* #undef intmax_t */ /* The number of bytes in a int. */ #define SIZEOF_INT 4 /* The number of bytes in a long. */ #define SIZEOF_LONG 4 /* The number of bytes in a off_t. */ #define SIZEOF_OFF_T 8 /* The number of bytes in a short. */ #define SIZEOF_SHORT 2 diff --git a/rsync/trace.h b/rsync/trace.h index 60a6477..2bb8552 100644 --- a/rsync/trace.h +++ b/rsync/trace.h @@ -23,100 +23,90 @@ /* * TODO: A function like perror that includes strerror output. Apache * does this by adding flags as well as the severity level which say * whether such information should be included. */ /* * trace may be turned off. * * error is always on, but you can return and continue in some way * * fatal terminates the whole process */ -void rs_fatal0(char const *s, ...); -void rs_error0(char const *s, ...); -void rs_trace0(char const *s, ...); - -void rs_log0_nofn(int level, char const *fmt, ...); - -#ifdef __GNUC__ +#if defined(HAVE_VARARG_MACROS) && defined(__GNUC__) +/* + * TODO: Don't assume this is a gcc thing; rather test in autoconf for + * support for __FUNCTION__. One simple way might just be to try compiling + * the definition of one of these functions! + * + * TODO: Also look for the C9X predefined identifier `_function', or + * whatever it's called. + */ void rs_log0(int level, char const *fn, char const *fmt, ...) __attribute__ ((format(printf, 3, 4))); #ifdef DO_RS_TRACE # define rs_trace(fmt, arg...) \ do { rs_log0(RS_LOG_DEBUG, __FUNCTION__, fmt , ##arg); \ } while (0) #else -# define rs_trace(s, str...) +# define rs_trace(fmt, arg...) #endif /* !DO_RS_TRACE */ -/* - * TODO: Don't assume this is a gcc thing; rather test in autoconf for - * support for __FUNCTION__ and varargs macros. One simple way might - * just be to try compiling the definition of one of these functions! - * - * TODO: Also look for the C9X predefined identifier `_function', or - * whatever it's called. - */ - #define rs_log(l, s, str...) do { \ rs_log0((l), __FUNCTION__, (s) , ##str); \ } while (0) #define rs_error(s, str...) do { \ rs_log0(RS_LOG_ERR, __FUNCTION__, (s) , ##str); \ } while (0) #define rs_fatal(s, str...) do { \ rs_log0(RS_LOG_CRIT, __FUNCTION__, \ (s) , ##str); \ abort(); \ } while (0) #else /************************* ! __GNUC__ */ - +# define rs_trace rs_trace0 # define rs_fatal rs_fatal0 # define rs_error rs_error0 # define rs_log rs_log0_nofn - -# ifdef DO_RS_TRACE -# define rs_trace rs_trace0 -# endif /* DO_RS_TRACE */ #endif /* ! __GNUC__ */ - +void rs_trace0(char const *s, ...); +void rs_fatal0(char const *s, ...); +void rs_error0(char const *s, ...); void rs_log0(int level, char const *fn, char const *fmt, ...); - +void rs_log0_nofn(int level, char const *fmt, ...); enum { RS_LOG_PRIMASK = 7, /**< Mask to extract priority part. \internal */ RS_LOG_NONAME = 8 /**< \b Don't show function name in message. */ }; - /** * \macro rs_trace_enabled() * * Call this before putting too much effort into generating trace * messages. */ extern int rs_trace_level; #ifdef DO_RS_TRACE # define rs_trace_enabled() ((rs_trace_level & RS_LOG_PRIMASK) >= RS_LOG_DEBUG) #else # define rs_trace_enabled() 0 #endif diff --git a/scripts/kconfig/lkc_proto.h b/scripts/kconfig/lkc_proto.h index 97c7917..e438bd8 100644 --- a/scripts/kconfig/lkc_proto.h +++ b/scripts/kconfig/lkc_proto.h @@ -1,33 +1,33 @@ /* confdata.c */ P(conf_parse,void,(const char *name)); P(conf_read,int,(const char *name)); P(conf_write,int,(const char *name)); /* menu.c */ -P(rootmenu,struct menu,); +extern struct menu rootmenu; P(menu_is_visible,bool,(struct menu *menu)); P(menu_get_prompt,const char *,(struct menu *menu)); P(menu_get_root_menu,struct menu *,(struct menu *menu)); P(menu_get_parent_menu,struct menu *,(struct menu *menu)); /* symbol.c */ P(symbol_hash,struct symbol *,[SYMBOL_HASHSIZE]); -P(sym_change_count,int,); +extern int sym_change_count; P(sym_lookup,struct symbol *,(const char *name, int isconst)); P(sym_find,struct symbol *,(const char *name)); P(sym_type_name,const char *,(enum symbol_type type)); P(sym_calc_value,void,(struct symbol *sym)); P(sym_get_type,enum symbol_type,(struct symbol *sym)); P(sym_tristate_within_range,bool,(struct symbol *sym,tristate tri)); P(sym_set_tristate_value,bool,(struct symbol *sym,tristate tri)); P(sym_toggle_tristate_value,tristate,(struct symbol *sym)); P(sym_string_valid,bool,(struct symbol *sym, const char *newval)); P(sym_string_within_range,bool,(struct symbol *sym, const char *str)); P(sym_set_string_value,bool,(struct symbol *sym, const char *newval)); P(sym_is_changable,bool,(struct symbol *sym)); P(sym_get_choice_prop,struct property *,(struct symbol *sym)); P(sym_get_default_prop,struct property *,(struct symbol *sym)); P(sym_get_string_value,const char *,(struct symbol *sym)); |