tora: 3.1 -> 3.2.176

This commit is contained in:
Peter Hoeg 2019-08-19 22:30:32 +08:00
parent 6141829b4d
commit 156e9b417a

View File

@ -1,41 +1,37 @@
{ mkDerivation, lib, fetchFromGitHub, cmake, extra-cmake-modules, makeWrapper
, boost, doxygen, openssl, mysql, postgresql, graphviz, loki, qscintilla, qtbase }:
, boost, doxygen, openssl, mysql, postgresql, graphviz, loki
, qscintilla, qtbase, qttools }:
let
qscintillaLib = (qscintilla.override { withQt5 = true; });
in mkDerivation rec {
mkDerivation rec {
pname = "tora";
version = "3.1";
version = "3.2.176";
src = fetchFromGitHub {
owner = "tora-tool";
repo = "tora";
rev = "v${version}";
sha256 = "0wninl10bcgiljf6wnhn2rv8kmzryw78x5qvbw8s2zfjlnxjsbn7";
rev = "39bf2837779bf458fc72a9f0e49271152e57829f";
sha256 = "0fr9b542i8r6shgnz33lc3cz333fnxgmac033yxfrdjfglzk0j2k";
};
nativeBuildInputs = [ cmake extra-cmake-modules makeWrapper ];
nativeBuildInputs = [ cmake extra-cmake-modules makeWrapper qttools ];
buildInputs = [
boost doxygen graphviz loki mysql.connector-c openssl postgresql qscintillaLib qtbase
boost doxygen graphviz loki mysql.connector-c openssl postgresql qscintilla qtbase
];
preConfigure = ''
sed -i \
's|defaultGvHome = "/usr/bin"|defaultGvHome = "${lib.getBin graphviz}/bin"|' \
src/widgets/toglobalsetting.cpp
sed -i \
's|/usr/bin/dot|${lib.getBin graphviz}/bin/dot|' \
extlibs/libermodel/dotgraph.cpp
substituteInPlace src/widgets/toglobalsetting.cpp \
--replace 'defaultGvHome = "/usr/bin"' 'defaultGvHome = "${lib.getBin graphviz}/bin"'
substituteInPlace extlibs/libermodel/dotgraph.cpp \
--replace /usr/bin/dot ${lib.getBin graphviz}/bin/dot
'';
cmakeFlags = [
"-DWANT_INTERNAL_LOKI=0"
"-DWANT_INTERNAL_QSCINTILLA=0"
# cmake/modules/FindQScintilla.cmake looks in qtbase and for the wrong library name
"-DQSCINTILLA_INCLUDE_DIR=${qscintillaLib}/include"
"-DQSCINTILLA_LIBRARY=${qscintillaLib}/lib/libqscintilla2.so"
"-DQSCINTILLA_INCLUDE_DIR=${qscintilla}/include"
"-DQSCINTILLA_LIBRARY=${qscintilla}/lib/libqscintilla2.so"
"-DENABLE_DB2=0"
"-DENABLE_ORACLE=0"
"-DENABLE_TERADATA=0"