Create a new project or use the default one that Lazarus IDE creates on first launch.
Note: Latest Lazarus IDE creates Application Bundles by himself when you create a new project, so you don't need to worry about this (while you leave the Create Application Bundle check box inside Project -> Project Options -> Application tab to it's default enabled state.
QT MAC INSTALL FREE
XCode 3.(Don't know - but it's free one).
Cannot build pure cocoa widget set ATSUXXXX symbols are missing (probably need to pass more frameworks to linker).
Qt-cocoa have problems with mouseGrabber (possible it's fixed in 4.8.0).
Tools->Configure Build Lazarus-> choose LCL widget type qt, in options write -k-framework -kApplicationServices (yes, without any quotes).
build it for carbon (32bit), startlazarus, go to Tools->Options, change cpu from /usr/local/bin/fpc to /usr/local/bin/ppc圆4 in Compiler path (also fix source path to 2.6.0 if it isn't already fixed).
make bigide CPU_TARGET=x86_64 LCL_PLATFORM=qt OPT="-k'-framework' -k'ApplicationServices'" (don't forget to change default compiler in Tools->Options->Compiler path)īuild carbon from terminal, then ide from ide.
QT MAC INSTALL INSTALL
Build and install bindings as in readme.
Open Qt4Pas.pro and comment CXXFLAGS += -mstackrealign (since it will be error with 64bit build on mac).
QT MAC INSTALL DOWNLOAD
Download qt-4.7.4 from nokia site (DO NOT DOWNLOAD 4.8.0 SINCE IT'S WRONGLY PACKAGED atm - won't work (missing symbols in QWebKit) ).
Download and install fpc-2.6.0 (with 2.4.4 64bit you can compile lazarus etc but it will crash imediatelly).I've used "svn co fpc260", then "fpcmake -Tall", "make all", "sudo make install", "sudo make CPU_TARGET=x86_64 make install" (of course you need fpc-2.4.4 to build 2.6.0, you can download dmgs from lazarus daily snapshots.
Qt binary distribution (>=4.7.4) is 64bit (cocoa only), so we need 64bit Qt4Pas and 64bit 2.6.0 compiler
64bit set qt widgetset and add -Px86_64 -Tdarwin in ide build config dialog.IMPORTANT NOTE: you must build IDE with make first (from terminal), and then you can rebuild from IDE because of bug (dunno where it is) which causes linking of lazarus against 32bit objects.īuild Lazarus with qt-cocoa (qt binary distribution from nokia >= 4.7.4).
32bit just set qt widgetset in ide build config dialog and rebuild.
64bit (Cocoa): make bigide OS_TARGET=darwin CPU_PLATFORM=x86_64 LCL_PLATFORM=qt.
32bit (Carbon): make bigide LCL_PLATFORM=qt.
You must rebuild libQt4Pas library according to your needs (32/64bit).
(Optional) Rename qt4.pas in qt45.pas and copy it inside /Developer/lazarus/lcl/interfaces/qt.
QT MAC INSTALL ZIP
After you click on the downloaded file it will be automatically unpacked and you will see another zip inside, unzip it too and install the package you find inside.
Next you need to download the Interface Binary Bindings from site, search for Mac: Libray Binary Intel, the file you download is named something like mac_bin-qt4pas-V2.4_Qt4.5.3.zip (don't worry about version in file name, it's indicating the lowest version required by Binaries).
Now Mount the disk image and install the package that you find inside.
The file you need is named something like qt-mac-opensource-4.7.4.dmg or with greater version.
Build yourself Interface Binary Bindings and Qt Framework Library (hard and may take many hours)įastest way to get you ready to develop applications with Qt Framework (+ LCL Widgetset)įirst you need to download the Cocoa Mac binary package of Qt4 Framework Library from Nokia Qt download section or from a Trolltech mirror.
Install compiled Interface Binary Bindings and Qt Framework Library.
There are two main path you can follow to start deploying your first Qt Application for Mac:
5 Uninstalling the Qt4 Interface and Qt4 Framework.
4 Distributing an app that uses the Qt Interface Framework.
3.7 Creating an LCL app that uses the Qt widgetset.
3.6.2 Starting from a Gtk based Lazarus.
3.5 Creating a demo program application bundle.
3.4 Compiling the non-Lazarus demo programs with Free Pascal.
3.3 Creating the Qt interface framework.
2.4 Build Lazarus with qt-cocoa (qt binary distribution from nokia >= 4.7.4).