mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-10-03 13:30:36 +00:00
Fix not FHS paths
Create explicit nix path replacement of hard coded FHS paths for pandoc and nodejs.
This commit is contained in:
@@ -128,6 +128,7 @@ in
|
||||
./clang-location.patch
|
||||
./use-system-node.patch
|
||||
./fix-resources-path.patch
|
||||
./pandoc-nix-path.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
@@ -137,14 +138,14 @@ in
|
||||
--replace 'SOCI_LIBRARY_DIR "/usr/lib"' 'SOCI_LIBRARY_DIR "${soci}/lib"'
|
||||
|
||||
substituteInPlace src/gwt/build.xml \
|
||||
--replace '/usr/bin/node' '${nodejs}/bin/node'
|
||||
--replace '@node@' ${nodejs}
|
||||
|
||||
substituteInPlace src/cpp/core/libclang/LibClang.cpp \
|
||||
--replace '@libclang@' ${llvmPackages.libclang.lib} \
|
||||
--replace '@libclang.so@' ${llvmPackages.libclang.lib}/lib/libclang.so
|
||||
|
||||
substituteInPlace src/cpp/session/include/session/SessionConstants.hpp \
|
||||
--replace "bin/pandoc" "${pandoc}/bin/pandoc"
|
||||
--replace '@pandoc@' ${pandoc}/bin/pandoc
|
||||
'';
|
||||
|
||||
hunspellDictionaries = with lib; filter isDerivation (unique (attrValues hunspellDicts));
|
||||
|
||||
11
pkgs/applications/editors/rstudio/pandoc-nix-path.patch
Normal file
11
pkgs/applications/editors/rstudio/pandoc-nix-path.patch
Normal file
@@ -0,0 +1,11 @@
|
||||
--- a/src/cpp/session/include/session/SessionConstants.hpp
|
||||
+++ b/src/cpp/session/include/session/SessionConstants.hpp
|
||||
@@ -140,7 +140,7 @@
|
||||
#ifdef QUARTO_ENABLED
|
||||
# define kDefaultPandocPath "bin/quarto/bin"
|
||||
#else
|
||||
-# define kDefaultPandocPath "bin/pandoc"
|
||||
+# define kDefaultPandocPath "@pandoc@"
|
||||
#endif
|
||||
|
||||
#define kDefaultQuartoPath "bin/quarto"
|
||||
@@ -21,7 +21,7 @@
|
||||
- property="node.bin"
|
||||
- value="/opt/rstudio-tools/dependencies/common/node/${node.version}/bin/node"
|
||||
- file="/opt/rstudio-tools/dependencies/common/node/${node.version}/bin/node"/>
|
||||
+ <property name="node.bin" value="/usr/bin/node"/>
|
||||
+ <property name="node.bin" value="@node@/bin/node"/>
|
||||
|
||||
<property name="panmirror.dir" value="./panmirror/src/editor"/>
|
||||
<property name="panmirror.build.dir" value="./www/js/panmirror"/>
|
||||
|
||||
Reference in New Issue
Block a user