Skip to content

Commit

Permalink
app-text/kbibtex: 0.6.2 version bump, add USE=webkit
Browse files Browse the repository at this point in the history
Package-Manager: portage-2.3.0
  • Loading branch information
a17r committed Mar 25, 2017
1 parent 2afe6de commit 8ba5961
Show file tree
Hide file tree
Showing 3 changed files with 149 additions and 0 deletions.
1 change: 1 addition & 0 deletions app-text/kbibtex/Manifest
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
DIST kbibtex-0.6.2.tar.xz 3081364 SHA256 d99e419aec1d3af0a57eba6d7498de4e6be25ddbd5a5e56fc9de09e7e17dcdf3 SHA512 aa23e80cb273c0ae721ecc917f540070deea520fea2d7ca7ee97fde2c6918dba84769ad083fed93b9d0260539273c20c214b92c94269b413f46cb644d16dc270 WHIRLPOOL 4ab308a8a44df4f3e3a485a67b265ecaf28d2c4a9e4e126d5ab4b95eac12ecacdd3b49bd03f67167a358d86b8359d758e3c4cbc72bd5eed8c10873d181f7e32e
DIST kbibtex-0.6.tar.xz 2430176 SHA256 fc67a376f05105f14a0bee595bfd073a1ef2c7f9fc6be35dc620bb34f3bd9656 SHA512 a6943271df529c15be8a3112ccbe2c64ccff4cc942c846f00447f7a40bb3e6a6408af12fafe201143a8cf0288ec5ea13da1abab5d870fea6d0516bf5c4543b60 WHIRLPOOL e679f3907fb3041e0680aee1f3f7e0a299fce648c5c1b81663de49ce9d77351dfde8165048cd92c2a5ba7139f8d67d5a9a4eb5f37c393e19006fba4bd5dcd98e
109 changes: 109 additions & 0 deletions app-text/kbibtex/files/kbibtex-0.6.2-webkit.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
commit 2cd09d41ed559461a0f0a346ebec3dea82c06947
Author: Andreas Sturmlechner <[email protected]>
Date: Sat Jan 21 18:26:46 2017 +0100

Add option to disable Qt4WebKit even if present

- Link against Qt4WebKit only if(HAVE_WEBKIT)
- Remove Qt4WebKit linking from tests

REVIEW: 129863

diff --git a/CMakeLists.txt b/CMakeLists.txt
index ee3d810..1acbf8a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -48,6 +48,12 @@ set(
)

option(
+ WITH_QTWEBKIT
+ "Enable QtWebkit support"
+ ON
+)
+
+option(
UNITY_BUILD
"Compile multiple C++ files in one big, merged file (\"Unity build\")\nSee also http://t-fischer.dreamwidth.org/3054.html"
)
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 04222a7..0b7be01 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -37,24 +37,41 @@ include(
# check if QtWebKit is available, which seems to be not available
# on e.g. RedHat Enterprise Linux 6 or Scientific Linux 6
if(
- QT_QTWEBKIT_FOUND
+ WITH_QTWEBKIT
)
- message(
- STATUS
- "Found QtWebKit, enabling WebKit support"
+ if(
+ QT_QTWEBKIT_FOUND
+ )
+ message(
+ STATUS
+ "Found QtWebKit, enabling WebKit support"
+ )
+ add_definitions(
+ -DHAVE_QTWEBKIT
+ )
+ set(
+ OPTIONAL_QTWEBKIT_LIBRARIES
+ ${QT_QTWEBKIT_LIBRARIES}
+ )
+ else(
+ QT_QTWEBKIT_FOUND
)
- add_definitions(
- -DHAVE_QTWEBKIT
+ message(
+ STATUS
+ "QtWebKit not found, disabling WebKit support"
+ )
+ endif(
+ QT_QTWEBKIT_FOUND
)
else(
- QT_QTWEBKIT_FOUND
+ WITH_QTWEBKIT
)
message(
STATUS
- "QtWebKit not found, disabling WebKit support"
+ "QtWebKit support disabled by configure"
)
endif(
- QT_QTWEBKIT_FOUND
+ WITH_QTWEBKIT
)

add_definitions(
diff --git a/src/networking/CMakeLists.txt b/src/networking/CMakeLists.txt
index efa14f4..f7ade08 100644
--- a/src/networking/CMakeLists.txt
+++ b/src/networking/CMakeLists.txt
@@ -131,7 +131,7 @@ target_link_libraries(
kbibtexnetworking
LINK_PRIVATE
${QT_QTCORE_LIBRARY}
- ${QT_QTWEBKIT_LIBRARY}
+ ${OPTIONAL_QTWEBKIT_LIBRARIES}
${KDE4_KDECORE_LIBS}
${KDE4_KIO_LIBS}
${POPPLER_QT4_LIBRARIES}
diff --git a/src/program/CMakeLists.txt b/src/program/CMakeLists.txt
index a9fe213..fa57506 100644
--- a/src/program/CMakeLists.txt
+++ b/src/program/CMakeLists.txt
@@ -65,7 +65,7 @@ kde4_add_executable(
target_link_libraries(
kbibtex
LINK_PRIVATE
- ${QT_QTWEBKIT_LIBRARIES}
+ ${OPTIONAL_QTWEBKIT_LIBRARIES}
${KDE4_KIO_LIBS}
${KDE4_KPARTS_LIBS}
${KDE4_KFILE_LIBS}
39 changes: 39 additions & 0 deletions app-text/kbibtex/kbibtex-0.6.2.ebuild
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=6

WEBKIT_REQUIRED="optional"
inherit kde4-base

DESCRIPTION="BibTeX editor by KDE to edit bibliographies used with LaTeX"
HOMEPAGE="http://home.gna.org/kbibtex/"
SRC_URI="http://download.gna.org/${PN}/0.6/${P}.tar.xz"

LICENSE="GPL-2"
SLOT="4"
KEYWORDS="~amd64 ~x86"
IUSE="debug"

DEPEND="
app-text/poppler[qt4]
dev-libs/libxml2
dev-libs/libxslt
dev-libs/qoauth:0
virtual/tex-base
x11-libs/libqxt
"
RDEPEND="${DEPEND}
dev-tex/bibtex2html
"

PATCHES=( "${FILESDIR}/${P}-webkit.patch" )

src_configure() {
local mycmakeargs=(
-DWITH_QTWEBKIT=$(usex webkit)
)

kde4-base_src_configure
}

0 comments on commit 8ba5961

Please sign in to comment.