You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/sci-mathematics/rstudio/files/rstudio-1.3.959-paths.patch

119 lines
6.0 KiB

--- rstudio-1.3.959-orig/CMakeGlobals.txt 2020-05-19 04:11:10.000000000 +1000
+++ rstudio-1.3.959/CMakeGlobals.txt 2020-05-25 19:30:10.711859714 +1000
@@ -181,7 +181,7 @@
else()
set(RSTUDIO_INSTALL_BIN bin)
endif()
- set(RSTUDIO_INSTALL_SUPPORTING .)
+ set(RSTUDIO_INSTALL_SUPPORTING ${DISTRO_SHARE})
endif()
# if the install prefix is /usr/local then tweak as appropriate
--- rstudio-1.3.959-orig/src/cpp/server/CMakeLists.txt 2020-05-19 04:11:10.000000000 +1000
+++ rstudio-1.3.959/src/cpp/server/CMakeLists.txt 2020-05-25 19:30:10.711859714 +1000
@@ -190,7 +190,7 @@
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${RSERVER_INITD_DEBIAN_SCRIPT}.in
${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_INITD_DEBIAN_SCRIPT})
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_INITD_DEBIAN_SCRIPT}
- DESTINATION ${RSERVER_INITD_DEBIAN_DIR})
+ DESTINATION ${DISTRO_SHARE}/${RSERVER_INITD_DEBIAN_DIR})
# install configured redhat init.d script
set(RSERVER_INITD_REDHAT_DIR "extras/init.d/redhat")
@@ -198,7 +198,7 @@
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${RSERVER_INITD_REDHAT_SCRIPT}.in
${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_INITD_REDHAT_SCRIPT})
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_INITD_REDHAT_SCRIPT}
- DESTINATION ${RSERVER_INITD_REDHAT_DIR})
+ DESTINATION ${DISTRO_SHARE}/${RSERVER_INITD_REDHAT_DIR})
# install configured suse init.d script
set(RSERVER_INITD_SUSE_DIR "extras/init.d/suse")
@@ -206,13 +206,13 @@
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${RSERVER_INITD_SUSE_SCRIPT}.in
${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_INITD_SUSE_SCRIPT})
install(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_INITD_SUSE_SCRIPT}
- DESTINATION ${RSERVER_INITD_SUSE_DIR})
+ DESTINATION ${DISTRO_SHARE}/${RSERVER_INITD_SUSE_DIR})
# install pam profile
set(RSERVER_PAM_DIR "extras/pam")
set(RSERVER_PAM_PROFILE "${RSERVER_PAM_DIR}/rstudio")
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/${RSERVER_PAM_PROFILE}
- DESTINATION ${RSERVER_PAM_DIR})
+ DESTINATION ${DISTRO_SHARE}/${RSERVER_PAM_DIR})
# install configured upstart profile
set(RSERVER_UPSTART_DIR "extras/upstart")
@@ -220,12 +220,12 @@
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${RSERVER_UPSTART_PROFILE}.in
${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_UPSTART_PROFILE})
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_UPSTART_PROFILE}
- DESTINATION ${RSERVER_UPSTART_DIR})
+ DESTINATION ${DISTRO_SHARE}/${RSERVER_UPSTART_DIR})
set(RSERVER_UPSTART_PROFILE_REDHAT "${RSERVER_UPSTART_DIR}/rstudio-server.redhat.conf")
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${RSERVER_UPSTART_PROFILE_REDHAT}.in
${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_UPSTART_PROFILE_REDHAT})
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${RSERVER_UPSTART_PROFILE_REDHAT}
- DESTINATION ${RSERVER_UPSTART_DIR})
+ DESTINATION ${DISTRO_SHARE}/${RSERVER_UPSTART_DIR})
# install configured systemd profile
set(RSERVER_SYSTEMD_DIR "extras/systemd")
--- rstudio-1.3.959-orig/src/cpp/server/ServerOptions.cpp 2020-05-19 04:11:10.000000000 +1000
+++ rstudio-1.3.959/src/cpp/server/ServerOptions.cpp 2020-05-25 19:34:19.377675880 +1000
@@ -442,8 +442,8 @@
// convert relative paths by completing from the system installation
// path (this allows us to be relocatable)
- resolvePath(resourcePath, &wwwLocalPath_);
- resolvePath(resourcePath, &wwwSymbolMapsPath_);
+ resolvePath(resourcePath.completeChildPath(DISTRO_SHARE), &wwwLocalPath_);
+ resolvePath(resourcePath.completeChildPath(DISTRO_SHARE), &wwwSymbolMapsPath_);
resolvePath(binaryPath, &authPamHelperPath_);
resolvePath(binaryPath, &rsessionPath_);
resolvePath(binaryPath, &rldpathPath_);
--- rstudio-1.3.959-orig/src/cpp/session/SessionOptions.cpp 2020-05-19 04:11:10.000000000 +1000
+++ rstudio-1.3.959/src/cpp/session/SessionOptions.cpp 2020-05-25 19:33:58.318606745 +1000
@@ -52,7 +52,7 @@
namespace session {
namespace {
-const char* const kDefaultPandocPath = "bin/pandoc";
+const char* const kDefaultPandocPath = "bin";
const char* const kDefaultPostbackPath = "bin/postback/rpostback";
const char* const kDefaultRsclangPath = "bin/rsclang";
@@ -586,14 +586,14 @@
}
// convert relative paths by completing from the app resource path
- resolvePath(resourcePath_, &rResourcesPath_);
- resolvePath(resourcePath_, &agreementFilePath_);
- resolvePath(resourcePath_, &wwwLocalPath_);
- resolvePath(resourcePath_, &wwwSymbolMapsPath_);
- resolvePath(resourcePath_, &coreRSourcePath_);
- resolvePath(resourcePath_, &modulesRSourcePath_);
- resolvePath(resourcePath_, &sessionLibraryPath_);
- resolvePath(resourcePath_, &sessionPackageArchivesPath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &rResourcesPath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &agreementFilePath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &wwwLocalPath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &wwwSymbolMapsPath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &coreRSourcePath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &modulesRSourcePath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &sessionLibraryPath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &sessionPackageArchivesPath_);
resolvePostbackPath(resourcePath_, &rpostbackPath_);
#ifdef _WIN32
resolvePath(resourcePath_, &consoleIoPath_);
@@ -626,7 +626,7 @@
}
winptyPath_ = pty.completePath(completion).getAbsolutePath();
#endif // _WIN32
- resolvePath(resourcePath_, &hunspellDictionariesPath_);
+ resolvePath(resourcePath_.completeChildPath(DISTRO_SHARE), &hunspellDictionariesPath_);
resolvePath(resourcePath_, &mathjaxPath_);
resolvePath(resourcePath_, &libclangHeadersPath_);
resolvePandocPath(resourcePath_, &pandocPath_);