From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id MGcgAm+96WMKpAAAbAwnHQ (envelope-from ) for ; Mon, 13 Feb 2023 05:32:47 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id mAInAm+96WNqSgEAauVa8A (envelope-from ) for ; Mon, 13 Feb 2023 05:32:47 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id BE9D4153AB for ; Mon, 13 Feb 2023 05:32:46 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pRQVg-0003tM-Fi; Sun, 12 Feb 2023 23:32:12 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRQVX-0003oi-AC for guix-patches@gnu.org; Sun, 12 Feb 2023 23:32:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pRQVX-0006d6-1Y for guix-patches@gnu.org; Sun, 12 Feb 2023 23:32:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pRQVW-0000g8-Gl for guix-patches@gnu.org; Sun, 12 Feb 2023 23:32:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#61207] [PATCH v2] gnu: Add opentaxsolver. Resent-From: Skylar Hill Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 13 Feb 2023 04:32:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 61207 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Nicolas Goaziou Cc: dev@jpoiret.xyz, 61207@debbugs.gnu.org X-Debbugs-Original-Cc: Josselin Poiret , 61207@debbugs.gnu.org, Josselin Poiret via Guix-patches via Received: via spool by submit@debbugs.gnu.org id=B.16762627082562 (code B ref -1); Mon, 13 Feb 2023 04:32:02 +0000 Received: (at submit) by debbugs.gnu.org; 13 Feb 2023 04:31:48 +0000 Received: from localhost ([127.0.0.1]:47329 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pRQVG-0000fD-0U for submit@debbugs.gnu.org; Sun, 12 Feb 2023 23:31:48 -0500 Received: from lists.gnu.org ([209.51.188.17]:56284) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pRP69-0006QQ-Bt for submit@debbugs.gnu.org; Sun, 12 Feb 2023 22:01:46 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRP69-0002Y0-67 for guix-patches@gnu.org; Sun, 12 Feb 2023 22:01:45 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pRP66-0008SA-Ih for guix-patches@gnu.org; Sun, 12 Feb 2023 22:01:44 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id BB6A5240178 for ; Mon, 13 Feb 2023 04:01:39 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1676257299; bh=Z/hqYR+Z9aI6wtH0EAWVg+4thEWGRSQv8BDCw7sFWCs=; h=From:To:Cc:Subject:Date:From; b=TlnsyxpqJw0Cz7tUMhhnIrXZOm6UrqmQGi6vA6dipIBJKXOSGt0D94cyK4BpE6jIP VvP0G+lGZ344GyvUx/F0VbV3Jm8sSeUlngB0P5uM4qNxnAY3+RLbFFsXqCmDdLf6CN gCYXPe5KWiXbJKkIzIWZ9MEE4+eBceNRlmpj/+gyYV5oMzfz9xRUtsSMCGWP4Z4/lP 19/MX8l8gNEQucSp9rvdhKhbuy5aqT5lM55sBZA9nGzhrhkSuVMjPxBlRzaRCMub/H 2emocKxWECOvhb5lDuDlIi9w7NnlF2tVpAxUBuR48opwY23opsoiCoHMcTn3+z5Shx lb5yc4aya93JQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4PFTdF5pqTz6trS; Mon, 13 Feb 2023 04:01:34 +0100 (CET) From: Skylar Hill References: <87edr6x169.fsf@jpoiret.xyz> <87mt5jsvt6.fsf@nicolasgoaziou.fr> Date: Mon, 13 Feb 2023 03:01:22 +0000 In-Reply-To: <87mt5jsvt6.fsf@nicolasgoaziou.fr> (Nicolas Goaziou's message of "Sat, 11 Feb 2023 23:07:22 +0100") Message-ID: <87mt5iz2t9.fsf@posteo.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=185.67.36.66; envelope-from=stellarskylark@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Sun, 12 Feb 2023 23:31:45 -0500 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1676262766; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=iKGyTMO5EwuJyUMrdYcPwCwL+uCrRxcREVe/bB1lk0Q=; b=YCP9XupmsxDE9HGzrVPk2q4wtGPoCu8eA0eaAlB6Vu428EZ27Uv5RMlSOvSOH1oT2nmahg 8VrpNFhc2T7S0BTSDtX2DFivTFvIkd4/cg4FP4KGedQv1lPZLE92trF1arAPL/RxdgVLdK cV/Aoue4URqTiA4WGl35D9WkB51dJU/HlH1bp7BbjaZT/tKaettdrSI1YWvrtQJh2f0zkb rAULT5Ry6aLTtnPYK3MMAeUSSX5mqWr1kEPsf3dTiWEaheFNRbg3hfrtZi78JHRea3D+nY sYXLOuq+21vyEMUWxhF/Fb5z5ccQp6pr76jx954QNP7D/m1ecgt+5F9akAa+RA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=Tlnsyxpq; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1676262766; a=rsa-sha256; cv=none; b=iXB8Rxr2U9BeU5I6F6kZ8iHOs/Y/9BrUTSttvytSNrK+qVMfKON265wsrXoxhiIqDK08a/ dZZKcHfC+n3fJxzyJR0D2gbNn1gpZOtx+6lfuUPM7QbIZbUn41mOkf/UdfLPxnanZqSVkw 3nKiFphLH42q7MOYeAKaOx1n2h2oCN/3uVxjzPpYjaFNj/J+M2ECuGWfZOdh0UkNIEcVFF pKwdydTlMsHTD9mVZXVeTIdyYA3DR3wrQpyfrJsd1Mh2f29YYCiWhI7xBumhnJi647hUtL VWj3U1GhIfM3bsSfg7HrsDSIGnGkWiB2MlB70fwfZSUAyk8ioCI/0gIZ0EzCrw== X-Migadu-Scanner: scn1.migadu.com X-Migadu-Spam-Score: 6.98 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=posteo.net header.s=2017 header.b=Tlnsyxpq; dmarc=fail reason="SPF not aligned (strict)" header.from=posteo.net (policy=none); spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: BE9D4153AB X-Spam-Score: 6.98 X-TUID: zz77SdLdTdok --=-=-= Content-Type: text/plain Thanks, y'all! I've attached a patch that addresses everything Nicolas brought up. > I agree with Josselin. Licensing is unclear. Many files do not have > a license, or are "user contributed" (under what terms?). > > Would it be possible to clarify this with upstream? I got a hold of Aston Roberts , the maintainer for OTS, and asked him about the licensing for files without headers. (The tax templates, in particular, seem to lack headers because the custom markup doesn't appear to have comment syntax.) He answered: > Yes, all files of OTS are released under GNU GPL license. > Will review the file headers. So it looks like all the files, even the ones without a clear license header, are GPL. Skylar --=-=-= Content-Type: text/plain; charset=utf-8 Content-Disposition: inline; filename=v3-0001-gnu-Add-opentaxsolver.patch Content-Transfer-Encoding: quoted-printable Content-Description: Patch version three >From f5f2b8b4539d48b474b131ece87b65dbfd9b2532 Mon Sep 17 00:00:00 2001 From: Skylar Hill Date: Sun, 12 Feb 2023 20:47:23 -0600 Subject: [PATCH v3] gnu: Add opentaxsolver --- gnu/local.mk | 1 + gnu/packages/finance.scm | 71 +++++++++++++++++++ .../opentaxsolver-file-browser-fix.patch | 58 +++++++++++++++ 3 files changed, 130 insertions(+) create mode 100644 gnu/packages/patches/opentaxsolver-file-browser-fix.pat= ch diff --git a/gnu/local.mk b/gnu/local.mk index cdb99813d0..148bd6e908 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1616,6 +1616,7 @@ dist_patch_DATA =3D \ %D%/packages/patches/opensles-add-license-file.patch \ %D%/packages/patches/openssl-1.1-c-rehash-in.patch \ %D%/packages/patches/openssl-3.0-c-rehash-in.patch \ + %D%/packages/patches/opentaxsolver-file-browser-fix.patch \ %D%/packages/patches/open-zwave-hidapi.patch \ %D%/packages/patches/orpheus-cast-errors-and-includes.patch \ %D%/packages/patches/osip-CVE-2017-7853.patch \ diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index c9c8e9b823..252f5e422c 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -33,6 +33,7 @@ ;;; Copyright =C2=A9 2022 Collin J. Doering ;;; Copyright =C2=A9 2022 Justin Veilleux ;;; Copyright =C2=A9 2023 Frank Pursel +;;; Copyright =C2=A9 2023 Skylar Hill ;;; ;;; This file is part of GNU Guix. ;;; @@ -2271,3 +2272,73 @@ (define-public p2pool Monero node and what it mines, but you get frequent payouts like on a regu= lar pool.") (license license:gpl3))) + +(define-public opentaxsolver + ;; The OTS version is formatted like tax-year_version. So, at time of + ;; writing, the version is 2022_20.00. Each part of this is used in + ;; different places in the source uri, so it's convenient to have them + ;; separately like this. + (let ((tax-year "2022") + (ots-version "20.00")) + (package + (name "opentaxsolver") + (version (string-append tax-year "_" ots-version)) + (source (origin + (method url-fetch) + (uri (string-append "mirror://sourceforge/opentaxsolver/OT= S_" + tax-year "/v" ots-version + "_linux/OpenTaxSolver" version "_linux= 64.tgz")) + (sha256 + (base32 + "06k0a72bmwdmr71dvrp8b4vl8vilnggsh92hrp7wjdgcjj9m074w")) + (patches (search-patches + "opentaxsolver-file-browser-fix.patch")))) + (build-system glib-or-gtk-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (delete 'configure) + ;; OTS does provide a shellscript that does exactly + ;; this, but we need to do it ourselves to specify + ;; the correct compiler and to delete the GUI + ;; binaries. + (replace 'build + (lambda _ + (delete-file "Run_taxsolve_GUI") + (delete-file-recursively "bin") + (mkdir "bin") + (chdir "src/Gui_gtk") + (invoke "make" + (string-append "CC=3D" + #$(cc-for-target))) + (chdir "..") + (invoke "make" + (string-append "CC=3D" + #$(cc-for-target))))) + ;; OTS doesn't provide a `make install` target, + ;; because it assumes it'll be run from the + ;; tarball. So, we do it ourselves, making sure to + ;; replicate the directory structure of the tarball. + (replace 'install + (lambda _ + (copy-recursively "../bin" + (string-append #$output "/bin")) + (symlink (string-append #$output "/bin/ots_gui2") + (string-append #$output "/bin/Run_taxsolve_GUI")) + (copy-recursively "../tax_form_files" + (string-append #$output + "/tax_form_files")) + (copy-recursively "formdata" + (string-append #$output + "/src/formdata"))))) + #:tests? #f)) + (inputs (list gtk+-2)) + (native-inputs (list pkg-config)) + (synopsis "Yearly tax preparation tool") + (description + "OpenTaxSolver is a program for calculating tax form entries for fe= deral and +state personal income taxes. It automatically fills out and prints your fo= rms +for mailing.") + (home-page "https://opentaxsolver.sourceforge.net/") + (license license:gpl2+)))) diff --git a/gnu/packages/patches/opentaxsolver-file-browser-fix.patch b/gn= u/packages/patches/opentaxsolver-file-browser-fix.patch new file mode 100644 index 0000000000..0e6be74f85 --- /dev/null +++ b/gnu/packages/patches/opentaxsolver-file-browser-fix.patch @@ -0,0 +1,58 @@ +From 96fda11a53a89c6647031f2c05ef12f1a9df6a08 Mon Sep 17 00:00:00 2001 +From: Skylar Hill +Date: Tue, 31 Jan 2023 21:02:18 -0600 +Subject: [PATCH] Change default directory in file browser + +--- + src/Gui_gtk/ots_gui2.c | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +diff --git a/src/Gui_gtk/ots_gui2.c b/src/Gui_gtk/ots_gui2.c +index ff3366b..1247933 100644 +--- a/src/Gui_gtk/ots_gui2.c ++++ b/src/Gui_gtk/ots_gui2.c +@@ -82,6 +82,7 @@ char ots_release_package[]=3D"20.00"; + #include + #include + #include ++#include + #include + // #include "backcompat.c" + #include "gtk_utils.c" /* Include the graphics library. */ +@@ -109,6 +110,7 @@ char toolpath[MaxFname]=3D"", *start_cmd; + int pending_compute=3D0, supported_pdf_form=3D1; + int filingstatus_mfj=3D1; + int round_to_whole_nums=3D0; ++char *working_dir[MaxFname+512]; +=20 + void pick_file( GtkWidget *wdg, void *data ); /* Prototype */ + void consume_leading_trailing_whitespace( char *line ); +@@ -2364,7 +2366,7 @@ void save_taxfile( GtkWidget *wdg, void *data ) + if (cpt !=3D 0) + strcpy( cpt, "_xxxx.txt" ); + // printf("OTS_save_taxfile: dir=3D'%s', wc=3D'%s', fname=3D'%s'\n", dir= ectory_dat, wildcards_fb, filename_fb ); +- Browse_Files( "File to Save As:", 2048, directory_dat, wildcards_fb, fil= ename_fb, Save_Tax_File ); ++ Browse_Files( "File to Save As:", 2048, working_dir, wildcards_fb, filen= ame_fb, Save_Tax_File ); + } +=20 +=20 +@@ -3878,7 +3880,7 @@ void pick_file( GtkWidget *wdg, void *data ) + strcpy( wildcards_fb, ".txt" ); + strcpy( filename_fb, "" ); + // printf("OTS_pick_file: dir=3D'%s', wc=3D'%s', fname=3D'%s'\n", direc= tory_dat, wildcards_fb, filename_fb ); +- Browse_Files( "Select File", 2048, directory_dat, wildcards_fb, filenam= e_fb, receive_filename ); ++ Browse_Files( "Select File", 2048, working_dir, wildcards_fb, filename_= fb, receive_filename ); + } +=20 +=20 +@@ -4019,6 +4021,7 @@ int main(int argc, char *argv[] ) + invocation_path[k] =3D '\0'; + // printf("Invocation path =3D '%s'\n", invocation_path); + set_ots_path(); ++ getcwd(working_dir, MaxFname+512); +=20 + /* Decode any command-line arguments. */ + argn =3D 1; k=3D1; +--=20 +2.38.1 + --=20 2.39.1 --=-=-=--