|
|
@@ -44,48 +44,50 @@ are part of the development packages of Cygwin.
|
|
|
If you want to run the unit tests you will also have to download CppUTest via
|
|
|
https://github.com/cpputest/cpputest
|
|
|
|
|
|
-For the development itself we recommend the use of Eclipse with the CDT plugin
|
|
|
-(http://www.eclipse.org).
|
|
|
+For configuring the project we recommend the use of a CMake GUI (e.g., the
|
|
|
+cmake-gui package on Linux, or the Installer for Windows available at [CMake](https://cmake.org/))
|
|
|
|
|
|
-For configuring the project we recommend the use of a CMake GUI (e.g.,the
|
|
|
-cmake-gui oackage on Linux)
|
|
|
-
|
|
|
-Compile for POSIX:
|
|
|
+Compile for Linux/POSIX:
|
|
|
----------------
|
|
|
-1. Directly in the shell:
|
|
|
- 1. Go into the bin/posix directory
|
|
|
- 2. For a standard configuration invoke setup_posix.sh, otherwise start
|
|
|
- cmake (GUI or shell application) and configure your project
|
|
|
- 3. Invoke make
|
|
|
- 4. For invoking opener type:
|
|
|
+1. Make sure all the needed tools are available (CMake, make, gcc, binutils)
|
|
|
+2. Change to the <OpENer main folder>/bin/posix
|
|
|
+3. For a standard configuration invoke ``setup_posix.sh``
|
|
|
+ 1. Invoke the ``make`` command
|
|
|
+ 2. Grant OpENer the right to use raw sockets via ``sudo setcap cap_net_raw+ep ./src/ports/POSIX/OpENer``
|
|
|
+ 3. Invoking OpENer:
|
|
|
|
|
|
- ./src/ports/POSIX/OpENer interface
|
|
|
+ ``./src/ports/POSIX/OpENer <interface_name>``
|
|
|
|
|
|
- e.g. ./src/ports/POSIX/OpENer eth1
|
|
|
-
|
|
|
-2. Within Eclipse
|
|
|
- 1. For a standard configuration invoke setup_posix.sh, otherwise start
|
|
|
- cmake (GUI or shell application) and configure your project
|
|
|
- 2. Import the project
|
|
|
- 3. Go to the bin/win32 folder in the make targets view
|
|
|
- 4. Choose all from the make targets
|
|
|
- 5. The resulting executable will be in the directory /bin/posix or the
|
|
|
-directoy you have choosen via CMake
|
|
|
-
|
|
|
-Compile for Windows XP/7/8:
|
|
|
----------------------------
|
|
|
+ e.g. ``./src/ports/POSIX/OpENer eth1``
|
|
|
+
|
|
|
+OpENer also now has a real-time capable POSIX startup via the OpENer_RT option, which requires that the used kernel has the full preemptive RT patches applied and activated.
|
|
|
+If you want to use OpENer_RT, instead of step 2, the ``sudo setcap cap_net_raw,cap_ipc_lock,cap_sys_nice+ep ./src/ports/POSIX/OpENer
|
|
|
+`` has to be run to grant OpENEr ``CAP_SYS_NICE``, ``CAP_IPC_LOCK``, and the ``CAP_NET_RAW`` capabilities, needed for the RT mode
|
|
|
+
|
|
|
+Compile for Windows XP/7/8 via Visual Studio:
|
|
|
+---------------------------------------------
|
|
|
1. Invoke setup_windows.bat or configure via CMake
|
|
|
-2. Open Visual Studio solution in bin/win32
|
|
|
-3. For invoking opener type in command line:
|
|
|
+2. Open Visual Studio solution OpENer.sln in bin/win32
|
|
|
+3. Compile OpENer by chosing ``Build All`` in Visual Studio
|
|
|
+4. For invoking OpENer type from the command line:
|
|
|
+ 1. Change to <OpENer main folder>\bin\win32\src\ports\WIN32\
|
|
|
+ 2. Depending if you chose the ``Debug`` or ``Release`` configuration in Visual Studio, your executable will either show up in the subfolder Debug or Release
|
|
|
+ 3. Invoke OpENer via
|
|
|
+
|
|
|
+ ``OpENer <interface_index>``
|
|
|
|
|
|
- OpENer interface_index
|
|
|
+ e.g. ``OpENer 3``
|
|
|
|
|
|
- e.g. OpENer 3
|
|
|
+In order to get the correct interface index enter the command ``route print`` in a command promt and search for the MAC address of your chosen network interface at the beginning of the output. The leftmost number is the corresponding interface index.
|
|
|
|
|
|
+Compile for Windows XP/7/8 via Cygwin:
|
|
|
+--------------------------------------
|
|
|
+This should work like the procedure for Linux, with the exception, that RT mode will not work for Cygwin.
|
|
|
+
|
|
|
Compile for MinGW on Windows 10
|
|
|
-------------------------------
|
|
|
1. Make sure 64 bit mingw is installed. (Test with gcc --version, should show x86_64-posix-seh-rev1)
|
|
|
-2. Make sure Cmake is installed. (Test with cmake --version, should be version 3.xx)
|
|
|
+2. Make sure CMake is installed. (Test with cmake --version, should be version 3.xx)
|
|
|
3. Change to <opener install dir>/bin/mingw
|
|
|
4. Run the command `setup_mingw.bat` in a dos command line. (Not a bash shell). If tracing is desired,
|
|
|
use the following (where the cmake parameter must be enclosed in quotes) or change the ./source/CMakeList.txt file.
|