FlexSEA Wiki


User Tools

Site Tools



This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
build_fx_plan [2019/02/14 15:43]
build_fx_plan [2019/05/06 19:34] (current)
kandoni Add step to change dir into plan GUI repo
Line 2: Line 2:
-=====Tools required===== +===== Requirements ​===== 
-Before you startinstall ​the following tools:+  * Git (version >= 1.47we recommend using the latest stable version available on your platform) 
 +  * Bash (Git bash works on Windows , just make sure it is the default to run .sh files) 
 +  * CMake (version >= 3.13, can be either 32 or 64 bit version based on your system'​s [[https://​support.microsoft.com/​en-us/​help/​827218/​how-to-determine-whether-a-computer-is-running-a-32-bit-version-or-64|architecture]] ) 
 +    * Get the latest version of[[https://​cmake.org/​download/​ | CMake]] and add it to your path. 
 +  * Ninja (version >= 1.3, can be either 32 or 64 bit version based on your system'​s [[https://​support.microsoft.com/​en-us/​help/​827218/​how-to-determine-whether-a-computer-is-running-a-32-bit-version-or-64|architecture]])  
 +    * We use version 1.90, which can be found at [[https://​github.com/​ninja-build/​ninja/​releases]] 
 +  * GCC 7.3
-  * CMake 
-  * git 
-  * g++ (should come pre-installed) 
-  * Python 3 (32 / 64 bit should match your g++ version. default is 32 bit) 
-__Windows:​__ +===== Setup =====
-  * CMake (Note: Do not use Cygwin'​s CMake) +
-  * git +
-  * MinGW_w64 (install the 32 bit version) +
-  * Python 3 (32 bit version)+
-Here are detailed instructions on how to [[installbuildtoolswindows|install the build tools on Windows]].+  - Start by installing[[https://​cmake.org/​download/​ | CMake]] 
 +    * Note the install path, you will need to add it to the PATH later. 
 +  - Next install GCC. Get a mingw64 installer from [[https://​sourceforge.net/​projects/​mingw-w64/ ​|source forge]]. 
 +    * Use the following setting when installing mingw64 {{gcc7_3_install.png}}. 
 +    * Note the installation path and navigate to it. Go into the mingw32 folder and then the bin folder. Note this path, you will need to add it to the PATH later. That path should look like this: C:\Program Files (x86)\mingw-w64\i686-7.3.0-posix-dwarf-rt_v5-rev2\mingw32\bin 
 +  - Next install ​ninja 
 +    - Get the latest [[https://​github.com/​ninja-build/​ninja/​releases | release]] (We use 1.90) and download it 
 +    - Unzip the file 
 +    - Place it the folder containing the ninja executable to your program files directory on Windows or your /usr/bin/ directory on Linux {{2019-04-03_14_05_00-c__program_files_ninja-win.png}} 
 +    - Add it to your path, this allows you to access any executables (such as Ninja, CMake and GCC) from the command line 
 +      - On Windows this is done using the advanced setting in the environment variables {{path.png}} 
 +      -  Navigate to advanced settings and select environment variables {{system_properties.png}}  
 +      -  Select the PATH variable in system variables {{env_variables.png}} 
 +      -  Then add the paths from the previous installs {{add_path.png}}
 =====How to build the libraries===== =====How to build the libraries=====
-These instructions are for compiling the libraries for your system. To cross compile, read the section [[build_fx_plan#​How to cross-compile the libraries|below]].  +  ​From your gitBash console 
- +  - Start from a fresh version of Plan GUI <​code>​ git clone --recursive ​https://​github.com/​DephyInc/​plan_3_0.git </​code>​ 
-First, navigate to an empty directory where you will clone the git. +  Change directory to the cloned Plan GUI repo <​code>​ cd plan_3_0</code> 
- +  ​Make sure all your submodules are up to date <​code> ​git submodule update --init ​--recursive ​</code> 
-**Clone the code repositories:​** +  - Change directory into fx_plan_stack and run stackBuilder.sh <​code>​ cd fx_plan_stack && ./stack_builder.sh && cd ..</code> 
-<​code>​ +  ​A successful build will print a message similar to <​code>​[83/​84] Linking CXX static library libs\libfx_plan_stack_static.
-git clone https://​github.com/​DephyInc/​serial.git +[84/84] Linking CXX shared library libs\libfx_plan_stack.dll
-git clone --recursive https://github.com/​DephyInc/​FlexSEA-Stack-SharedLib.git +
-git clone --recursive ​https://github.com/DephyInc/​Actuator-Package.git+
 </​code>​ </​code>​
-**Compile the serial library:** 
-cd serial 
-git checkout dev 
-mkdir build && cd build 
-cmake .. #See note 1) 
-make #See note 2) 
-**Compile FlexSEA-Stack-SharedLib (see note 3):** 
-cd ../​../​FlexSEA-Stack-SharedLib 
-mkdir build && cd build 
-cmake .. 
-The libraries are built in either a '​win'​ directory on windows or a '​unix'​ directory on unix. Copy the libraries from the build directory to the folder where they'​ll be used. You can do that graphically,​ or via command line. The libserialc.a and libFlexSEA-Stack-Plan.a libraries must be in the fx_plan_stack\lib folder. 
-cp serial/​build/​unix/​libserialc.a Actuator-Package/​fx_plan_stack/​lib/​ 
-cp FlexSEA-Stack-SharedLib/​Release_static/​libFlexSEA-Stack-Plan.a Actuator-Package/​fx_plan_stack/​lib/​ 
-**Compile fx_plan_stack:​** 
-cd Actuator-Package/​fx_plan_stack 
-mkdir build && cd build 
-cmake .. 
-**Test the library:**+====Test the library:====
   - First, make sure that Actuator-Package\Python\flexseapython\com.txt has the right COM port.   - First, make sure that Actuator-Package\Python\flexseapython\com.txt has the right COM port.
   - Navigate to the Actuator-Package\Python folder.   - Navigate to the Actuator-Package\Python folder.
build_fx_plan.1550158993.txt.gz · Last modified: 2019/02/14 15:43 by flabelle