File: 0004-move-rp-to-lib-rtags.patch

package info (click to toggle)
rtags 2.41-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,768 kB
  • sloc: cpp: 51,883; lisp: 5,389; ansic: 1,637; sh: 563; python: 305; objc: 81; makefile: 29
file content (39 lines) | stat: -rw-r--r-- 1,517 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
From: Denis Danilov <danilovdenis@yandex.ru>
Date: Thu, 8 Nov 2018 23:10:43 +0100
Subject: move rp to lib/rtags

Forwarded: not-needed
---
 src/CMakeLists.txt | 3 ++-
 src/rdm.cpp        | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 0beeb3f..633c2d6 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -333,7 +333,8 @@ if (BASH_COMPLETION_FOUND)
     install(FILES "${PROJECT_BINARY_DIR}/completions/rc" "${PROJECT_BINARY_DIR}/completions/rdm"
         DESTINATION ${BASH_COMPLETION_COMPLETIONSDIR})
 endif ()
-install(TARGETS rdm rc rp RUNTIME DESTINATION bin COMPONENT rtags)
+install(TARGETS rdm rc RUNTIME DESTINATION bin COMPONENT rtags)
+install(TARGETS rp RUNTIME DESTINATION lib/rtags COMPONENT rtags)
 install(FILES ../bin/gcc-rtags-wrapper.sh DESTINATION bin
     PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
 install(FILES ../man/man7/rc.7 ../man/man7/rdm.7 DESTINATION share/man/man7/)
diff --git a/src/rdm.cpp b/src/rdm.cpp
index 8eb46ef..2fa656d 100644
--- a/src/rdm.cpp
+++ b/src/rdm.cpp
@@ -120,8 +120,8 @@ static inline Path defaultRP()
             rp = Rct::executablePath();
             rp.resolve();
             rp = rp.parentDir() + "rp";
-            if (!rp.isFile()) // should be in $PATH
-                rp = "rp";
+            if (!rp.isFile()) // should be under lib/rtags
+                rp = "/usr/lib/rtags/rp";
         }
     }
     return rp;