Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update installation readme for libudev + add ROS dependency #9849

Merged
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 18 additions & 15 deletions doc/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ The scripts and commands below invoke `wget, git, add-apt-repository` which may
Unplug any connected Intel RealSense camera.<br />

2. Install the core packages required to build *librealsense* binaries and the affected kernel modules:
`sudo apt-get install git libssl-dev libusb-1.0-0-dev pkg-config libgtk-3-dev` <br /><br />

`sudo apt-get install git libssl-dev libusb-1.0-0-dev libudev-dev pkg-config libgtk-3-dev` <br /><br />
Distribution-specific packages: <br />
* Ubuntu 14 or when running Ubuntu 16.04 live-disk:<br />
`./scripts/install_glfw3.sh` <br />
Expand All @@ -51,8 +52,11 @@ The scripts and commands below invoke `wget, git, add-apt-repository` which may
> **Cmake Note**: certain librealsense CMAKE flags (e.g. CUDA) require version 3.8+ which is currently not made available via apt manager for Ubuntu LTS.
Go to the [official CMake site](https://cmake.org/download/) to download and install the application

**Note** on graphic sub-system utilization:<br />
*glfw3*, *mesa* and *gtk* packages are required if you plan to build the SDK's OpenGL-enabled examples. The *librealsense* core library and a range of demos/tools are designed for headless environment deployment.
**Note**:

* on graphic sub-system utilization:<br />
*glfw3*, *mesa* and *gtk* packages are required if you plan to build the SDK's OpenGL-enabled examples. The *librealsense* core library and a range of demos/tools are designed for headless environment deployment.
* `libudev-dev` installation is optional but recommended, when the `libudev-dev` is installed the SDK will use an event driven approach for triggering USB detection and enumeration, if not the SDK will use a timer polling approach which is less sensitive for device detection.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

event-driven ...
if not - ...

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done


3. Run Intel Realsense permissions script from librealsense root directory:<br />
`./scripts/setup_udev_rules.sh`
Expand All @@ -61,15 +65,14 @@ The scripts and commands below invoke `wget, git, add-apt-repository` which may
*`./scripts/setup_udev_rules.sh --uninstall`*

4. Build and apply patched kernel modules for: <br />
* **Ubuntu 14/16/18 with LTS kernel**

* **Ubuntu 14/16/18 with LTS kernel**
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add 20

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

`./scripts/patch-realsense-ubuntu-lts.sh`<br />
* **Ubuntu with Kernel 4.16**

`./scripts/patch-ubuntu-kernel-4.16.sh`<br />
* **Intel® Joule™ with Ubuntu**
Based on the custom kernel provided by Canonical Ltd.

`./scripts/patch-realsense-ubuntu-xenial-joule.sh`<br />

The script above will download, patch and build realsense-affected kernel modules (drivers).<br />
Expand Down Expand Up @@ -122,15 +125,15 @@ The scripts and commands below invoke `wget, git, add-apt-repository` which may
* `cmake ../ -DBUILD_EXAMPLES=true -DBUILD_GRAPHICAL_EXAMPLES=false` - For systems without OpenGL or X11 build only textual examples<br /><br />

* Recompile and install *librealsense* binaries:<br />
`sudo make uninstall && make clean && make && sudo make install`<br />
The shared object will be installed in `/usr/local/lib`, header files in `/usr/local/include`.<br />
The binary demos, tutorials and test files will be copied into `/usr/local/bin`<br />
**Tip:** Use *`make -jX`* for parallel compilation, where *`X`* stands for the number of CPU cores available:<br />
`sudo make uninstall && make clean && make **-j8** && sudo make install`<br />
This enhancement may significantly improve the build time. The side-effect, however, is that it may cause a low-end platform to hang randomly.<br />
**Note:** Linux build configuration is presently configured to use the V4L2 backend by default.<br />
**Note:** If you encounter the following error during compilation `gcc: internal compiler error` it might indicate that you do not have enough memory or swap space on your machine. Try closing memory consuming applications, and if you are running inside a VM, increase available RAM to at least 2 GB.<br />
**Note:** You can find more information about the available configuration options on [this wiki page](https://github.com/IntelRealSense/librealsense/wiki/Build-Configuration).
`sudo make uninstall && make clean && make && sudo make install`<br />
The shared object will be installed in `/usr/local/lib`, header files in `/usr/local/include`.<br />
The binary demos, tutorials and test files will be copied into `/usr/local/bin`<br />
**Tip:** Use *`make -jX`* for parallel compilation, where *`X`* stands for the number of CPU cores available:<br />
`sudo make uninstall && make clean && make **-j8** && sudo make install`<br />
This enhancement may significantly improve the build time. The side-effect, however, is that it may cause a low-end platform to hang randomly.<br />
**Note:** Linux build configuration is presently configured to use the V4L2 backend by default.<br />
**Note:** If you encounter the following error during compilation `gcc: internal compiler error` it might indicate that you do not have enough memory or swap space on your machine. Try closing memory consuming applications, and if you are running inside a VM, increase available RAM to at least 2 GB.<br />
**Note:** You can find more information about the available configuration options on [this wiki page](https://github.com/IntelRealSense/librealsense/wiki/Build-Configuration).

2. Install IDE (Optional):
We use QtCreator as an IDE for Linux development on Ubuntu. Follow the [link](https://wiki.qt.io/Install_Qt_5_on_Ubuntu) for QtCreator5 installation
Expand Down
1 change: 1 addition & 0 deletions package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

<build_depend>libusb-1.0-dev</build_depend>
<build_depend>libssl-dev</build_depend>
<build_depend>libudev-dev</build_depend>
<build_depend>dkms</build_depend>
<build_depend>udev</build_depend>

Expand Down