Changeset 1058
- Timestamp:
- Sep 7, 2011, 1:09:53 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/README.OS2
r1040 r1058 75 75 http://www.os2site.com/sw/util/archiver/lxlt133.zip 76 76 77 - CUPS 1. 3.11or later to support printing in Qt. The CUPS libraries are77 - CUPS 1.4.8 or later to support printing in Qt. The CUPS libraries are 78 78 available at: 79 79 80 http://download.smedley.info/cups-1.3.11-os2-20090807.zip 81 82 Linking against eCUPS also requires pthread.lib: 83 84 http://web.os2power.com/download/lib/pthread-20100217-os2.zip 80 http://sourceforge.net/projects/ecsports/files/CUPS/cups-1.4.8-os2-20110831.zip/download 81 http://svn.netlabs.org/ecups/wiki/CupsPort 85 82 86 83 - OpenSSL 0.9.8o or later to support OpenSSL in Qt. The OpenSSL libraries are … … 95 92 http://download.smedley.info/mysql-5.1.51-os2-20101001.zip 96 93 97 Note that you will also need the above OpenSSL libraries and pthread.lib to 98 be able to use this MySQL build. The MySQL Qt plugin itself will require 99 OpenSSL DLLs in your LIBPATH at runtime. 94 Linking against this MySQL build also requires pthread.lib: 95 96 http://web.os2power.com/download/lib/pthread-20100217-os2.zip 97 98 Note that you will also need the above OpenSSL libraries to be able to use 99 this MySQL build. The MySQL Qt plugin itself will require OpenSSL DLLs in 100 your LIBPATH at runtime. 100 101 101 102 - PostgersSQL 9.0.1 or later to support the PostgresSQL Qt plugin. The … … 191 192 192 193 set CUPS_INCLUDEPATH=<path_to_CUPS>\include 193 set CUPS_LIBS=-L<path_to_CUPS>\lib -llibcups.a -L<path_to_pthread> -lpthread.lib 194 set CUPS_LIBS= 195 196 Note that you will also need to add the location of cups.dll to BEGINLIBPATH 197 (if it is not already in your LIBPATH) so that Qt applications can find it 198 at runtime: 199 200 set BEGINLIBPATH=<path_to_CUPS>\sbin;%BEGINLIBPATH% 194 201 195 202 - Unzip the OpenSSL libraries to some directory and set the following … … 199 206 set OPENSSL_LIBS= 200 207 201 Note that you will also need to place OpenSSL DLLs to BEGINLIBPATH (if they202 are not already in your LIBPATH) so that Qt applications can find them at203 runtime:208 Note that you will also need to add the location of OpenSSL DLLs to 209 BEGINLIBPATH (if they are not already in your LIBPATH) so that Qt 210 applications can find them at runtime: 204 211 205 212 set BEGINLIBPATH=<path_to_OpenSSL>\dll;%BEGINLIBPATH% -
trunk/configure.cmd
r1055 r1058 839 839 G.CUPS_INCLUDEPATH = GetEnv('CUPS_INCLUDEPATH') 840 840 G.CUPS_LIBS = GetEnv('CUPS_LIBS') 841 if (G.CUPS_INCLUDEPATH \== '' & G.CUPS_LIBS \== '') then do841 if (G.CUPS_INCLUDEPATH \== '') then do 842 842 call SayVerbose 'CUPS include path : 'G.CUPS_INCLUDEPATH 843 843 call SayVerbose 'CUPS libraries : 'G.CUPS_LIBS -
trunk/src/gui/painting/qcups.cpp
r846 r1058 50 50 51 51 QT_BEGIN_NAMESPACE 52 53 #ifndef Q_WS_PM54 52 55 53 typedef int (*CupsGetDests)(cups_dest_t **dests); … … 88 86 static CupsPrintFile _cupsPrintFile = 0; 89 87 90 #else // ifndef Q_WS_PM 91 92 // On OS/2, we link to libcups statically 93 94 static bool cupsLoaded = false; 95 static int qt_cups_num_printers = 0; 96 97 #define _cupsGetDests cupsGetDests 98 #define _cupsFreeDests cupsFreeDests 99 #define _cupsGetPPD cupsGetPPD 100 #define _cupsLangGet cupsLangGet 101 #define _cupsLangEncoding cupsLangEncoding 102 #define _ppdOpenFile ppdOpenFile 103 #define _ppdMarkDefaults ppdMarkDefaults 104 #define _ppdClose ppdClose 105 #define _cupsMarkOptions cupsMarkOptions 106 #define _ppdMarkOption ppdMarkOption 107 #define _cupsFreeOptions cupsFreeOptions 108 #define _cupsSetDests cupsSetDests 109 #define _cupsAddOption cupsAddOption 110 #define _cupsTempFd cupsTempFd 111 #define _cupsPrintFile cupsPrintFile 112 113 #endif // ifndef Q_WS_PM 88 #ifdef Q_OS_OS2 89 #define CUPS_RESOLVE_cups(func) _cups##func = (Cups##func) cupsLib.resolve("_cups"#func) 90 #define CUPS_RESOLVE_ppd(func) _ppd##func = (PPD##func) cupsLib.resolve("_ppd"#func) 91 #else 92 #define CUPS_RESOLVE_cups(func) _cups##func = (Cups##func) cupsLib.resolve("cups"#func) 93 #define CUPS_RESOLVE_ppd(func) _ppd##func = (PPD##func) cupsLib.resolve("ppd"#func) 94 #endif 114 95 115 96 static void resolveCups() 116 97 { 117 #ifndef Q_WS_PM118 98 QLibrary cupsLib(QLatin1String("cups"), 2); 119 99 if(cupsLib.load()) { 120 _cupsGetDests = (CupsGetDests) cupsLib.resolve("cupsGetDests");121 _cupsFreeDests = (CupsFreeDests) cupsLib.resolve("cupsFreeDests");122 _cupsGetPPD = (CupsGetPPD) cupsLib.resolve("cupsGetPPD");123 _cupsLangGet = (CupsLangGet) cupsLib.resolve("cupsLangGet");124 _cupsLangEncoding = (CupsLangEncoding) cupsLib.resolve("cupsLangEncoding");125 _ppdOpenFile = (PPDOpenFile) cupsLib.resolve("ppdOpenFile");126 _ppdMarkDefaults = (PPDMarkDefaults) cupsLib.resolve("ppdMarkDefaults");127 _ppdClose = (PPDClose) cupsLib.resolve("ppdClose");128 _cupsMarkOptions = (CupsMarkOptions) cupsLib.resolve("cupsMarkOptions");129 _ppdMarkOption = (PPDMarkOption) cupsLib.resolve("ppdMarkOption");130 _cupsFreeOptions = (CupsFreeOptions) cupsLib.resolve("cupsFreeOptions");131 _cupsSetDests = (CupsSetDests) cupsLib.resolve("cupsSetDests");132 _cupsAddOption = (CupsAddOption) cupsLib.resolve("cupsAddOption");133 _cupsTempFd = (CupsTempFd) cupsLib.resolve("cupsTempFd");134 _cupsPrintFile = (CupsPrintFile) cupsLib.resolve("cupsPrintFile");100 CUPS_RESOLVE_cups(GetDests); 101 CUPS_RESOLVE_cups(FreeDests); 102 CUPS_RESOLVE_cups(GetPPD); 103 CUPS_RESOLVE_cups(LangGet); 104 CUPS_RESOLVE_cups(LangEncoding); 105 CUPS_RESOLVE_ppd(OpenFile); 106 CUPS_RESOLVE_ppd(MarkDefaults); 107 CUPS_RESOLVE_ppd(Close); 108 CUPS_RESOLVE_cups(MarkOptions); 109 CUPS_RESOLVE_ppd(MarkOption); 110 CUPS_RESOLVE_cups(FreeOptions); 111 CUPS_RESOLVE_cups(SetDests); 112 CUPS_RESOLVE_cups(AddOption); 113 CUPS_RESOLVE_cups(TempFd); 114 CUPS_RESOLVE_cups(PrintFile); 135 115 136 116 if (_cupsGetDests && _cupsFreeDests) { 137 #endif138 117 cups_dest_t *printers; 139 118 int num_printers = _cupsGetDests(&printers); … … 141 120 _cupsFreeDests(num_printers, printers); 142 121 qt_cups_num_printers = num_printers; 143 #ifndef Q_WS_PM 144 } 145 } 146 #endif 122 } 123 } 147 124 cupsLoaded = true; 148 125 } … … 250 227 251 228 return 252 #ifndef Q_WS_PM253 229 _cupsGetDests && 254 230 _cupsFreeDests && … … 264 240 _cupsLangEncoding && 265 241 _cupsAddOption && 266 #endif267 242 (qt_cups_num_printers > 0); 268 243 } -
trunk/src/gui/painting/qcups_p.h
r846 r1058 60 60 #ifndef QT_NO_CUPS 61 61 62 #ifndef Q_WS_PM63 62 #include <QtCore/qlibrary.h> 64 #endif65 63 #include <cups/cups.h> 66 64 #include <cups/ppd.h>
Note:
See TracChangeset
for help on using the changeset viewer.