Excerpt | ||
---|---|---|
| ||
Describes how to download and install the Trafodion source using git, tar files, and zip files. |
You can obtain the Trafodion source code using one of these methods:
Anchor | ||||
---|---|---|---|---|
|
Git Fork
If you intend to make changes to the Trafodion source tree, then install the source tree from GitHub.
Install Git Tools
If you haven’t done so already, install the Git Tools:
- Download the appropriate tool version; Linux or Windows: http://git-scm.com/downloads.
- Set up your git environment: GitHub Documentation
- Ensure that you register your ssh keys.
Download Trafodion Source Tree
You download the Trafodion source tree once the git tools have been installed.
Fork Trafodion Repository
You create a private fork of Trafodion on https://github.com/apache/incubator-trafodion. Use the fork button top-right on the page to create your fork, which will be named <your-git-id>_fork
.
The following examples use trafdeveloper
to represent <your-git-id>
.
Clone Trafodion Repository
Use the git shell to perform this task.
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
# Move to the directory where you want to install the Trafodion source code.
cd mysource
# Clone the Trafodion source code
git clone git://git.apache.org/incubator-trafodion.git
# Register your fork as a remote branch
git remote add trafdeveloper_fork git@github.com:trafdeveloper/incubator-trafodion |
Create Task Branch
You create a task branch to make changes to the Trafodion source tree. Typically, we name the branches after the Jira we are working on. In this example, the Jira is: TRAFODION-1507.
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
# Ensure that you have the latest changes
git fetch --all
# Checkout source
git checkout -b TRAFODION-1507 origin/master |
tar/zip Download
Typically, you download the Trafodion source tree as a tar/zip file if you don’t intend the change the source code. For example, when you want to build the Trafodion binaries only.
tar file
Download Location: https://dist.apache.org/repos/dist/release/incubator/trafodion
Open the
trafodion
folder.Info title PGP Key The source tar file has been signed with pgp key A44C5A05, which is included in the download location’s KEYS folder.
Open the folder containing the version you want to download. For example: apache-trafodion-1.3.0-incubating
Download the
-src
file that fits your security needs. For example:apache-trafodion-1.3.0-incubating-src.tar.gz
Unpack the tar file:
Code Block language bash theme Emacs collapse true mkdir <target-directory> tar -xzf <tar file> -C <target-directory> # Change direcotry name to match GitHub download name; makes this guide simpler to write. mv <target-directory>/apache-trafodion-<version>-incubating <target-directory>/incubator-trafodion
Example
Code Block language bash theme Emacs collapse true $ mkdir ~/mysource $ tar -xzf apache-trafodion-1.3.0-incubating-src.tar.gz -C ~/mysource $ ls mysource apache-trafodion-1.3.0-incubating $ ls mysource/apache-trafodion-1.3.0-incubating core DISCLAIMER.txt env.sh licenses Makefile pom.xml README.txt win-odbc64 dcs docs install LICENSE.txt NOTICE.txt RAT_README.txt tests wms $ # Change directory name to match GitHub download name; makes this guide simpler to write. $ mv mysource/apache-trafodion-1.3.0-incubating mysource/incubator-trafodion $ ls mysource incubator-trafodion
zip File