This is a walkthrough for setting up a <city w:st="on"><place w:st="on">Sakai</place></city> development environment on a laptop or desktop. These instructions will also work for setting up a development server though I suggest slightly beefier settings for memory. This is currently tailored for <city w:st="on"><place w:st="on">Sakai</place></city> 2.2.x. Once you have a <city w:st="on">Sakai</city> development environment setup you should be able to program your own <city w:st="on"><place w:st="on">Sakai</place></city> tools or modify existing tools.
<shapetype id="_x0000_t75" stroked="f" filled="f" path="m@4@5l@4@11@9@11@9@5xe" o:preferrelative="t" o:spt="75" coordsize="21600,21600"><stroke joinstyle="miter"></stroke><formulas><f eqn="if lineDrawn pixelLineWidth 0"></f><f eqn="sum @0 1 0"></f><f eqn="sum 0 0 @1"></f><f eqn="prod @2 1 2"></f><f eqn="prod @3 21600 pixelWidth"></f><f eqn="prod @3 21600 pixelHeight"></f><f eqn="sum @0 0 1"></f><f eqn="prod @6 1 2"></f><f eqn="prod @7 21600 pixelWidth"></f><f eqn="sum @8 21600 0"></f><f eqn="prod @7 21600 pixelHeight"></f><f eqn="sum @10 21600 0"></f></formulas><path o:connecttype="rect" gradientshapeok="t" o:extrusionok="f"></path><lock aspectratio="t" v:ext="edit"></lock></shapetype><shape id="_x0000_i1025" style="WIDTH: 12pt; HEIGHT: 12pt" alt="" type="#_x0000_t75"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/emoticons/warning.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image001.gif"></imagedata></shape> |
Notes for windows users
|
<shape id="_x0000_i1026" style="WIDTH: 12pt; HEIGHT: 12pt" alt="" type="#_x0000_t75"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/emoticons/check.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image002.gif"></imagedata></shape> |
All of sakai and related programs should be installed in an opt directory which you will need full write access to, put this directory anywhere you want, this document will assume you have placed it in your root directory |
1. Install/Verify you have Java 1.5
1. To check: Run java -version on the command line
2. If not correct, download the J2SE SDK from:
§ Mac OS X users will have Java 1.5 by default
3. Install it (the SDK) to /opt/java
§ Note: Install the JRE to a different directory (probably the default, especially under windows)
§ or you will have problems
4. Set environment variable: JAVA_HOME=/opt/java
§ Mac users: JAVA_HOME=/Library/Java/Home
§ Windows users default: JAVA_HOME=C:/j2sdk<chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">1.5.0</chsdate>_xx (where "xx" is the minor version - for example "j2sdk1.5.0_11")
5. Add $JAVA_HOME/bin to PATH
6. Set JAVA_OPTS for tomcat in the tomcat/bin/setenv file (see Install Tomcat 5.5)
7. JAVA_OPTS='-server -XX:+UseParallelGC -Xmx<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="768" unitname="m">768m</chmetcnv> -XX:MaxPermSize=<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="128" unitname="m">128m</chmetcnv> -Djava.awt.headless=true'
§ These settings are for developers
§ More info on JVM tuning: Sakai 2.2 developer JVM tuning
2. Install/Verify you have MySQL 4.1
§ Some have reported that MySQL 5.0.x works just fine as well. If you already have this version, there's likely no point in downgrading to 4.1.*.
2. To check: Run mysql --help on the command line
3. If not, download MySQL from:
4. Custom install to /opt/mysql (options vary slightly based on operating system)
§ Linux users should install MySQL using a package or binaries if possible
2. Choose standard configuration
3. Install as a windows service (Windows only)
4. Launch automatically (recommended)
§ If you choose not to do this, make sure that you startup MySQL before you try to run <city w:st="on"><place w:st="on">Sakai</place></city>
5. Include the bin directory in Path
6. Don't use an anonymous account
7. Set your root password to "mysqlpwd1"
3. Setup <city w:st="on"><place w:st="on">Sakai</place></city> DB (schema) and user
0. Create the <city w:st="on">sakai</city> database and <city w:st="on"><place w:st="on">sakai</place></city> user (password=ironchef)
1. Run the following from a command line prompt:
2. mysql -uroot -pmysqlpwd1
§ Note: You can also do the following if you prefer to be prompted for the password: mysql -uroot -p
3. Then run these commands from the mysql prompt (one command per line):
4. create database <city w:st="on"><place w:st="on">sakai</place></city> default character set utf8;
5. grant all privileges on sakai.* to '<city w:st="on"><place w:st="on">sakai</place></city>'@'localhost' identified by 'ironchef';
6. flush privileges;
7. quit
8. [Optional] Download and install mysql query browser
1. You do not have to do anything with query browser now
4. Download and setup Maven 1.0.2 stable package
§ Note - although Maven 2.0 is out and stable, it does not currently work with <city w:st="on"><place w:st="on">Sakai</place></city>.
2. Extract to /opt (should create maven-<chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">1.0.2</chsdate> folder)
3. Set environment variable: MAVEN_HOME=/opt/maven-<chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">1.0.2</chsdate>
4. Add $MAVEN_HOME/bin to PATH/
5. Set the MAVEN_OPTS environment variable
6. MAVEN_OPTS='-Xms<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="256" unitname="m">256m</chmetcnv> -Xmx<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="512" unitname="m">512m</chmetcnv> -XX:PermSize=<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="64" unitname="m">64m</chmetcnv> -XX:MaxPermSize=<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="128" unitname="m">128m</chmetcnv>'
5.Install/Verify you have Subversion
1. To check: Run svn --version on the command line
§ Get the subversion binaries and not the source, if possible
§ If there are no binaries for your platform, get the source and use the configuration
§ options --with-ssl and --with-libs
2. Extract to /opt (should create subversion-<chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">1.2.3</chsdate>)
§ Windows users will want to rename the extracted directory
§ Unix users will probably want to use a package for their flavor
3. Set environment variable: SUBVERSION_HOME=/opt/subversion-<chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">1.2.3</chsdate>
4. Add $SUBVERSION_HOME/bin to PATH
6. Download and setup tomcat 5.5.17+ (stable only)
1. Note: Always do a fresh install of Tomcat
§ Windows users should get the zip file instead of installing a service
It makes viewing the tomcat logs easier and it is easier to configure
3. Extract to /opt (symlink the apache-tomcat-5.5.x directory to tomcat after extracting)
§ Windows users should just rename the directory since they cannot symlink
4. Download the jav<chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">a 1.4.2</chsdate> compat patch (compat.zip)
5. Extract the files to the same location as tomcat itself
6. Modify conf/server.xml for international character support
0. Add URIEncoding="UTF-8" to the Connector element
§ <Connector port="8080" URIEncoding="UTF-8" ...
7. Set environment variable: CATALINA_HOME=/opt/tomcat
8. Add $CATALINA_HOME/bin to PATH
9. Setup the SETENV file in the tomcat/bin directory with JAVA_OPTS (from Install Java 1.5)
0. Mac/Linux: Create a file called setenv.sh with the following:
export JAVA_OPTS="-server -XX:+UseParallelGC -Xmx<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="768" unitname="m">768m</chmetcnv> -XX:MaxPermSize=<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="160" unitname="m">160m</chmetcnv> -Djava.awt.headless=true"
1. Windows(PC): Create a file called setenv.bat with the following:
set JAVA_OPTS=-server -XX:+UseParallelGC -Xmx<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="768" unitname="m">768m</chmetcnv> -XX:MaxPermSize=<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="160" unitname="m">160m</chmetcnv> -Djava.awt.headless=true
7. Download and setup MySQL Connector/J stable
1. Download connector for your version of MySQL
0. If running mySQL 4.1
Download version <chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">3.1.12</chsdate>+ from http://dev.mysql.com/downloads/connector/j/3.1.html<shape id="_x0000_i1044" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>
1. If running MySQL 5.0.x
Download version <chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">5.0.4</chsdate>+ from http://dev.mysql.com/downloads/connector/j/5.0.html<shape id="_x0000_i1045" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>
2. Extract the file to /opt
3. Copy mysql-connector-java-<version>-bin.jar to $CATALINA_HOME/common/lib
4. Delete the extracted folder
8. Use Subversion to download <city w:st="on"><place w:st="on">sakai</place></city> 2.2.x cafe branch
0. Change to the /opt directory
0. If you want a version other than this one, browse the tags at
2. subversion will create a "2-2-x" directory for you,
you can use any directory name you like, just add a name after the checkout location:
svn checkout https://source.sakaiproject.org/svn/cafe/branches/2-2-x/<shape id="_x0000_i1048" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>cafe-2.2.x
2. Checkout will take about 5-10 minutes
3. The directory created by subversion will be referred to as <sakai-src> directory
9. Setup sakai.properties file
0. Create <city w:st="on"><place w:st="on"><strong>sakai</strong></place></city> directory in $CATALINA_HOME
§ $CATALINA_HOME should be /opt/tomcat if you have been following these instructions
§ Note: There were previously two configuration files, sakai.properties and placeholder.properties. These have now been combined into sakai.properties. You can attempt to manually combine the two files from a previous version,
§ but it's better to start with the sample included with the <place w:st="on"><city w:st="on">sakai</city></place> source in the reference directory.
1. Copy sakai.properties from <sakai-src>/reference/docs to $CATALINA_HOME/sakai
§ Note: This file may not be in your checkout if you have acquired
§ one of the older versions of cafe - you can fetch it manually from
§ here https://source.sakaiproject.org/svn/reference/trunk/docs/sakai.properties<shape id="_x0000_i1049" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>.
Make sure you get the sakai.properties for the version of <city w:st="on">Sakai</city> you are using (e.g. <place w:st="on"><city w:st="on">Sakai</city></place> 2.2.x):
http://source.sakaiproject.org/svn/reference/branches/sakai_2-2-x/docs/sakai.properties<shape id="_x0000_i1050" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>
2. Edit the sakai.properties file for a MySQL dev environment.
3. Starting at the section # DATABASE CONFIGURATION:
0. Set BaseDataSource username
1. Set [email protected]=sakai
1. Set BaseDataSource password
0. Set [email protected]=ironchef
2. Find the section: ## HSQLDB settings and comment out 7+ lines in it
3. ## HSQLDB settings - on by default
4. #[email protected]=hsqldb
5. #[email protected]=org.hsqldb.jdbcDriver
6. #hibernate.dialect=org.hibernate.dialect.HSQLDialect
7. #[email protected]=select 1 from SYSTEM_USERS
8. # two hsqldb storage options: first for in-memory (no persistence between runs), second for disk based
9. #[email protected]=jdbc:hsqldb:.
10. #[email protected]=jdbc:hsqldb:${sakai.home}/db/sakai.db
11. Find the section: ## MySQL settings and uncomment the 6+ lines in it
12. ## MySQL settings - make sure to alter as appropriate
13. [email protected]=mysql
14. [email protected]=com.mysql.jdbc.Driver
15. hibernate.dialect=org.hibernate.dialect.MySQLDialect
16. [email protected]=jdbc:mysql://127.0.0.1:3306/sakai?useUnicode=true&characterEncoding=UTF-8
17. [email protected]=select 1 from DUAL
18. [email protected]=TRANSACTION_READ_COMMITTED
§ Note that this line may be incorrect in the default file, it should read as shown:
§ [email protected]=mysql
4. Save the changes to the file
10. Create maven build.properties file
0. Create a new text file in your user home directory
§ Note: This is probably c:/documents and settings/<username> in Windows
1. Add the following lines:
2. maven.repo.remote = http://source.sakaiproject.org/maven/
3. maven.tomcat.home = /opt/tomcat/
§ Note: The trailing slashes are required
§ Note: You must use forward slashes
§ Note: You must have spaces around the "="
§ Note: Do not change / to / if using windows
§ Note: DO add c: to the path if using windows
11. Use Maven to build Sakai
0. Open a command line shell
1. Change directory to /opt/<sakai-src>
2. Execute maven bld to build <city w:st="on"><place w:st="on">Sakai</place></city> using maven
§ Do NOT use maven <place w:st="on"><city w:st="on">sakai</city></place> the first time or your build will take 5-10 times longer!
§ Note: The build will take an extra 5-10 minutes to download dependencies the first time
3. Execute maven dpl to deploy <city w:st="on"><place w:st="on">Sakai</place></city> to your tomcat using maven
4. Add the maven plugin to allow for partial builds in <city w:st="on">Sakai</city>
Run the following command from the <city w:st="on"><place w:st="on">sakai</place></city> source root:
5. maven plugin:download -DartifactId=<city w:st="on">sakai</city> -DgroupId=sakaiproject -Dversion=2.2
You can now do a "maven <place w:st="on"><city w:st="on">sakai</city></place>" from any subdirectory and build just that code
6. For future builds, use maven <place w:st="on"><city w:st="on">sakai</city></place> which does a clean, build, and deploy
(it is basically the same as doing maven cln bld dpl)
12. Start Tomcat and check to make sure <city w:st="on"><place w:st="on">Sakai</place></city> runs
0. Start tomcat using $CATALINA_HOME/bin/startup
1. Allow 1 minute+ for tomcat to start up
3. Open http://localhost:8080/portal<shape id="_x0000_i1052" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>to verify <city w:st="on"><place w:st="on">sakai</place></city> is running
4. Login to <city w:st="on"><place w:st="on">sakai</place></city> as username:admin, password:admin
5. Shutdown Tomcat using $CATALINA_HOME/bin/shutdown
13. Install Eclipse 3.2+ stable
§ Note: If you already have eclipse 3.1.x installed, your best best is to start over with a fresh install rather than attempting to upgrade
§ Note: If you have not installed eclipse already, you should download the WebTools<shape id="_x0000_i1054" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>Platform: All-in-one package for Eclipse 3.2 which includes Eclipse and all of the necessary webtools packages, this is much faster and easier than downloading them seperately, you can skip the WebTools step if you do this, here are instructions to install the Eclipse WebTools
2. Extract the downloaded file to /opt
§ Windows users should extract to c:/
§ Mac users should use the installer and put it in Applications
3. Run eclipse to verify it works (/opt/eclipse/eclipse)
§ Windows users: c:/eclipse/eclipse.exe to run eclipse
§ Note: If it does not work, there is probably a problem with your java install
4. Set the memory settings for Eclipse
§ The default memory settings for Eclipse are much too low to handle the number of webapps in a full <city w:st="on"><place w:st="on">Sakai</place></city> installation
1. Shutdown eclipse if it is running
2. Edit the eclipse.ini file in the directory you extracted/installed eclipse
3. Change the settings from this:
4. -vmargs
5. -Xms<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="40" unitname="m">40m</chmetcnv>
6. -Xmx<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="256" unitname="m">256m</chmetcnv>
to this:
-vmargs
-Xms<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="256" unitname="m">256m</chmetcnv>
-Xmx<chmetcnv w:st="on" tcsc="0" numbertype="1" negative="False" hasspace="False" sourcevalue="768" unitname="m">768m</chmetcnv>
§ Windows users should not use notepad to edit this file, use wordpad or edit (command line)
§ Mac users will need to take additional steps to edit the eclipse.ini file
2. Control-click on the Eclipse Application icon and select Show Package Contents
3. Double-click on the Contents folderD
4. Double-click on the MacOS folder, the eclipse.ini file should be here
5. Full path: eclipse/Eclipse.app/Contents/MacOS/eclipse.ini
5. Set the JVM
§ The default JVM will be the one in the JRE, things will work better if you change this to the one in the J2SE
1. Startup eclipse if it is not running
2. Select Window -> Preferences -> Java -> Installed JREs
3. Select the current installed JRE
4. Click the Edit button
5. Click Browse and navigate to the home directory of your JAVA installation (e.g. /opt/java)
6. Click OK to save and then OK to Finish
§ Running Eclipse with a different JVM from the default
Add -vm /opt/java/bin/java after the eclipse executable
§ You must include the full path to the java executable file
o More Eclipse tips here: ARW:Eclipse notes
14. Add Eclipse Web Tools Project (WTP)
1. Manual installation (faster)
1. Download WTP 1.5+ to your desktop
2. Shutdown Eclipse
3. Extract the package to your Eclipse installation directory
4. Startup Eclipse
2. Install using the Eclipse updater (easier)
0. Start eclipse
1. Select Help -> Software Updates -> Find and Install
2. Select Search for new features to install, click Next
3. Choose the Eclipse.org Update Site and click Finish
4. Select WTP 0.7 (or newer)
§ Note: If it is not listed, use the following update URL:
http://download.eclipse.org/webtools/updates/<shape id="_x0000_i1058" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>
5. Click Select Required
6. Click Next and follow installation instructions
7. Accept terms, click Finish
8. Click Install All
9. Restart the workbench when asked
3. WebTools Platform: All-in-one (fastest)
§ This should only be used if you do not already have Eclipse installed
2. Click on downloads<shape id="_x0000_i1060" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>to the right side of the page
3. Click on the most current 1.5 build version
§ Note: There does not appear to be an all-in-one package for <chsdate w:st="on" isrocdate="False" islunardate="False" day="30" month="12" year="1899">1.5.3</chsdate> so we recommend you choose 1.5.2 instead
4. Locate the All-in-one packages and download the appropriate one for your platform
5. Extract the package to whereever you want to install eclipse (normally your drive root)
6. Startup Eclipse
15. Add subclipse to Eclipse
1. Startup eclipse
2. Select Help -> Software Updates -> Find and Install
3. Select Search for new features to install, click Next
4. Click New Remote Site
5. Enter Subclipse for the name
§ If you are using Eclipse 3.1 or older, you must use http://subclipse.tigris.org/update_1.0.x<shape id="_x0000_i1063" title='"Visit page outside Confluence"' style="WIDTH: 5.25pt; HEIGHT: 5.25pt" alt="" type="#_x0000_t75" o:button="t"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/linkext7.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image003.gif"></imagedata></shape>instead
Note: We highly recommend you upgrade to eclipse 3.2+
7. Click Finish
8. Check the Subclipse box and click Next
9. Accept terms, click Next, click Finish, click Install All
10. Restart the workbench when asked
o Add bin and target to global svn ignore in Eclipse (Optional)
§ This will keep you from committing bin and target directory files when you add projects to svn
1. Click on Window -> Preferences
2. Select Team -> Ignored Resources
3. Click on Add Pattern and enter "bin"
4. Click on Add Pattern and enter "target"
5. Click on Apply and then OK
16. Add SpringIDE to Eclipse
1. Startup Eclipse
2. Select Help -> Software Updates -> Find and Install
3. Select Search for new features to install, click Next
4. Click New Remote Site
5. Enter Spring IDE updatesite for the Name
7. Click OK
8. Check the box marked "Spring IDE updatesite" and click Finish
9. Check the Spring IDE box and click Next
10. Accept terms, click Next, click Finish, click Install All
11. Restart the workbench when asked
17. Import Sakai source code into Eclipse
0. Startup eclipse if it is not running
1. Create a new workspace for <city w:st="on"><place w:st="on">Sakai</place></city>
0. Click on File -> Switch Workspace
1. Enter "WS-Sakai" in place of the default "workspace" directory
2. Click OK (eclipse will restart)
§ The following steps should be done in the WS-Sakai workspace
2. Add Maven Repository libraries to classpath
0. Select Window -> Preferences -> Java -> Build Path -> Classpath Variables
1. Add MAVEN_REPO classpath variable with the path to the local maven repository
§ The path should be: $USER_HOME/.maven/repository
3. Switch to the Java perspective (Window -> Open Perspective -> Java)
§ Make sure you are in the package explorer
4. Turn off Automatic builds
§ Select Project and uncheck Build automatically
5. Select File -> Import -> Existing Projects into Workspace
0. Enter the full path to the <city w:st="on"><place w:st="on">sakai</place></city> source directory for the root directory
§ This should be /opt/cafe-2.2.x if you followed the steps in this document
1. Click Deselect All to unselect all projects
2. Select the following projects (you only need most of the APIs, a few utils, and all of the db projects)
alias-api
announcement-api
archive-api
authz-api
component-api
content-api
courier-api
db-api
db-impl
db-util
entity-api
email-api
event-api
jsf
message-api
master
site-api
site-manage-api
tool-api
user-api
util-api
util-util
velocity
3. Click Finish to import the selected projects
§ This will take awhile, probably 5+ minutes
6. Create a working set for <city w:st="on"><place w:st="on">Sakai</place></city> (optional)
§ You do not have to create a working set, these are here in case you want to
1. Switch to the Java perspective
2. In the Package Explorer pane click the drop-down arrow menu and choose Select Working Set
3. Click the New button from the Select Working Set Dialog window
4. Choose Java for the Working Set Type and click Next
5. Enter <city w:st="on"><place w:st="on"><strong>Sakai</strong></place></city> as the name for your Working Set
6. Select the imported <city w:st="on"><place w:st="on">Sakai</place></city> projects and click Finish
7. Build <city w:st="on"><place w:st="on">Sakai</place></city> in Eclipse
§ Initially you will get build failures on almost every <city w:st="on">Sakai</city> project, this is because they are building in the default order and their dependencies are in a different order, this has been partially addressed in <city w:st="on"><place w:st="on">Sakai</place></city> 2.2
1. Clean all <city w:st="on"><place w:st="on">Sakai</place></city> projects
0. Select Project -> Clean
1. Select Clean all projects
2. Check Start a build immediately
3. Click OK
2. Build All (Project -> Build All)
§ Do this if using working sets:
Build the <city w:st="on">Sakai</city> working set (Select Project -> Build Working Set -> <city w:st="on"><place w:st="on">Sakai</place></city>)
§ Repeat this step until no errors remain (should be no more than 3-4 times)
§ There will be hundreds of warnings, do not worry about these
8. Turn back on Automatic builds
§ Select Project and check Build automatically
Children Hide Children | View in hierarchy
<shape id="_x0000_i1027" style="WIDTH: 12pt; HEIGHT: 12pt" alt="" type="#_x0000_t75"><imagedata o:href="http://bugs.sakaiproject.org/confluence/images/icons/docs_16.gif" src="file:///C:/DOCUME~1/new/LOCALS~1/Temp/msohtml1/01/clip_image004.gif"></imagedata></shape>Install Java 1.4.2 (WG: Programmer's Cafe)