Mac details

Downloading from a CD or Memory Stick

 * The installers will be available to workshop participants on site.
 * Copy the file SIGCSE-HFOSS-XAMPP-0.3 and ECLIPSE-WKSP-0.3 from the CD (or the memory stick) to your desktop.

Download Image (Caution: 300 Mb)

 * Mac Image (.dmg)

Preliminaries
prompt$ ps ax | grep mysql 9068 s000 R+     0:00.00 grep mysql prompt$ ps ax | grep httpd 9078 s000 R+     0:00.00 grep httpd The output in this example indicates that no process containing the name mysql is running. If you find apache or mysql processes running, you will want to kill them. For example, if the mysql process id (pid) is 9077, the use one of the following commands to kill it: prompt$ kill 9077 prompt$ sudo kill 9077 The sudo command will prompt you for a super user password.
 * Quit all applications except your browser.
 * Make sure the Apache and MySQL servers are not running on your system.
 * Make sure Apache 2 is not running--i.e., Stop Web Sharing in System Preferences.
 * To test if your system is running MySQL or Apache (httpd), type the following commands in a Terminal Window:

Instructions
For MacOS, there are two packages:  SIGCSE-XAMPP-0.3 and SIGCSE-ECLIPSE-0.3. The first installs and configures XAMPP, the second installs Eclipse and sets up a workspace for the workshop.
 * 1) Install SIGCSE-XAMPP-0.3 first, then SIGCSE-ECLIPSE-0.3.  For SIGCSE-ECLIPSE-0.3, select your home directory as Destination Folder.
 * 2) The SIGCSE-XAMPP-0.3 package will create and install files in /Applications/xampp, and this cannot be changed.  If you have an existing XAMPP installation at that location, be sure to move it out of the way, as otherwise some components will be overwritten.
 * 3) For SIGCSE-ECLIPSE-0.3, You may choose a different destination folder, but the destination you choose must have global read and execute permissions.
 * 4) You will need your administrator name and password for both packages.
 * 5) When installation is complete:
 * 6) XAMPP will be installed in /Applications/xampp.
 * 7) The directory hfoss will have been created in your selected destination directory.
 * 8) Apache and MySQL will be started.
 * 9) Verify that Apache and MySQL have been started and configured properly.
 * 10) Start your web browser and enter "localhost" for the URL.  You should see the XAMPP splash page, which indicates that Apache has been started.  Click on the language of your choice.
 * 11) Click on "phpMyAdmin" in the toolbar on the left; you should get a new window in which a database-looking screen appears, which indicates that MySQL has been started and configured properly.
 * 12) Note that if you click on the XAMPP "Status" link, it may claim that MySQL is deactivated.  This is because XAMPP expects MySQL to have a root account with no password, whereas part of our configuration sets a password for that account.
 * 13) Start Eclipse; the application is located at  /hfoss/eclipse/Eclipse.app).  When you start Eclipse the first time, do the following:
 * 14) You will be prompted for a workspace; select  /hfoss/workspace.
 * 15) Close the "Welcome" screen by clicking on the "X" in its tab.
 * 16) Import some preferences for working in PHP as follows.
 * 17) Go to File->Import; Select General->Preferences; and click "Next."
 * 18) Click Browse to select the file  /hfoss/eclipse_preferences.epf; make sure "Import all" is selected; and press Finish.  It may take up to 20 seconds for the import to complete, and unfortunately Eclipse does not provide much feedback at this stage.
 * 19) Set the perspective for working on PHP projects as follows.
 * 20) If there is a button in the upper-right corner labeled "PHP," select it.
 * 21) If there is no such button (more likely), go to Window->Open Perspective->Other..., select PHP from the list, and click on OK.
 * 22) Import the SIGCSE workshop projects into Eclipse.
 * 23) Go to File->Import; Select General->Existing Projects into Workspace; and click "Next."
 * 24) Choose the "Select root directory" radiobutton and browse to select root directory  /hfoss/workspace.
 * 25) The projects "helloworld" and "vmoss" should appear in the list and be checked; if they are not checked, check them.
 * 26) Click on Finish.
 * 27) Verify that Eclipse has been installed and configured properly.
 * 28) Click on the "PHP Browser" tab in the lower section of Eclipse.
 * 29) Open the twistie for the "helloworld" project and double-click on "hello.php."  A small PHP file should appear in the editor section of Eclipse.
 * 30) Click somewhere in the editor section; the text "Hello World!" should appear in the PHP Browser.  You may not need to click on the editor for the text to appear.

File Structure On Mac OS
The following directories and files are installed by the above packages: /tmp/ or   hfoss/ eclipse_preferences.epf (Eclipse preferences) eclipse/ (Eclipse application) workspace/ helloworld/ (Hello world test project) vmoss/ (VMOSS Installation) /Applications/ xampp/ (XAMPP installation) XAMPP Control Panel.app (Run this to start/stop XAMPP) etc/ (httpd.conf, php.ini and other config files) htdocs -> /Applications/xampp/xamppfiles/htdocs (Apache document root) /apache (Apache greeting page) /workspace -> /hfoss/workspace (Workshop applications) /xampp (Sample Applications) logs -> /Applications/xampp/xamppfiles/logs (Apache and other logs)

Shutting down XAMPP
To shut down XAMPP, start the XAMPP control panel that is located at /Applications/xampp/XAMPP Control Panel. You may need to authenticate as an administrator. Click on the "Stop" button for "All Components."