sigil: new package
This commit is contained in:
parent
4d246d00e5
commit
bfa942c9bf
69
pkgs/applications/editors/sigil/default.nix
Normal file
69
pkgs/applications/editors/sigil/default.nix
Normal file
|
@ -0,0 +1,69 @@
|
|||
{ stdenv, fetchurl, unzip, cmake, pkgconfig, makeWrapper
|
||||
, hunspell, minizip, boost, xercesc, qt5
|
||||
}:
|
||||
|
||||
let
|
||||
the_version = "0.7.4";
|
||||
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "sigil-${the_version}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://sigil.googlecode.com/files/Sigil-${the_version}-Code.zip";
|
||||
sha256 = "68c7ca15ea8611921af0c435369563f55c6afd2ef1fb0945cf6c4a47429b0fb5";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
unzip cmake pkgconfig
|
||||
hunspell minizip boost xercesc qt5
|
||||
];
|
||||
|
||||
# XXX: the compiler seems to treat the .h file inappropriately:
|
||||
#
|
||||
# COMMAND ${CMAKE_CXX_COMPILER} ${compile_flags} \
|
||||
# ${CMAKE_CURRENT_SOURCE_DIR}/${header_name}.h \
|
||||
# -o ${header_name}.h.gch
|
||||
#
|
||||
# but using -c or -x c++-header seems to work:
|
||||
#
|
||||
# COMMAND ${CMAKE_CXX_COMPILER} ${compile_flags} \
|
||||
# -c ${CMAKE_CURRENT_SOURCE_DIR}/${header_name}.h \
|
||||
# -o ${header_name}.h.gch
|
||||
#
|
||||
# COMMAND ${CMAKE_CXX_COMPILER} ${compile_flags} \
|
||||
# -x c++-header ${CMAKE_CURRENT_SOURCE_DIR}/${header_name}.h \
|
||||
# -o ${header_name}.h.gch
|
||||
#
|
||||
# Might be related to:
|
||||
#
|
||||
# http://permalink.gmane.org/gmane.comp.gcc.bugs/361195
|
||||
buildCommand = ''
|
||||
mkdir -pv $out
|
||||
mkdir -pv ${name}/src ${name}/build ${name}/run
|
||||
cd ${name}/src
|
||||
unzip -n ${src}
|
||||
sed -i \
|
||||
-e 's|\(COMMAND\) \([^ ]\+\) \([^ ]\+\) \(.*\)|\1 \2 \3 -c \4|' \
|
||||
cmake_extras/CustomPCH.cmake
|
||||
# sed -i \
|
||||
# -e 's|\(COMMAND\) \([^ ]\+\) \([^ ]\+\) \(.*\)|\1 \2 \3 -x c++-header \4|' \
|
||||
# cmake_extras/CustomPCH.cmake
|
||||
cd ../build
|
||||
cmake -G "Unix Makefiles" \
|
||||
-DCMAKE_INSTALL_PREFIX=$out \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_SKIP_BUILD_RPATH=ON \
|
||||
../src
|
||||
#make VERBOSE=1
|
||||
make
|
||||
make install
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Free, open source, multi-platform ebook (ePub) editor";
|
||||
homepage = https://code.google.com/p/sigil/;
|
||||
license = stdenv.lib.licenses.gpl3;
|
||||
};
|
||||
}
|
|
@ -2211,6 +2211,8 @@ let
|
|||
|
||||
siege = callPackage ../tools/networking/siege {};
|
||||
|
||||
sigil = callPackage ../applications/editors/sigil { };
|
||||
|
||||
silc_client = callPackage ../applications/networking/instant-messengers/silc-client { };
|
||||
|
||||
silc_server = callPackage ../servers/silc-server { };
|
||||
|
|
Loading…
Reference in a new issue