FreeBSD Bugzilla – Attachment 189110 Details for
Bug 224580
[deskutils/calibre]: MTP devices not detected
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch including suggested changes
calibre.diff (text/plain), 5.27 KB, created by
Guido Falsi
on 2017-12-26 10:59:23 UTC
(
hide
)
Description:
Patch including suggested changes
Filename:
MIME Type:
Creator:
Guido Falsi
Created:
2017-12-26 10:59:23 UTC
Size:
5.27 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 457276) >+++ Makefile (working copy) >@@ -3,6 +3,7 @@ > > PORTNAME= calibre > PORTVERSION= 3.14.0 >+PORTREVISION= 1 > CATEGORIES= deskutils python > MASTER_SITES= http://download.calibre-ebook.com/${PORTVERSION}/ > >@@ -52,7 +53,7 @@ > USE_RC_SUBR= calibre > EXTRACT_BEFORE_ARGS= -x -s '/^calibre/~-src/' -f > SHEBANG_GLOB= *.sh *.py >-python_OLD_CMD= "/usr/bin/env python2" /bin/python2 /usr/bin/python2 /usr/local/bin/python2 >+python_OLD_CMD= "/usr/bin/env python2" "/usr/bin/env python2" /bin/python2 /usr/bin/python2 /usr/local/bin/python2 > USE_PYQT= core gui network sip svg webkit widgets webkitwidgets xmlpatterns > USE_QT5= buildtools_build core dbus gui qmake_build widgets > USE_GL= egl gl >Index: files/patch-setup_build__environment.py >=================================================================== >--- files/patch-setup_build__environment.py (revision 457276) >+++ files/patch-setup_build__environment.py (working copy) >@@ -1,11 +1,24 @@ >---- setup/build_environment.py.orig 2017-06-16 04:00:12 UTC >+--- setup/build_environment.py.orig 2017-12-15 02:50:37 UTC > +++ setup/build_environment.py >-@@ -84,7 +84,7 @@ pyqt['sip_bin'] = os.environ.get('SIP_BIN', 'sip') >- from PyQt5.QtCore import PYQT_CONFIGURATION >+@@ -9,7 +9,7 @@ __docformat__ = 'restructuredtext en' >+ import os, subprocess, re, sys, sysconfig >+ from distutils.spawn import find_executable >+ >+-from setup import isosx, iswindows, is64bit, islinux, ishaiku >++from setup import isbsd, isosx, iswindows, is64bit, islinux, ishaiku >+ is64bit >+ >+ NMAKE = RC = msvc = MT = win_inc = win_lib = None >+@@ -85,6 +85,12 @@ from PyQt5.QtCore import PYQT_CONFIGURATION > pyqt['sip_flags'] = PYQT_CONFIGURATION['sip_flags'] > def get_sip_dir(): >-- q = os.environ.get('SIP_DIR', os.path.join(sys.prefix, 'share', 'sip') if iswindows else os.path.join(sys.prefix, 'share', 'sip')) >-+ q = os.environ.get('SIP_DIR', os.path.join(sys.prefix, 'share', 'sip') if iswindows else os.path.join(sys.prefix, 'share', 'py-sip')) >+ q = os.environ.get('SIP_DIR', os.path.join(sys.prefix, 'share', 'sip') if iswindows else os.path.join(sys.prefix, 'share', 'sip')) >++ if iswindows: >++ q = os.environ.get('SIP_DIR', os.path.join(sys.prefix, 'share', 'sip')) >++ elif isbsd: >++ q = os.environ.get('SIP_DIR', os.path.join(sys.prefix, 'share', 'py-sip')) >++ else: >++ q = os.path.join(sys.prefix, 'share', 'sip') > for x in ('', 'Py2-PyQt5', 'PyQt5', 'sip/PyQt5'): > base = os.path.join(q, x) > if os.path.exists(os.path.join(base, 'QtWidgets')): >Index: files/patch-setup_extensions.json >=================================================================== >--- files/patch-setup_extensions.json (nonexistent) >+++ files/patch-setup_extensions.json (working copy) >@@ -0,0 +1,18 @@ >+--- setup/extensions.json.orig 2017-12-15 02:50:37 UTC >++++ setup/extensions.json >+@@ -194,8 +194,14 @@ >+ "libraries": "usb-1.0" >+ }, >+ { >++ "name": "libusb-bsd", >++ "only": "bsd", >++ "sources": "calibre/devices/libusb/libusb.c", >++ "libraries": "usb" >++ }, >++ { >+ "name": "libmtp", >+- "only": "osx linux haiku", >++ "only": "osx linux haiku bsd", >+ "sources": "calibre/devices/mtp/unix/devices.c calibre/devices/mtp/unix/libmtp.c", >+ "headers": "calibre/devices/mtp/unix/devices.h calibre/devices/mtp/unix/upstream/music-players.h calibre/devices/mtp/unix/upstream/device-flags.h", >+ "libraries": "mtp" > >Property changes on: files/patch-setup_extensions.json >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: files/patch-src_calibre_devices_libusb_libusb.c >=================================================================== >--- files/patch-src_calibre_devices_libusb_libusb.c (nonexistent) >+++ files/patch-src_calibre_devices_libusb_libusb.c (working copy) >@@ -0,0 +1,14 @@ >+--- src/calibre/devices/libusb/libusb.c.orig 2017-12-15 02:50:37 UTC >++++ src/calibre/devices/libusb/libusb.c >+@@ -8,7 +8,11 @@ >+ #define UNICODE >+ >+ #include <Python.h> >++#ifdef __FreeBSD__ >++#include <libusb.h> >++#else >+ #include <libusb-1.0/libusb.h> >++#endif >+ >+ static PyObject *Error = NULL; >+ static PyObject *cache = NULL; > >Property changes on: files/patch-src_calibre_devices_libusb_libusb.c >___________________________________________________________________ >Added: fbsd:nokeywords >## -0,0 +1 ## >+yes >\ No newline at end of property >Added: svn:eol-style >## -0,0 +1 ## >+native >\ No newline at end of property >Added: svn:mime-type >## -0,0 +1 ## >+text/plain >\ No newline at end of property >Index: pkg-plist >=================================================================== >--- pkg-plist (revision 457276) >+++ pkg-plist (working copy) >@@ -1181,6 +1181,8 @@ > lib/calibre/calibre/plugins/icu.so > lib/calibre/calibre/plugins/imageops.so > lib/calibre/calibre/plugins/libheadless.so >+lib/calibre/calibre/plugins/libmtp.so >+lib/calibre/calibre/plugins/libusb-bsd.so > lib/calibre/calibre/plugins/lzma_binding.so > lib/calibre/calibre/plugins/lzx.so > lib/calibre/calibre/plugins/matcher.so
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 224580
:
189110
|
189442