diff options
author | joerg <joerg@pkgsrc.org> | 2016-09-29 12:13:43 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2016-09-29 12:13:43 +0000 |
commit | e751ae5f31020d0cb45b5e15b9c075eb4d0daff7 (patch) | |
tree | 849fe7e6596f8f2dc29274f20be3285ef910d9d9 /misc | |
parent | 4c3d5ad1733007f7d2ca8acd3d0bc4617f24385a (diff) | |
download | pkgsrc-e751ae5f31020d0cb45b5e15b9c075eb4d0daff7.tar.gz |
Redo linking to work like in older Calibre, fixing build with native X.
Bump revision.
Diffstat (limited to 'misc')
-rw-r--r-- | misc/calibre/Makefile | 3 | ||||
-rw-r--r-- | misc/calibre/distinfo | 6 | ||||
-rw-r--r-- | misc/calibre/patches/patch-setup_build.py | 36 | ||||
-rw-r--r-- | misc/calibre/patches/patch-setup_build__environment.py | 26 | ||||
-rw-r--r-- | misc/calibre/patches/patch-setup_extensions.json | 17 |
5 files changed, 52 insertions, 36 deletions
diff --git a/misc/calibre/Makefile b/misc/calibre/Makefile index 7ba1842601b..57a24bb8abe 100644 --- a/misc/calibre/Makefile +++ b/misc/calibre/Makefile @@ -1,6 +1,7 @@ -# $NetBSD: Makefile,v 1.155 2016/09/18 21:56:47 wiz Exp $ +# $NetBSD: Makefile,v 1.156 2016/09/29 12:13:43 joerg Exp $ DISTNAME= calibre-2.68.0 +PKGREVISION= 1 CATEGORIES= misc #MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=calibre/} MASTER_SITES= http://download.calibre-ebook.com/${PKGVERSION_NOREV}/ diff --git a/misc/calibre/distinfo b/misc/calibre/distinfo index 6ceaf8c8de7..76727c06542 100644 --- a/misc/calibre/distinfo +++ b/misc/calibre/distinfo @@ -1,9 +1,9 @@ -$NetBSD: distinfo,v 1.76 2016/09/18 21:56:47 wiz Exp $ +$NetBSD: distinfo,v 1.77 2016/09/29 12:13:43 joerg Exp $ SHA1 (calibre-2.68.0.tar.xz) = 47159097f78d282ba5cb5bd7f55ce88e242397e4 RMD160 (calibre-2.68.0.tar.xz) = 1b4e4cd91bccdca3c52b9feb775a92d966697921 SHA512 (calibre-2.68.0.tar.xz) = 60d70f494b80f6fd10266162f54284e824207c9105e50d21ea0a14f6e612a911d2e6475c78cb4b499f3e411893ab2c7255c7b762ac8c5bfa5040e6a2efb100c1 Size (calibre-2.68.0.tar.xz) = 39949696 bytes -SHA1 (patch-setup_build.py) = 9699b5badd044aacd72b223c182ab14f38eb1dcb -SHA1 (patch-setup_extensions.json) = a08c9c6675f9b7926fa53dbb74846ed47c4298c7 +SHA1 (patch-setup_build.py) = 4a601e44fb69085c1f05ca0f90b73ce3f6d51ba6 +SHA1 (patch-setup_build__environment.py) = d44460d96f9fb76cd80814a9cba8b153c52b5bfc SHA1 (patch-src_calibre_linux.py) = 16c3122a612ec9996f774c5c2c9d40a475723662 diff --git a/misc/calibre/patches/patch-setup_build.py b/misc/calibre/patches/patch-setup_build.py index e3f14763c05..e7122a64d36 100644 --- a/misc/calibre/patches/patch-setup_build.py +++ b/misc/calibre/patches/patch-setup_build.py @@ -1,21 +1,27 @@ -$NetBSD: patch-setup_build.py,v 1.1 2016/07/24 07:08:54 wiz Exp $ +$NetBSD: patch-setup_build.py,v 1.2 2016/09/29 12:13:43 joerg Exp $ -Add rpath to linker command. -Look in libtool directory for file. +Find libtool output correctly. +Fix linking against native X. ---- setup/build.py.orig 2016-07-22 02:21:05.000000000 +0000 +--- setup/build.py.orig 2016-09-29 10:28:31.000000000 +0000 +++ setup/build.py -@@ -251,8 +251,7 @@ class Build(Command): - return ['-I'+x for x in dirs] - - def lib_dirs_to_ldflags(self, dirs): -- pref = '/LIBPATH:' if iswindows else '-L' -- return [pref+x for x in dirs] -+ return ['-L'+x+' -Wl,-R'+x for x in dirs] - - def libraries_to_ldflags(self, dirs): - pref = '' if iswindows else '-l' -@@ -452,7 +451,7 @@ class Build(Command): +@@ -368,6 +368,7 @@ class Build(Command): + INCLUDEPATH += {freetype} + DESTDIR = {destdir} + CONFIG -= create_cmake # Prevent qmake from generating a cmake build file which it puts in the calibre src directory ++ QMAKE_LFLAGS += $(COMPILER_RPATH_FLAG)$(X11BASE)/lib + QMAKE_LIBS_PRIVATE += {glib} {fontconfig} + ''').format( + headers=' '.join(headers), sources=' '.join(sources), others=' '.join(others), destdir=self.d( +@@ -426,6 +427,7 @@ class Build(Command): + SOURCES = {sources} + INCLUDEPATH += {sipinc} {pyinc} + VERSION = {ver} ++ QMAKE_LFLAGS += $(COMPILER_RPATH_FLAG)$(X11BASE)/lib + win32 {{ + LIBS += {py_lib} + TARGET_EXT = .dll +@@ -456,7 +458,7 @@ class Build(Command): if iswindows: qmc += ['-spec', qmakespec] fext = 'dll' if iswindows else 'dylib' if isosx else 'so' diff --git a/misc/calibre/patches/patch-setup_build__environment.py b/misc/calibre/patches/patch-setup_build__environment.py new file mode 100644 index 00000000000..380b8261848 --- /dev/null +++ b/misc/calibre/patches/patch-setup_build__environment.py @@ -0,0 +1,26 @@ +$NetBSD: patch-setup_build__environment.py,v 1.3 2016/09/29 12:13:43 joerg Exp $ + +Always build like on Linux. + +--- setup/build_environment.py.orig 2016-09-29 09:55:14.000000000 +0000 ++++ setup/build_environment.py +@@ -97,8 +97,8 @@ def get_sip_dir(): + pyqt['pyqt_sip_dir'] = get_sip_dir() + pyqt['sip_inc_dir'] = os.environ.get('SIP_INC_DIR', sysconfig.get_path('include')) + +-glib_flags = subprocess.check_output([PKGCONFIG, '--libs', 'glib-2.0']).strip() if islinux else '' +-fontconfig_flags = subprocess.check_output([PKGCONFIG, '--libs', 'fontconfig']).strip() if islinux else '' ++glib_flags = subprocess.check_output([PKGCONFIG, '--libs', 'glib-2.0']).strip() ++fontconfig_flags = subprocess.check_output([PKGCONFIG, '--libs', 'fontconfig']).strip() + qt_inc = pyqt['inc'] + qt_lib = pyqt['lib'] + ft_lib_dirs = [] +@@ -121,7 +121,7 @@ QT_DLLS = ['Qt5' + x for x in ( + 'WebKit', 'WebKitWidgets', 'Widgets', 'Multimedia', 'MultimediaWidgets', 'Xml', # 'XmlPatterns', + )] + QT_PLUGINS = ('imageformats', 'audio', 'iconengines', 'mediaservice', 'platforms', 'playlistformats', 'printsupport', 'sqldrivers') +-if islinux: ++if True: + # platformthemes cause crashes in Ubuntu + QT_PLUGINS += ('platforminputcontexts', 'generic',) + diff --git a/misc/calibre/patches/patch-setup_extensions.json b/misc/calibre/patches/patch-setup_extensions.json deleted file mode 100644 index 6e78e696e3a..00000000000 --- a/misc/calibre/patches/patch-setup_extensions.json +++ /dev/null @@ -1,17 +0,0 @@ -$NetBSD: patch-setup_extensions.json,v 1.1 2016/07/24 07:08:54 wiz Exp $ - -Add X11 libraries to search path. -XXX: should be using ${PREFIX} and ${X11BASE} - ---- setup/extensions.json.orig 2016-07-22 02:21:05.000000000 +0000 -+++ setup/extensions.json -@@ -141,7 +141,8 @@ - "sources": "calibre/gui2/pictureflow/pictureflow.cpp", - "headers": "calibre/gui2/pictureflow/pictureflow.h", - "sip_files": "calibre/gui2/pictureflow/pictureflow.sip", -- "inc_dirs": "calibre/gui2/pictureflow" -+ "inc_dirs": "calibre/gui2/pictureflow", -+ "lib_dirs": "/usr/X11R7/lib /usr/pkg/X11R7/lib" - }, - { - "name": "progress_indicator", |