diff --git a/recipes-extended/librealsense/librealsense/0001-Fix-detection-of-ROS-build.patch b/recipes-extended/librealsense/librealsense/0001-Fix-detection-of-ROS-build.patch
deleted file mode 100644
index d283441e35c4cc79f16df0bc686489f844185a18..0000000000000000000000000000000000000000
--- a/recipes-extended/librealsense/librealsense/0001-Fix-detection-of-ROS-build.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From e036c870bca711ef419f6942df125b20d988353c Mon Sep 17 00:00:00 2001
-From: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com>
-Date: Fri, 9 Dec 2016 16:10:21 +0200
-Subject: [PATCH] Fix detection of ROS build
-
-CMAKE_PREFIX_PATH is not an environment variable, but CMake's
-internal one that contains a list of items (strings). This
-list needs to be concattenated into a single string in order
-to become "match"-able against a regex.
-
-Upstream-Status: Submitted [https://github.com/IntelRealSense/librealsense/pull/387]
-
-Signed-off-by: Dmitry Rozhkov <dmitry.rozhkov@linux.intel.com>
----
- CMakeLists.txt | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 8772f10..44295ee 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -3,8 +3,8 @@
- # ubuntu 16.04 LTS cmake version 3.5.1
- cmake_minimum_required(VERSION 2.8.3)
- 
--IF(DEFINED ENV{CMAKE_PREFIX_PATH})
--  IF($ENV{CMAKE_PREFIX_PATH} MATCHES "/opt/ros")
-+IF(DEFINED CMAKE_PREFIX_PATH)
-+  IF("${CMAKE_PREFIX_PATH}" MATCHES "/opt/ros")
-     set(ROS_BUILD_TYPE TRUE)
-   ENDIF()
- ENDIF()
--- 
-2.7.4
-
diff --git a/recipes-extended/librealsense/librealsense_1.11.2.bb b/recipes-extended/librealsense/librealsense_1.11.2.bb
index 6e7935a9350386b0f4a931ee414f408c5ce8f84b..960739e4db350c0d4cc1427eb99feef773105e9d 100644
--- a/recipes-extended/librealsense/librealsense_1.11.2.bb
+++ b/recipes-extended/librealsense/librealsense_1.11.2.bb
@@ -2,11 +2,13 @@ DESCRIPTION = "Cross-platform camera capture for Intel® RealSense™ F200, SR30
 LICENSE = "Apache-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57"
 
-SRC_URI = "https://github.com/IntelRealSense/librealsense/archive/v${PV}.tar.gz \
-           file://0001-Fix-detection-of-ROS-build.patch \
-           "
+SRC_URI = "https://github.com/IntelRealSense/librealsense/archive/v${PV}.tar.gz"
 SRC_URI[md5sum] = "27ce627c02731623c23894baeb73b2b1"
 
+EXTRA_OECMAKE_prepend = "\
+    -DROS_BUILD_TYPE=TRUE \
+    "
+
 DEPENDS = "libusb1"
 
 inherit catkin