Merge pull request #272854 from a-n-n-a-l-e-e/recoll-darwin

recoll: fix darwin build
This commit is contained in:
Mario Rodas
2024-02-19 05:09:29 -05:00
committed by GitHub
2 changed files with 59 additions and 2 deletions
@@ -0,0 +1,48 @@
From 9a0102fe1da038ebe08107ead991964df11b0271 Mon Sep 17 00:00:00 2001
From: annalee <150648636+a-n-n-a-l-e-e@users.noreply.github.com>
Date: Mon, 19 Feb 2024 03:31:20 +0000
Subject: [PATCH] no qtgui darwin bundle
---
qtgui/recoll.pro.in | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/qtgui/recoll.pro.in b/qtgui/recoll.pro.in
index a0ef314..6dbc3b5 100644
--- a/qtgui/recoll.pro.in
+++ b/qtgui/recoll.pro.in
@@ -180,7 +180,7 @@ windows {
}
}
-macx: {
+if (false) {
QCBUILDLOC=Qt_6_4_2_for_macOS
# QT += webkit webkitwidgets
@@ -375,7 +375,7 @@ macx: {
QMAKE_BUNDLE_DATA = APP_EXAMPLES APP_EXAMPLES_MAC APP_FILTERS APP_IMAGES APP_DOC
}
-unix:!macx {
+unix {
VPATH = @srcdir@
@@ -400,6 +400,13 @@ VPATH = @srcdir@
SOURCES += crontool.cpp \
rtitool.cpp
+ macx {
+ SOURCES += ../utils/closefrom.cpp \
+ ../utils/execmd.cpp \
+ ../utils/netcon.cpp \
+ ../utils/rclionice.cpp
+ }
+
FORMS += crontool.ui \
rtitool.ui
--
2.43.0
+11 -2
View File
@@ -105,6 +105,8 @@ mkDerivation rec {
patches = [
# fix "No/bad main configuration file" error
./fix-datadir.patch
# use the same configure based build for darwin as linux
./0001-no-qtgui-darwin-bundle.patch
];
nativeBuildInputs = [
@@ -135,6 +137,10 @@ mkDerivation rec {
libiconv
];
qtWrapperArgs = [
"--prefix PATH : ${filterPath}"
];
# the filters search through ${PATH} using a sh proc 'checkcmds' for the
# filtering utils. Short circuit this by replacing the filtering command with
# the absolute path to the filtering command.
@@ -150,8 +156,6 @@ mkDerivation rec {
substituteInPlace $f --replace /usr/bin/perl ${lib.getBin (perl.passthru.withPackages (p: [ p.ImageExifTool ]))}/bin/perl
fi
done
wrapProgram $out/bin/recoll --prefix PATH : "${filterPath}"
wrapProgram $out/bin/recollindex --prefix PATH : "${filterPath}"
wrapProgram $out/share/recoll/filters/rclaudio.py \
--prefix PYTHONPATH : $PYTHONPATH
wrapProgram $out/share/recoll/filters/rclimg \
@@ -163,6 +167,11 @@ mkDerivation rec {
mv $out/bin/recoll.app $out/Applications
'';
# create symlink after fixup to prevent double wrapping of recoll
postFixup = lib.optionalString (stdenv.isDarwin && withGui) ''
ln -s ../Applications/recoll.app/Contents/MacOS/recoll $out/bin/recoll
'';
enableParallelBuilding = true;
meta = with lib; {