Merge pull request #44651 from jtojnar/gobby

gobby5: fix build
This commit is contained in:
Jan Tojnar 2018-08-12 17:25:07 +02:00 committed by GitHub
commit f496d26247
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 62 additions and 69 deletions

View file

@ -10,8 +10,8 @@ in {
package = mkOption {
type = types.package;
default = pkgs.libinfinity.override { daemon = true; };
defaultText = "pkgs.libinfinity.override { daemon = true; }";
default = pkgs.libinfinity;
defaultText = "pkgs.libinfinity";
description = ''
Package providing infinoted
'';
@ -119,7 +119,7 @@ in {
users.groups = optional (cfg.group == "infinoted")
{ name = "infinoted";
};
systemd.services.infinoted =
{ description = "Gobby Dedicated Server";
@ -129,7 +129,7 @@ in {
serviceConfig = {
Type = "simple";
Restart = "always";
ExecStart = "${cfg.package}/bin/infinoted-${versions.majorMinor cfg.package.version} --config-file=/var/lib/infinoted/infinoted.conf";
ExecStart = "${cfg.package.infinoted} --config-file=/var/lib/infinoted/infinoted.conf";
User = cfg.user;
Group = cfg.group;
PermissionsStartOnly = true;

View file

@ -1,26 +1,22 @@
{ avahiSupport ? false # build support for Avahi in libinfinity
, gnomeSupport ? false # build support for Gnome(gnome-vfs)
, stdenv, fetchurl, pkgconfig
, gtkmm2, gsasl, gtksourceview, libxmlxx, libinfinity, intltool
, gnome_vfs ? null}:
, stdenv, fetchurl, fetchFromGitHub, autoconf, automake, pkgconfig, wrapGAppsHook
, gtkmm3, gsasl, gtksourceview3, libxmlxx, libinfinity, intltool, itstool, gnome3 }:
let
libinf = libinfinity.override { gtkWidgets = true; inherit avahiSupport; };
in stdenv.mkDerivation rec {
name = "gobby-0.5.0";
src = fetchurl {
url = "http://releases.0x539.de/gobby/${name}.tar.gz";
sha256 = "165x0r668ma5blziisvbr8qig3jw9hf7i6w8r7wwvz3wsac3bswc";
name = "gobby-unstable-2018-04-03";
src = fetchFromGitHub {
owner = "gobby";
repo = "gobby";
rev = "ea4df27c9b6b885434797b0071ce198b23f9f63b";
sha256 = "0q7lq64yn16lxvj4jphs8y9194h0xppj8k7y9x8b276krraak2az";
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ gtkmm2 gsasl gtksourceview libxmlxx libinf intltool ]
++ stdenv.lib.optional gnomeSupport gnome_vfs;
configureFlags = ''
'';
nativeBuildInputs = [ autoconf automake pkgconfig intltool itstool gnome3.yelp-tools wrapGAppsHook ];
buildInputs = [ gtkmm3 gsasl gtksourceview3 libxmlxx libinf ];
preConfigure = "./autogen.sh";
meta = with stdenv.lib; {
homepage = http://gobby.0x539.de/;

View file

@ -1,52 +1,53 @@
{ gtkWidgets ? false # build GTK widgets for libinfinity
, daemon ? false # build infinote daemon
, documentation ? false # build documentation
, avahiSupport ? false # build support for Avahi in libinfinity
, stdenv, fetchurl, pkgconfig, glib, libxml2, gnutls, gsasl
, gtk2 ? null, gtkdoc ? null, avahi ? null, libdaemon ? null, libidn, gss
, gobjectIntrospection
, gtk3 ? null, gtk-doc, docbook_xsl, docbook_xml_dtd_412, avahi ? null, libdaemon, libidn, gss
, libintl }:
assert avahiSupport -> avahi != null;
assert gtkWidgets -> gtk3 != null;
let
edf = flag: feature: (if flag then "--with-" else "--without-") + feature;
optional = cond: elem: assert cond -> elem != null; if cond then [elem] else [];
mkFlag = flag: feature: (if flag then "--with-" else "--without-") + feature;
in stdenv.mkDerivation rec {
self = stdenv.mkDerivation rec {
name = "libinfinity-${version}";
version = "0.7.1";
src = fetchurl {
url = "http://releases.0x539.de/libinfinity/${name}.tar.gz";
sha256 = "1jw2fhrcbpyz99bij07iyhy9ffyqdn87vl8cb1qz897y3f2f0vk2";
};
name = "libinfinity-${version}";
version = "0.7.1";
src = fetchurl {
url = "http://releases.0x539.de/libinfinity/${name}.tar.gz";
sha256 = "1jw2fhrcbpyz99bij07iyhy9ffyqdn87vl8cb1qz897y3f2f0vk2";
outputs = [ "bin" "out" "dev" "man" "devdoc" ];
nativeBuildInputs = [ pkgconfig gtk-doc docbook_xsl docbook_xml_dtd_412 gobjectIntrospection ];
buildInputs = [ glib libxml2 gsasl libidn gss libintl libdaemon ]
++ stdenv.lib.optional gtkWidgets gtk3
++ stdenv.lib.optional avahiSupport avahi;
propagatedBuildInputs = [ gnutls ];
configureFlags = [
"--enable-gtk-doc"
"--enable-introspection"
(mkFlag gtkWidgets "inftextgtk")
(mkFlag gtkWidgets "infgtk")
"--with-infinoted"
"--with-libdaemon"
(mkFlag avahiSupport "avahi")
];
passthru = {
infinoted = "${self.bin}/bin/infinoted-${stdenv.lib.versions.majorMinor version}";
};
meta = {
homepage = http://gobby.0x539.de/;
description = "An implementation of the Infinote protocol written in GObject-based C";
license = stdenv.lib.licenses.lgpl2Plus;
maintainers = [ stdenv.lib.maintainers.phreedom ];
platforms = with stdenv.lib.platforms; linux ++ darwin;
};
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ glib libxml2 gsasl libidn gss libintl ]
++ optional gtkWidgets gtk2
++ optional documentation gtkdoc
++ optional avahiSupport avahi
++ optional daemon libdaemon;
propagatedBuildInputs = [ gnutls ];
configureFlags = ''
${if documentation then "--enable-gtk-doc" else "--disable-gtk-doc"}
${edf gtkWidgets "inftextgtk"}
${edf gtkWidgets "infgtk"}
${edf daemon "infinoted"}
${edf daemon "libdaemon"}
${edf avahiSupport "avahi"}
'';
passthru = {
inherit version;
};
meta = {
homepage = http://gobby.0x539.de/;
description = "An implementation of the Infinote protocol written in GObject-based C";
license = stdenv.lib.licenses.lgpl2Plus;
maintainers = [ stdenv.lib.maintainers.phreedom ];
platforms = with stdenv.lib.platforms; linux ++ darwin;
};
}
in self

View file

@ -10514,9 +10514,7 @@ with pkgs;
libiec61883 = callPackage ../development/libraries/libiec61883 { };
libinfinity = callPackage ../development/libraries/libinfinity {
inherit (gnome2) gtkdoc;
};
libinfinity = callPackage ../development/libraries/libinfinity { };
libinput = callPackage ../development/libraries/libinput {
graphviz = graphviz-nox;
@ -16512,9 +16510,7 @@ with pkgs;
gocr = callPackage ../applications/graphics/gocr { };
gobby5 = callPackage ../applications/editors/gobby {
inherit (gnome2) gtksourceview;
};
gobby5 = callPackage ../applications/editors/gobby { };
gphoto2 = callPackage ../applications/misc/gphoto2 { };