< Getting Started | BuildRevision as of 00:20, 10 August 2010 by Odysseus (talk | contribs) (→Using MacPorts.)(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff) Contents 1 Introduction 2 Install XCode and X11. 3 MacPorts. 3.1 Install MacPorts. 3.2 Using MacPorts. 4 Install stable KDE 5 Configure your KDE development environment Introduction The process described here sets up a MacPorts installation of the latest stable KDE SC release and uses this to then build a KDE trunk development environment. This approach has the big advantage of using MacPorts to build, install and keep updated the base system and libraries required with minimal effort and without touching the base OSX system install, and allows you to run stable KDE apps for everyday use while still developing on the unstable trunk. The big disadvantage is compiling all the MacPort dependencies takes longer than binary installs. This process makes use of David Faure's scripts. One point to remember is that OS X is a customised version of BSD, so while it feels fairly familiar to a Linux developer, there are the occasional banana skins to slip you up. Install XCode and X11. Install Apple's XCode developer tools either from your OS X install disks or download from http://developer.apple.com/technologies/xcode.html. If you are running Tiger you will also need to install Apple's X11 from your OS X Install disks. Snow Leopard and Leopard come with it installed by default. Once installed, perform an OS X Software Update to ensure your system is fully up-to-date and reboot if required. MacPorts. "The MacPorts Project is an open-source community initiative to design an easy-to-use system for compiling, installing, and upgrading either command-line, X11 or Aqua based open-source software on the Mac OS X operating system." MacPorts installs everything into /opt/local and so doesn't interfere with the base OS X install or any other local installs you have. This enables you to control the environment search hierarchy for different purposes. Applications installed via MacPorts can be run from the command line or from the /Applications/MacPorts folder in the finder. Install MacPorts. It is recommended to initially install MacPorts using the package installer as this will automatically set-up your required $PATH. Using MacPorts. MacPorts should be very easy to use for anyone used to Linux-style package management. Update MacPorts and the list of available ports, you should do this regularly: sudo port selfupdate Update all packages with new versions and uninstall the old versions (omit the -u to keep the old version): sudo port -u -v upgrade outdated Update all installed packages and uninstall any old versions: sudo port -u -v upgrade installed List all available packages: port list List all installed packages: port installed List all installed packages with available updates: port outdated Search for a package: port search <package> Show information about a package: port info <package> Install a package, the -v is needed to see the build output: sudo port -v install <package> List the contents of an installed package port contents <package> Uninstall a package: sudo port uninstall <package> See the MacPorts documentation for more advanced options. GUI frontends are available if you prefer. Install stable KDE If you have plenty of time, just choose to install one of the major KDE packages and leave it running for 24-48 hours: sudo port -v install kdegames4 This will resolve all the dependencies and compile and install everything you need including development tolls like subversion and cmake. You may prefer to break it up into smaller chunks, although the Qt build will still take a long time. sudo port -v install cmake sudo port -v install qt4-mac sudo port -v install kdelibs4 etc... Once everything is built you should be able to run the stable apps from /Applications/MacPorts/KDE4 or just search for them using Spotlight. Configure your KDE development environment From this point on, the process is very similar to a standard KDE development build. Retrieved from "https://techbase.kde.org/index.php?title=Getting_Started/Build/Mac_OS_X/MacPorts&oldid=53313" Content is available under Creative Commons License SA 4.0 unless otherwise noted.