07-04-2016, 06:15 AM | #1 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Calibre and WINE
When I add books to Calibre in Kubuntu, for some it expects Wine stuff in my home directory. Since my Wine prefix is /home/myname/.wine/, Calibre doesn't find it, then adds dosdevices & drive_c folders along with registry files in /home/myname/ directory. Is there any way to tell Calibre to look in the right place for Wine?
Calibre 2.60 Kubuntu 14.04 |
07-04-2016, 09:34 AM | #2 |
Wizard
Posts: 4,552
Karma: 950151
Join Date: Nov 2008
Device: Sony PRS-950, iphone/ipad (Marvin/iBooks/QuickReader)
|
There should be no reason why Calibre expects WINE. Are you sure you did not install the Windows version of Calibre?
|
Advert | |
|
07-04-2016, 01:28 PM | #3 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Only if this series of commands installs a windows version:
sudo -v && wget -nv -O- https://raw.githubusercontent.com/ko...x-installer.py | sudo python -c "import sys; main=lambda:sys.stderr.write('Download failed\n'); exec(sys.stdin.read()); main()" |
07-04-2016, 01:41 PM | #4 | |
Wizard
Posts: 2,082
Karma: 8796704
Join Date: Jun 2010
Device: Kobo Clara HD,Hisence Sero 7 Pro RIP, Nook STR, jetbook lite
|
Quote:
Code:
sudo -v && wget -nv -O- https://raw.githubusercontent.com/kovidgoyal/calibre/master/setup/linux-installer.py | sudo python -c "import sys; main=lambda x:sys.stderr.write('Download failed\n'); exec(sys.stdin.read()); main('/opt')" |
|
07-04-2016, 02:58 PM | #5 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Thanks, I uninstalled then reinstalled using the command you supplied. That seems to have fixed the issue.
Two questions: 1. I see the difference in the commands - "main=lambda:sys.stderr.write" vs "main=lambda x:sys.stderr.write". What is the significance of the change? 2. Will the supplied command for Binary Install on the calibre download page be changed? Or should I plan to keep using the one you supplied for updates? |
Advert | |
|
07-04-2016, 03:20 PM | #6 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
A lambda creates an anonymous function, and needs to know how many arguments to consume in case the installation script fails to download.
It is the difference between printing: Code:
2016-07-04 15:11:16 ERROR 404: Not Found.
Traceback (most recent call last):
File "<string>", line 1, in <module>
TypeError: <lambda>() takes 0 positional arguments but 1 was given
Code:
2016-07-04 15:10:39 ERROR 404: Not Found.
Download failed
tl;dr How many arguments did you pass into: main() main('/opt') main('/opt', True) |
07-04-2016, 03:49 PM | #7 | ||
Wizard
Posts: 2,082
Karma: 8796704
Join Date: Jun 2010
Device: Kobo Clara HD,Hisence Sero 7 Pro RIP, Nook STR, jetbook lite
|
Quote:
Quote:
What version of Kubuntu are you using? bernie P.S. Did calibre work? |
||
07-04-2016, 05:09 PM | #8 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Yes, installing with the second command worked. You are correct, the first command did not put it in /opt but the second one did. I'm using Kubuntu 14.04.4
|
07-07-2016, 01:59 PM | #9 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Guess I spoke too quickly :-( Once again Calibre thought it needed to create WINE folders and files. This time it occurred (maybe always, I'm not sure) when I imported a PDF into Calibre. EPUB's and AZW3's seem to import fine. So... I'm still not sure what's going on.
|
07-07-2016, 02:40 PM | #10 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Do you have any plugins installed, and if so, which ones?
Particularly, filetype plugins (which operate during the importation of books). ... calibre itself certainly doesn't invoke WINE at any time (unless you run calibre from WINE for some strange reason) but thirdparty plugins can do whatever they want. |
07-07-2016, 03:51 PM | #11 |
Grand Sorcerer
Posts: 12,166
Karma: 73448616
Join Date: Nov 2007
Location: Toronto
Device: Nexus 7, Clara, Touch, Tolino EPOS
|
Might also be worth while running calibre in debug mode and posting the resulting log file.
|
07-07-2016, 10:17 PM | #12 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Thanks for the suggestions eschwartz and PeterT. It is one of the filetype plugins that requires windows to run a python script. Guess I'll have to bug the author of the plugin to fix it.
Last edited by therapon; 07-07-2016 at 10:37 PM. |
07-07-2016, 10:33 PM | #13 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Hmm, now that I think about it, the DeDRM plugin (which uses WINE to decrypt EPUB/PDF via Adobe Digital Editions) is probably responsible.
It is probably calling WINE in order to attempt to run the key extraction code. But in that case, it should be triggering on EPUBs as well. ... AFAIK, the plugin tries DeDRMing all imported AZW*/EPUB/PDF whether they need it or not. |
07-08-2016, 08:04 AM | #14 |
Junior Member
Posts: 7
Karma: 10
Join Date: Jul 2016
Device: none
|
Yup, you are correct eschwartz. Setting the WINEPREFIX in the plugin config seems to have remedied the problem. It would be nice, though, if it would use the linux version of ActiveState instead of requiring the Win version. Oh well
|
07-08-2016, 09:46 AM | #15 |
Ex-Helpdesk Junkie
Posts: 19,422
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
No, it has to run within WINE in order to use the Windows/WINE environment to scrape information from the Windows programs in question and/or config/registry info.
I mean, how else do you expect to use a Windows program (the Windows version of the DeDRM internals) on Linux? |
Tags |
import, linux, wine |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Wine with updated Calibre and a shared data partition | oakridge | Devices | 4 | 04-30-2015 04:56 PM |
Calibre using wine | And | Devices | 2 | 06-24-2011 05:55 PM |
Calibre in Wine | EvilWayz | Calibre | 8 | 05-23-2011 08:35 PM |
Calibre on Linux, ADE on Windows/WINE - how do I manage? | Beetle B. | Calibre | 4 | 11-28-2010 03:35 PM |
Calibre on Linux under Wine | tulsa | Calibre | 7 | 03-24-2010 05:17 AM |