Similar documents

Code::Blocks Student Manual

Uninstall Java Manually Mac Os X 10.6 Update 6 Developer Package

ECE QNX Real-time Lab

Physics REU Unix Tutorial

Installing Firefox on Mac

COP 3014: Spring 2018 A Guide to Using CLion

Code::Blocks Student Manual

CS193E: Temperature Converter Walkthrough

January 2015 SPIDER 2j Full Install & Update

Install Guide Windows 7 Usb Macbook Pro 2011 Without Cd

Finder windows To open a new Finder window, click the Finder icon in the Dock, then select File > New Window.

Autumn Apps. Breeze Documentation.

New to the Mac? Then start with this lesson to learn the basics.

Manual Update Java Mac Os X Developer Package

Using Eclipse for C Programming

Introduction. Key features and lab exercises to familiarize new users to the Visual environment

Engr 123 Spring 2018 Notes on Visual Studio

Installation Guide: VirtualBox, Windows 10, and Microsoft Visio (Mac OS)

X Lion Applet Plug-in Using

Introduction to Computers By Jennifer King, YA and Marketing Librarian, Great Bend Public Library

Windows XP. A Quick Tour of Windows XP Features

Prerequisites for Eclipse

Software Installations

ZP NEWS ZONEPRO CUSTOMER SUPPORT NEWSLETTER. August 2010 Volume 14, Number 2

There are a few things that some of you may be worried about, so here is a list of what Picasa will not do for those that may be concerned.

Figure 1-1. When we finish Part 2, our server will be ready to have workstations join the domain and start sharing files. Now here we go!

Mac Show Desktop Keyboard Shortcut Lion >>>CLICK HERE<<<

Using Eclipse for Java. Using Eclipse for Java 1 / 1

Tabbing Between Fields and Control Elements

QNX Software Development Platform 6.6. Quickstart Guide

The New Look of Office 2007

The Start menu (overview)

Installing and Using Xcode

How To Changing Album Name On Macbook Pro Home Folder

Assignment 1. Application Development

Arduino IDE Friday, 26 October 2018

Configuring JCreator to create Javadocs Compilation Shortcut Key

Where Did My Files Go? How to find your files using Windows 10

Manual Mac Os X 10.6 Iso Update 8 Combo >>>CLICK HERE<<<

Using Windows 7 Explorer By Len Nasman, Bristol Village Computer Club

Mac OS X. Starting Up. The Menulets/ Menu Extras. The Menu Bar. The Apple Menu. The Disk/Hard Drive. The Dock. The Finder

Manual Update Java Mac Os X Lion

Getting Started. Chapter

Ad Muncher's New Interface Layout

Learn to make desktop LE

Lab: Supplying Inputs to Programs

Mac App Store Manual Location Lion Installer

Migrating to Daylite 3.9 or later versions (Aug 23, 2011)

Unit 10. Linux Operating System

Unit 13. Linux Operating System Debugging Programs

Manual Eclipse CDT Mac OS Snow Leopard

Backup using Carbon Copy Cloner

Here is a complete outline of the entire course as it is currently planned (contents approximate):

Table of Contents. ShredIt X Read Me.

Managing Files & Folders

KNOWLEDGE FORUM 4 MACINTOSH SERVER ADMINISTRATOR S GUIDE

Manual Xcode Ios 5 Simulator Black Screen >>>CLICK HERE<<<

Mac OS X keyboard shortcuts Learn about common Mac OS X keyboard shortcuts.

CS193P: HelloPoly Walkthrough

Version 8 Installation Guide: Windows or Mac versions

Notepad++ The COMPSCI 101 Text Editor for Windows. What is a text editor? Install Python 3. Installing Notepad++

Getting Started With Parallels Desktop 14

INSTALLATION GUIDELINES FOR CLIENTS

CSE 303 Lecture 2. Introduction to bash shell. read Linux Pocket Guide pp , 58-59, 60, 65-70, 71-72, 77-80

Sample Spark Web-App. Overview. Prerequisites

If you save your printer setup in AUTOLOAD.SON you don't have to bother with the printer setting each time you want to use 1. Load AUTOLOAD.SON.

Chapter 1 HMSL on the Macintosh

DEVELOPING OOSIML SIMULATION MODELS. Using Codeblocks

FILE / HOW TO BACKUP RESTORE FRESH OSX NEW HDD EBOOK

Administering Jive Ideation

Itunes Ipod Manual Sync New Computer Without Deleting Music Windows 7

Running Java Programs

Macintosh OS X 10.4 Tips

Download the current release* of VirtualBox for the OS on which you will install VirtualBox. In these notes, that's Windows 7.

How To Restore Macbook Pro To Factory Settings Snow Leopard No Disk

2a. Widgets-Basics 10/30/06 4:05 PM

Getting Started with Command Prompts

General Guidelines: SAS Analyst

Manual Mac Os X 10.6 Iso Update 8 Or Later

Click Here to Begin OS X. Welcome to the OS X Basics Learning Module.

How to install aabridge on a Mac

Module 3: Working with C/C++

Computer Basics: Step-by-Step Guide (Session 2)

Windows XP Lab 2. Competencies

JCreator. Starting JCreator

Below you'll find some browser and device specific instructions, as well as links to more expansive tutorials if you need them.

Frequently Asked Questions About the Unitor 8 Preference Pane

Slide 1 CS 170 Java Programming 1 Testing Karel

Iphone 4 Headphones Volume Control Not. Working >>>CLICK HERE<<<

Build your own NeXT with a virtual machine Created by Matthew Goodrich. Last updated on :10:02 PM UTC

How To Install Latex Mac Os X Lion On Pc Step By Step

Add Student Course Survey Link To A Canvas Course

Chris' Makefile Tutorial

EECE.2160: ECE Application Programming Spring 2018 Programming Assignment #1: A Simple C Program Due Monday, 1/29/18, 11:59:59 PM

Manually Update Firefox Mac Os X To

ArtDMX DMX control software V1.4

Uninstall Java Manual Mac Os X Mountain Lion Oracle

Getting Help...71 Getting help with ScreenSteps...72

How Do I Open Up My Itunes Library On Another Computer

Transcription:

1 of 5 3/28/2010 8:04 AM XCode Notes Home Class Info Links Lectures Newsgroup Assignmen Xcode is a free integrated development environment (IDE) for C, C++, Java and other languages on MacOS X. It comes on the CD distributed with the Leopard edition of MacOS X. Jump to Installing, Creating a project, Tips and traps. Requirements You need to have XCode installed. It's best to have the current version. If you have Leopard, install XCode from the CD distributed with your machine. If you have an older version of MacOS X, or don't have your installer disk, see these instructions for downloading Xcode from Apple. This chapter has useful tips on what you can leave out. For Tiger, get Xcode Version 2.5. For Leopard or later, get Version 3.0 or later. You need CppUnit. See these instructions for using MacPorts to get it. MacPorts will install CppUnit in the /opt/local directory. The example Makefile used below checks this directory. Download and test the example Makefile. You need the directory and files from that test to do these instructions. How to Create a EECS 211 Console Project The instructions below show how to build an EECS 211 console C++ project, using a Makefile. A console project is one that does all its input and output in a console window, e.g., a terminal window. Such programs are simple to set up, but a bit old-fashioned. Start Xcode, click on the File menu, then on New Project... The New Project dialog box will appear. Select Empty Project, then click Next.

2 of 5 3/28/2010 8:04 AM Xcode now asks for a project name and a directory. Click on Choose... to get a file dialog box. Use it to find and select your EECS 211 projects directory. Then enter the name of the project, e.g,. Xcode automatically uses the project name to make a subdirectory. When done, click Finish. The New Project window will appear. Select Add to Project... from the Project menu. Use the mini-finder window to find and select the two source files in the example directory. Use command-click to select all four files at once. (You don't actually need to select Makefile or header files, if there were any, but it's handy to have them available in the editor.) Click Add to add the selected files. Your project window should now look like this.

3 of 5 3/28/2010 8:04 AM Now tell XCode to use the Makefile. Select New Target... from the Project menu. Select External Target under Special Targets. Then click Next. Xcode will ask you to name your target. Just call it example and click Finish. Now you're back to the project window. Click the Build button. You should see "Build succeeded" and "Succeded" in the status lines at the bottom of the window. If not, click the small error icon to the left of "Failed" in the lower-right corner to see the error messages. Try to fix them. Post the first one or two to the newsgroup if you can't figure out what to do. When you have an executable file, you can tell XCode to run it when you click the Build and Go icon. Select New Custom Executable... under the Project menu. Click Choose... and use the mini-finder to find and select the example.exe file that the Makefile created, then click Finish.

4 of 5 3/28/2010 8:04 AM A dialog appears to let you specify options for running this executable. Just close this box. From now on, clicking the Build and Go icon will compile and run your project. Try it now. Assuming you've made no errors in your code, it should compile and run, and the output should appear in the console window. To see the output, select Console under the Run menu. The console output should look like the output you saw when you ran the executable directly in a Terminal window. Tips and Traps Learn the shorcuts. This is a general tip for any development tool. After you've used your IDE a bit, learn to use the keyboard shortcuts for compiling and running and so on. This will speed up coding and testing a lot. Don't rename code files in the Finder. This is a general tip for any development tool. Don't rename or delete files behind its back. The IDE can get very confused. Most IDEs provide their own commands for renaming and removing files, that rename or remove the file and also update the IDE's internal records. Watch your head(er)! When you tell XCode to create a new C++ file, it automatically creates a header file too. That's fine because header files are good. But XCode opens the header file not the.cpp file. Many students accidentally put their C++ code into the header file, thinking they're putting it in the.cpp file. Why can't it find my file? If your program needs to read a data file, you have to tell XCode where to look. Select Project Edit Active Executable to get the Executable Info dialog box, and set the working directory as shown to the directory that contains your data file(s).

5 of 5 3/28/2010 8:04 AM Comments? Contact the Prof!