albert: use substituteInPlace instead of sed
This is more robust and automatic to check if the file still exists in the same location and if we can still replace the string.
This commit is contained in:
@@ -58,10 +58,8 @@ stdenv.mkDerivation (finalAttrs: {
|
||||
postPatch = ''
|
||||
find -type f -name CMakeLists.txt -exec sed -i {} -e '/INSTALL_RPATH/d' \;
|
||||
|
||||
# WARN: This is necessary for albert to detect the package libraries.
|
||||
# Please check if the file below has changed upstream before updating.
|
||||
sed -i src/app/qtpluginprovider.cpp \
|
||||
-e "/QStringList install_paths;/a install_paths << QFileInfo(\"$out/lib\").canonicalFilePath();"
|
||||
substituteInPlace src/app/qtpluginprovider.cpp \
|
||||
--replace-fail "QStringList install_paths;" "QStringList install_paths;${"\n"}install_paths << QFileInfo(\"$out/lib\").canonicalFilePath();"
|
||||
'';
|
||||
|
||||
postFixup = ''
|
||||
|
||||
Reference in New Issue
Block a user