diff --git a/pkgs/applications/science/electronics/gerbv/default.nix b/pkgs/applications/science/electronics/gerbv/default.nix index 0c45184e31c7..a8eb0ac4c082 100644 --- a/pkgs/applications/science/electronics/gerbv/default.nix +++ b/pkgs/applications/science/electronics/gerbv/default.nix @@ -1,34 +1,29 @@ -{ lib, stdenv, fetchurl, fetchpatch, pkg-config, gettext, libtool, automake, autoconf, cairo, gtk2-x11, autoreconfHook }: +{ lib, stdenv, fetchFromGitHub, pkg-config, gettext, libtool, automake, autoconf, cairo, gtk2-x11, autoreconfHook }: stdenv.mkDerivation rec { pname = "gerbv"; - version = "2.7.0"; + version = "2.9.6"; - src = fetchurl { - url = "mirror://sourceforge/gerbv/${pname}-${version}.tar.gz"; - sha256 = "sha256-xe6AjEIwzmvjrRCrY8VHCYOG1DAicE3iXduTeOYgU7Q="; + src = fetchFromGitHub { + owner = "gerbv"; + repo = pname; + rev = "v${version}"; + hash = "sha256-HNhrnXOBlzfO/roWzTsg0RcJPb0c7RuJepankB5zNts="; }; - patches = [ - # Pull patch pending upstream inclusion for -fno-common toolchains: - # https://sourceforge.net/p/gerbv/patches/84/ - (fetchpatch { - name = "fnoc-mmon.patch"; - url = "https://sourceforge.net/p/gerbv/patches/84/attachment/0001-gerbv-fix-build-on-gcc-10-fno-common.patch"; - sha256 = "1avfbkqhxl7wxn1z19y30ilkwvdgpdkzhzawrs5y3damxmqq8ggk"; - }) - ]; + postPatch = '' + sed -i '/AC_INIT/s/m4_esyscmd.*/${version}])/' configure.ac + ''; nativeBuildInputs = [ autoreconfHook pkg-config automake autoconf ]; buildInputs = [ gettext libtool cairo gtk2-x11 ]; configureFlags = ["--disable-update-desktop-database"]; - env.NIX_CFLAGS_COMPILE = "-Wno-format-security"; - meta = with lib; { description = "A Gerber (RS-274X) viewer"; - homepage = "http://gerbv.geda-project.org/"; + homepage = "https://gerbv.github.io/"; + changelog = "https://github.com/gerbv/gerbv/releases/tag/v${version}"; maintainers = with maintainers; [ mog ]; platforms = platforms.unix; license = licenses.gpl2; diff --git a/pkgs/tools/misc/pcb2gcode/default.nix b/pkgs/tools/misc/pcb2gcode/default.nix index 9079817d9eb8..7d371cc6e183 100644 --- a/pkgs/tools/misc/pcb2gcode/default.nix +++ b/pkgs/tools/misc/pcb2gcode/default.nix @@ -9,29 +9,19 @@ , gerbv , librsvg , bash -, fetchpatch }: stdenv.mkDerivation rec { pname = "pcb2gcode"; - version = "2.4.0"; + version = "2.5.0"; src = fetchFromGitHub { owner = "pcb2gcode"; repo = "pcb2gcode"; rev = "v${version}"; - sha256 = "sha256-3VQlYtSi6yWWNuxTlBzvBtkM5hAss47xat+sEW+P79E="; + hash = "sha256-c5YabBqZn6ilIkF3lifTsYyLZMsZN21jDj1hNu0PRAc="; }; - patches = [ - # the patch below is part of upstream mainline, we can remove this - # when they make their next release - (fetchpatch { - url = "https://github.com/pcb2gcode/pcb2gcode/commit/01cd18a6d859ab1aac6c532c99be9109f083448d.patch"; - sha256 = "sha256-5hl8KsDxSWMzXS3oRG0fBfHFq0IpZ//sU8lfY9Yp8L0="; - }) - ]; - nativeBuildInputs = [ autoreconfHook pkg-config ]; buildInputs = [ boost glibmm gtkmm2 gerbv librsvg ];