From f81fe9d978c2b4eeea8cf628cebccdf57fb40060 Mon Sep 17 00:00:00 2001 From: makefu Date: Sat, 9 Jun 2018 01:35:34 +0200 Subject: [PATCH 1/3] uhub: re-enable sqlite plugin --- pkgs/servers/uhub/default.nix | 1 + pkgs/servers/uhub/plugin-dir.patch | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/pkgs/servers/uhub/default.nix b/pkgs/servers/uhub/default.nix index 87d0a0ee4553..297e064d7caf 100644 --- a/pkgs/servers/uhub/default.nix +++ b/pkgs/servers/uhub/default.nix @@ -20,6 +20,7 @@ stdenv.mkDerivation rec { "mod_welcome" "mod_logging" "mod_auth_simple" + "mod_auth_sqlite" "mod_chat_history" "mod_chat_only" "mod_topic" diff --git a/pkgs/servers/uhub/plugin-dir.patch b/pkgs/servers/uhub/plugin-dir.patch index 01cbcbb31cf3..d29d600425ff 100644 --- a/pkgs/servers/uhub/plugin-dir.patch +++ b/pkgs/servers/uhub/plugin-dir.patch @@ -7,7 +7,7 @@ - install( TARGETS mod_example mod_welcome mod_logging mod_auth_simple mod_auth_sqlite mod_chat_history mod_chat_history_sqlite mod_chat_only mod_topic mod_no_guest_downloads DESTINATION /usr/lib/uhub/ OPTIONAL ) - install( FILES ${CMAKE_SOURCE_DIR}/doc/uhub.conf ${CMAKE_SOURCE_DIR}/doc/plugins.conf ${CMAKE_SOURCE_DIR}/doc/rules.txt ${CMAKE_SOURCE_DIR}/doc/motd.txt DESTINATION /etc/uhub OPTIONAL ) + -+ set( PLUGINS mod_example mod_welcome mod_logging mod_auth_simple mod_chat_history mod_chat_only mod_topic mod_no_guest_downloads ) ++ set( PLUGINS mod_example mod_welcome mod_logging mod_auth_simple mod_auth_sqlite mod_chat_history mod_chat_only mod_topic mod_no_guest_downloads ) + + foreach( PLUGIN ${PLUGINS} ) + install( TARGETS ${PLUGIN} DESTINATION $ENV{${PLUGIN}} OPTIONAL ) From 92a77c32baa6c0f7cbb12213c27f8961bca9bb67 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 8 Oct 2018 00:53:16 +0200 Subject: [PATCH 2/3] uhub: use official upstream sources the project changed the code repository to github --- pkgs/servers/uhub/default.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pkgs/servers/uhub/default.nix b/pkgs/servers/uhub/default.nix index 297e064d7caf..456f73dc52ed 100644 --- a/pkgs/servers/uhub/default.nix +++ b/pkgs/servers/uhub/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, cmake, openssl, sqlite, pkgconfig, systemd +{ stdenv, fetchurl, fetchFromGitHub, cmake, openssl, sqlite, pkgconfig, systemd , tlsSupport ? false }: assert tlsSupport -> openssl != null; @@ -7,9 +7,11 @@ stdenv.mkDerivation rec { name = "uhub-${version}"; version = "0.5.0"; - src = fetchurl { - url = "https://www.extatic.org/downloads/uhub/uhub-${version}-src.tar.bz2"; - sha256 = "1xcqjz20lxikzn96f4f69mqyl9y985h9g0gyc9f7ckj18q22b5j5"; + src = fetchFromGitHub { + owner = "janvidar"; + repo = "uhub"; + rev = version; + sha256 = "0zdbxfvw7apmfhqgsfkfp4pn9iflzwdn0zwvzymm5inswfc00pxg"; }; nativeBuildInputs = [ pkgconfig ]; From d74ea280d1cdd630642da22230b4eb9391392e03 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 8 Oct 2018 00:54:00 +0200 Subject: [PATCH 3/3] uhub: fix build for aarch64 related: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=770175 related: https://github.com/janvidar/uhub/issues/46 --- pkgs/servers/uhub/default.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/pkgs/servers/uhub/default.nix b/pkgs/servers/uhub/default.nix index 456f73dc52ed..52866784faa9 100644 --- a/pkgs/servers/uhub/default.nix +++ b/pkgs/servers/uhub/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchurl, fetchFromGitHub, cmake, openssl, sqlite, pkgconfig, systemd +{ stdenv, fetchpatch, fetchFromGitHub, cmake, openssl, sqlite, pkgconfig, systemd , tlsSupport ? false }: assert tlsSupport -> openssl != null; @@ -31,9 +31,14 @@ stdenv.mkDerivation rec { patches = [ ./plugin-dir.patch + # fix aarch64 build: https://github.com/janvidar/uhub/issues/46 + (fetchpatch { + url = "https://github.com/janvidar/uhub/pull/47.patch"; + sha256 = "07yik6za89ar5bxm7m2183i7f6hfbawbxvd4vs02n1zr2fgfxmiq"; + }) # Fixed compilation on systemd > 210 - (fetchurl { + (fetchpatch { url = "https://github.com/janvidar/uhub/commit/70f2a43f676cdda5961950a8d9a21e12d34993f8.diff"; sha256 = "1jp8fvw6f9jh0sdjml9mahkk6p6b96p6rzg2y601mnnbcdj8y8xp"; })