|
|
#1 |
|
Enthusiast
![]() Posts: 38
Karma: 10
Join Date: Nov 2009
Location: Poland
Device: kindle 1st gen, kindle dxg, kindle paperwhite2
|
calibre develop on gentoo
Hi Kovid,
I've decided to do my development on gentoo, but it turns out that preparing the environment is not a trivial task... I'm using code cloned from github and trying to get calibre development installed. The OS is 64bit, lxde with no kde or anything like that. At first I got Code:
[tomek ~/calibre]$ sudo python2.7 setup.py develop
Traceback (most recent call last):
File "setup.py", line 13, in <module>
import setup.commands as commands
File "/home/tomek/calibre/setup/commands.py", line 28, in <module>
from setup.translations import POT, GetTranslations, Translations, ISO639, ISO3166
File "/home/tomek/calibre/setup/translations.py", line 14, in <module>
from setup.parallel_build import parallel_check_output
File "/home/tomek/calibre/setup/parallel_build.py", line 13, in <module>
from setup.build_environment import cpu_count
File "/home/tomek/calibre/setup/build_environment.py", line 84, in <module>
qraw = subprocess.check_output([QMAKE, '-query']).decode('utf-8')
File "/usr/lib64/python2.7/subprocess.py", line 566, in check_output
process = Popen(stdout=PIPE, *popenargs, **kwargs)
File "/usr/lib64/python2.7/subprocess.py", line 710, in __init__
errread, errwrite)
File "/usr/lib64/python2.7/subprocess.py", line 1327, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
Got qt overlay installed to get qt5 (emerge @qt5-essentials). So now I have a qmake: Code:
[tomek ~/calibre]$ which qmake
/usr/bin/qmake
[tomek ~/calibre]$ equery b /usr/bin/qmake
* Searching for /usr/bin/qmake ...
dev-qt/qtchooser-0_p20140613 (/usr/bin/qmake -> qtchooser)
dev-qt/qtchooser-0_p20140613 (/usr/bin/qtchooser)
[tomek ~/calibre]$ sudo python2.7 setup.py develop
Password:
qmake: could not find a Qt installation of ''
Traceback (most recent call last):
File "setup.py", line 13, in <module>
import setup.commands as commands
File "/home/tomek/calibre/setup/commands.py", line 28, in <module>
from setup.translations import POT, GetTranslations, Translations, ISO639, ISO3166
File "/home/tomek/calibre/setup/translations.py", line 14, in <module>
from setup.parallel_build import parallel_check_output
File "/home/tomek/calibre/setup/parallel_build.py", line 13, in <module>
from setup.build_environment import cpu_count
File "/home/tomek/calibre/setup/build_environment.py", line 84, in <module>
qraw = subprocess.check_output([QMAKE, '-query']).decode('utf-8')
File "/usr/lib64/python2.7/subprocess.py", line 573, in check_output
raise CalledProcessError(retcode, cmd, output=output)
subprocess.CalledProcessError: Command '['/usr/bin/qmake', '-query']' returned non-zero exit status 1
[tomek ~/calibre]$ qmake -query
qmake: could not find a Qt installation of ''
[tomek ~/calibre]$ echo $?
1
but there is another one, buried somewhere outside of $PATH: Code:
/usr/lib64/qt5/bin/qmake Code:
[tomek ~/calibre]$ sudo PATH=/usr/lib64/qt5/bin/:$PATH python2.7 setup.py develop
Traceback (most recent call last):
File "setup.py", line 13, in <module>
import setup.commands as commands
File "/home/tomek/calibre/setup/commands.py", line 28, in <module>
from setup.translations import POT, GetTranslations, Translations, ISO639, ISO3166
File "/home/tomek/calibre/setup/translations.py", line 14, in <module>
from setup.parallel_build import parallel_check_output
File "/home/tomek/calibre/setup/parallel_build.py", line 13, in <module>
from setup.build_environment import cpu_count
File "/home/tomek/calibre/setup/build_environment.py", line 96, in <module>
from PyQt5.QtCore import PYQT_CONFIGURATION
ImportError: No module named PyQt5.QtCore
Code:
mutex calibre # emerge -av qtcore
These are the packages that would be merged, in order:
Calculating dependencies... done!
[ebuild R ] dev-qt/qtcore-5.4.0_beta:5::qt USE="-debug -icu {-test}" 0 KiB
And I know that there is no need to install the development version, but the ebuild on gentoo is for calibre-1.48... |
|
|
|
|
|
#2 |
|
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,609
Karma: 28549044
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
You dont need to install anything. Just install the official calibre binary from http://calibre-ebook.com/download_linux, that will acts as its own complete runtime.
See the instructions here: http://manual.calibre-ebook.com/develop.html |
|
|
|
| Advert | |
|
|
|
|
#3 |
|
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
You can just use the binaries from the main website, and use the CALIBRE_DEVELOP_FROM variable to run the source code from your GitHub clone.
Much easier than messing around with setting up the compilation yourself. Also, see Fully automatic calibre installer/updater for linux to keep the binaries updated (necessary when C++ extensions are updated). |
|
|
|
|
|
#4 |
|
Enthusiast
![]() Posts: 38
Karma: 10
Join Date: Nov 2009
Location: Poland
Device: kindle 1st gen, kindle dxg, kindle paperwhite2
|
Thanks, using the CALIBRE_DEVELOP_FROM should be sufficient.
|
|
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Helping to Develop Calibre Core Software | Borodin | Development | 6 | 09-11-2014 12:23 AM |
| Gentoo problem with error :No device connected | joebie13 | Devices | 1 | 12-09-2011 10:04 AM |
| What happened to calibre-debug "--develop-from" option? | macr0t0r | Calibre | 6 | 12-03-2009 08:22 PM |
| Gentoo Weekly News, Handbooks in Plucker format | hacker | Workshop | 5 | 08-28-2007 10:39 AM |
| Gentoo Handbook (and news feed) in Plucker format | hacker | Workshop | 3 | 04-28-2005 07:22 AM |