| Summary: | kio_man does not support XZ compressed manpages | ||
|---|---|---|---|
| Product: | TDE | Reporter: | Francois Andriot <albator78> |
| Component: | tdebase | Assignee: | Slávek Banko <slavek.banko> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | albator78, bugwatch, darrella, kb9vqf, slavek.banko |
| Priority: | P5 | ||
| Version: | 3.5.13.2 [Trinity] | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Compiler Version: | TDE Version String: | ||
| Application Version: | Application Name: | ||
| Attachments: |
Add support for xz compression in kio-man
Add support for xz and lzma compression in kio-man tdelibs 3.5.13.2 : add XZ kioslave |
||
|
Description
Francois Andriot
2013-05-05 03:03:16 CDT
Created attachment 1209 [details]
Add support for xz compression in kio-man
Please, try proposed patch.
OK I've analyzed a bit further. In fact there are 2 problems that must be solved for this bug: 1) kio_man cannot not locate ".xz" nor ".lzma" compressed man pages. E.g, if you type "man:bash", you get a message: ================ KDE Man Viewer Error No man page matching to bash found. Check that you have not mistyped the name of the page that you want. Be careful that you must take care about upper case and lower case characters! If everything looks correct, then perhaps you need to set a better search path for man pages, be it by the environment variable MANPATH or a matching file in the directory /etc . ================ BUT you can still (try to) display man pages by their full path:, e.g: "man:/usr/share/man/man1/bash.1.xz" The patch you have posted fix this first issue (you should add the ".lzma" extension too, I think this is a valid compression for man pages) 2) The "makewhatis" variant of kio_man does not display the XZ file content at all, I just get a blank page. I think this is because it is using some generic kioslave filter to load the file and uncompress it on the fly, but currently there is no XZ kio_filter available, only gzip and bzip2. This issue still need to be solved (I'm currently looking for it) Note: I think (not sure) the "mandb" variant of kio_man is not affected, since it's using the "man" command directly and parses output. The KIO related stuff is not involved. Created attachment 1223 [details]
Add support for xz and lzma compression in kio-man
Lzma suffix added.
I also tried to add "protocol" files for other compressions in kio-filters.
I have no idea if this will help, please try it.
Hello, I see you had the same idea as me :) Alas it is not enough. There are more stuff to add in tdelibs. I'm currently working on it. I will tell you when I find the final solution. You can focus on other bugs for now :) Created attachment 1224 [details] tdelibs 3.5.13.2 : add XZ kioslave Here is the patch for tdelibs. Your patch is required too. XZ format information: http://tukaani.org/xz/xz-file-format.txt Original XZ kioslave code from KDE4 : https://projects.kde.org/projects/kde/kdelibs/repository/revisions/bbe9e8f51f5f9af4236f1b160fc785c64021cafc ... backported to TDE library code, adapted to TQT layer, inspired from kbzip2filter ... finally it works !!! I can see my XZ man pages in konqueror !!! I did not try LZMA since I do not know if/which distribution use it today. I'm exhausted and going to sleep now . Good night :) Comment on attachment 1224 [details]
tdelibs 3.5.13.2 : add XZ kioslave
Looks like this was committed to GIT in hash 7f328ba6
I forward-ported Slavek's patch to R14 GIT in hash f08ddb4. (Odpověď na komentář #7)
> I forward-ported Slavek's patch to R14 GIT in hash f08ddb4.
I was going to commit the remaining part today.
You were faster :) Thank you.
I updated both tdelibs and tdebase sources. There is no xz.protocol file in either and building tdebase fails because of that. Oops: The failure message: file INSTALL cannot find "/dev/shm/tdebase/tdeioslave/filter/xz.protocol". (Odpověď na komentář #10)
> Oops:
>
> The failure message:
>
> file INSTALL cannot find "/dev/shm/tdebase/tdeioslave/filter/xz.protocol".
Good point - I need to commit new files that Tim forgot.
Note: That is why I always recommend to use git add --all ;)
Remaining files pushed to GIT in hash c58d6f50. All is well --- no build errors. :-) |