LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Google Desktop Search equivalent (https://www.linuxquestions.org/questions/slackware-14/google-desktop-search-equivalent-553949/)

titopoquito 05-18-2007 06:07 PM

I've just submitted the scripts. Let's hope they are well done so that they are accepted by Eric or the other guys from slackbuild.org :)

Alien Bob 05-18-2007 09:49 PM

They're in the SBo repository now.

Eric

adriv 05-19-2007 06:07 AM

Got it installed now without a hitch. :)
Thanks!

UPDATE:
It works great!
Fast and very little RAM-consuming.
Nice work.

allend 05-19-2007 09:51 AM

Great thread and slick work!
I have been following this with great interest and now all is installed and running using the Slackbuild scripts.
This will fulfil a wish I have had for indexing a data archive.

SlackMagic! :-)

Thanks to all concerned.

Drone4four 06-06-2007 03:02 AM

I installed Recoll like everyone else just fine with SBo. Special thanks to the SBo team! After reading the dox on the Recoll website I learned how to set index certain directories. Now my problem is: how do I click on a searched item on the results page? It's like I can't click the results. wtf??

Hangdog42 06-06-2007 07:07 AM

There are preview and edit links in the first line of every result (well, edit only shows up if recoll knows what program to use to edit it). The whole result isn't clickable, but the links should be there.

Drone4four 06-18-2007 11:38 PM

Quote:

Originally Posted by Hangdog42
There are preview and edit links in the first line of every result (well, edit only shows up if recoll knows what program to use to edit it). The whole result isn't clickable, but the links should be there.

thanks, that explains it

Drone4four 06-18-2007 11:47 PM

Now the index is horribly incomplete. Reading the official documentation here, http://www.lesbonscomptes.com/recoll...ual/index.html I learned that this is the command to start the index:
Quote:

recollindex
However, a handle full of files which should exist in my index, do not. WTF? What commands do you use to start your recoll index?

edit:sp

gnashley 06-19-2007 03:09 AM

adriv if you do decide to try converting a binary rpm package, you can use src2pkg for that instead of using rpm2tgz and installpkg. src2pkg incorporated binary rpm and deb conversion a while back. It should do a better job because the conents get checked and corrected like other src2pkg output and it will insert the slack-desc for you which is missing for the package otherwise.

Still, getting the sources to compile correctly would the best solution. Maybe you are missing some overlooked package or configure option. I don't use KDE and don't normally install any of the qt or kde stuff so I can't easily help.

titopoquito 06-19-2007 03:39 AM

Quote:

Originally Posted by Drone4four
Now the index is horribly incomplete. Reading the official documentation here, http://www.lesbonscomptes.com/recoll...ual/index.html I learned that this is the command to start the index:However, a handle full of files which should exist in my index, do not. WTF? What commands do you use to start your recoll index?

edit:sp

I use the GUI to do that after I have edited the config file by hand to tell recoll which folders to index (I have to of them -- one on my computer and one on my girlfiend's computer -- that go into one search database). So, no command line involved here, although I'm quite sure the way you start indexing has or should have the same effets.
Bad to hear that your index isn't complete. I've got nearly no document in my index that is unique enough to test that.

Hangdog42 06-19-2007 07:25 AM

Quote:

Originally Posted by Drone4four
Now the index is horribly incomplete. Reading the official documentation here, http://www.lesbonscomptes.com/recoll...ual/index.html I learned that this is the command to start the index:However, a handle full of files which should exist in my index, do not. WTF? What commands do you use to start your recoll index?

That's odd, I just use recollindex (in fact I run it as a daily cron job) and it seems to index everything. OK, it indexes everything in my home directory, which is the default top of the search tree. Are the things it isn't indexing outside of your home directory?

adriv 06-20-2007 06:20 AM

Quote:

Originally Posted by gnashley
adriv if you do decide to try converting a binary rpm package, you can use src2pkg for that instead of using rpm2tgz and installpkg. src2pkg incorporated binary rpm and deb conversion a while back. It should do a better job because the conents get checked and corrected like other src2pkg output and it will insert the slack-desc for you which is missing for the package otherwise.

Still, getting the sources to compile correctly would the best solution. Maybe you are missing some overlooked package or configure option. I don't use KDE and don't normally install any of the qt or kde stuff so I can't easily help.

Thanks, I have src2pkg installed for several months now (recently upgraded), just tried rpm2tgz because I couldn't get the job done with src2pkg.

By the way, the Slackbuild worked perfectly. ;)

titopoquito 06-28-2007 08:01 AM

EDIT: The following patch enables OGG and FLAC audio file indexing in recoll when used with the recoll build script from http://www.slackbuild.org


---

What I still missed from recoll is the ability to index flac and ogg audio files. I created a patch for that, which I want to give you below if you want flac and ogg support. These changes are not on Slackbuild.org because the submission part is disabled at the moment. I testet it and it seems okay, but please report if you encounter any problems with that. Oh, and of course it requires that you the Slackware's flac and vorbis-tools package installed :)

If you have untarred the Slackbuild "recoll.tar.gz" from Slackbuild, go to that folder. Save the code below as a file and apply it:

Code:

patch -p0 < /path/to/where/you/saved/this/file
now the patch itself:

Code:

--- recoll.SlackBuild.withoutflac        2007-06-28 14:54:27.491524250 +0200
+++ recoll.SlackBuild        2007-06-28 20:07:49.856360750 +0200
@@ -49,6 +49,11 @@
 chown -R root:root .
 chmod -R u+w,go+r-w,a-s .
 
+# If you do NOT want a patch that enables flac and ogg audio file indexing comment out the
+# next line. Note: requires "metaflac" and "ogginfo", found in the stock Slackware flac and
+# vorbis-tools package.
+patch -p0 < $CWD/patch.flac+ogg
+
 CFLAGS="$SLKCFLAGS" \
 CXXFLAGS="$SLKCFLAGS" \
 ./configure \
--- patch.flac+ogg.nul        2007-06-28 20:09:11.921489500 +0200
+++ patch.flac+ogg        2007-06-28 19:56:03.288203000 +0200
@@ -0,0 +1,263 @@
+--- sampleconf/mimeconf        2007-02-06 19:01:16.000000000 +0100
++++ sampleconf/mimeconf.flac        2007-06-28 19:33:30.066579750 +0200
+@@ -26,6 +26,7 @@
+ # have a look at the scripts.
+ [index]
+ application/msword = exec rcldoc
++application/ogg = exec rclogg
+ application/pdf = exec rclpdf
+ application/postscript = exec rclps
+ application/vnd.ms-powerpoint = exec rclppt
+@@ -41,6 +42,7 @@
+ application/vnd.sun.xml.writer.global = exec rclsoff
+ application/vnd.sun.xml.writer.template = exec rclsoff
+ application/x-dvi = exec rcldvi
++application/x-flac = exec rclflac
+ application/x-lyx = exec rcllyx
+ application/x-scribus = exec rclscribus
+ audio/mpeg = exec rclmedia
+@@ -57,6 +59,7 @@
+ # Icons to be used in the result list if required by gui config
+ [icons]
+ application/msword = wordprocessing
++application/ogg = sownd
+ application/pdf = pdf
+ application/postscript = postscript
+ application/vnd.ms-excel = spreadsheet
+@@ -70,6 +73,7 @@
+ application/vnd.sun.xml.writer = wordprocessing
+ application/vnd.sun.xml.writer.global = wordprocessing
+ application/vnd.sun.xml.writer.template = wordprocessing
++application/x-flac = sownd
+ application/x-fsdirectory = folder
+ application/x-dvi = document
+ audio/mpeg = sownd
+@@ -108,6 +112,8 @@
+              application/vnd.sun.xml.impress.template
+
+ media = audio/mpeg \
++      application/ogg \
++      application/x-flac \
+      image/jpeg \
+      image/png \
+
+--- sampleconf/mimemap        2007-02-06 19:01:16.000000000 +0100
++++ sampleconf/mimemap.flac        2007-06-28 19:33:30.066579750 +0200
+@@ -62,6 +62,8 @@
+ .rtf = text/rtf
+
+ .mp3 = audio/mpeg
++.flac = application/x-flac
++.ogg = application/ogg
+ .png = image/png
+ .jpg = image/jpeg
+
+--- sampleconf/mimeview        2007-02-14 11:10:43.000000000 +0100
++++ sampleconf/mimeview.flac        2007-06-28 19:54:07.452963750 +0200
+@@ -9,6 +9,7 @@
+ application/x-all = xdg-open %f
+
+ application/msword = openoffice %f
++application/ogg = xmms %f
+ application/pdf  = xpdf %f
+ application/postscript = gv %f
+ application/vnd.ms-excel = openoffice %f
+@@ -25,6 +26,7 @@
+ application/vnd.sun.xml.writer.template = openoffice %f
+ application/x-fsdirectory = rox %f
+ application/x-dvi = xdvi %f
++application/x-flac = xmms %f
+ application/x-lyx = lyx %f
+ application/x-scribus = scribus %f
+ audio/mpeg = xmms %f
+--- filters/rclflac.nul        2007-06-28 13:38:54.966033500 +0200
++++ filters/rclflac        2007-06-28 19:39:29.093017500 +0200
+@@ -0,0 +1,93 @@
++#!/bin/sh
++# @(#$Id: rclflac,v 0.1 2007/06/27 19:39:00 dockes Exp $  (C) 2007 J.F.Dockes
++#================================================================
++# rclflac
++# Handle flac audio files for recoll.
++#================================================================
++# set variables
++LANG=C ; export LANG
++LC_ALL=C ; export LC_ALL
++progname="rclflac"
++filetype=media
++
++
++#RECFILTCOMMONCODE
++##############################################################################
++# !! Leave the previous line unmodified!! Code imported from the
++# recfiltcommon file
++
++# Utility code common to all shell filters. This could be sourced at run
++# time, but it's slightly more efficient to include the code in the
++# filters at build time (with a sed script).
++
++# Describe error in a way that can be interpreted by our caller
++senderror()
++{
++    echo RECFILTERROR $*
++    # Also alert on stderr just in case
++    echo ":2:$progname::: $*" 1>&2
++    exit 1
++}
++
++iscmd()
++{
++    cmd=$1
++    case $cmd in
++    */*)
++        if test -x $cmd ; then return 0; else return 1; fi ;;
++    *)
++      oldifs=$IFS; IFS=":"; set -- $PATH; IFS=$oldifs
++      for d in $*;do test -x $d/$cmd && return 0;done
++      return 1 ;;
++    esac
++}
++
++checkcmds()
++{
++    for cmd in $*;do
++      if iscmd $cmd
++      then
++        a=1
++      else
++        senderror HELPERNOTFOUND $cmd
++      fi
++    done
++}
++
++# show help message
++if test $# -ne 1 -o "$1" = "--help"
++then
++  echo "Convert a $filetype file to HTML text for Recoll indexing."
++  echo "Usage: $progname [infile]"
++  exit 1
++fi
++
++infile="$1"
++
++# check the input file existence (may be '-' for stdin)
++if test "X$infile" != X- -a ! -f "$infile"
++then
++  senderror INPUTNOSUCHFILE "$infile"
++fi
++
++##############################################################################
++# !! Leave the following line unmodified !
++#ENDRECFILTCOMMONCODE
++
++checkcmds metaflac
++
++# output the result
++echo '<html><head>'
++#echo '<title>' "$title" '</title>'
++echo '<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">'
++echo '</head><body>'
++echo '<pre>'
++
++metaflac --list "$infile" | \
++  grep 'comment\[' | sed -e 's/</&lt;/g' -e 's/&/&amp;/g' -e 's/ *comment\[.*\]: .*=//'
++
++echo '</pre>'
++echo '</body></html>'
++
++# exit normally
++exit 0
+--- filters/rclogg.nul        2007-06-28 19:33:55.980199250 +0200
++++ filters/rclogg        2007-06-28 19:54:50.323643000 +0200
+@@ -0,0 +1,92 @@
++#!/bin/sh
++# @(#$Id: rclogg,v 0.1 2007/06/27 19:39:50 dockes Exp $  (C) 2007 J.F.Dockes
++#================================================================
++# rclogg
++# Handle ogg audio files for recoll.
++#================================================================
++# set variables
++LANG=C ; export LANG
++LC_ALL=C ; export LC_ALL
++progname="rclogg"
++filetype=media
++
++
++#RECFILTCOMMONCODE
++##############################################################################
++# !! Leave the previous line unmodified!! Code imported from the
++# recfiltcommon file
++
++# Utility code common to all shell filters. This could be sourced at run
++# time, but it's slightly more efficient to include the code in the
++# filters at build time (with a sed script).
++
++# Describe error in a way that can be interpreted by our caller
++senderror()
++{
++    echo RECFILTERROR $*
++    # Also alert on stderr just in case
++    echo ":2:$progname::: $*" 1>&2
++    exit 1
++}
++
++iscmd()
++{
++    cmd=$1
++    case $cmd in
++    */*)
++        if test -x $cmd ; then return 0; else return 1; fi ;;
++    *)
++      oldifs=$IFS; IFS=":"; set -- $PATH; IFS=$oldifs
++      for d in $*;do test -x $d/$cmd && return 0;done
++      return 1 ;;
++    esac
++}
++
++checkcmds()
++{
++    for cmd in $*;do
++      if iscmd $cmd
++      then
++        a=1
++      else
++        senderror HELPERNOTFOUND $cmd
++      fi
++    done
++}
++
++# show help message
++if test $# -ne 1 -o "$1" = "--help"
++then
++  echo "Convert a $filetype file to HTML text for Recoll indexing."
++  echo "Usage: $progname [infile]"
++  exit 1
++fi
++
++infile="$1"
++
++# check the input file existence (may be '-' for stdin)
++if test "X$infile" != X- -a ! -f "$infile"
++then
++  senderror INPUTNOSUCHFILE "$infile"
++fi
++
++##############################################################################
++# !! Leave the following line unmodified !
++#ENDRECFILTCOMMONCODE
++
++checkcmds ogginfo
++
++# output the result
++echo '<html><head>'
++#echo '<title>' "$title" '</title>'
++echo '<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">'
++echo '</head><body>'
++echo '<pre>'
++
++ogginfo "$infile" | \
++  sed -e "1,/^User comments/d" | grep -v Warning | sed "s/^ *.*=//"
++echo '</pre>'
++echo '</body></html>'
++
++# exit normally
++exit 0


msantinho 06-28-2007 04:12 PM

By the way, I noticed now that Google has released Google Desktop for Linux. http://desktop.google.com/linux/


All times are GMT -5. The time now is 10:11 AM.