From 06a65dd592a62663b15547796b6f11fddb205b31 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:03:32 +0200 Subject: ma 5pkgs: cleanup --- makefu/5pkgs/alsa-tools/default.nix | 26 ----------- makefu/5pkgs/custom/alsa-tools/default.nix | 26 +++++++++++ makefu/5pkgs/custom/default.nix | 3 ++ makefu/5pkgs/custom/qcma/default.nix | 65 +++++++++++++++++++++++++++ makefu/5pkgs/default.nix | 11 ++--- makefu/5pkgs/dionaea/default.nix | 50 +++++++++++++++++++++ makefu/5pkgs/farpd/default.nix | 2 +- makefu/5pkgs/libopencm3/default.nix | 30 +++++++++++++ makefu/5pkgs/logstash-output-exec/default.nix | 32 +++++++++++++ makefu/5pkgs/mcomix/default.nix | 20 +++++++++ makefu/5pkgs/minibar/default.nix | 12 +++++ makefu/5pkgs/nltk/default.nix | 17 +++++++ makefu/5pkgs/novnc/default.nix | 1 - makefu/5pkgs/programs-db/default.nix | 12 +++++ makefu/5pkgs/qcma/default.nix | 64 -------------------------- 15 files changed, 274 insertions(+), 97 deletions(-) delete mode 100644 makefu/5pkgs/alsa-tools/default.nix create mode 100644 makefu/5pkgs/custom/alsa-tools/default.nix create mode 100644 makefu/5pkgs/custom/default.nix create mode 100644 makefu/5pkgs/custom/qcma/default.nix create mode 100644 makefu/5pkgs/dionaea/default.nix create mode 100644 makefu/5pkgs/libopencm3/default.nix create mode 100644 makefu/5pkgs/logstash-output-exec/default.nix create mode 100644 makefu/5pkgs/mcomix/default.nix create mode 100644 makefu/5pkgs/minibar/default.nix create mode 100644 makefu/5pkgs/nltk/default.nix create mode 100644 makefu/5pkgs/programs-db/default.nix delete mode 100644 makefu/5pkgs/qcma/default.nix diff --git a/makefu/5pkgs/alsa-tools/default.nix b/makefu/5pkgs/alsa-tools/default.nix deleted file mode 100644 index 5134c10ec..000000000 --- a/makefu/5pkgs/alsa-tools/default.nix +++ /dev/null @@ -1,26 +0,0 @@ -{stdenv,alsaToolTarget,fetchurl, alsaLib, ncurses, fltk13, gtk3}: - -stdenv.mkDerivation rec { - name = "alsa-${alsaToolTarget}-${version}"; - alsaToolsName = "alsa-tools-${version}"; - version = "1.0.29"; - - src = fetchurl { - urls = [ - "ftp://ftp.alsa-project.org/pub/tools/${alsaToolsName}.tar.bz2" - "http://alsa.cybermirror.org/tools/${alsaToolsName}.tar.bz2" - - ]; - sha256 = "1lgvyb81md25s9ciswpdsbibmx9s030kvyylf0673w3kbamz1awl"; - }; - sourceRoot = "${alsaToolsName}/${alsaToolTarget}/"; - buildInputs = [ alsaLib fltk13 gtk3 ncurses ]; - - meta = { - homepage = http://www.alsa-project.org/; - description = "ALSA tools - ${name}"; - - platforms = stdenv.lib.platforms.linux; - maintainers = [ stdenv.lib.maintainers.makefu ]; - }; -} diff --git a/makefu/5pkgs/custom/alsa-tools/default.nix b/makefu/5pkgs/custom/alsa-tools/default.nix new file mode 100644 index 000000000..5134c10ec --- /dev/null +++ b/makefu/5pkgs/custom/alsa-tools/default.nix @@ -0,0 +1,26 @@ +{stdenv,alsaToolTarget,fetchurl, alsaLib, ncurses, fltk13, gtk3}: + +stdenv.mkDerivation rec { + name = "alsa-${alsaToolTarget}-${version}"; + alsaToolsName = "alsa-tools-${version}"; + version = "1.0.29"; + + src = fetchurl { + urls = [ + "ftp://ftp.alsa-project.org/pub/tools/${alsaToolsName}.tar.bz2" + "http://alsa.cybermirror.org/tools/${alsaToolsName}.tar.bz2" + + ]; + sha256 = "1lgvyb81md25s9ciswpdsbibmx9s030kvyylf0673w3kbamz1awl"; + }; + sourceRoot = "${alsaToolsName}/${alsaToolTarget}/"; + buildInputs = [ alsaLib fltk13 gtk3 ncurses ]; + + meta = { + homepage = http://www.alsa-project.org/; + description = "ALSA tools - ${name}"; + + platforms = stdenv.lib.platforms.linux; + maintainers = [ stdenv.lib.maintainers.makefu ]; + }; +} diff --git a/makefu/5pkgs/custom/default.nix b/makefu/5pkgs/custom/default.nix new file mode 100644 index 000000000..626938cdc --- /dev/null +++ b/makefu/5pkgs/custom/default.nix @@ -0,0 +1,3 @@ +{}: +{ +} diff --git a/makefu/5pkgs/custom/qcma/default.nix b/makefu/5pkgs/custom/qcma/default.nix new file mode 100644 index 000000000..d67cda142 --- /dev/null +++ b/makefu/5pkgs/custom/qcma/default.nix @@ -0,0 +1,65 @@ +{ lib, stdenv, fetchFromGitHub, fetchgit, libusb, libtool, autoconf, pkgconfig, git, +gettext, automake, libxml2 , qmake, +qtbase, qttools, qtmultimedia, libnotify, ffmpeg, gdk_pixbuf }: +let + libvitamtp = stdenv.mkDerivation rec { + name = "libvitamtp-${version}"; + version = "2.5.9"; + + src = fetchFromGitHub { + owner = "codestation"; + repo = "vitamtp"; + rev = "v"+version; + sha256 = "09c9f7gqpyicfpnhrfb4r67s2hci6hh31bzmqlpds4fywv5mzaf8"; + }; + + buildInputs = [ libusb libxml2 libtool autoconf automake gettext pkgconfig ]; + preConfigure = "sh ./autogen.sh"; + + meta = { + description = "Content Manager Assistant for the PS Vita"; + homepage = https://github.com/codestation/qcma; + license = stdenv.lib.licenses.gpl2; + platforms = stdenv.lib.platforms.linux; + maintainers = with stdenv.lib.maintainers; [ makefu ]; + }; + }; +in stdenv.mkDerivation rec { + name = "qcma-${version}"; + version = "0.3.13"; + + src = fetchgit { + url = "git://github.com/codestation/qcma.git"; + rev = "refs/tags/v"+version; + leaveDotGit = true; + sha256 = "164abjwlw2nw2i30wlwpsavz1zjkp6a14yprvinma5hflkw4yj6i"; + }; + + preConfigure = '' + lrelease common/resources/translations/*.ts + ''; + + # TODO: manually adding qtbase and qtmultimedia to the library path is shit, + # this should be done somewhere before when building the project, idk. + installPhase = '' + make INSTALL_ROOT="$(out)" install + for i in qcma qcma_cli; do + wrapQtProgram $out/bin/$i --prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ + qtbase qtmultimedia ]} + done + ''; + + enableParallelBuilding = true; + + buildInputs = [ gdk_pixbuf ffmpeg libnotify libvitamtp git qtmultimedia qtbase ]; + nativeBuildInputs = [ qmake qttools pkgconfig ]; + + meta = { + description = "Content Manager Assistant for the PS Vita"; + homepage = https://github.com/codestation/qcma; + license = stdenv.lib.licenses.gpl2; + platforms = stdenv.lib.platforms.linux; + broken = true; + maintainers = with stdenv.lib.maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/default.nix b/makefu/5pkgs/default.nix index bb776ef25..6070fc096 100644 --- a/makefu/5pkgs/default.nix +++ b/makefu/5pkgs/default.nix @@ -20,13 +20,14 @@ self: super: let (filterAttrs (_: eq "directory") (readDir path)); in { - alsa-hdspconf = callPackage ./alsa-tools { alsaToolTarget="hdspconf";}; - alsa-hdspmixer = callPackage ./alsa-tools { alsaToolTarget="hdspmixer";}; - alsa-hdsploader = callPackage ./alsa-tools { alsaToolTarget="hdsploader";}; + alsa-hdspconf = callPackage ./custom/alsa-tools { alsaToolTarget="hdspconf";}; + alsa-hdspmixer = callPackage ./custom/alsa-tools { alsaToolTarget="hdspmixer";}; + alsa-hdsploader = callPackage ./custom/alsa-tools { alsaToolTarget="hdsploader";}; + qcma = super.pkgs.libsForQt5.callPackage ./custom/qcma { }; inherit (callPackage ./devpi {}) devpi-web devpi-server devpi-client; - nodemcu-uploader = callPackage ./nodemcu-uploader {}; + nodemcu-uploader = super.pkgs.callPackage ./nodemcu-uploader {}; pwqgen-ger = callPackage { - wordset-file = pkgs.fetchurl { + wordset-file = super.pkgs.fetchurl { url = https://gist.githubusercontent.com/makefu/b56f5554c9ef03fe6e09878962e6fd8d/raw/1f147efec51325bc9f80c823bad8381d5b7252f6/wordset_4k.c ; sha256 = "18ddzyh11bywrhzdkzvrl7nvgp5gdb4k1s0zxbz2bkhd14vi72bb"; }; diff --git a/makefu/5pkgs/dionaea/default.nix b/makefu/5pkgs/dionaea/default.nix new file mode 100644 index 000000000..fef197c20 --- /dev/null +++ b/makefu/5pkgs/dionaea/default.nix @@ -0,0 +1,50 @@ +{ stdenv, lib, pkgs, fetchurl,fetchFromGitHub, + libpcap, libdnet, libevent, readline, autoconf, automake, libtool, zlib, pcre, + libev, + ... }: +let + liblcfg = stdenv.mkDerivation rec { + name = "liblcfg-${version}"; + version = "750bc90"; + src = fetchFromGitHub { + owner = "ThomasAdam"; + repo = "liblcfg"; + rev = version; + sha256 = "1k3r47p81paw5802jklx9xqbjrxr26pahipxn9nq3177qhxxibkr"; + }; + buildInputs = with pkgs;[ autoconf automake ]; + preConfigure = ''autoreconf -fi''; + sourceRoot = "${name}-src/code"; + }; +in stdenv.mkDerivation rec { + name = "liblcfg-${version}"; + + #version = "1.5c"; #original, does not compile due to libc errors + #src = fetchurl { + # url = "http://www.honeyd.org/uploads/honeyd-${version}.tar.gz"; + # sha256 = "0vcih16fk5pir5ssfil8x79nvi62faw0xvk8s5klnysv111db1ii"; + #}; + + #version = "64d087c"; # honeyd-1.6.7 + # sha256 = "0zhnn13r24y1q494xcfx64vyp84zqk8qmsl41fq2674230bn0p31"; + + version = "6756787f94c4f1ac53d1e5545d052774a0446c04"; + src = fetchFromGitHub { + owner = "rep"; + repo = "dionaea"; + rev = version; + sha256 = "04zjr9b7x0rqwzgb9gfxq6pclb817gz4qaghdl8xa79bqf9vv2p7"; + }; + + buildInputs = with pkgs;[ libtool automake autoconf ]; + configureFlags = [ + "--with-liblcfg=${liblcfg}" + "--with-libpcap=${libpcap}" + ]; + + meta = { + homepage = http://www.honeyd.org/; + description = "virtual Honeypots"; + license = lib.licenses.gpl2; + }; +} diff --git a/makefu/5pkgs/farpd/default.nix b/makefu/5pkgs/farpd/default.nix index d16400016..8dfcee90c 100644 --- a/makefu/5pkgs/farpd/default.nix +++ b/makefu/5pkgs/farpd/default.nix @@ -24,7 +24,7 @@ stdenv.mkDerivation rec { zlib coreutils python - pythonPackages.sqlite3 + pythonPackages.pysqlite ]; patches = [ ( fetchurl { diff --git a/makefu/5pkgs/libopencm3/default.nix b/makefu/5pkgs/libopencm3/default.nix new file mode 100644 index 000000000..ed35fc639 --- /dev/null +++ b/makefu/5pkgs/libopencm3/default.nix @@ -0,0 +1,30 @@ +{ lib, stdenv, fetchFromGitHub, gcc-arm-embedded, python }: +stdenv.mkDerivation rec { + name = "libopencm-${version}"; + version = "2017-04-01"; + + src = fetchFromGitHub { + owner = "libopencm3"; + repo = "libopencm3"; + rev = "383fafc862c0d47f30965f00409d03a328049278"; + sha256 = "0ar67icxl39cf7yb5glx3zd5413vcs7zp1jq0gzv1napvmrv3jv9"; + }; + + buildInputs = [ gcc-arm-embedded python ]; + buildPhase = '' + sed -i 's#/usr/bin/env python#${python}/bin/python#' ./scripts/irq2nvic_h + make + ''; + installPhase = '' + mkdir -p $out + cp -r lib $out/ + ''; + + meta = { + description = "Open Source ARM cortex m microcontroller library"; + homepage = https://github.com/libopencm3/libopencm3; + license = stdenv.lib.licenses.gpl2; + platforms = stdenv.lib.platforms.linux; + maintainers = with stdenv.lib.maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/logstash-output-exec/default.nix b/makefu/5pkgs/logstash-output-exec/default.nix new file mode 100644 index 000000000..d1de851c7 --- /dev/null +++ b/makefu/5pkgs/logstash-output-exec/default.nix @@ -0,0 +1,32 @@ +{ pkgs, stdenv, lib, fetchFromGitHub }: + + +# TODO: requires ftw ruby package +stdenv.mkDerivation rec { + name = "logstash-input-github-${version}"; + version = "3.1.0"; + + src = fetchFromGitHub { + owner = "logstash-plugins"; + repo = "logstash-output-exec"; + rev = "v${version}"; + sha256 = "0ix5w9l6hrbjaymkh7fzymjvpkiias3hs0l77zdpcwdaa6cz53nf"; + }; + + dontBuild = true; + dontPatchELF = true; + dontStrip = true; + dontPatchShebangs = true; + installPhase = '' + mkdir -p $out/logstash + cp -r lib/* $out + ''; + + meta = with lib; { + description = "logstash output plugin"; + homepage = https://github.com/logstash-plugins/logstash-output-exec; + license = stdenv.lib.licenses.asl20; + platforms = stdenv.lib.platforms.unix; + maintainers = with maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/mcomix/default.nix b/makefu/5pkgs/mcomix/default.nix new file mode 100644 index 000000000..a12e2e821 --- /dev/null +++ b/makefu/5pkgs/mcomix/default.nix @@ -0,0 +1,20 @@ +{ pkgs, lib ,python2Packages, fetchurl, gtk3}: +python2Packages.buildPythonPackage rec { + name = "mcomix-${version}"; + version = "1.2.1"; + + src = fetchurl { + url = "mirror://sourceforge/mcomix/${name}.tar.bz2"; + sha256 = "0fzsf9pklhfs1rzwzj64c0v30b74nk94p93h371rpg45qnfiahvy"; + }; + + propagatedBuildInputs = with python2Packages; + [ python2Packages.pygtk gtk3 python2Packages.pillow ]; + + meta = { + homepage = https://github.com/pyload/pyload; + description = "Free and Open Source download manager written in Python"; + license = lib.licenses.gpl3; + maintainers = with lib.maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/minibar/default.nix b/makefu/5pkgs/minibar/default.nix new file mode 100644 index 000000000..384a73261 --- /dev/null +++ b/makefu/5pkgs/minibar/default.nix @@ -0,0 +1,12 @@ +{ lib, pkgs, fetchFromGitHub, ... }: + +with pkgs.python3Packages;buildPythonPackage rec { + name = "minibar-${version}"; + version = "0.5.0"; + src = fetchFromGitHub { + owner = "canassa"; + repo = "minibar"; + rev = "c8ecd61"; + sha256 = "1k718zrjd11rw93nmz2wxvhvsai6lwqfblnwjpmkpnslcdan7641"; + }; +} diff --git a/makefu/5pkgs/nltk/default.nix b/makefu/5pkgs/nltk/default.nix new file mode 100644 index 000000000..b2d88b3fe --- /dev/null +++ b/makefu/5pkgs/nltk/default.nix @@ -0,0 +1,17 @@ +{ lib, pkgs, fetchFromGitHub, ... }: + +with pkgs.pythonPackages;buildPythonPackage rec { + name = "nltk-${version}"; + version = "3.2.1"; + src = pkgs.fetchurl{ + #url = "mirror://pypi/n/${name}.tar.gz"; + url = "https://pypi.python.org/packages/58/85/8fa6f8c488507aab7d6234ce754bbbe61bfeb8382489785e2d764bf8f52a/${name}.tar.gz"; + sha256 = "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"; + + }; + meta = { + homepage = http://nltk.org; + description = "Natural languages Toolkit"; + license = lib.licenses.asl20; + }; +} diff --git a/makefu/5pkgs/novnc/default.nix b/makefu/5pkgs/novnc/default.nix index b1d62248d..7da8e9be1 100644 --- a/makefu/5pkgs/novnc/default.nix +++ b/makefu/5pkgs/novnc/default.nix @@ -13,7 +13,6 @@ stdenv.mkDerivation rec { }; p = stdenv.lib.makeBinPath [ pkgs.nettools pkgs.python27Packages.websockify pkgs.coreutils pkgs.which pkgs.procps ]; - # TODO: propagatedBuildInputs does not seem to work with shell scripts patchPhase = '' sed -i '1aset -efu\nexport PATH=${p}\n' utils/launch.sh ''; diff --git a/makefu/5pkgs/programs-db/default.nix b/makefu/5pkgs/programs-db/default.nix new file mode 100644 index 000000000..f40b1b96e --- /dev/null +++ b/makefu/5pkgs/programs-db/default.nix @@ -0,0 +1,12 @@ +{ stdenv }: + +stdenv.mkDerivation rec { + name = "programs-db"; + src = builtins.fetchTarball https://nixos.org/channels/nixos-unstable/nixexprs.tar.xz ; + + phases = [ "unpackPhase" "installPhase" ]; + installPhase = '' + cp programs.sqlite $out + ''; + +} diff --git a/makefu/5pkgs/qcma/default.nix b/makefu/5pkgs/qcma/default.nix deleted file mode 100644 index 6eb1a971d..000000000 --- a/makefu/5pkgs/qcma/default.nix +++ /dev/null @@ -1,64 +0,0 @@ -{ lib, stdenv, fetchFromGitHub, fetchgit, libusb, libtool, autoconf, pkgconfig, git, -gettext, automake, libxml2 , qmakeHook, makeQtWrapper, -qtbase, qttools, qtmultimedia, libnotify, ffmpeg, gdk_pixbuf }: -let - libvitamtp = stdenv.mkDerivation rec { - name = "libvitamtp-${version}"; - version = "2.5.9"; - - src = fetchFromGitHub { - owner = "codestation"; - repo = "vitamtp"; - rev = "v"+version; - sha256 = "09c9f7gqpyicfpnhrfb4r67s2hci6hh31bzmqlpds4fywv5mzaf8"; - }; - - buildInputs = [ libusb libxml2 libtool autoconf automake gettext pkgconfig ]; - preConfigure = "sh ./autogen.sh"; - - meta = { - description = "Content Manager Assistant for the PS Vita"; - homepage = https://github.com/codestation/qcma; - license = stdenv.lib.licenses.gpl2; - platforms = stdenv.lib.platforms.linux; - maintainers = with stdenv.lib.maintainers; [ makefu ]; - }; - }; -in stdenv.mkDerivation rec { - name = "qcma-${version}"; - version = "0.3.13"; - - src = fetchgit { - url = "git://github.com/codestation/qcma.git"; - rev = "refs/tags/v"+version; - leaveDotGit = true; - sha256 = "164abjwlw2nw2i30wlwpsavz1zjkp6a14yprvinma5hflkw4yj6i"; - }; - - preConfigure = '' - lrelease common/resources/translations/*.ts - ''; - - # TODO: manually adding qtbase and qtmultimedia to the library path is shit, - # this should be done somewhere before when building the project, idk. - installPhase = '' - make INSTALL_ROOT="$(out)" install - for i in qcma qcma_cli; do - wrapQtProgram $out/bin/$i --prefix LD_LIBRARY_PATH : ${lib.makeLibraryPath [ - qtbase qtmultimedia ]} - done - ''; - - enableParallelBuilding = true; - - buildInputs = [ gdk_pixbuf ffmpeg libnotify libvitamtp git qtmultimedia qtbase ]; - nativeBuildInputs = [ qmakeHook qttools pkgconfig makeQtWrapper ]; - - meta = { - description = "Content Manager Assistant for the PS Vita"; - homepage = https://github.com/codestation/qcma; - license = stdenv.lib.licenses.gpl2; - platforms = stdenv.lib.platforms.linux; - maintainers = with stdenv.lib.maintainers; [ makefu ]; - }; -} -- cgit v1.2.3