wiki:Getting started

Version 2 (modified by foehst, 7 years ago) (diff)

--

Getting started

Installation

Currently, the only supported way to install Finroc® ist from source.

If you use Ubuntu, feel free to use our finroc-dependencies-package to install the needed tools and libraries now. If you want to use Finroc® with a different Linux distribution, remember that you need to at least have to install mercurial, gcc >= 4.6, ...

Setup mercurial

The main source control management system used on finroc.org is mercurial. You can skip this step if you want to just have a quick look on Finroc®. However, if you are going to checkout more components, create or change code and want to commit you changes, it is recommended to first create some configuration for mercurial.

If is does not already exist, create the file ~/.hgrc:

[ui]
username = Your Name <your@email.address>
merge = kdiff3

[merge-tools]
kdiff3.args = $base $local $other -o $output
kdiff3.premerge = true

[auth]
finroc_org.prefix = https://finroc.org/hg
finroc_org.username = anonymous
finroc_org.password = your@email.address

[hostfingerprints]
rrlib.org = 69:59:b1:33:a3:4a:bb:ad:f7:95:cb:a5:f4:a9:43:ee:9f:a7:58:32
finroc.org = 69:59:b1:33:a3:4a:bb:ad:f7:95:cb:a5:f4:a9:43:ee:9f:a7:58:32

Configuring the merge tool is our recommendation and optional. The hostfingerprints are currently needed until the server gets a properly assured SSL certificate. If you already created an account on finroc.org, of course replace the anonymous credentials by your own. As the file now contains you credentials, make it non-readable for others:

~$ chmod go= ~/.hgrc

Clone the Finroc® environment

Getting the source code of components, configuring, building and execution is all conveniently done from within the Finroc® environment. Therefore, clone it using mercurial.

~$ hg clone https://finroc.org/hg/finroc

If you skipped the step Setup mercurial, you might be asked about your username and password. Just use anonymous together with a valid email address as password.

Setup environment

Each time you want to use Finroc®, some paths and other environment variables must be set.

~$ cd finroc
~/finroc$ source scripts/setenv
----------------------------------
 FINROC Settings
----------------------------------
 Home:          /home/$USER/finroc
 Project:       <unknown>
 Project Home:  <unknown>
 Language:      <unknown>
 Target:        i686_linux_debug
----------------------------------

Get the core and main tools

In Finroc®, the source code of the single components (core, libraries, plugins, tools, projects) can be easily cloned/checked out using finroc_get. Use it to install the first three components and their dependencies:

~/finroc$ finroc_get finroc_core finroc_tools_finstruct-java finroc_tools_gui-java

Questions for optional components can be answer with no for now.

Compiling

To check if all dependencies are satisfied and all targets can be build run makeSafeMakefile.

~/finroc$ makeSafeMakefile

This step is mainly for diagnositics and included in the main build command makeSafe. Use it to build the core and main tools:

~/finroc$ makeSafe -j4

This starts parallel building with 4 threads. If you have more cpu cores and enough RAM, feel free to increase the number of build threads.

Next steps