View Issue Details

IDProjectCategoryView StatusLast Update
0025139LazarusWidgetsetpublic2013-10-04 07:42
ReporterGroffy Assigned ToZeljan Rikalo  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
OSWindows 
Product Version1.0.13 (SVN) 
Summary0025139: Lazarus trunk not compiling with QT widgetset under Windows
DescriptionThis issue exists since ref 19501. The conditionnal compiler switches

{$ifdef BINUX or MSWINDOWS or DARWIN}

are not working. They need to be replaced with

{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}

Patch file is attached
Tagsqt
Fixed in Revision43062
LazTarget-
WidgetsetQT
Attached Files

Activities

Groffy

2013-10-03 11:27

reporter  

qt45.pas.patch (4,957 bytes)   
Index: qt45.pas
===================================================================
--- qt45.pas	(Revision 43061)
+++ qt45.pas	(Arbeitskopie)
@@ -4131,7 +4131,7 @@
 function QApplication_x11ClientMessage(handle: QApplicationH; AnonParam1: QWidgetH; AnonParam2: PEvent; passive_only: Boolean): Integer; cdecl; external Qt4PasLib name 'QApplication_x11ClientMessage';
 function QApplication_x11ProcessEvent(handle: QApplicationH; AnonParam1: PEvent): Integer; cdecl; external Qt4PasLib name 'QApplication_x11ProcessEvent';
 {$endif}
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
 function QApplication_isSessionRestored(handle: QApplicationH): Boolean; cdecl; external Qt4PasLib name 'QApplication_isSessionRestored';
 procedure QApplication_sessionId(handle: QApplicationH; retval: PWideString); cdecl; external Qt4PasLib name 'QApplication_sessionId';
 procedure QApplication_sessionKey(handle: QApplicationH; retval: PWideString); cdecl; external Qt4PasLib name 'QApplication_sessionKey';
@@ -4171,7 +4171,7 @@
   QApplication_lastWindowClosed_Event = procedure () of object cdecl;
   QApplication_focusChanged_Event = procedure (old: QWidgetH; now: QWidgetH) of object cdecl;
   QApplication_fontDatabaseChanged_Event = procedure () of object cdecl;
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
   QApplication_commitDataRequest_Event = procedure (sessionManager: QSessionManagerH) of object cdecl;
   QApplication_saveStateRequest_Event = procedure (sessionManager: QSessionManagerH) of object cdecl;
 {$endif}
@@ -5338,7 +5338,7 @@
   QShortcut_activatedAmbiguously_Event = procedure () of object cdecl;
 
 
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
 
 type
   QSessionManagerRestartHint = ( // QSessionManager::RestartHint (1)
@@ -5345,7 +5345,7 @@
     QSessionManagerRestartIfRunning, QSessionManagerRestartAnyway, QSessionManagerRestartImmediately, QSessionManagerRestartNever );
 
 {$endif}
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
 procedure QSessionManager_sessionId(handle: QSessionManagerH; retval: PWideString); cdecl; external Qt4PasLib name 'QSessionManager_sessionId';
 procedure QSessionManager_sessionKey(handle: QSessionManagerH; retval: PWideString); cdecl; external Qt4PasLib name 'QSessionManager_sessionKey';
 {$endif}
@@ -5352,7 +5352,7 @@
 {$ifdef BINUX or DARWIN }
 function QSessionManager_handle(handle: QSessionManagerH): Pointer; cdecl; external Qt4PasLib name 'QSessionManager_handle';
 {$endif}
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
 function QSessionManager_allowsInteraction(handle: QSessionManagerH): Boolean; cdecl; external Qt4PasLib name 'QSessionManager_allowsInteraction';
 function QSessionManager_allowsErrorInteraction(handle: QSessionManagerH): Boolean; cdecl; external Qt4PasLib name 'QSessionManager_allowsErrorInteraction';
 procedure QSessionManager_release(handle: QSessionManagerH); cdecl; external Qt4PasLib name 'QSessionManager_release';
@@ -6503,7 +6503,7 @@
 procedure QFont_removeSubstitution(AnonParam1: PWideString); cdecl; external Qt4PasLib name 'QFont_removeSubstitution';
 procedure QFont_initialize(); cdecl; external Qt4PasLib name 'QFont_initialize';
 procedure QFont_cleanup(); cdecl; external Qt4PasLib name 'QFont_cleanup';
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
 procedure QFont_cacheStatistics(); cdecl; external Qt4PasLib name 'QFont_cacheStatistics';
 {$endif}
 procedure QFont_defaultFamily(handle: QFontH; retval: PWideString); cdecl; external Qt4PasLib name 'QFont_defaultFamily';
@@ -13360,7 +13360,7 @@
 procedure QApplication_hook_hook_lastWindowClosed(handle: QApplication_hookH; hook: QApplication_lastWindowClosed_Event); cdecl; external Qt4PasLib name 'QApplication_hook_hook_lastWindowClosed';
 procedure QApplication_hook_hook_focusChanged(handle: QApplication_hookH; hook: QApplication_focusChanged_Event); cdecl; external Qt4PasLib name 'QApplication_hook_hook_focusChanged';
 procedure QApplication_hook_hook_fontDatabaseChanged(handle: QApplication_hookH; hook: QApplication_fontDatabaseChanged_Event); cdecl; external Qt4PasLib name 'QApplication_hook_hook_fontDatabaseChanged';
-{$ifdef BINUX or MSWINDOWS or DARWIN }
+{$if defined(BINUX) or defined(MSWINDOWS) or defined(DARWIN)}
 procedure QApplication_hook_hook_commitDataRequest(handle: QApplication_hookH; hook: QApplication_commitDataRequest_Event); cdecl; external Qt4PasLib name 'QApplication_hook_hook_commitDataRequest';
 procedure QApplication_hook_hook_saveStateRequest(handle: QApplication_hookH; hook: QApplication_saveStateRequest_Event); cdecl; external Qt4PasLib name 'QApplication_hook_hook_saveStateRequest';
 {$endif}
qt45.pas.patch (4,957 bytes)   

Zeljan Rikalo

2013-10-03 13:44

developer   ~0070508

1.Trunk is not 1.0.13
2.What compiler do you use ?

Zeljan Rikalo

2013-10-03 13:45

developer   ~0070509

Please test and close if ok. I've changed a bit your patch since you forgot to apply cpu64 conditional at the beginning of qt45.pas

Groffy

2013-10-03 18:26

reporter   ~0070521

If I update to latest version from trunk, which version I have to choose from the combobox? Version 1.3 is not available. I just took the latest qt45.pas file and changed this 6 or 7 compiler conditions. At home I have only Win XP-32bit for testing. Tomorrow I can test on Win7-64bit as well. Actually I'm still using FPC 2.6.2

Issue History

Date Modified Username Field Change
2013-10-03 11:27 Groffy New Issue
2013-10-03 11:27 Groffy File Added: qt45.pas.patch
2013-10-03 11:34 Groffy Tag Attached: qt
2013-10-03 13:44 Zeljan Rikalo Note Added: 0070508
2013-10-03 13:45 Zeljan Rikalo Fixed in Revision => 43062
2013-10-03 13:45 Zeljan Rikalo LazTarget => -
2013-10-03 13:45 Zeljan Rikalo Note Added: 0070509
2013-10-03 13:45 Zeljan Rikalo Status new => resolved
2013-10-03 13:45 Zeljan Rikalo Resolution open => fixed
2013-10-03 13:45 Zeljan Rikalo Assigned To => Zeljan Rikalo
2013-10-03 18:26 Groffy Note Added: 0070521
2013-10-04 07:42 Groffy Status resolved => closed